Sample Code

Document Name

Details

Download

Modbus Serial Examples

Sample PLC programs to implement Modbus master functions 01, 02, 04, 05, and 06 that are not supported via built in TBASIC commands (Function 04 is now supported on all Super PLCs and Function 06 is now supported on all SmartTILE based PLCs)
**Supported on all PLCs and SmartTILE
Opens the "Using PLC as MODBUS or RTU master" FAQ topic on the Forum

Modbus TCP Examples

Sample PLC programs to implement a Modbus TCP client connection using TBASIC commands. A version is provided for both TL6 and TL7
**Supported on all PLCs and SmartTILE
Sample PLC program to configure the PLC as a Modbus TCP to RTU gateway.
This allows Modbus TCP devices/software to access Modbus RTU devices connected to the PLCs COM ports
**Supported on all PLCs and SmartTILE

TCP/IP Client Examples

Sample PLC program to implement various TCP/IP functions such as Email, TCPCONNECT, MBTCPCONNECT, and more.
**Supported on all PLCs and SmartTILE
Sample PLC program to establish a connection to an Internet Time Server to retrieve the current time and date
**Supported on all PLCs and SmartTILE

Floating Point Examples

Sample PLC program to implement a sinewave generator using floating point functions supported in TL7.
**Only supported on Fx PLCs, EZWire1616, and SmartTILE
Sample PLC program to emulate integer to floating point conversion for the FMD series and Nano-10 PLCs that do not support native floating point functions.
**Not needed for Fx/EZWire/SmartTILE PLCs that natively support floating point math

Stepper Motor Examples

Sample PLC program to implement a 2 channel stepper motor controller.
**Supported on all PLCs and SmartTILE
Sample PLC program to implement a 3 channel stepper motor controller and driver (selectable during program operation).
**Only supported on the Fx2424, EZWire1616, and SmartTILE (with necessary motor controller/driver circuitry)

Light Dimmer Example

Sample PLC program to implement brightness control of a light using a dimming function.
**Only supported on Fx PLCs, EZWire1616, and SmartTILE

XBEE Wireless Communication Examples

Sample PLC program to implement XBEE radio configuration on COM2.
**Only Supported on Fx PLCs with XBEE radio chip sockets (supported on all PLCs via XBEE serial module)
Sample PLC programs to implement master/slave operation of a XBEE radio module.
**Only Supported on Fx PLCs with XBEE radio chip sockets (supported on all PLCs via XBEE serial module)

Extended File System Example

Sample PLC program to utilize the extended file system on Fx/EZWire PLCs and the FRAM-RTC-256 module for FMD/Nano-10 PLCs. Examples of file reading/writing and uploading to a FTP server.
**Only directly supported on Fx PLCs, EZWire1616, and SmartTILE. Also supported on FMD/Nano-10 with the FRAM-RTC-256 module