ms3pro with 'A' command..

Testing and development of Megasquirt 3

Moderators: jsmcortina, muythaibxr

prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

ms3pro with 'A' command..

Post by prop »

Dear James:
I try to develop a electric dash for ms3pro,
In the beginning I wrote a VB program to read rpm,ign advance,map,mat
, clt and TPS by using the 'A' command.
All seems good But the TPS.--- It freezed at "3097.7" which means U24=121 and U25=1 so 121x256+1= 30977, Then times 0.1(scale)= 3097.7
I check my program hundred times and verified it with mini terminal in TS, The value is right --- U24=121 and U25=1, But in TS TPS read no problem and changing normal...
I search ms3pro.ini too; Seems no where for TPS value but only U24 and 25, Can you help me to solve that?

Regards

Howard
From Taiwan
Reverant
Super MS/Extra'er
Posts: 1233
Joined: Sat Apr 15, 2006 12:39 am
Location: Athens, Greece

Re: ms3pro with 'A' command..

Post by Reverant »

Check your indianess, it's probably 377.
The man behind MS Labs
2005 Audi A3 2.0L TFSI DSG AWD - Extreme MS3
2002 Mazda Miata 1.8 6sp - Enhanced MS3 1.4.0, sequential injection, sequential ignition, big turbo, lots of boost
grom_e30
Super MS/Extra'er
Posts: 4459
Joined: Thu Mar 08, 2012 12:44 pm
Location: UK

Re: ms3pro with 'A' command..

Post by grom_e30 »

are you pulling data via serial?
1990 bmw 320i daily driver with m20b25 ms3 sequential fuel, 380cc injectors, d585 coil near plug, home made cam sync, launch control, fan control, vss, homebrew egt logging what's next????
prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

Re: ms3pro with 'A' command..

Post by prop »

Reverant wrote:Check your indianess, it's probably 377.
Hi:
What you mean "indianess"? What is this?
prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

Re: ms3pro with 'A' command..

Post by prop »

grom_e30 wrote:are you pulling data via serial?
Yes,I do it via rs232.
I can read rpm,ign advance,map,mat and clt no problem, But the TPS seems nuts, And no changes on number 24 & 25 byte when I move the throttle....But they do works in the TS...
I check it byte by byte. and I'm pretty sure that the program is right ,But the 24 and 25 byte still never change value when I move the throttle... Again in TS,Everything just work fine.
Actually I ask Phil at support@efianalytics.com ,He said that TS do use 'A' command to obtain real time variable from ms3pro too.....

Regards

Any help appreciated.
prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

Re: ms3pro with 'A' command..

Post by prop »

I verified in TS:
When tps works correctly, I switch to mini terminal and send 'A' command.
----- I found same phenomenon like in my VB program! The u24 and 25 never change when I move throttle....Obviously my program do read real data from ms3pro like TS!
prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

Re: ms3pro with 'A' command..

Post by prop »

Hi:
Will 'A' command involved with http://www.msextra.com/forums/viewtopic ... 25&t=41274 ??
Do I have to consider with this issue?
jsmcortina
Site Admin
Posts: 39615
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: ms3pro with 'A' command..

Post by jsmcortina »

Enable "Hex" in Miniterminal and send an 'A' to the Megasquirt.

Compare the results with what your programme is seeing.

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
grom_e30
Super MS/Extra'er
Posts: 4459
Joined: Thu Mar 08, 2012 12:44 pm
Location: UK

Re: ms3pro with 'A' command..

Post by grom_e30 »

funnily enough i was pulling data using an arduino, I had problems reading the tps on ms3 but worked on ms2 correctly, so i read the tps adc and mapped that to give me 0-100% and that works fine but battery voltage was strange should be bytes 26+27 but that gave strange numbers (again worked correctly on ms2) i found that just using byte 27 gave a correct battery reading, and finally the coolant temp reads funny through my arduino it kind of goes in steps it will read 80c, any temp above that it will still read 80, so at 85 it will still report 80 until the temp hits 90 then it will read 90 until the temp goes past 100 then it will jump again.
1990 bmw 320i daily driver with m20b25 ms3 sequential fuel, 380cc injectors, d585 coil near plug, home made cam sync, launch control, fan control, vss, homebrew egt logging what's next????
jsmcortina
Site Admin
Posts: 39615
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: ms3pro with 'A' command..

Post by jsmcortina »

Sounds like your Arduino is mishandling the data?

Same question - what is the raw data you are seeing and how does that compare to the raw data that shows in Miniterminal.

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
grom_e30
Super MS/Extra'er
Posts: 4459
Joined: Thu Mar 08, 2012 12:44 pm
Location: UK

Re: ms3pro with 'A' command..

Post by grom_e30 »

to be honest i put that project on hold as i was able to display everything i needed to, il get back to it soon and report back
1990 bmw 320i daily driver with m20b25 ms3 sequential fuel, 380cc injectors, d585 coil near plug, home made cam sync, launch control, fan control, vss, homebrew egt logging what's next????
grom_e30
Super MS/Extra'er
Posts: 4459
Joined: Thu Mar 08, 2012 12:44 pm
Location: UK

Re: ms3pro with 'A' command..

Post by grom_e30 »

this is a dump from an 'A' using a terminal program on my computer,

bytes 18&19 map 0x03ea =1002 x0.1 = 100.2 correct
bytes 24&25 tps 0xb300 = 45824 x 0.1 would = 4582 %
bytes 26&27 battery 0xfd7a = 64890 x 0.1 = 6489v
bytes 28&29 afr1 0x00df = 223 x 0.1 = 22.3 afr correct

correct me if i am wrong.
1990 bmw 320i daily driver with m20b25 ms3 sequential fuel, 380cc injectors, d585 coil near plug, home made cam sync, launch control, fan control, vss, homebrew egt logging what's next????
jsmcortina
Site Admin
Posts: 39615
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: ms3pro with 'A' command..

Post by jsmcortina »

That data looks odd, here's what I see:
From A
00 32 07 d0 07 d0 00 00 00 00 00 01 93 93 01 01
03 e1 03 e1 04 51 08 70 00 43 00 7c 00 91 00 00
00 00 03 e8 03 e8 03 9d 00 64 00 00 00 64 03 e8
00 64 03 e8 03 e8 00 00 00 00 ff ee 00 00 00 3c
...

In TSlog
23/08/14 12:12:46 :Time: 0:33.841: Received, 124 bytes
x00 x2F x07 xD0 x07 xD0 x00 x00 x00 x00 x00 x01 x93 x93 x01 x01 ./..............
x03 xE1 x03 xE1 x04 x51 x08 x79 x00 x43 x00 x7C x00 x91 x00 x00 .....Q.y.C.|....
x00 x00 x03 xE8 x03 xE8 x03 x9D x00 x64 x00 x00 x00 x64 x03 xE8 .........d...d..
x00 x64 x03 xE8 x03 xE8 x00 x00 x00 x00 xFF xFC x00 x00 x00 x3C .d.............<

24,25 = 0x0043 = 67 -> 6.7% = correct
26,27 = 0x007c = 124 -> 12.4V = correct

This is with current MS3 firmware. I tested with MS2/Extra in Miniterminal and get similar results.
Please repeat your test using TunerStudio MiniTerminal in hex mode.

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

Re: ms3pro with 'A' command..

Post by prop »

jsmcortina wrote:Enable "Hex" in Miniterminal and send an 'A' to the Megasquirt.

Compare the results with what your programme is seeing.

James
Dear James:
That's really nice to got your reply. :D
I did set to HEX in miniterminal and the value are in the same like my VB.
Even the sample program from (http://www.msextra.com/doc/ms2extra/RS232_MS2.html) got the same saturation --- tps halt and shows a ridiculous value.
I asked Pill, They said they do use 'A' command in TS as well
Again, Thanks for your reply.

Cheers

Howard
Last edited by prop on Sat Aug 23, 2014 7:36 am, edited 1 time in total.
prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

Re: ms3pro with 'A' command..

Post by prop »

grom_e30 wrote:funnily enough i was pulling data using an arduino, I had problems reading the tps on ms3 but worked on ms2 correctly, so i read the tps adc and mapped that to give me 0-100% and that works fine but battery voltage was strange should be bytes 26+27 but that gave strange numbers (again worked correctly on ms2) i found that just using byte 27 gave a correct battery reading, and finally the coolant temp reads funny through my arduino it kind of goes in steps it will read 80c, any temp above that it will still read 80, so at 85 it will still report 80 until the temp hits 90 then it will read 90 until the temp goes past 100 then it will jump again.
Sir:
You are right!
Some time TS gots funny value, The volts read out never accurate inTS: I confirm by volt meter and oscillator scope, It shows 1~ 1.5 volts deference .
Also the same on O2 gauge: I switched between TS and PLX O2 A/F meter , They never identical.

Regards

Howard
Last edited by prop on Sat Aug 23, 2014 10:56 pm, edited 2 times in total.
jsmcortina
Site Admin
Posts: 39615
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: ms3pro with 'A' command..

Post by jsmcortina »

So, what values do you see in MiniTerminal and what values are you seeing in your VB programme. The original post isn't talking about a 1V difference, but a totally incorrect reading. These are two different issues.

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

Re: ms3pro with 'A' command..

Post by prop »

jsmcortina wrote:So, what values do you see in MiniTerminal and what values are you seeing in your VB programme. The original post isn't talking about a 1V difference, but a totally incorrect reading. These are two different issues.

James
Yes,The volts read out not accurate is another issue.
Attached is my VB's result..

Howard
S01.gif
jsmcortina
Site Admin
Posts: 39615
Joined: Mon May 03, 2004 1:34 am
Location: Birmingham, UK
Contact:

Re: ms3pro with 'A' command..

Post by jsmcortina »

That wasn't MiniTerminal.

James
I can repair or upgrade Megasquirts in UK. http://www.jamesmurrayengineering.co.uk

My Success story: http://www.msextra.com/forums/viewtopic ... 04&t=34277
MSEXTRA documentation at: http://www.msextra.com/doc/index.html
New users, please read the "Forum Help Page".
prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

Re: ms3pro with 'A' command..

Post by prop »

jsmcortina wrote:So, what values do you see in MiniTerminal and what values are you seeing in your VB programme. The original post isn't talking about a 1V difference, but a totally incorrect reading. These are two different issues.

James
Dear James:
Here are another time I turn off ms3pro, Then turn on, I got the result in TS, The sample VB program, miniterminal and My VB...
In TS, tps value is correct and changes when I move the throttle. Others halt and seems funny.
S014.gif
S012.gif
S015.gif
prop
MS/Extra Newbie
Posts: 14
Joined: Thu Oct 10, 2013 8:28 pm
Location: Taiwan

Re: ms3pro with 'A' command..

Post by prop »

prop wrote:
jsmcortina wrote:So, what values do you see in MiniTerminal and what values are you seeing in your VB programme. The original post isn't talking about a 1V difference, but a totally incorrect reading. These are two different issues.

James
Another VB's result..
S013.gif
Post Reply