Difference between revisions of "Component: Injector (File) (Test Injectors)"
From Flowcode Help
Jump to navigationJump to searchLine 20: | Line 20: | ||
==Detailed description== | ==Detailed description== | ||
+ | |||
+ | |||
Line 38: | Line 40: | ||
==Examples== | ==Examples== | ||
+ | |||
+ | |||
Line 60: | Line 64: | ||
[[File:FileWrite.jpg]] | [[File:FileWrite.jpg]] | ||
− | == | + | ==Macro reference== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" |
Revision as of 14:11, 20 January 2023
Author | Matrix Ltd |
Version | 1.0 |
Category | Test Injectors |
Contents
Injector (File) component
Comms data injector to allow data to be streamed to and from a file during simulation. The component will read data from the incoming file and write data to the outgoing file.
Component Source Code
Please click here for the component source code: FC_Comp_Source_InjectorFile.fcfx
Detailed description
No detailed description exists yet for this component
Examples
Example to log the bytes sent via the UART RS232 component to a file as comma separated decimal numbers. LogToFile Contents of the file in the Flowcode project directory after running the simulation.
Macro reference
UARTBaud | |
- BYTE | Channel |
- BYTE | Rate |
- VOID | Return |
UARTCheckRX | |
- BYTE | Channel |
- BYTE | Return |
UARTInitialise | |
- BYTE | Channel |
- VOID | Return |
SPITransfer | |
Transfer a byte using the SPI bus | |
- BYTE | Channel |
Channel Index: Range 0 - SPI Bus Count - 1 | |
- BYTE | DataOut |
- BYTE | Return |
SPIPrescaler | |
Modify the speed of the SPI bus | |
- BYTE | Channel |
Channel Index: Range 0 - SPI Bus Count - 1 | |
- BYTE | Prescaler |
Range: 0-2 | |
- VOID | Return |
UARTReceive | |
- BYTE | Channel |
- BYTE | Return |
SPIInitialise | |
Initialsie the SPI module ready for communications | |
- BYTE | Channel |
Channel Index: Range 0 - SPI Bus Count - 1 | |
- VOID | Return |
UARTSend | |
- BYTE | Channel |
- BYTE | Data |
- VOID | Return |