Hi
I'm using PLC-TMDSPLCKIT V3.
I want to know how to read this device ID?
And I try to write some code to read the PLC's product id.
I refer to PRIME Host Message Protocol Specification this datasheet.
In p.59, it talks about GET_INFO(Meaage Type 0x14), and I want to get the information inside of it.
And in p.69, I try to write the code.
MSG_TYP = 0x14; //GET_INFO
MSG_ORG = '1'; //originated from PLC
MSG_RPY = '0'; //need reply message
MSG_BDY = uint16_t blob_id; // blob id to identify the blob
uint16_t blob_len; // length in bytes of blob to read
uint16_t blob_addr; //start address of the blob, only exist when blob_id=4
I don't know what else I need to write in the code and my code is use it right or anything wrong.
Any suggestion or information would be appreciated
Thanks,
Wayne