Jump to content

Component: IrDA (EB012, MCP1250, MCP2120) (Wireless)

From Flowcode Help
Revision as of 19:48, 16 November 2021 by Wiki bot (talk | contribs)
Author Matrix Ltd.
Version 2.0
Category Wireless


IrDA (EB012, MCP1250, MCP2120) component

Low level routines for controlling a standard IrDA interface. Also available in the form of the EB012 IrDA E-block.

Detailed description

No detailed description exists yet for this component

Examples

Transmit

Basic example which repeatedly transmits a string of data via the IrDA interface. IrDA Transmit

Receive

Basic example which waits for any incoming data and then displays the data on the LCD. IrDA Receive

Downloadable macro reference

SendChar
Sends a byte character to the IrDA connection. 
[[File:]] - Char
 
- VOID Return


ReceiveChar
Receives byte character from the IrDA connection. 
[[File:]] - Timeout
Max amount of time in milliseconds to wait for data. 
[[File:]] - Return


Initialise
Initialises the UART ready for IrDA data to be sent or received, 
- VOID Return


Disconnect
Disconnects from the MQTT server and the network 
- BYTE Return


Ping
Ping packet is sent to the Server and checks for a reply. Returns non-zero value if successful  
- BYTE Return


GetPayload
Get the Payload of the last received (Read) packet. Returns the number of bytes for the Payload 
- STRING Payload
 
- BYTE Size
Byte count the Payload buffer 
- BYTE Return


Subscribe
Subscribe to a Topic. Must be Connected first Returns non-zero if successful  
- STRING Topic
 
- BYTE Return


Unsubscribe
Unsubscribe from a Topic. Must be Connected first Returns non-zero if successful  
- STRING Topic
 
- BYTE Return


Initialise
 
- VOID Return


GetPayloadString
Get the Payload of the last received (Read) packet as a string value 
- STRING Payload
 
- BYTE Size
 
- BYTE Return


Initialise
Starts up the MQTT component - call this after initialising the NetworkComms component. 
- VOID Return



Property reference

Properties
Interface
Decides which IrDA interface IC we wish to communicate via. 
Baud Options
Baud rate option selector 
Baud Rate
 
Data Bits
Number of data bits 
Echo
Echo selection 
Connections
Channel
UART Channel selector Software channels are bit banged using generic I/O pins but are not as reliable as hardware channels. Hardware channels use the selected peripheral on-board the target microcontroller. 
TX
Pin to be used for Transmit data 
RX
Pin to be used for Receive data 
Use Flow Control
Flow Control (Handshake) enable or disable. On: Two I/O pins are used to control the flow of data in and out of the device. Off: Flow control is disabled. 
Simulations
Label
Label used to help identify the component on the panel. 
Scope Traces
Selects if the scope traces are automatically added to the data recorder window or not. Simulation - draws an approximation of the UART data onto the scope trace. ICT - sets up the scope trace for incoming data and adds UART packet decoding at the correct BAUD. 
Console Data
Selects if the console data is automatically generated or not 
Console Columns
Number of characters that can be displayed on a single line of the console. 
Data Source
Simulation data source used to allow the component to connect to various remote devices Nothing - Simulation data is ignored COM port - Routes the communication data to and from a physical or virtual COM port API - Routes the communication data via a data API component on the Panel.