For beginners, how to route one ID to another ID
Posted: Fri 23. Aug 2019, 20:43
Hi, please bear with me, I need a kick to get the wheel rolling. Yes, beginner in all this.
Problem: I bought a corner lighting module, which looks to the HSCAN of a car, and turns on and off individually each fog light, based on input data engine running and steering angle sensor data. Nice, however, it turned out that the message ID for steering angle data mismatches my car. Maker does not want to support, no reply, nothing.
So I went ahead, reversed engineer my SAS sensor and got the ID and data bytes necessary (thank you PCAN-USB pro for making this easy to me
). I went to a supported car, reversed engineer the SAS there and got the ID.
It turns out, I only need to change the ID, from 180h to 1E4h, the rest of the message looks the same. I have a PCAN-Router I would like to use. Attached is the schematic of what I want to achieve. Yes, I know I have to have a module which acknowledges the ID messages, but that is a problem for later to think off.
Easy job to setup PCAN-Router, is it?
Manual reading, all resources of PCAN-router can be accessed by the .a library, which is explained by .h header files.
I will comply and read them by the letter.
However, how do I follow the right steps? I created a folder Steering angle sensor, copied there folders:
.dep
.lst
.obj
.out
Copied all .h files, Flash.Id, hex2bin.exe and makefile.
Is this for a start ok? Are there any folders / files I don't actually need there? What about crt0.S? What is this file used for? Do I always need it?
In terms of writing .c files, is there a specific order, specific file names, how would one start from scratch? I see in the ROUTING example a can_user.c and main.c. Why there are two files? What do I need to put in each?
Sorry for the long text, I have more questions then I can turn my head around at this time. Can anyone give me a kick in the right road?
Problem: I bought a corner lighting module, which looks to the HSCAN of a car, and turns on and off individually each fog light, based on input data engine running and steering angle sensor data. Nice, however, it turned out that the message ID for steering angle data mismatches my car. Maker does not want to support, no reply, nothing.
So I went ahead, reversed engineer my SAS sensor and got the ID and data bytes necessary (thank you PCAN-USB pro for making this easy to me

It turns out, I only need to change the ID, from 180h to 1E4h, the rest of the message looks the same. I have a PCAN-Router I would like to use. Attached is the schematic of what I want to achieve. Yes, I know I have to have a module which acknowledges the ID messages, but that is a problem for later to think off.
Easy job to setup PCAN-Router, is it?

Manual reading, all resources of PCAN-router can be accessed by the .a library, which is explained by .h header files.
I will comply and read them by the letter.
However, how do I follow the right steps? I created a folder Steering angle sensor, copied there folders:
.dep
.lst
.obj
.out
Copied all .h files, Flash.Id, hex2bin.exe and makefile.
Is this for a start ok? Are there any folders / files I don't actually need there? What about crt0.S? What is this file used for? Do I always need it?
In terms of writing .c files, is there a specific order, specific file names, how would one start from scratch? I see in the ROUTING example a can_user.c and main.c. Why there are two files? What do I need to put in each?
Sorry for the long text, I have more questions then I can turn my head around at this time. Can anyone give me a kick in the right road?