A bridge connects two networks do not have the same physical layer.
The outside of a bridge uses UDP and behaves like a device associated with a schema. The inside of a bridge acts as a hub and does not use UDP.
|
int | gxPLBridgeClose (gxPLBridge *bridge) |
| Close a gxPLBridge object and release all ressources. More...
|
|
gxPLDevice * | gxPLBridgeDevice (gxPLBridge *bridge) |
| Returns the device for the outsite network. More...
|
|
int | gxPLBridgeDeviceEnable (gxPLBridge *bridge, bool enable) |
| Enable device for the outsite network. More...
|
|
int | gxPLBridgeDeviceIsEnabled (const gxPLBridge *bridge) |
| Checks if device is enabled. More...
|
|
int | gxPLBridgeDeviceSet (gxPLBridge *bridge, const char *vendor_id, const char *device_id, const char *filename, const char *version) |
| Sets the device for the outsite network. More...
|
|
gxPLApplication * | gxPLBridgeInApp (gxPLBridge *bridge) |
| Returns the inside application. More...
|
|
gxPLBridge * | gxPLBridgeOpen (gxPLSetting *insetting, gxPLSetting *outsetting, uint8_t max_hop) |
| Opens a new gxPLBridge object. More...
|
|
gxPLApplication * | gxPLBridgeOutApp (gxPLBridge *bridge) |
| Returns the outside application. More...
|
|
int | gxPLBridgePoll (gxPLBridge *bridge, int timeout_ms) |
| Polling event of a bridge. More...
|
|
int | gxPLBridgeSetNewInSetting (gxPLBridge *bridge, gxPLSetting *insetting) |
| Sets new setting for inside network If configuration differ, the network will be closed then opened with the new configuration. More...
|
|
int gxPLBridgeClose |
( |
gxPLBridge * |
bridge | ) |
|
Close a gxPLBridge object and release all ressources.
- Parameters
-
bridge | pointer to a gxPLBridge object |
- Returns
- 0, -1 if an error occurs
gxPLDevice* gxPLBridgeDevice |
( |
gxPLBridge * |
bridge | ) |
|
Returns the device for the outsite network.
- Parameters
-
bridge | pointer to a gxPLBridge object |
- Returns
int gxPLBridgeDeviceEnable |
( |
gxPLBridge * |
bridge, |
|
|
bool |
enable |
|
) |
| |
Enable device for the outsite network.
- Parameters
-
bridge | pointer to a gxPLBridge object |
enable | |
- Returns
- 0, -1 if an error occurs
int gxPLBridgeDeviceIsEnabled |
( |
const gxPLBridge * |
bridge | ) |
|
Checks if device is enabled.
- Parameters
-
bridge | pointer to a gxPLBridge object |
- Returns
- false, true, -1 if an error occurs
int gxPLBridgeDeviceSet |
( |
gxPLBridge * |
bridge, |
|
|
const char * |
vendor_id, |
|
|
const char * |
device_id, |
|
|
const char * |
filename, |
|
|
const char * |
version |
|
) |
| |
Sets the device for the outsite network.
- Parameters
-
bridge | pointer to a gxPLBridge object |
vendor_id | |
device_id | |
filename | |
version | |
- Returns
- 0, -1 if an error occurs
gxPLApplication* gxPLBridgeInApp |
( |
gxPLBridge * |
bridge | ) |
|
Returns the inside application.
- Parameters
-
bridge | pointer to a gxPLBridge object |
- Returns
- the application
Opens a new gxPLBridge object.
- Parameters
-
insetting | pointer to the inside configuration, this configuration can be modified by the function to return the actual configuration. |
outsetting | pointer to the outside configuration (udp), this configuration can be modified by the function to return the actual configuration |
max_hop | only messages with a hop count less than or equal to max_hop cross the bridge |
- Returns
- the object or NULL if error occurs
gxPLApplication* gxPLBridgeOutApp |
( |
gxPLBridge * |
bridge | ) |
|
Returns the outside application.
- Parameters
-
bridge | pointer to a gxPLBridge object |
- Returns
- the application
int gxPLBridgePoll |
( |
gxPLBridge * |
bridge, |
|
|
int |
timeout_ms |
|
) |
| |
Polling event of a bridge.
- Parameters
-
bridge | pointer to a gxPLBridge object |
timeout_ms | waiting period in ms before output if no event occurs |
- Returns
- 0, -1 if an error occurs
int gxPLBridgeSetNewInSetting |
( |
gxPLBridge * |
bridge, |
|
|
gxPLSetting * |
insetting |
|
) |
| |
Sets new setting for inside network If configuration differ, the network will be closed then opened with the new configuration.
- Parameters
-
bridge | pointer to a gxPLBridge object |
insetting | new inside network setting |
- Returns
- 0, -1 if an error occurs