F´ Flight Software - C/C++ Documentation
A framework for building embedded system applications to NASA flight quality standards.
LinuxI2cDriverStub.cpp
Go to the documentation of this file.
1 // ======================================================================
2 // \title LinuxI2cDriver.cpp
3 // \author tcanham
4 // \brief cpp file for LinuxI2cDriver component implementation class
5 //
6 // \copyright
7 // Copyright 2009-2015, by the California Institute of Technology.
8 // ALL RIGHTS RESERVED. United States Government Sponsorship
9 // acknowledged.
10 //
11 // ======================================================================
12 
14 #include <Fw/FPrimeBasicTypes.hpp>
15 #include "Fw/Types/Assert.hpp"
16 
17 namespace Drv {
18 
19 // ----------------------------------------------------------------------
20 // Construction, initialization, and destruction
21 // ----------------------------------------------------------------------
22 
23 LinuxI2cDriver ::LinuxI2cDriver(const char* const compName) : LinuxI2cDriverComponentBase(compName) {}
24 
26 
27 bool LinuxI2cDriver::open(const char* device) {
28  return true;
29 }
30 
31 // ----------------------------------------------------------------------
32 // Handler implementations for user-defined typed input ports
33 // ----------------------------------------------------------------------
34 
35 // Note this port handler is guarded, so we can make the ioctl call
36 
37 I2cStatus LinuxI2cDriver ::write_handler(const FwIndexType portNum, U32 addr, Fw::Buffer& serBuffer) {
38  return I2cStatus::I2C_OK;
39 }
40 
41 Drv::I2cStatus LinuxI2cDriver ::read_handler(const FwIndexType portNum, U32 addr, Fw::Buffer& serBuffer) {
42  return I2cStatus::I2C_OK;
43 }
44 
45 Drv::I2cStatus LinuxI2cDriver ::writeRead_handler(const FwIndexType portNum,
46  U32 addr,
47  Fw::Buffer& writeBuffer,
48  Fw::Buffer& readBuffer) {
49  return I2cStatus::I2C_OK;
50 }
51 
52 } // end namespace Drv
bool open(const char *device)
LinuxI2cDriver(const char *const compName)
PlatformIndexType FwIndexType
Transaction okay.