Line Pressure dead...

A forum for discussing applications and implementations of the MegaShift transmission controller code for the GPIO from B&G. This can control up to 8-speeds and 6 shift solenoids (plus a 16x9 table for controlling a PWM line pressure valve). It has manual and fully automatic modes (16x9 load x speed table), with under and over rev-limit protection, and full data logging of all inputs and outputs (among many other abilities). A TransStim to test your completed board is also available.
mill3833
Posts: 72
Joined: Mon Jan 27, 2014 3:33 pm

Re: Line Pressure dead...

Post by mill3833 »

Lance,

I didn't get to spend much time in the garage tonight. Am still confused on some of this. I appreciate your patience with this, as it is probably something I'm missing. In your last email you said:

>>The limits in the present code are that a 0-5V signal maps into 0 to 1023 ADC counts
and
>>BTW, you can certainly have the ADC count reported. This is covered in the manual here: http://www.msgpio.com/manuals/mshift/V41tune.html#gi

I looked over the reference material expecting to find a reference to different offset value that would represent the Line_ADC_raw value. But couldn't find it. The way I'm thinking this works, is, that the value linepressure maps to offset 20 (memory address) and that value already is calibrated for the default sensor. That is, software parameter linepressure = 0 psi with an input voltage of 0.5V. So how is it possible to see the raw ADC value without getting it from a different internal memory location? From everything I'm seeing, linepressure (offset 20) is not a 0-5V input, 0-1023ADC output signal. It might start out that way, but there is more math applied to it (slope, offset) before it is reported out on memory location offset 20.

>>Could you try changing the pressure values by 10x (i.e. 0,1060) and 0.10x (0,10.6) and see what happens in each case?

Am guessing you just want me to map out more values, to help bound the issue. I can't do 1060, that would be 1060 psi. But I can do more points in between 100 and zero psi.

Will post more data in the following days.

And thanks again for taking the time to help me understand this. Dave
Bernard Fife
Posts: 1696
Joined: Fri Apr 04, 2008 1:28 pm

Re: Line Pressure dead...

Post by Bernard Fife »

Dave,

The ADC count is not stored at all in the outpc structure (or anywhere else, the ADC register is just accessed once and discarded). Instead, by using the values in the manual (0V = 0, 4.998V = 1023) the reported/stored "pressure" is essentially the same numeric value as the ADC count.

Lance.
"Never wrestle with pigs. You both get dirty and the pig likes it." - George Bernard Shaw
mill3833
Posts: 72
Joined: Mon Jan 27, 2014 3:33 pm

Re: Line Pressure dead...

Post by mill3833 »

Lance,

I made a video tonight and posted it on youtube to show you how this linepressure is responding.

For this demo, I replaced the pressure sensor with a 0-5 volt pot, and used it to drive both Aux_volts and linepressure inputs for comparison purposes. Below are the cal values used in the ini file. I have also attached the ini file.

aux_volts = scalar, U16, 26, "V", 0.001, 0.0
linepressure = scalar, U16, 20, "", 0.001, 0.0

Video is here:
http://www.youtube.com/watch?v=xDSw-_EmH88

I still don't understand what I can do with the ini file to fix this 0.48V under-run.

Let me know what you think,
Dave
Attachments
MShift.ini
(218.76 KiB) Downloaded 598 times
Bernard Fife
Posts: 1696
Joined: Fri Apr 04, 2008 1:28 pm

Re: Line Pressure dead...

Post by Bernard Fife »

Dave,

I can't tell much from the video, because it depends a lot on how the channels are set-up (for example, the line pressure may be a function of the linefactor.inc lookup table). It is better to post a datalog and the MSQ used while making the log.

The default lookup table returns 'error values' of 990 (=0.990 on the gauge) for pressures under 0.5 volts and returns error values of 999 (=0.999 on the gauge) for voltages over 4.5V and I think that is what you are seeing on the video (less than 0.5 Volts or more than 4.5 Volts are not valid for the default sensor). The presence of these values in your video indicates that you are still using the lookup table and not the 2-point calcs.

The non-CAN load value (pin 24) should always report the voltage (x1000) in aux_volts at offset 26 . To get the ADC value back from the volts, change the 0.001 value in line ~2858 from:

Code: Select all

aux_volts         = scalar, U16,   26,       "V",      0.001, 0.0
to:

Code: Select all

aux_volts         = scalar, U16,   26,       "V",      0.2048, 0.0
Then 5V will result in an internal value of 5000, which when multiplied by .2048 is 1024. The internal voltage (x1000) value is then transformed by the controller's code and put in the LOAD value by the 2-pt load calcs if there is no CAN connection setup (but the original aux_volts value is not changed).

The line pressure reports the ADC count in offset 20 when the 0,0 & 4.998,1023 values are used with the 2-point line pressure calcs (and SI_LENGTHS are not set) otherwise the table is used to lookup the line pressure from the ADC count. To use the 2-pt calcs, you need to set that up under 'Standard Inputs/Outputs Configuration -> Line Pressure Input -> Use 2-Point Calcs'. If you don't do that, you will get the table lookup values.

Note that there are 2-pt calcs for both the line pressure and non-CAN load values, but these are independent - and neither are applied to aux_volts. In theory you can use the non-CAN load 2-point calcs to get the ADC value from aux_volts, but this will mess with many other things.

If I get a chance tomorrow, I will have a look for the 0.5V offset you mention (my test bench is undergoing a rebuild at the moment, which makes it less convenient than usual).

Lance.
"Never wrestle with pigs. You both get dirty and the pig likes it." - George Bernard Shaw
mill3833
Posts: 72
Joined: Mon Jan 27, 2014 3:33 pm

Re: Line Pressure dead...

Post by mill3833 »

Hey Lance,

Well, this tip was the secret...

>>To use the 2-pt calcs, you need to set that up under 'Standard Inputs/Outputs Configuration -> Line Pressure Input -> Use 2-Point Calcs'.

After I did that, I could get a nice sweep from 0 to 5 V. And then using that menu within TS, was able to get the 2-point setup to work with my sensor.

Thanks,
Dave
Bernard Fife
Posts: 1696
Joined: Fri Apr 04, 2008 1:28 pm

Re: Line Pressure dead...

Post by Bernard Fife »

Dave,

Great, I am glad you got it sorted out.

Lance.
"Never wrestle with pigs. You both get dirty and the pig likes it." - George Bernard Shaw
Post Reply