Difference between revisions of "Component: TCP/IP (EB023 v2) (E-blocks 1)"
From Flowcode Help
Jump to navigationJump to searchLine 17: | Line 17: | ||
==Component Source Code== | ==Component Source Code== | ||
− | Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/ | + | Please click here to download the component source project: [https://www.flowcode.co.uk/wiki/componentsource/FC_Comp_Source_temp/TCPIP_EB023-00-2_EB.fcfx FC_Comp_Source_temp/TCPIP_EB023-00-2_EB.fcfx] |
− | Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/ | + | Please click here to view the component source code (Beta): [https://www.flowcode.co.uk/FlowchartView/?wfile=componentsource/FC_Comp_Source_temp/TCPIP_EB023-00-2_EB.fcfx FC_Comp_Source_temp/TCPIP_EB023-00-2_EB.fcfx] |
==Detailed description== | ==Detailed description== | ||
Line 72: | Line 72: | ||
''<span style="color:red;">No additional examples</span>'' | ''<span style="color:red;">No additional examples</span>'' | ||
+ | |||
+ | |||
Line 79: | Line 81: | ||
==Macro reference== | ==Macro reference== | ||
− | === | + | ===CreateIPSocket=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''CreateIPSocket''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Note that sockets on up to 4 channels can be simultaneously opened and these channels are numbered 0 to 3. Note that sockets with different modes can be opened on different channels. |
|- | |- | ||
|- | |- | ||
Line 93: | Line 95: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | Protocol | ||
+ | |- | ||
+ | | colspan="2" | Specifies which IP protocol to use | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | Broadcast | ||
+ | |- | ||
+ | | colspan="2" | Allows broadcast type packets to be sent and received | ||
+ | |- | ||
+ | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===CreateMACSocket=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''CreateMACSocket''' |
+ | |- | ||
+ | | colspan="2" | This macro creates a socket for sending and receiving Ethernet data using raw data. | ||
+ | |- | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | Promiscuous | ||
+ | |- | ||
+ | | colspan="2" | Receive everything (1) or just data bound for your MAC (0) | ||
|- | |- | ||
− | | | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | Broadcast | ||
|- | |- | ||
+ | | colspan="2" | Allows broadcast messages to be accepted (1) or rejected (0) | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Error |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Allowsmessages with errors to be accepted (1) or rejected (0) |
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 117: | Line 139: | ||
− | === | + | ===CreateTCPSocket=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''CreateTCPSocket''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro creates a socket for sending and receiving TCP data. |
|- | |- | ||
|- | |- | ||
Line 131: | Line 153: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | + | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT |
− | | width="90%" | | + | | width="90%" | Src_Port |
+ | |- | ||
+ | | colspan="2" | Port Number | ||
+ | |- | ||
+ | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
+ | |} | ||
+ | |||
+ | |||
+ | ===CreateUDPSocket=== | ||
+ | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
− | | | + | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
+ | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''CreateUDPSocket''' | ||
|- | |- | ||
− | | | + | | colspan="2" | This macro creates a socket for sending and receiving UDP data. |
− | |||
|- | |- | ||
− | |||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | Specifies the | + | | colspan="2" | Specifies the communications channel 0-3 |
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT |
− | | width="90%" | | + | | width="90%" | Src_Port |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Port Number |
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 156: | Line 187: | ||
− | === | + | ===CreateUDPSocket_Sim=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''CreateUDPSocket_Sim''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro creates a socket for sending and receiving UDP data. |
|- | |- | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
+ | |- | ||
+ | | colspan="2" | Specifies the communications channel 0-3 | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT | ||
+ | | width="90%" | Src_Port | ||
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Port Number |
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | | + | | width="90%" style="border-top: 2px solid #000;" | ''Return'' |
+ | |} | ||
+ | |||
+ | |||
+ | ===GetSocketStatus=== | ||
+ | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
− | | | + | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
+ | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''GetSocketStatus''' | ||
|- | |- | ||
− | | | + | | colspan="2" | This returns the state of the requested channel's socket. |
− | |||
|- | |- | ||
− | |||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the communications channel 0-3 |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===Initialise=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''Initialise''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Resets and initialises the Internet E-Block. It sets up the gateway address, subnet mask, device IP address and device MAC address as defined in the properties of the Flowcode component. This macro must be called before any other TCP_IP component macros |
|- | |- | ||
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | | + | | width="90%" style="border-top: 2px solid #000;" | ''Return'' |
+ | |} | ||
+ | |||
+ | |||
+ | ===MIAC_Module_GetData=== | ||
+ | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
− | | | + | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
+ | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''MIAC_Module_GetData''' | ||
|- | |- | ||
− | | | + | | colspan="2" | |
− | |||
|- | |- | ||
− | |||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Index |
|- | |- | ||
| colspan="2" | | | colspan="2" | | ||
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===MIAC_Module_Message=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''MIAC_Module_Message''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | |
|- | |- | ||
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT |
− | | width="90%" | | + | | width="90%" | CAN_ID |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | |
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT |
− | | width="90%" | | + | | width="90%" | CMD_ID |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | |
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 243: | Line 287: | ||
− | === | + | ===MIAC_Module_PushData=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''MIAC_Module_PushData''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | |
|- | |- | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Data |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | |
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | ||
Line 316: | Line 355: | ||
− | === | + | ===RxDataAvailable=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxDataAvailable''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | This macro is used to check whether or not data has been received by the Internet E-Block. A return value of zero indicated that no data has been received. A positive return value indicates that data is available. |
|- | |- | ||
|- | |- | ||
Line 329: | Line 368: | ||
|- | |- | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 345: | Line 374: | ||
− | === | + | ===RxDataSize=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxDataSize''' |
|- | |- | ||
− | | colspan="2" | This is used | + | | colspan="2" | This macro is used to detect the size of data collected by the Rx_data_available macro. |
|- | |- | ||
|- | |- | ||
Line 359: | Line 388: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u16-icon.png]] - UINT |
− | | width="90%" | | + | | width="90%" style="border-top: 2px solid #000;" | ''Return'' |
+ | |} | ||
+ | |||
+ | |||
+ | ===RxDataSize_Sim=== | ||
+ | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
− | | | + | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] |
+ | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxDataSize_Sim''' | ||
|- | |- | ||
− | | | + | | colspan="2" | This macro is used to detect the size of data collected by the Rx_data_available macro. |
− | |||
|- | |- | ||
− | |||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | Specifies the | + | | colspan="2" | Specifies the communications channel 0-3 |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 389: | Line 412: | ||
− | === | + | ===RxFlushData=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxFlushData''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Once data reception has been completed, this macro should be called to discard the data packet and allow other data packets to be read. |
|- | |- | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the communications channel 0-3 |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===RxFlushData_Sim=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxFlushData_Sim''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Once data reception has been completed, this macro should be called to discard the data packet and allow other data packets to be read. |
|- | |- | ||
|- | |- | ||
Line 427: | Line 450: | ||
− | === | + | ===RxMatchMyIP=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxMatchMyIP''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | This macro returns a non-zero value when the next 4 bytes of data in the specified channel's reception buffer are the same as the Internet E-block's IP address. |
|- | |- | ||
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the communications channel 0-3 |
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 451: | Line 469: | ||
− | === | + | ===RxMatchMyMAC=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxMatchMyMAC''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | This macro returns a non-zero value when the next 6 bytes of data in the specified channel's reception buffer are the same as the Internet E-block's MAC address entered in the component's property page. |
|- | |- | ||
|- | |- | ||
Line 470: | Line 488: | ||
− | === | + | ===RxMatchMyMAC_Sim=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxMatchMyMAC_Sim''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro returns a non-zero value when the next 4 bytes of data in the specified channel's reception buffer are the same as the Internet E-block's IP address. |
|- | |- | ||
|- | |- | ||
Line 483: | Line 501: | ||
|- | |- | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 494: | Line 507: | ||
− | === | + | ===RxMatch_2_Bytes=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxMatch_2_Bytes''' |
|- | |- | ||
− | | colspan="2" | This macro returns a non-zero value when the next | + | | colspan="2" | This macro returns a non-zero value when the next 2 bytes of data in the specified channel's reception buffer are the same as those passed as parameters. There are similar functions that check for 4 bytes and 6 bytes. |
|- | |- | ||
|- | |- | ||
Line 518: | Line 531: | ||
| colspan="2" | Specifies the value of the second byte | | colspan="2" | Specifies the value of the second byte | ||
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | | + | | width="90%" style="border-top: 2px solid #000;" | ''Return'' |
+ | |} | ||
+ | |||
+ | |||
+ | ===RxMatch_2_Bytes_Sim=== | ||
+ | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
+ | |- | ||
+ | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
+ | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxMatch_2_Bytes_Sim''' | ||
+ | |- | ||
+ | | colspan="2" | This macro returns a non-zero value when the next 2 bytes of data in the specified channel's reception buffer are the same as those passed as parameters. There are similar functions that check for 4 bytes and 6 bytes. | ||
|- | |- | ||
− | |||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | Specifies the | + | | colspan="2" | Specifies the communications channel 0-3 |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Byte1 |
|- | |- | ||
− | | colspan="2" | Specifies the value of the | + | | colspan="2" | Specifies the value of the first byte |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Byte2 |
|- | |- | ||
− | | colspan="2" | Specifies the value of the | + | | colspan="2" | Specifies the value of the second byte |
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 543: | Line 565: | ||
− | === | + | ===RxMatch_4_Bytes=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxMatch_4_Bytes''' |
|- | |- | ||
− | | colspan="2" | This macro returns a non-zero value when the next | + | | colspan="2" | This macro returns a non-zero value when the next 4 bytes of data in the specified channel's reception buffer are the same as those passed as parameters. There are similar functions that check for 2 bytes and 6 bytes. |
|- | |- | ||
|- | |- | ||
Line 566: | Line 588: | ||
|- | |- | ||
| colspan="2" | Specifies the value of the second byte | | colspan="2" | Specifies the value of the second byte | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | Byte3 | ||
+ | |- | ||
+ | | colspan="2" | Specifies the value of the third byte | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | Byte4 | ||
+ | |- | ||
+ | | colspan="2" | Specifies the value of the fourth byte | ||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 572: | Line 604: | ||
− | === | + | ===RxMatch_4_Bytes_Sim=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxMatch_4_Bytes_Sim''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | This macro returns a non-zero value when the next 4 bytes of data in the specified channel's reception buffer are the same as those passed as parameters. There are similar functions that check for 2 bytes and 6 bytes. |
|- | |- | ||
|- | |- | ||
Line 586: | Line 618: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | | width="10%" align="center | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | + | | width="90%" | Byte1 |
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
− | | | + | | colspan="2" | Specifies the value of the first byte |
− | |||
|- | |- | ||
− | | | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | Byte2 | ||
|- | |- | ||
+ | | colspan="2" | Specifies the value of the second byte | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Byte3 |
|- | |- | ||
− | | colspan="2" | Specifies the | + | | colspan="2" | Specifies the value of the third byte |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Byte4 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the value of the fourth byte |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===RxMatch_6_Bytes=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxMatch_6_Bytes''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro returns a non-zero value when the next 6 bytes of data in the specified channel's reception buffer are the same as those passed as parameters. There are similar functions that check for 2 bytes and 4 bytes. |
|- | |- | ||
|- | |- | ||
Line 629: | Line 657: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | | + | | width="90%" | Byte1 |
+ | |- | ||
+ | | colspan="2" | Specifies the value of the first byte | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | Byte2 | ||
+ | |- | ||
+ | | colspan="2" | Specifies the value of the second byte | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | Byte3 | ||
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the value of the third byte |
|- | |- | ||
− | | width="10%" align="center | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | + | | width="90%" | Byte4 |
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
− | | | + | | colspan="2" | Specifies the value of the fourth byte |
− | |||
|- | |- | ||
− | | | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | Byte5 | ||
|- | |- | ||
+ | | colspan="2" | Specifies the value of the fifth byte | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Byte6 |
|- | |- | ||
− | | colspan="2" | Specifies the | + | | colspan="2" | Specifies the value of the sixth byte |
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
Line 658: | Line 692: | ||
− | === | + | ===RxReadByte=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxReadByte''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | A call to this macro will return a byte of data in the reception buffer of the specified channel. It will also internally increment a pointer to that data so that the next call to 'Rx_readbyte' (or any other read function) will read the next byte |
|- | |- | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the communications channel 0-3 |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===RxReadByte_Sim=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxReadByte_Sim''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | A call to this macro will return a byte of data in the reception buffer of the specified channel. It will also internally increment a pointer to that data so that the next call to 'Rx_readbyte' (or any other read function) will read the next byte |
|- | |- | ||
|- | |- | ||
Line 691: | Line 725: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | |
− | |||
− | |||
− | |||
− | |||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | ||
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===RxReadHeader=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxReadHeader''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Once data in a particular channel has been received, the header will be filled with information about the received data. This macro will return the information in the header. The idx parameter specifies which byte of information in the header to read |
|- | |- | ||
|- | |- | ||
Line 715: | Line 744: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | Idx | ||
+ | |- | ||
+ | | colspan="2" | Specifies the byte index to return | ||
+ | |- | ||
+ | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE | ||
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===RxReadString=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxReadString''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | A call to this macro will return a string of data in the reception buffer of the specified channel. It will also internally increment a pointer to that data so that the next call to 'Rx_readbyte' (or any other read function) will read the next byte |
|- | |- | ||
|- | |- | ||
Line 735: | Line 769: | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Length |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-string-icon.png]] - STRING |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===RxSkipBytes=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''RxSkipBytes''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Often when receiving data packets, it may be necessary to ignore large sections of the data. This can be achieved by reading each byte individually (and ignoring the returned data), but a better way is to use this Rx_skipbytes macro. |
|- | |- | ||
|- | |- | ||
Line 757: | Line 791: | ||
|- | |- | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | Count | ||
+ | |- | ||
+ | | colspan="2" | Specifies how many bytes to skip | ||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | ||
Line 763: | Line 802: | ||
− | === | + | ===SetDestination=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetDestination''' |
|- | |- | ||
− | | colspan="2" | This | + | | colspan="2" | This is used in IP and UDP modes to set the destination of the intended data transfer. The destination IP address needs to be set for both IP and UDP modes. |
|- | |- | ||
|- | |- | ||
Line 780: | Line 819: | ||
| width="90%" | Dst_IP0 | | width="90%" | Dst_IP0 | ||
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the first byte of an IP address |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
| width="90%" | Dst_IP1 | | width="90%" | Dst_IP1 | ||
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the second byte of an IP address |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
| width="90%" | Dst_IP2 | | width="90%" | Dst_IP2 | ||
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the third byte of an IP address |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
| width="90%" | Dst_IP3 | | width="90%" | Dst_IP3 | ||
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the fourth byte of an IP address |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT | ||
Line 807: | Line 846: | ||
− | === | + | ===SetGateway=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetGateway''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | This macro sets up the Internet E-Block's Gateway address. In most circumstances, this macro will not be required as the gateway address setting in the component property page will remain constant throughout your application. |
|- | |- | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | IP0 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | First Byte of IP address |
|- | |- | ||
− | | width="10%" align="center | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | + | | width="90%" | IP1 |
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
− | | | + | | colspan="2" | Second Byte of IP address |
− | |||
|- | |- | ||
− | | | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | IP2 | ||
|- | |- | ||
+ | | colspan="2" | Third Byte of IP address | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | IP3 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Fourth Byte of IP address |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===SetMACAddress=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetMACAddress''' |
+ | |- | ||
+ | | colspan="2" | This macro sets up the Internet E-Block's MAC address. In most circumstances, this macro will not be required as the MAC address setting in the component property page will remain constant throughout your application. | ||
+ | |- | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | MAC0 | ||
+ | |- | ||
+ | | colspan="2" | First Byte of address | ||
|- | |- | ||
− | | | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | MAC1 | ||
|- | |- | ||
+ | | colspan="2" | Second Byte of address | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | MAC2 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Third Byte of address |
|- | |- | ||
− | | width="10%" align="center | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | + | | width="90%" | MAC3 |
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
− | | | + | | colspan="2" | Fourth Byte of address |
− | |||
|- | |- | ||
− | | | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | MAC4 | ||
|- | |- | ||
+ | | colspan="2" | Fourth Byte of address | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | MAC5 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Fifth Byte of address |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===SetMyIP=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetMyIP''' |
+ | |- | ||
+ | | colspan="2" | This macro sets up the Internet E-Block's own IP address. In most circumstances, this macro will not be required as the IP address setting in the component property page will remain constant throughout your application. | ||
+ | |- | ||
|- | |- | ||
− | | | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | IP0 | ||
|- | |- | ||
+ | | colspan="2" | First Byte of IP address | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | IP1 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Second Byte of IP address |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | IP2 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Third Byte of IP address |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | IP3 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Fourth Byte of IP address |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===SetSubnetMask=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''SetSubnetMask''' |
+ | |- | ||
+ | | colspan="2" | This macro sets up the Internet E-Block's Subnet Mask. In most circumstances, this macro will not be required as the subnet mask setting in the component property page will remain constant throughout your application. | ||
+ | |- | ||
+ | |- | ||
+ | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
+ | | width="90%" | IP0 | ||
+ | |- | ||
+ | | colspan="2" | First Byte of IP address | ||
|- | |- | ||
− | | | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | IP1 | ||
|- | |- | ||
+ | | colspan="2" | Second Byte of IP address | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | IP2 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Third Byte of IP address |
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
− | | width="90%" | | + | | width="90%" | IP3 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Fourth Byte of IP address |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===TCPClose=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TCPClose''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | When an established TCP connection has finished transmission of data, either the local application (i.e. your code) or the remote application (i.e. the application at the other end of the connection) can initiate closure of the socket. |
|- | |- | ||
|- | |- | ||
Line 955: | Line 1,011: | ||
− | === | + | ===TCPConnect=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TCPConnect''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro puts a previously opened TCP channel in "active open" mode. This is the required mode when writing a TCP client application (e.g. using SMTP to send an email). |
|- | |- | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the communications channel 0-3 |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Dst_IP0 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | First Byte of IP address |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Dst_IP1 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Second Byte of IP address |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Dst_IP2 |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Third Byte of IP address |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Dst_IP3 |
|- | |- | ||
− | | colspan="2" | Fourth Byte of address | + | | colspan="2" | Fourth Byte of IP address |
|- | |- | ||
− | | width="10%" align="center" | [[File:Fc9- | + | | width="10%" align="center" | [[File:Fc9-u16-icon.png]] - UINT |
− | | width="90%" | | + | | width="90%" | Dst_Port |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Destination Port |
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-u8-icon.png]] - BYTE |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===TCPListen=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TCPListen''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro puts a previously opened TCP channel in "passive open" mode. This is the required mode when writing a TCP server application (e.g. a web server to display HTML web pages). |
|- | |- | ||
|- | |- | ||
Line 1,013: | Line 1,069: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | ||
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===TxEnd=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TxEnd''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Once the transmit buffer has been filled with data, call this macro to actually send the data. |
|- | |- | ||
|- | |- | ||
Line 1,052: | Line 1,088: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===TxSendByte=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TxSendByte''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro fills the specified channel's transmit buffer with data. It can fill the buffer with a single byte of data, or with a string of information. |
|- | |- | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the communications channel 0-3 |
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Data |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Data byte to append to Tx buffer. |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | ||
Line 1,091: | Line 1,117: | ||
− | === | + | ===TxSendByte_Sim=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TxSendByte_Sim''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro fills the specified channel's transmit buffer with data. It can fill the buffer with a single byte of data, or with a string of information. |
|- | |- | ||
|- | |- | ||
Line 1,106: | Line 1,132: | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Data |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Data byte to append to Tx buffer. |
|- | |- | ||
− | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | |
− | |||
− | |||
− | |||
− | |||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | ||
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===TxSendMyIP=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TxSendMyIP''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro fills the specified channel's transmit buffer with 4 bytes of data representing this Internet E-Block's IP address as specified in the component's property page. |
|- | |- | ||
|- | |- | ||
Line 1,134: | Line 1,155: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===TxSendMyMAC=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TxSendMyMAC''' |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | This macro fills the specified channel's transmit buffer with 6 bytes of data representing this Internet E-Block's MAC address as specified in the component's property page. |
|- | |- | ||
|- | |- | ||
Line 1,158: | Line 1,179: | ||
− | === | + | ===TxSendString=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TxSendString''' |
|- | |- | ||
− | | colspan="2" | This | + | | colspan="2" | This macro fills the specified channel's transmit buffer with data. It can fill the buffer with a string of information. |
|- | |- | ||
|- | |- | ||
Line 1,172: | Line 1,193: | ||
| colspan="2" | Specifies the communications channel 0-3 | | colspan="2" | Specifies the communications channel 0-3 | ||
|- | |- | ||
− | | width="10%" align="center | + | | width="10%" align="center" | [[File:Fc9-string-icon.png]] - STRING |
− | | width="90%" | + | | width="90%" | Data |
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
− | | | + | | colspan="2" | Data byte to append to Tx buffer. |
− | |||
|- | |- | ||
− | | | + | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE |
+ | | width="90%" | Length | ||
|- | |- | ||
+ | | colspan="2" | | ||
|- | |- | ||
− | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9- | + | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
| width="90%" style="border-top: 2px solid #000;" | ''Return'' | | width="90%" style="border-top: 2px solid #000;" | ''Return'' | ||
|} | |} | ||
− | === | + | ===TxStart=== |
{| class="wikitable" style="width:60%; background-color:#FFFFFF;" | {| class="wikitable" style="width:60%; background-color:#FFFFFF;" | ||
|- | |- | ||
| width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | | width="10%" align="center" style="background-color:#D8C9D8;" align="center" | [[File:Fc9-comp-macro.png]] | ||
− | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | ''' | + | | width="90%" style="background-color:#D8C9D8; color:#4B008D;" | '''TxStart''' |
|- | |- | ||
− | | colspan="2" | This macro | + | | colspan="2" | This macro indicates the start of data transmission for the specified buffer. In TCP mode, data transmission can only begin once the socket has become established. In other modes, data transmission can occur as soon as the socket has been opened. |
|- | |- | ||
|- | |- | ||
| width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | | width="10%" align="center" | [[File:Fc9-u8-icon.png]] - BYTE | ||
− | | width="90%" | | + | | width="90%" | Channel |
|- | |- | ||
− | | colspan="2" | | + | | colspan="2" | Specifies the communications channel 0-3 |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
|- | |- | ||
| width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID | | width="10%" align="center" style="border-top: 2px solid #000;" | [[File:Fc9-void-icon.png]] - VOID |
Revision as of 12:03, 3 February 2023
Author | Matrix TSL |
Version | 2.0 |
Category | E-blocks 1 |
Contents
- 1 TCP/IP component
- 2 Component Source Code
- 3 Detailed description
- 4 Examples
- 5 Macro reference
- 5.1 CreateIPSocket
- 5.2 CreateMACSocket
- 5.3 CreateTCPSocket
- 5.4 CreateUDPSocket
- 5.5 CreateUDPSocket_Sim
- 5.6 GetSocketStatus
- 5.7 Initialise
- 5.8 MIAC_Module_GetData
- 5.9 MIAC_Module_Message
- 5.10 MIAC_Module_PushData
- 5.11 MIAC_Module_SetData
- 5.12 RxDataAvailable
- 5.13 RxDataSize
- 5.14 RxDataSize_Sim
- 5.15 RxFlushData
- 5.16 RxFlushData_Sim
- 5.17 RxMatchMyIP
- 5.18 RxMatchMyMAC
- 5.19 RxMatchMyMAC_Sim
- 5.20 RxMatch_2_Bytes
- 5.21 RxMatch_2_Bytes_Sim
- 5.22 RxMatch_4_Bytes
- 5.23 RxMatch_4_Bytes_Sim
- 5.24 RxMatch_6_Bytes
- 5.25 RxReadByte
- 5.26 RxReadByte_Sim
- 5.27 RxReadHeader
- 5.28 RxReadString
- 5.29 RxSkipBytes
- 5.30 SetDestination
- 5.31 SetGateway
- 5.32 SetMACAddress
- 5.33 SetMyIP
- 5.34 SetSubnetMask
- 5.35 TCPClose
- 5.36 TCPConnect
- 5.37 TCPListen
- 5.38 TxEnd
- 5.39 TxSendByte
- 5.40 TxSendByte_Sim
- 5.41 TxSendMyIP
- 5.42 TxSendMyMAC
- 5.43 TxSendString
- 5.44 TxStart
- 6 Property reference
TCP/IP component
TCP/IP component designed to work with the WIZ810MJ module from Wiznet, as used on version 2 EB023 E-block and the MIAC Industrial Addon module.
Component Source Code
Please click here to download the component source project: FC_Comp_Source_temp/TCPIP_EB023-00-2_EB.fcfx
Please click here to view the component source code (Beta): FC_Comp_Source_temp/TCPIP_EB023-00-2_EB.fcfx
Detailed description
No detailed description exists yet for this component
Examples
No additional examples
Macro reference
CreateIPSocket
CreateMACSocket
CreateTCPSocket
CreateTCPSocket | |
This macro creates a socket for sending and receiving TCP data. | |
- BYTE | Channel |
Specifies the communications channel 0-3 | |
- UINT | Src_Port |
Port Number | |
- BYTE | Return |
CreateUDPSocket
CreateUDPSocket | |
This macro creates a socket for sending and receiving UDP data. | |
- BYTE | Channel |
Specifies the communications channel 0-3 | |
- UINT | Src_Port |
Port Number | |
- BYTE | Return |
CreateUDPSocket_Sim
CreateUDPSocket_Sim | |
This macro creates a socket for sending and receiving UDP data. | |
- BYTE | Channel |
Specifies the communications channel 0-3 | |
- UINT | Src_Port |
Port Number | |
- BYTE | Return |
GetSocketStatus
GetSocketStatus | |
This returns the state of the requested channel's socket. | |
- BYTE | Channel |
Specifies the communications channel 0-3 | |
- BYTE | Return |
Initialise
MIAC_Module_GetData
MIAC_Module_GetData | |
- BYTE | Index |
- BYTE | Return |
MIAC_Module_Message
MIAC_Module_Message | |
- UINT | CAN_ID |
- UINT | CMD_ID |
- BYTE | Return |
MIAC_Module_PushData
MIAC_Module_PushData | |
- BYTE | Data |
- VOID | Return |
MIAC_Module_SetData
MIAC_Module_SetData | |
- BYTE | Count |
- BYTE | D0 |
- BYTE | D1 |
- BYTE | D2 |
- BYTE | D3 |
- BYTE | D4 |
- BYTE | D5 |
- VOID | Return |
RxDataAvailable
RxDataSize
RxDataSize | |
This macro is used to detect the size of data collected by the Rx_data_available macro. | |
- BYTE | Channel |
Specifies the communications channel 0-3 | |
- UINT | Return |
RxDataSize_Sim
RxDataSize_Sim | |
This macro is used to detect the size of data collected by the Rx_data_available macro. | |
- BYTE | Channel |
Specifies the communications channel 0-3 | |
- BYTE | Return |
RxFlushData
RxFlushData_Sim
RxMatchMyIP
RxMatchMyMAC
RxMatchMyMAC_Sim
RxMatch_2_Bytes
RxMatch_2_Bytes_Sim
RxMatch_4_Bytes
RxMatch_4_Bytes_Sim
RxMatch_6_Bytes
RxReadByte
RxReadByte_Sim
RxReadHeader
RxReadString
RxSkipBytes
SetDestination
SetGateway
SetMACAddress
SetMyIP
SetSubnetMask
TCPClose
TCPConnect
TCPListen
TxEnd
TxEnd | |
Once the transmit buffer has been filled with data, call this macro to actually send the data. | |
- BYTE | Channel |
Specifies the communications channel 0-3 | |
- VOID | Return |
TxSendByte
TxSendByte_Sim
TxSendMyIP
TxSendMyMAC
TxSendString
TxStart