08-02-2010 10:48 AM
Hi anyone knows what does it mean, when using an isolated USB2RS232 port, receiving exactly the same message that I sent?
I'm interrogating a custom frequency converter, with its own protocol, and the device responds with the same message I sent.
Basic serial settings, read bytes at port and so on.
The company who build it is sending me their rs232 port converter, so to make sure why they are successful and me not.
Thanks
Solved! Go to Solution.
08-02-2010 01:16 PM
If the instrument is not simply set to echo everything, then perhaps you are sending the incorrect command, sending the command incorrectly formatted, or the incorrect termination character.
You have not provided the protocol or details on what you are sending or how, what language, what functions, etc.
08-03-2010 01:32 AM
Hi it is a proprietary protocol. I was asking for the DC Bus voltage. The frame is made up of:
first 3 bytes 313131 in hex
1 byte for length (info+param)
1 byte for query information
1 byte for the parameter I am asking
1 byte for checksum (sum length+info+param and truncate at 8 bit)
I sent 313131 02 61 05 68 where 02 is the length, 6 means analog values, 1 means query, 05 means DC bus, 68 checksum.
The answer had to be 313131 04 62 05 0CF8 6F. I'm receiving what I sent and even I send "Homer Simpson", I get "Homer Simpson".
The doubt is the termination char which no one gave me instructions.
08-03-2010 10:01 AM
And how exactly are you sending the hex characters? You still haven't provided the language you are using. If it's LabVIEW, you need to set a string control/constant to hex display, convert a U8 array with Byte Array to String, the Typecast or Flatten to String function.
08-04-2010 01:24 AM
Sure, I'm using LabVIEW. The string control is set to HEX display. I'm able to talk to modbus devices pretty easy in this way. The problem seems to be the serial interface of the frequency converter which works with 0-5V levels. I will be waiting for the converter and then write here again.
08-09-2010 09:28 AM
It was the serial interface the problem. The one I got from the inverter supplier is a custom made RS232 device, working on 0-5V levels.
04-07-2011 01:53 AM
Hi everyone!
I have a problem to send and recieve data from rs232 (my cable is USB to COM). How to distinguish between a byte we had already read and a new byte in a stream data byte ???
Thank you so much!
04-07-2011 02:02 AM
Hi, there is a cycle while reading the bytes. Where si the problem?
04-07-2011 02:06 AM
Hi flori!
My problem is that I can't distinguish between a byte I have already read and a new byte in a frame data from rs232. How can we do this ?
Thanks
04-07-2011 02:09 AM
Normally, using a cycle you always read (if present) new bytes. How does your device respond to a request/command?