Install a UDP Config Server user callback function
|[in] ||udpcfgUserCbFuncPtr ||Pointer to user's callback function.|
- 0 : success
- This function installs a user callback function for the UDP Config Server. This function will be invoked when a UDP configuration request with command number 06 is received. This allows you to implement your own UDP Config sub protocol and commands.
A connection handler function must be declared in the following way:
The UDP Cfg callback function is passed an argument with information about the UDP Cfg Request and its requester. If the callback function sets a pointer in the dataPtr member of the UDPCFGSRV_USERCBINFO structure, the UDP Config server will send the referenced data using the dataLength member of the structure for the byte count. If this pointer is set to null or the dataLength field is set to 0 then no data will be sent back to the requester.
The amount data sent and received is limited to 1024 bytes maximum. To remove an installed callback function, call this API function with a null pointer.
The function will be automatically uninstalled, if the application exits.
For more information on the UDP Config Server and its protocol have a look at the UDP Config Server description available on our website.
- SC2x3 V1.00 - CLIB V1.00