CAN ADC & Generic Sensor Inputs Precision?
Moderators: jsmcortina, muythaibxr
CAN ADC & Generic Sensor Inputs Precision?
Hi all,
So i have some values being transmitted on to the CANBUS that i would like the MS3 to read, display in TS and log.
The values are fractional (voltages, pressures, etc), so are multiplied by 100 and transmitted in L4S.
I have CAN Reading setup with the appropriate CAN settings, with mult=1 div=100 and add=0.
Generic Sensor Inputs are setup as being RAW inputs, with 100 lag.
Why are all the readings being displayed/logged rounded down to the nearest decimal place?
For example, one of the values is battery voltage, so is a value of 13.83V, which is put on the CANBUS as 1383. It appears as 13.0V in TS and the logs.
What can i do about this?
Thanks!
So i have some values being transmitted on to the CANBUS that i would like the MS3 to read, display in TS and log.
The values are fractional (voltages, pressures, etc), so are multiplied by 100 and transmitted in L4S.
I have CAN Reading setup with the appropriate CAN settings, with mult=1 div=100 and add=0.
Generic Sensor Inputs are setup as being RAW inputs, with 100 lag.
Why are all the readings being displayed/logged rounded down to the nearest decimal place?
For example, one of the values is battery voltage, so is a value of 13.83V, which is put on the CANBUS as 1383. It appears as 13.0V in TS and the logs.
What can i do about this?
Thanks!
Toyota Celica GT4/Alltrac with 5S-GTE stroker (2.2L I4 turbo, high CR) on E85 w/FlexFuel.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
-
- Site Admin
- Posts: 39615
- Joined: Mon May 03, 2004 1:34 am
- Location: Birmingham, UK
- Contact:
Re: CAN ADC & Generic Sensor Inputs Precision?
Generic Sensors are one decimal place.
James
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".
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".
Re: CAN ADC & Generic Sensor Inputs Precision?
Thanks James, but that doesn't seem to be the case.
Ive double checked... as i said, a value of 13.83V, which is put on the CANBUS as 1383. It appears as 13.0V in TS and the logs. Not 13.8 as you suggest it should.
Same goes with other similar values. They all get rounded down.
BTW, i am running MS3 pre-1.4.1 beta 4.
Ive double checked... as i said, a value of 13.83V, which is put on the CANBUS as 1383. It appears as 13.0V in TS and the logs. Not 13.8 as you suggest it should.
Same goes with other similar values. They all get rounded down.
BTW, i am running MS3 pre-1.4.1 beta 4.
Toyota Celica GT4/Alltrac with 5S-GTE stroker (2.2L I4 turbo, high CR) on E85 w/FlexFuel.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
-
- Site Admin
- Posts: 39615
- Joined: Mon May 03, 2004 1:34 am
- Location: Birmingham, UK
- Contact:
Re: CAN ADC & Generic Sensor Inputs Precision?
Sounds perhaps like a rounding error within the calculation. It is still "precise" to 1 decimal, but rounded.
Please post your MSQ.
James
Please post your MSQ.
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".
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".
Re: CAN ADC & Generic Sensor Inputs Precision?
It's attached.
Thanks again James.
Thanks again James.
Toyota Celica GT4/Alltrac with 5S-GTE stroker (2.2L I4 turbo, high CR) on E85 w/FlexFuel.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
Re: CAN ADC & Generic Sensor Inputs Precision?
Hello,
do you really send 4 bytes per Sensor?
And why?
What is the data type within you external system?
BR
do you really send 4 bytes per Sensor?
And why?
What is the data type within you external system?
BR
Alfa 156 GTA
Alfa 75 Race Car MS III -- alway latest FW
Alfa 164 V6 Turbo
Alfa 155 2,5TD RIP
Test MS II --always latest FW
Tunerstudio V2.6.11 Registered
MegaLog Viewer V3.4.04 Registered
Alfa 75 Race Car MS III -- alway latest FW
Alfa 164 V6 Turbo
Alfa 155 2,5TD RIP
Test MS II --always latest FW
Tunerstudio V2.6.11 Registered
MegaLog Viewer V3.4.04 Registered
-
- Site Admin
- Posts: 39615
- Joined: Mon May 03, 2004 1:34 am
- Location: Birmingham, UK
- Contact:
Re: CAN ADC & Generic Sensor Inputs Precision?
You could reduce CANbus traffic by sending four 16bit values per packet instead of each sensor value in its own packet.
Thanks for the MSQ, I'll try it out later.
EDIT: Thinking again, I think it is working "as expected" ish. Set it to divide by 10 and then use the generic sensors with a linear scale of 0-102.3 But I'll test later.
James
Thanks for the MSQ, I'll try it out later.
EDIT: Thinking again, I think it is working "as expected" ish. Set it to divide by 10 and then use the generic sensors with a linear scale of 0-102.3 But I'll test later.
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".
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".
Re: CAN ADC & Generic Sensor Inputs Precision?
Ah, so internally the "CAN ADCx" are all 16bit signed int's, and the Generic Sensors are 16bit signed int's / 10?jsmcortina wrote: EDIT: Thinking again, I think it is working "as expected" ish. Set it to divide by 10 and then use the generic sensors with a linear scale of 0-102.3 But I'll test later.
James
This leaves me wondering why the "CAN ADCx" variables exist at all?
Why not go directly from CANBUS input data into the Generic Input vars?
Toyota Celica GT4/Alltrac with 5S-GTE stroker (2.2L I4 turbo, high CR) on E85 w/FlexFuel.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
Re: CAN ADC & Generic Sensor Inputs Precision?
James, do you mind if i send you a PM?
Toyota Celica GT4/Alltrac with 5S-GTE stroker (2.2L I4 turbo, high CR) on E85 w/FlexFuel.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
MS3 + MS3X + KnockBoard + RTC + BT + DIY CAN-IO-Board + DIY CAN Digital Dash.
-
- Site Admin
- Posts: 39615
- Joined: Mon May 03, 2004 1:34 am
- Location: Birmingham, UK
- Contact:
Re: CAN ADC & Generic Sensor Inputs Precision?
Because they are used for other things besides generic sensors.MWPau wrote:Ah, so internally the "CAN ADCx" are all 16bit signed int's, and the Generic Sensors are 16bit signed int's / 10?
This leaves me wondering why the "CAN ADCx" variables exist at all?
Why not go directly from CANBUS input data into the Generic Input vars?
PM ok.
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".
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".
-
- Site Admin
- Posts: 39615
- Joined: Mon May 03, 2004 1:34 am
- Location: Birmingham, UK
- Contact:
Re: CAN ADC & Generic Sensor Inputs Precision?
In your case, you are receiving processed data instead of ADC data as it was designed for. So, an option in the CAN Receiving screen to store directly to the Generic Sensors would probably make sense.
(Allowing that is pretty simple, but checking for conflicts and cleanly enabling datalogging isn't so straighforward.)
James
(Allowing that is pretty simple, but checking for conflicts and cleanly enabling datalogging isn't so straighforward.)
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".
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".