Page 1 of 1

How to receive CAN data word larger than 4 bytes

PostPosted: Sat Mar 24, 2012 8:43 pm
by oz_olly
Hi,

I have been setting up a custom CAN template for an INSGPS device. The lattitude and longitude are each 6 byte singed integers, 1 count=180/2^39 degrees. The ACL will not allow me to receive a word longer than 4 bytes. I have looked for a concatenate function within both the ACL manager and i2 Pro but can't find one. I am thinking I will have to write a custom function or plug in to concatenate and then apply the scaling. My plan would be to receive the 6 byte word as qty 3, 2 byte unsigned words. I would then have my plugin convert the numbers back to binary and concatenate the the words together then convert to decimal and scale to give the ouput as a channel.

Has anyone had experience with this, if not does my approach sound sensible and feasible. I am not very familiar with VB but I work with some data acquisition software engineers who may be able to help me write the script.

Cheers

Olly

Re: How to receive CAN data word larger than 4 bytes

PostPosted: Fri Apr 06, 2012 1:10 am
by Hugh
Olly,

It might not be exactly the same problem, but on this thread http://www.motec.com/forum/viewtopic.php?f=13&t=169&sid=050e7d84195f43a4ea3ab788ccbcb0f7 there is a discussion on how to get the long GPS word into the original ADL dash.

The answer was to break the GPS words down into degrees minutes and seconds then recombine.

Somewhere about reply 6 the interesting reading starts.

Cheers

Hugh