Struggling to get LED output to match what I set
Re: Struggling to get LED output to match what I set
My matrix is an Adafruit mini 8x8 matrix (0.8" tall) controlled by a Arduino Pro Mini (manufactured by Sparkfun) I intend to put up a post detailing it when I get the shifter working. I have already written the code and am happy to share it. BTW, the matrix is dimmable in 1/16th steps. It would be easy to take a feed from the light cicuit into the Arduino to dim the matrix when you turn the lights on. Additionally if your car has dimmable instrument lighting you could take a feed from that to dim the matrix.. that would be cool.
Lance,
I've flashed your supplied code and tried it. I have disconnected everything at the 2 x 25 header except for the 4 inputs, I was trying to see if one of the other circuits was messing things up..
I put the lever in Park, started logging, then shifted to Reverse, then Neutral, then Drive then 3 and finally 2. (Drive is set as 1)
LED patterns are perfect.. according to log..
- Attachments
-
- 2014-07-09_22.13.09.msl
- (120.1 KiB) Downloaded 665 times
-
- CAN1_July.msq
- (45.2 KiB) Downloaded 643 times
-
- Posts: 1696
- Joined: Fri Apr 04, 2008 1:28 pm
Re: Struggling to get LED output to match what I set
As Guillaume mentioned above, the LEDs follow the currently selected gear (cGear in the datalog), NOT the manual gear lever position (mGear). I could easily make that an option in the code, though.
As well, disconnecting all the other circuits will likely mean the controller will never command the trans to shift, so that doesn't help a lot.
The code you tried polls the LEDs' physical outputs to see what state they are in (i.e. it makes no assumption about anything else the code does), so I am inclined to believe the datalog. Do the LED outputs look correct in Reverse with the newest code? Is Reverse still the only problem?
Exactly which pins on the header are you checking for each of LED1 through LED4? PM4 for LED1, PB4 for LED4, etc.? This is important. Is is also important to check over the 25x2 header, circuits and connections to make sure they are working as they should.
Lance.
Re: Struggling to get LED output to match what I set
Thanks for sticking wih me on this. The time differences between us really draws out this conversation

The LED outputs in the datalog are correct. The solenoid outputs also appear to be correct at first glance!

My LEDs are connected thus:
LED1 - GPO1 - PM4
LED2 - GPO2 - PM3
LED3 - GPO3 - PM5
LED4 - GPO4 - PB4
Hopefully I'll get another hour on it tonight and report back..
Re: Struggling to get LED output to match what I set
One problem remains..
Manual gear..
When in 1 it displays 1
When in 2 it displays 2
but...
When in 3 it display 1
Looking at my datalog, with one graph showing CAN1.in1adc, CAN1.in2adc, CAN1.in3adc & CAN1.swD and another showing CAN1.mgear at 167s the inputs change state from high, low, high, high to high, low, high, low.. but CAN1.mgear stays at 1 (high, low, high, low should be 3)
at 170s, when I shift the lever from 3 to 2, it then changes to high, high, high, low and then the CAN1.mgear changes to 2 correctly
Re: Struggling to get LED output to match what I set
Thanks for your answer Addicted,Addicted wrote:Bonjour Guillaume,
My matrix is an Adafruit mini 8x8 matrix (0.8" tall) controlled by a Arduino Pro Mini (manufactured by Sparkfun) I intend to put up a post detailing it when I get the shifter working. I have already written the code and am happy to share it. BTW, the matrix is dimmable in 1/16th steps. It would be easy to take a feed from the light cicuit into the Arduino to dim the matrix when you turn the lights on. Additionally if your car has dimmable instrument lighting you could take a feed from that to dim the matrix.. that would be cool.
I had a quick look at the product you described: it seems that I would not need to run the 7 wires: LED 1, 2, 3, 4, 12V, ground and TC signal to the led but only 4 wires. and the possibility to write the letters like P, N and R...
How did you integrate it in the car, I really would like to see pictures and more details if you have time once you sorted your problems.
Guillaume
Re: Struggling to get LED output to match what I set
I looked quicly at your log.
It seems that the engine was not running.
I know for my transmission (GM 4L80), it uses pressure switches to sense the position of the lever (manual gear) So if the engine is not turning, I have no pressure in the transmission and all the switches are off, even if I move the lever. Is it possible that it is the same for you(it needs pressure to activate the switches?)
I think in Tunerstudio, you can see the input 1, 2,3 and 4: do they match what you expect when you move the lever in the different positions? Compared to the manufacturer specs?
Re: Struggling to get LED output to match what I set
As per Lances instructions I'm not going to start the engine until I have the lever selection correct
Re: Struggling to get LED output to match what I set
the only difference between 1st and 3rd is the 4th input once on low and once on HIGH.
Otherwise, all other gears have differences between the 3 first inputs. If you look at 1 and 3, both are High, low, High.
I would try to look at problem on GPI1, check if the voltage arrives and if the circuit is correct.
Or it might be soft related. (I only have 3 inputs, never tested 4 inputs)