06-14-2006 03:09 AM
06-15-2006 05:20 AM
06-19-2006 01:21 AM
Hello KC.
Thank you for your Answer. The mode of my string control is already Hex mode. The problem is, that the wire between my string constant an the CAN send VI ist broken if I connect them. The Error message is that the Datasource ist string and the Data sink is 1D Array of double. Is it possible to but the Input mode of the CAN send VI into HEX mode? When I press the right mouse button I don´t have the alternative to select HEX mode!
Thank you
06-19-2006 01:37 AM
Hi,
Then you have to convert the string into a array of numbers with the 'string to byte array' function.
06-19-2006 06:31 AM
Hi KC.
I have testet your suggestion but the problem is, that the device to which i send my message needs the 6 Byte Data in one piece. Do you know any other possibility to send the string ( for examle 0501 44880000 ) in one piece to my device an particularly to recieve this string in the same form as I send it? ( in the example 05 is a channel type, 01 is a channel number and 44880000 is the Hex value for the float value 4,25 ). The recieving device needs the complete information in ONE 6 Byte message.
Thank you
06-19-2006 06:36 AM - edited 06-19-2006 06:36 AM
I don't see the problem You send a string with one send command.
Have a look at this. http://forums.ni.com/ni/board/message?board.id=140&message.id=17616&jump=true
Try my VI COM port.vi (several LV versions there) Make sure you know how to terminate (or not) the command to your device.
Sorry mixed up some post, You are the CAN guy
Get back to you
Message Edited by K C on 06-19-2006 01:39 PM
06-19-2006 06:45 AM
Your CAN VI is expecting the data in a 1D array (DBL) If you convert your ASCII data into an byte array you can wire this to your CAN vi data input.
If I look at the CAN VI i think it should work.
If it's not working can you tell me what CAN VI's you are using or can you post a VI with your (basic) program ?
06-20-2006 06:32 AM
06-20-2006 06:53 AM
Hi,
I am afraid that I put you on the wrong track.
Take a look at this VI (LV8) You convert ASCII characters to a byte array. A ASCII '0' (Zero) is in hex 0x30 is decimal 48
You should set your ASCII constant in HEX mode in this way a zero is a 'real' zero.
You can answer in German if you like I can read that. Mein schreiben in Deutsch a;sojfioehrgo;hg .
06-20-2006 07:01 AM
Hi.
I will have a look at your VI soon. I´d like to answer you in english because it´s a good training for me