minhtham Posted August 19, 2016 Share Posted August 19, 2016 Dear Support! I have problems in reading data from the controller Carel, because it uses the protocol Carel, not supported by DAQ. I want to create a new protocol to read data in the DAQ. I need an example of creating new protocols and steps to implement them. I have a document about Carel protocol is attached below. Thank you! Link to comment Share on other sites More sharing options...
AzeoTech Posted August 19, 2016 Share Posted August 19, 2016 I'm sorry, but we can't accept .dll or .docx attachments. Please repost the protocol specs as a PDF. Link to comment Share on other sites More sharing options...
minhtham Posted August 20, 2016 Author Share Posted August 20, 2016 Carel protocol is attached below. Carel Protocol.pdf Link to comment Share on other sites More sharing options...
AzeoTech Posted August 23, 2016 Share Posted August 23, 2016 Start by using the command monitor and make sure you get the response you expect from the device. Use \ notation to enter hex values, such as \x05\x3A. Once you are sure it responds as documented, create a sequence, then use the device.myDevice.purge(), write() and readUntil() to post the queries automatically and respond. There should be general sample script on this forum in a number of locations. The general form is: private string datain device.mydevice.purge() while(1) try device.mydevice.write(chr(0x05) + chr(0x3a)) datain = device.mydevice.readuntil(3) // parse data // .... catch() ? strLastError endcatch delay(1) endwhile Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.