New ones is with the canbus logs I made it should go down.
can id´s 4 Gear Selector
-
- Posts: 1328
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 106 times
- Been thanked: 228 times
-
- Posts: 481
- Joined: Thu Jul 04, 2019 6:35 pm
- Location: Somerset, UK
- Has thanked: 43 times
- Been thanked: 113 times
Re: can id´s 4 Gear Selector
I got mine to lower! I got the pinout wrong. pin 4 does nothing. pin 10 needs 12v, then when you disconnect ignition it will lower. It does need canbus to raise though, but doesn't lower via canbus messages.nkiernan wrote: ↑Sun Feb 05, 2023 11:42 am Model number on mine is BW83-7E453-AC and I get the same result as you. Playing back some of the different logs raises the knob, allows it to rotate, changes light between P-R-N-D but doesn't lower the knob in any. The knob raised on the first playback and stayed there.
Updated my pinout post.
-
- Posts: 481
- Joined: Thu Jul 04, 2019 6:35 pm
- Location: Somerset, UK
- Has thanked: 43 times
- Been thanked: 113 times
Re: can id´s 4 Gear Selector
So you just need 0x3F3 to raise and unlock the gear selector, sending every 20ms.
No changing lights yet, but I do get the gear selector sending back gear change canbus messages. Just need to write in the changing of messages depending on value of byte 2 in 0x312
No changing lights yet, but I do get the gear selector sending back gear change canbus messages. Just need to write in the changing of messages depending on value of byte 2 in 0x312
Code: Select all
#include "variant.h"
#include <due_can.h>
//Leave defined if you use native port, comment if using programming port
#define Serial SerialUSB
const int CAN_SPEED = 500000; // CAN bus speed in baud
const int SEND_DELAY = 20; // send message every 10ms
const int MESSAGE_LENGTH = 8; // 8 byte long message
void setup()
{
Serial.begin(115200);
// Initialize CAN0 and set the baud rate
Can0.begin(CAN_SPEED);
Can0.watchFor();
}
void loop()
{
static unsigned long lastTime = 0;
static int counter = 0x82;
static int counter1 = 0x00;
// Send a new message every SEND_DELAY milliseconds
if (millis() - lastTime >= SEND_DELAY)
{
CAN_FRAME msg;
msg.id = 0x3F3; // message ID
msg.length = MESSAGE_LENGTH;
msg.extended = 0; // standard frame format
// Set the data in the message
for (int i = 0; i < MESSAGE_LENGTH; i++)
{
msg.data.bytes[i] = 0;
}
msg.data.bytes[0] = 0x5C;
msg.data.bytes[1] = 0x66;
msg.data.bytes[2] = counter1;
counter1++;
if (counter1 > 0x0E)
{
counter1 = 0x00;
}
msg.data.bytes[3] = counter;
counter++;
if (counter > 0x90)
{
counter = 0x82;
}
msg.data.bytes[4] = 0xFF;
msg.data.bytes[5] = 0x7F;
msg.data.bytes[6] = 0x00;
msg.data.bytes[7] = 0x80;
// Send the message
Can0.sendFrame(msg);
// Record the time the message was sent
lastTime = millis();
}
}
-
- Posts: 481
- Joined: Thu Jul 04, 2019 6:35 pm
- Location: Somerset, UK
- Has thanked: 43 times
- Been thanked: 113 times
Re: can id´s 4 Gear Selector
Got a working arduino due script for selecting modes and lights.
Currently I can't get the S mode light to work. However I can select it without the selector locking up. It was a bit tricky to figure out. The two cycling values in 0x3F3 are in relation to each other. It also locks up for a couple of seconds when going into Park. Maybe an inbuilt timer to allow the E-brake to come on?
Edit: Updated thanks to Tom's canbus logs. S mode light now works. Still get the delay with the Park light, but it's functional at least.
https://github.com/SomersetEV/LandRover ... ear-change
Currently I can't get the S mode light to work. However I can select it without the selector locking up. It was a bit tricky to figure out. The two cycling values in 0x3F3 are in relation to each other. It also locks up for a couple of seconds when going into Park. Maybe an inbuilt timer to allow the E-brake to come on?
Edit: Updated thanks to Tom's canbus logs. S mode light now works. Still get the delay with the Park light, but it's functional at least.
https://github.com/SomersetEV/LandRover ... ear-change
-
- Posts: 511
- Joined: Mon Feb 24, 2020 8:59 pm
- Location: Ireland
- Has thanked: 287 times
- Been thanked: 66 times
Re: can id´s 4 Gear Selector
Nice one, I'll check this out. I have the 22 pin connector on mine, so I expect one of the pins needs the same 12V. Will do some checking
-
- Posts: 1328
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 106 times
- Been thanked: 228 times
Re: can id´s 4 Gear Selector
No.
Not directly you need to create a controller to have the two interact.
-
- Posts: 1328
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 106 times
- Been thanked: 228 times
Re: can id´s 4 Gear Selector
Arduino Uno with Canshield code to have full control of the shifter.
https://github.com/Tom-evnut/Land-Rover ... LRgearknob
This code allows raising and lowering of the knob and selecting of all the positions with the lights working. This is ready for anyone to take and integrate into a vehicle.
The checksum has not been worked out, so it just is brute forced message filling based on logs.
https://github.com/Tom-evnut/Land-Rover ... LRgearknob
This code allows raising and lowering of the knob and selecting of all the positions with the lights working. This is ready for anyone to take and integrate into a vehicle.
The checksum has not been worked out, so it just is brute forced message filling based on logs.
-
- Posts: 511
- Joined: Mon Feb 24, 2020 8:59 pm
- Location: Ireland
- Has thanked: 287 times
- Been thanked: 66 times
Re: can id´s 4 Gear Selector
Thank you for sharing Tom. I will try testing at the weekend on the gear selector I have
-
- Posts: 1328
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 106 times
- Been thanked: 228 times
Re: can id´s 4 Gear Selector
Also made the Gen 1 knob I have work. CAN bus was a bit easier.
Lights come on and Sport is selectable. I have not gone in depth to figure out any more.
Logs and Arduino code is on github.
https://github.com/Tom-evnut/Land-Rover ... en1%20Knob
Lights come on and Sport is selectable. I have not gone in depth to figure out any more.
Logs and Arduino code is on github.
https://github.com/Tom-evnut/Land-Rover ... en1%20Knob
-
- Posts: 1328
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 106 times
- Been thanked: 228 times
Re: can id´s 4 Gear Selector
22 way connector is TE 0-1411226-1
https://www.aliexpress.com/item/1005002582017711.html
This possibly looks like this part: https://www.te.com/usa-en/product-1-1419158-7.html , the drawing references FORD part numbers so most likely true.
12 way https://www.te.com/usa-en/product-1452015-2.html
https://www.aliexpress.com/item/1005002582017711.html
This possibly looks like this part: https://www.te.com/usa-en/product-1-1419158-7.html , the drawing references FORD part numbers so most likely true.
12 way https://www.te.com/usa-en/product-1452015-2.html
-
- Posts: 511
- Joined: Mon Feb 24, 2020 8:59 pm
- Location: Ireland
- Has thanked: 287 times
- Been thanked: 66 times
Re: can id´s 4 Gear Selector
Thank you Tom.
Are you seeing that for both the 12 and 22 way connectors, you only need 5 connections:
- GND
- 12V+ main feed
- 12V+ Ign
- CAN H
- CAN L
Or are there signals required on other pins also (just looking at LRBen's post re needing 12V on pin 10 of the 12 way connector also and wondeirng what the description of that pin is)
Are you seeing that for both the 12 and 22 way connectors, you only need 5 connections:
- GND
- 12V+ main feed
- 12V+ Ign
- CAN H
- CAN L
Or are there signals required on other pins also (just looking at LRBen's post re needing 12V on pin 10 of the 12 way connector also and wondeirng what the description of that pin is)
Re: can id´s 4 Gear Selector
Hello friends. How long have I been looking for this topic in all the forums !!!! I'm trying to get it to work with a stepper motor for shifting gears in another car. I needed to find all the CAN bus codes and then I stumbled upon this forum. Happiness!!!
I found only 2 leds like in my picture
I found only 2 leds like in my picture
Re: can id´s 4 Gear Selector
I also found voltage on the pins of the 22 way connector
- Attachments
-
- GSMTSM - Pinout.pdf
- (484.6 KiB) Downloaded 79 times
-
- Posts: 511
- Joined: Mon Feb 24, 2020 8:59 pm
- Location: Ireland
- Has thanked: 287 times
- Been thanked: 66 times
Re: can id´s 4 Gear Selector
tom91 wrote: ↑Mon Mar 27, 2023 3:54 pm Arduino Uno with Canshield code to have full control of the shifter.
https://github.com/Tom-evnut/Land-Rover ... LRgearknob
Was having some compile issues (old CAN library installed, but when I updated to the latest, it required 3 arguments instead of the 2 used), so had to change below for my setup:
Code: Select all
while (CAN_OK != CAN0.begin(CAN_500KBPS, MCP_16MHZ)
Code: Select all
while (CAN_OK != CAN0.begin(MCP_ANY, CAN_500KBPS, MCP_16MHZ)
Re: can id´s 4 Gear Selector
Hi! Where can I download the libraries: variant.h, mcp_can.h for MCP 8MHZ?
I am using an Arduino Nano with a module mcp2515 and library mcp2515.h.
-
- Posts: 1328
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 106 times
- Been thanked: 228 times
Re: can id´s 4 Gear Selector
I believe this one should be okay https://github.com/autowp/arduino-mcp2515
Libraries and sharing them is always a painful part of the Arduino system.
Re: can id´s 4 Gear Selector
I found mcp_can.h library on git. Applied nkiernan's advice uploaded to arduino. What should happen? Maybe I don't have a CAN bus connection? The port monitor should display information with the line 0x312 from selector?
-
- Posts: 1328
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 106 times
- Been thanked: 228 times
Re: can id´s 4 Gear Selector
It does not print anything, as the Leds will feedback on the knob.
Send it the letter 'd' is you want to toggle canbus debugging.
Re: can id´s 4 Gear Selector
I don't understand. Maybe my GSM doesn't work with this code? Because on the video of the seller from Aliexpress there is no mine. Does anyone have a video review of working GSM with arduino? How to make the knob move? I haven't been able to move it for 2 weeks now((((
I Send it the letter 'd', but nothing. Then 's', then 'w' and nothing(((
I Send it the letter 'd', but nothing. Then 's', then 'w' and nothing(((
-
- Posts: 511
- Joined: Mon Feb 24, 2020 8:59 pm
- Location: Ireland
- Has thanked: 287 times
- Been thanked: 66 times
Re: can id´s 4 Gear Selector
Couple of suggestions. You have the CAN lines connected between the arduino CAN shield and the Jag unit and did you check the resistance between the lines ( approx 60R). Think I added a 120R resistor between the lines because my CAN shield didn't have the termination resistor.VanGogh wrote: ↑Tue Apr 04, 2023 8:08 pm I don't understand. Maybe my GSM doesn't work with this code? Because on the video of the seller from Aliexpress there is no mine. Does anyone have a video review of working GSM with arduino? How to make the knob move? I haven't been able to move it for 2 weeks now((((
I Send it the letter 'd', but nothing. Then 's', then 'w' and nothing(((
You're applying 12V+ and GND to relevant pins and are you applying the 12V+ ignition signal also? When you open serial monitor in arduino and connected to the UNO, this is what would print when first powered up or reset (baud rate is set to 115200 yes?):
- Entering Configuration Mode Successful!
Setting Baudrate Successful!
CAN BUS OK!
Time Stamp,ID,Extended,LEN,D1,D2,D3,D4,D5,D6,D7,D8
-
- Posts: 1328
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 106 times
- Been thanked: 228 times
Re: can id´s 4 Gear Selector
Please show us your wiring setup, as wiring can be an issue.VanGogh wrote: ↑Tue Apr 04, 2023 8:08 pm I don't understand. Maybe my GSM doesn't work with this code? Because on the video of the seller from Aliexpress there is no mine. Does anyone have a video review of working GSM with arduino? How to make the knob move? I haven't been able to move it for 2 weeks now((((
I Send it the letter 'd', but nothing. Then 's', then 'w' and nothing(((
Have you ever gotten canbus from it using anything else?
-
- Posts: 1328
- Joined: Fri Mar 01, 2019 9:15 pm
- Location: Bristol
- Has thanked: 106 times
- Been thanked: 228 times
Re: can id´s 4 Gear Selector
Thanks I tried.
I have another code for arduino and used canhacker 2.00.02 to find signals without 120 ohm resistor. But he could not find the signals to raise the knob. Found your code and can't get any results with it. There is no resistance between the CAN bus contacts. I added a 150 ohm resistor and no change (or do you need 120 ohms?). I sent a letter 'w' and the port monitor says "UnLocked" and "Locked" but I don't hear the solenoid valve inside.
When I send other characters nothing happens at all
I have another code for arduino and used canhacker 2.00.02 to find signals without 120 ohm resistor. But he could not find the signals to raise the knob. Found your code and can't get any results with it. There is no resistance between the CAN bus contacts. I added a 150 ohm resistor and no change (or do you need 120 ohms?). I sent a letter 'w' and the port monitor says "UnLocked" and "Locked" but I don't hear the solenoid valve inside.
When I send other characters nothing happens at all
-
- Posts: 511
- Joined: Mon Feb 24, 2020 8:59 pm
- Location: Ireland
- Has thanked: 287 times
- Been thanked: 66 times