Component: SRF (WirelessThings) (SRF) (Wireless)

From Flowcode Help
Revision as of 08:59, 9 June 2025 by Wiki bot (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search
Author MatrixTSL
Version 6.6
Category Wireless


SRF (WirelessThings) component

The SRF is designed for wireless transmission and reception of serial data in an easy to use surface mounted module. It has an on-board balun and chip antenna, which can be detached for applications where an external antenna is required.

Version information

Library Version, Component Version, Date, Author, Info


Detailed description

No detailed description exists yet for this component

Examples

No additional examples







Macro reference

ChangeHWBaud

Fc9-comp-macro.png ChangeHWBaud
Changes the hardware UART baud rate allowing for dynamic speed changes.  
Fc9-u8-icon.png - BYTE NewBaud
0=1200, 1=2400, 2=4800, 3=9600, 4=19200, 5=38400, 6=57600, 7=115200, 8=250000 
Fc9-void-icon.png - VOID Return


ReceiveByteArray

Fc9-comp-macro.png ReceiveByteArray
Receives an array of bytes and returns the number of bytes received. 
Fc9-u8-icon.png - BYTE Data
Array to store the incoming data 
Fc9-u16-icon.png - UINT NumBytes
Maximum number of bytes to try and receive 
Fc9-u8-icon.png - BYTE Timeout
Max amount of time in ms to wait between bytes 
Fc9-u8-icon.png - BYTE Return


ReceiveChar

Fc9-comp-macro.png ReceiveChar
 
Fc9-u8-icon.png - BYTE Timeout
 
Fc9-s16-icon.png - INT Return


ReceiveFloat

Fc9-comp-macro.png ReceiveFloat
Attempts to receive a floating point number as ASCII characters and convert back into a numeric value. Note this function will receive until a timeout or a none numeric char is received, the none numeric char will be lost. 
Fc9-u8-icon.png - BYTE Timeout
Max time in ms to wait in between bytes 
Fc9-bool-icon.png - BOOL IgnoreData
0=Dont ignore any data, 1=Ignore any initial none numeric data 
Fc9-f32-icon.png - FLOAT Return


ReceiveNumber

Fc9-comp-macro.png ReceiveNumber
Attempts to receive a number as ASCII characters and convert back into a numeric value. Note this function will receive until a timeout or a none numeric char is received, the none numeric char will be lost. 
Fc9-u8-icon.png - BYTE Timeout
Max time in ms to wait in between bytes 
Fc9-bool-icon.png - BOOL IgnoreData
0=Dont ignore any data, 1=Ignore any initial none numeric data 
Fc9-s32-icon.png - LONG Return


ReceiveString

Fc9-comp-macro.png ReceiveString
Send a string of data using the SRF Module 
Fc9-u8-icon.png - BYTE Timeout
 
Fc9-u8-icon.png - BYTE NumBytes
 
Fc9-string-icon.png - STRING Return


SRFInitialise

Fc9-comp-macro.png SRFInitialise
Initialise the SRF Module. Activate device through 'enable' pin, and wake device to ensure it is not sleeping. 
Fc9-void-icon.png - VOID Return


SendByteArray

Fc9-comp-macro.png SendByteArray
Transmits an array of bytes via the UART peripheral 
Fc9-u8-icon.png - BYTE Data
Data to transmit 
Fc9-u16-icon.png - UINT NumBytes
Number of bytes to send from the array 
Fc9-void-icon.png - VOID Return


SendChar

Fc9-comp-macro.png SendChar
 
Fc9-s16-icon.png - INT Char
 
Fc9-void-icon.png - VOID Return


SendFloat

Fc9-comp-macro.png SendFloat
Sends out a floating point number as an ASCII String from the UART interface. 
Fc9-f32-icon.png - FLOAT Number
 
Fc9-void-icon.png - VOID Return


SendNumber

Fc9-comp-macro.png SendNumber
Sends out a number as an ASCII String from the UART interface. 
Fc9-s32-icon.png - LONG Number
 
Fc9-void-icon.png - VOID Return


SendString

Fc9-comp-macro.png SendString
Send a string of data using the SRF Module 
Fc9-string-icon.png - STRING Data
 
Fc9-void-icon.png - VOID Return


Sleep

Fc9-comp-macro.png Sleep
Sets the SRF module to sleep mode. (Includes a 10mS delay to allow any data to finish sending) 
Fc9-void-icon.png - VOID Return


Wake

Fc9-comp-macro.png Wake
Wake the SRF module. Includes a 10ms delay to allow radio to wake. 
Fc9-void-icon.png - VOID Return


Property reference

Fc9-prop-icon.png Properties
Fc9-type-16-icon.png Sleep Mode (ATSM)
Defines which sleep mode will be used when calling the Sleep component macro. 
Fc9-type-16-icon.png Baud Rate
Serial comms data rate specified in bits per second. 
Fc9-conn-icon.png Connections
Fc9-type-16-icon.png Channel
Onboard UART peripheral to use to perform serial commands. Software mode available but not recommended for receive applications unless combined with a pin interrupt. 
Fc9-type-7-icon.png Use TX
Selects if the Transmit pin is used by the component. Yes: The TX pin is active and used to transmit data for the UART. No: The TX pin is disabled and free to be used as general I/O. 
Fc9-type-5-icon.png TX
Pin to be used for Transmit data 
Fc9-type-16-icon.png TX Remap Pin
Allows the hardware transmit pin to be configured from a list of available pins based on your target device, 
Fc9-type-7-icon.png Use RX
Selects if the Receive pin is used by the component. Yes: The RX pin is active and used to receive data for the UART. No: The RX pin is disabled and free to be used as general I/O. 
Fc9-type-5-icon.png RX
Pin to be used for Receive data 
Fc9-type-16-icon.png RX Remap Pin
Allows the hardware receive pin to be configured from a list of available pins based on your target device, 
Fc9-type-5-icon.png Sleep
 
Fc9-conn-icon.png Simulation
Fc9-type-7-icon.png Scope Traces
Selects if the scope traces are automatically generated or not 
Fc9-type-7-icon.png Console Data
Selects if the console data is automatically generated or not 
Fc9-type-16-icon.png Data Source
Simulation data source used to allow the component to connect to COM port hardware or the the data API components. 
Fc9-type-16-icon.png COM Port
Lists all the current available COM port hardware on your PC. 

Component Source Code

Please click here to download the component source project: FC_Comp_Source_SRF_Component_v2.fcfx

Please click here to view the component source code (Beta): FC_Comp_Source_SRF_Component_v2.fcfx