Gm bcm and cluster can bus messages through eml327 script

Disassembly, Reassembly, Tools and devleopment. Going deep with Hardware and Software.
gmtech825
Posts: 186
Joined: Fri Feb 24, 2017 11:27 am

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by gmtech825 »

have you tried ATAL (allow long messages)?
04colyZQ8
Posts: 380
Joined: Thu Jan 16, 2014 12:41 pm
cars: 2004 Colorado 4.8L swap
86/90 Jimmy 6.5L diesel swap
80 Chevrolet Silverado TBI swap
88dodge W100 LPG conversion

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by 04colyZQ8 »

gmtech825 wrote:have you tried ATAL (allow long messages)?
Soon no i haven’t will do soon
04colyZQ8
Posts: 380
Joined: Thu Jan 16, 2014 12:41 pm
cars: 2004 Colorado 4.8L swap
86/90 Jimmy 6.5L diesel swap
80 Chevrolet Silverado TBI swap
88dodge W100 LPG conversion

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by 04colyZQ8 »

gmtech825 wrote:have you tried ATAL (allow long messages)?

Yes it took awhile though because I had to Re-write the code in C sharp the python wasn’t cutting it!

Now the header stays correct for the bcm!
So it’s definitely finicky when it comes to setting times between messages on the elm327

Cable I got a great rhythm going for the initial setup!
Sleep for 2000 or about 2 seconds between prompts

However I’m having an issue unlocking it!

If I use putty I get 6416702 back which I believe is a positive unlock?

However my c# script is saying 6412701seed

So I have messed with timming and can’t seem to get it right here, seems
Like something else is the issue?

In putty I turn if wrapping and send automatic lf and cr
Which is /r/n so far as I know

Right now my c# is sending /r only but it reads the seed just fine same with reading
The first part of a vin. So I can try /r/n but prob make no difference

Any ideas what to try next how much time can I go between 2701
And 2702key ?

I’m wondering if I’m just over writing the message length since it’s
A 5 byte seed and key but it works in putty so idk?

Even if I use my program to setup then exit and open putty and all I send in putty is
2701
2702key boom postive unlock return message?
So strange why I can’t get it to work in the program

Also still not having any luck with sending or reading longer messages !
So 1A DF
Should return 00 00 06 41 1A DF xx xx xx xx xx xx xx xx xx xx

Which is 15 bytes right? So how come it’s cutting it off like this ..

00 00 06 41 1A DF xx xx xx

That’s what it’s sending

Plus If I send 3B DF xx xx xx xx xx xx xx xx xx xx
I should get 00 00 06 41 7F 31 //rejected

Yet I get ? //Return from the elm which leads me to believe it’s just not
Liking that long of a message.

Yes I’m using atal , how many bytes is that?

Can I split it up? Can I send part then don’t send /r but just send the rest?

What’s the max length an elm327 should handle?
User avatar
Gampy
Posts: 2330
Joined: Sat Dec 15, 2018 7:38 am

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by Gampy »

You should not need to change the wrapping and crlf PuTTY settings ... The only PuTTY settings you should change are, the radio button to select Serial, and then the Serial line and Speed.

The ELM interpreter only cares about return ('\r') (0x0D), newlines ('\n') (0x0A) are ignored, ATL1 should not be used in programs, nor should E1, in fact it should be E0.

There is a good chance you are working with a numb ELM and it cannot do as asked, and or it could be your code (program), it's hard to say without seeing more.
Like how you're reading and handling the incoming data stream, how you're sending commands.

If the interpreter returns a '?', it didn't understand the question ...

-Enjoy
Intelligence is in the details!

It is easier not to learn bad habits, then it is to break them!

If I was here to win a popularity contest, their would be no point, so I wouldn't be here!
User avatar
antus
Site Admin
Posts: 8237
Joined: Sat Feb 28, 2009 8:34 pm
cars: TX Gemini 2L Twincam
TX Gemini SR20 18psi
Datsun 1200 Ute
Subaru Blitzen '06 EZ30 4th gen, 3.0R Spec B
Contact:

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by antus »

Any ideas what to try next how much time can I go between 2701
And 2702key ?
You should be able to send back the 2702 the moment you get the 2701. It sounds like you have something else going wrong in your app. If putty is showing you getting back the 2702 and your app is showing 2701 I think your app comms has the problem. The 2701 you see would either be an echo (which you can turn off in the init, or read properly if you expect it). Or if its the same buffer it might not have updated at all and it just still has the contents from the last message you sent outbound.
Have you read the FAQ? For lots of information and links to significant threads see here: http://pcmhacking.net/forums/viewtopic.php?f=7&t=1396
04colyZQ8
Posts: 380
Joined: Thu Jan 16, 2014 12:41 pm
cars: 2004 Colorado 4.8L swap
86/90 Jimmy 6.5L diesel swap
80 Chevrolet Silverado TBI swap
88dodge W100 LPG conversion

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by 04colyZQ8 »

Gampy wrote:You should not need to change the wrapping and crlf PuTTY settings ... The only PuTTY settings you should change are, the radio button to select Serial, and then the Serial line and Speed.

The ELM interpreter only cares about return ('\r') (0x0D), newlines ('\n') (0x0A) are ignored, ATL1 should not be used in programs, nor should E1, in fact it should be E0.

There is a good chance you are working with a numb ELM and it cannot do as asked, and or it could be your code (program), it's hard to say without seeing more.
Like how you're reading and handling the incoming data stream, how you're sending commands.

If the interpreter returns a '?', it didn't understand the question ...

-Enjoy

Ok I’ll try changing the echo to E1.
And remove atl1

When ever I send something the elm doesn’t recognize as a legal command it returns ?
If it’s legal command it returns ok.

So trying to send over 10 bytes it returns ?

So I know it’s not able to send or receive over 10 bytes.

Maybe at cea hh or something can help with that? Or maybe it’s the max an elm327 can send ?
04colyZQ8
Posts: 380
Joined: Thu Jan 16, 2014 12:41 pm
cars: 2004 Colorado 4.8L swap
86/90 Jimmy 6.5L diesel swap
80 Chevrolet Silverado TBI swap
88dodge W100 LPG conversion

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by 04colyZQ8 »

antus wrote:
Any ideas what to try next how much time can I go between 2701
And 2702key ?
You should be able to send back the 2702 the moment you get the 2701. It sounds like you have something else going wrong in your app. If putty is showing you getting back the 2702 and your app is showing 2701 I think your app comms has the problem. The 2701 you see would either be an echo (which you can turn off in the init, or read properly if you expect it). Or if its the same buffer it might not have updated at all and it just still has the contents from the last message you sent outbound.

I have a condition in a loop until the message length is at least 6 bytes do not print the buffer, after that print it. Of course I tried changing byte size doesn’t seem to matter to much but I should be getting back
00 00 06 41 67 02, which is 6 bytes right? Are the leading zeros and user defined header counted as well?
04colyZQ8
Posts: 380
Joined: Thu Jan 16, 2014 12:41 pm
cars: 2004 Colorado 4.8L swap
86/90 Jimmy 6.5L diesel swap
80 Chevrolet Silverado TBI swap
88dodge W100 LPG conversion

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by 04colyZQ8 »

Put a 5 second timmer between sending
2701
And
2702 key

Getting positive unlock msg back I think?
641106702

So now it’s just a matter of sending longer messages if possible!
ironduke
Posts: 579
Joined: Thu Feb 13, 2020 11:32 pm
cars: Mainly GM trucks, a Cruze and an Equinox for dailys..

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by ironduke »

Very surprised you can wait 5 seconds between asking for seed and sending key..

I was never able to get any of my elm devices to send long messages.. What I did was turn off can formatting and send the "long message" line by line.. You'll have to research how they're formatted and then copy the formatting..

basically with CAN formatting ON the length byte and counter bytes are done for you.. If you turn it off you have to do it yourself.. for example 00 00 02 41 27 01 would need to be send as 00 00 02 41 02 27 01 where the 02 is the length byte..

It gets harder with messages longer than 7 bytes.. The 1st message has 10 for length but to say that it's going to be multiline and then the next byte is number of bytes..
After that each line has a counter instead of byte length byte.. starts at 0x21 and goes up to 0x2f and then resets to 0x20 and loops repeatedly..
This is from memory but to write the vin it's something like

00 00 02 41 10 13 3B 90 01 02 03 04
>> Here is where the ecu would send a 00 00 06 41 01 30 back in response for you to send the rest of the data..
00 00 02 41 21 05 06 07 08 09 10 11
00 00 02 41 22 12 13 14 15 16 17 00

Also maybe get in the habit of adding zero's at the end to make up a complete 12 bytes.. With CAN on I have seen some elms do it for you and other didn't.. With it off it is up to you to do it..
Some modules work ok without the message being 12 bytes, others not so happy..
04colyZQ8
Posts: 380
Joined: Thu Jan 16, 2014 12:41 pm
cars: 2004 Colorado 4.8L swap
86/90 Jimmy 6.5L diesel swap
80 Chevrolet Silverado TBI swap
88dodge W100 LPG conversion

Re: Gm bcm and cluster can bus messages through eml327 scrip

Post by 04colyZQ8 »

ironduke wrote:Very surprised you can wait 5 seconds between asking for seed and sending key..

I was never able to get any of my elm devices to send long messages.. What I did was turn off can formatting and send the "long message" line by line.. You'll have to research how they're formatted and then copy the formatting..

basically with CAN formatting ON the length byte and counter bytes are done for you.. If you turn it off you have to do it yourself.. for example 00 00 02 41 27 01 would need to be send as 00 00 02 41 02 27 01 where the 02 is the length byte..

It gets harder with messages longer than 7 bytes.. The 1st message has 10 for length but to say that it's going to be multiline and then the next byte is number of bytes..
After that each line has a counter instead of byte length byte.. starts at 0x21 and goes up to 0x2f and then resets to 0x20 and loops repeatedly..
This is from memory but to write the vin it's something like

00 00 02 41 10 13 3B 90 01 02 03 04
>> Here is where the ecu would send a 00 00 06 41 01 30 back in response for you to send the rest of the data..
00 00 02 41 21 05 06 07 08 09 10 11
00 00 02 41 22 12 13 14 15 16 17 00

Also maybe get in the habit of adding zero's at the end to make up a complete 12 bytes.. With CAN on I have seen some elms do it for you and other didn't.. With it off it is up to you to do it..
Some modules work ok without the message being 12 bytes, others not so happy..
ok no I was using sp6, I did also set sp2c user defined Can so I could attempt to ty and change data length it says its variable DLC but seems not to be the case.

either way how to read multi line response? Vin should come on more than one line? right?
Post Reply