Component: Injector (AT) (Comms)
Author | Matrix Ltd |
Version | 1.1 (Release) |
Category | Comms |
This inherits from Data Injector Template |
Contents
Injector (AT) component
Comms data injector to replicate basic AT command syntax. The component will record each incoming character until the termination character is received. Once this happens the component will respond by echoing back the received data followed by an "OK" reply.
Examples
GSM Example File GSM Example Example should show the following on the display on the panel and on the hardware.
The AT injector component allows us to simulate the response of the GSM module.
Downloadable macro reference
This component does not contain any downloadable macros
Simulation macro reference
This component inherits simulation macros from Data Injector Template
InitialiseInjector
Sets up the injector ready to receive commands or send data
Parameters
- <- STRING InjectorName
- Name of the console that will be created
- This parameter may be returned back to the caller
Return value
RxByteCount
Returns the number of bytes currently sat in the receive buffer.
Parameters
- This macro has no parameters
Return value
TxByte
Puts a byte onto the comms channel.
Parameters
- BYTE DataByte
Return value
- This call does not return a value
RxByte
Attempt to receive a byte back from the injector
0 - 255 = Valid data
256 = RX timeout no data available
Parameters
- This macro has no parameters
Return value
GetTxConsoleHandle
Gets the handle to the console allowing data displaying on the panel etc.
This call is provided by Data Injector Template
Parameters
- This macro has no parameters
Return value
ChangeState
Changes the state for I2C or SPI type comms where the data bytes along are not enough to go on.
This call is provided by Data Injector Template
Parameters
- BYTE NewState
- Assigns new state, 0=default
Return value
- This call does not return a value
GetRxConsoleHandle
Gets the handle to the console allowing data displaying on the panel etc.
This call is provided by Data Injector Template
Parameters
- This macro has no parameters
Return value
GetConsoleHandle
Gets the handle to the console allowing data displaying on the panel etc.
Parameters
- This macro has no parameters
Return value
Property reference
Circular Buffer Size
This property is of type Unsigned integer and can be referenced with the variable name CircularBufferSize.
Amount of room in the circular buffers before running out of memory.
e.g. max command that can be recorded.
Termination Character
This property is of type Fixed list of ints and can be referenced with the variable name TermChar.
Character that will trigger the AT Injector to automatically switch from recording to repeating.