A C-library which "hides" the ElektorBus-protocols (ElektorMessageProtocol and ApplicationProtocol) and makes the actual bus-application-code running on a microcontroller-node hardware-independent. Furthermore, this ElektorBus-library is hardware-independent itself.
The ElektorBus-Library is now part of a bigger project, the Embedded Firmware Library EFL. See
To hide the ElektorBus-protocols from the application-developer, the lib offers functions like
void SetValue(unsigned char sender, unsigned char receiver, unsigned char channel, unsigned char mode, int setvalue);
void TransmitValue(unsigned char sender, unsigned char receiver, unsigned char channel, unsigned char mode, int currentvalue);
which actually add a Part (unit of information, here a number from -1023..1023) to a buffer of parts, which will be encoded to a bus-message and sent out with the command
Additionally the lib defines some "callback-functions" like
This function is called every time a part was received. The application programmer has to implement this function in his application code, which is located in the main-C-file.