10 #ifndef TRANSPORT_SERIALTRANSPORT_SERIALTRANSPORT_H
11 #define TRANSPORT_SERIALTRANSPORT_SERIALTRANSPORT_H 1
13 #ifndef ZFORCECOMMON_H
14 #error Please include "zForceCommon.h" before this file.
313 #define RECEIVEBUFFERSIZE 128
void zForceThread
Typecast to underlying (system) type.
Definition: OsAbstractionLayer.h:20
DLLINTERNAL bool SerialTransport_AddSerialTransportEntry(void)
Internal call to add a SerialTransport to the list of available transports.
ReadWriteThreadStatus
Enum describing the current status of a Read or Write thread.
Definition: Transport.h:21
The main Connection struct.
Definition: Connection.h:66
Struct containing the DataFrame information.
Definition: DataFrame.h:25
The Queue struct.
Definition: Queue.h:25
Struct containing the SerialTransport information.
Definition: SerialTransport.h:27
void(* TransportLost)(Transport *self)
Signals the transport that it has been lost and acts accordingly.
Definition: SerialTransport.h:271
Transport * Base
Base pointer to the immediate base Transport class.
Definition: SerialTransport.h:36
bool(* Write)(Transport *self, DataFrame *payload)
Function pointer to Transport's Write.
Definition: SerialTransport.h:216
bool StopCommunication
Boolean value that indicates that there is no longer any communication. Internal use only.
Definition: SerialTransport.h:280
bool(* Close)(Transport *self)
Close the generic Transport.
Definition: SerialTransport.h:180
volatile bool Terminate
A flag indicating if the Transport Read and Write threads should terminate (true) or not (false).
Definition: SerialTransport.h:75
bool(* EnqueueDataFrame)(Transport *self, DataFrame *dataFrame)
Enqueue given dataframe.
Definition: SerialTransport.h:249
zForceThread * WriteThread
Write Thread pointer.
Definition: SerialTransport.h:111
zForceThread * ReadThread
Read Thread pointer.
Definition: SerialTransport.h:120
char ConnectionString[TRANSPORTPROTOCOL_MaxOptionParameterLength+1]
Connection string.
Definition: SerialTransport.h:66
volatile ReadWriteThreadStatus ReadThreadStatus
Thread is active.
Definition: SerialTransport.h:138
Connection * Connection
Each Transport is linked to one Connection.
Definition: SerialTransport.h:45
volatile ReadWriteThreadStatus WriteThreadStatus
Thread is active.
Definition: SerialTransport.h:129
zForce * zForce
A pointer to the global zForce instance.
Definition: SerialTransport.h:54
Queue * WriteQueue
A pointer to the Write queue used by EnqueueDataFrame.
Definition: SerialTransport.h:84
bool Opening
Transport is in Opening phase.
Definition: SerialTransport.h:102
void(* Destructor)(Transport *self)
Destructor frees all the resources that have been allocated.
Definition: SerialTransport.h:260
bool(* Open)(Transport *self)
Open the generic Transport.
Definition: SerialTransport.h:162
uint64_t(* GetTimeOutValue)(Transport *self)
Function pointer to Transport's GetTimeOutValue.
Definition: SerialTransport.h:229
bool IsOpen
A flag indicating if the Transport is open (true) or not (false).
Definition: SerialTransport.h:93
int FileDescriptor
Instance-specific file descriptor.
Definition: SerialTransport.h:282
Transport struct. This structure represents the base class of all Transport definitions.
Definition: Transport.h:43
Main struct.
Definition: zForce.h:29