Lucon SDK 1.0.7
Loading...
Searching...
No Matches

Functions

LuconHandle LUCON_NewUdpConnection (const char *const raddr, uint16_t lport, const char *const laddr)
 New UDP connection.
LuconHandle LUCON_NewRs232Connection (const char *const name, uint32_t baudRate)
 New RS232 serial-port connection.
LuconHandle LUCON_NewFakeConnection ()
 Creates a new fake connection, which may be used for simulation / testing without real hardware.

Detailed Description

Function Documentation

◆ LUCON_NewFakeConnection()

LuconHandle LUCON_NewFakeConnection ( )
extern

Creates a new fake connection, which may be used for simulation / testing without real hardware.

Returns
The new LuconHandle or NULL in case of an error

◆ LUCON_NewRs232Connection()

LuconHandle LUCON_NewRs232Connection ( const char *const name,
uint32_t baudRate )
extern

New RS232 serial-port connection.

Parameters
nameThe name of the COM port, e.g. "COM3"
baudRateThe baud rate for serial communication. If 0 is specified, the factory default will be used.
Returns
The new LuconHandle or NULL in case of an error

◆ LUCON_NewUdpConnection()

LuconHandle LUCON_NewUdpConnection ( const char *const raddr,
uint16_t lport,
const char *const laddr )
extern

New UDP connection.

The inputs are immediately parsed and resolved to IP addresses

Parameters
raddrThe remote/device IP address as a zero-terminated string, e.g. "10.0.30.2"
lportThe local UDP port to be used for listening for device data. If 0 is specified, an arbitrary port is chosen automatically
laddrThe address of the local network interface to be used, e.g. "10.0.30.1". NULL or an empty cstring result in automatic choice.
Returns
The new LuconHandle or NULL in case of an error