Closed troky closed 2 years ago
Providing this kind of abstraction is a lot of effort if its done manually (just by my own). Therefore the question 2 years ago was, how to do this automatically. The problem was that the event information was only available in the wiki. So I decided to write a wiki parser, which generated more or less the files automatically. Unfortunately, the wiki changed again.
The vision is to have the whole event informations in a xml file and use this as single source to generate them and additional other stuff as well. I am working on it in the background, but not ready right now.
This means you have to this by your own right now, e.g.
extern BOOL vscp_information_sendAliveEvent(uint8_t userData, uint8_t zone, uint8_t subZone)
{
vscp_TxMessage txMsg;
vscp_core_prepareTxMessage(&txMsg, VSCP_CLASS_L1_INFORMATION, VSCP_TYPE_INFORMATION_ALIVE, VSCP_PRIORITY_3_NORMAL);
txMsg.dataNum = 3;
txMsg.data[0] = userData;
txMsg.data[1] = zone;
txMsg.data[2] = subZone;
return vscp_core_sendEvent(&txMsg);
}
If you like, you can provide a file e.g. for CLASS1.DISPLAY via pull request. :-)
Ok, will do.
BTW, have you ever considered renaming that dataNum to something less confusing with meaning like dataLen? :)
Always a question of the perspective ... what about dataSize :-)
dataSize is also fine
How can I add unimplemented events, e.g. CLASS1.DISPLAY etc? I see those files are auto-generated.