Cruise Control Arduino System
#1
Cruise Control Arduino System
Hi everyone!
So like many of you, I have had nothing but problems with my cruise control system in my 89' S2. When I got the car it would work about 50% of the time, but eventually began to mash the pedal to the floor when set. I checked all my inputs to the computer and they all read their expected values, so I replaced the control computer assuming that was the problem. This new computer worked for a couple of months, but began to fail when it got cold out. After many trials with a heat gun and even using a third computer, I got tired of trying to make these old boards work. Considering that the factory computers in the car are fairly basic I/O devices, I feel that this is definitely something that has the potential to be replaced by an Arduino. So I went and bought myself an Arduino Uno (ok maybe it was an off-brand one) and got to work.
The first hurdle I found was getting the 5V Arduino pins to control the 12V, relatively high current system of the servo. At first I thought I could work around this using mosfet transistors, but, as the "load" of the servo is downstream of the location of the computer and, thus, where the mosfets would be, I would need to use some fairly complicated P-channel mosfets that really made it impractical. As a result, I decided on good old electromechanical relays to do the job instead and bought this:
This makes it simple enough to control with 5V Arduino pins. The biggest downside is that these relays are LOUD for use inside the cabin, but its the best I can come up with for now. They also make 12V relay boards like these:
to act as input control so that the Arduino pins are not fed 12V from the car. The board itself can technically be powered by 12V, but I think it wound be better to wire it up to a 12V to 5V adapter like a car charger for stable power.
Next comes the code to actually run the logic. I started work on this and saved it to GitHub here:
https://github.com/rhit-hoggatt/Crui...ol_Project.git
I tried using some premade frequency reading libraries, but none of them really did what I was looking for so I began to write my own. Outside of this, the program essentially acts as logic to enable and disable the servo when appropriate.
I do want to reiterate that this project is by no means complete, but this is the start that I have. I haven't had time to get to a lab bench power supply to actually ensure my outputs to the servo are correct, nor have I had time to set up a frequency generator to test the input frequency reading.
At this point I decided to replace the caps on one of my old boards, and that seems to have fixed all the problems that I was having (for now...). I am at a point where I do not really have time to complete this project, but I thought I should offer what I have to others as I know I am not the only one with this problem.
If my current board starts acting up again and I get time I will be revisiting this, but I hope others can make use of what I have!
So like many of you, I have had nothing but problems with my cruise control system in my 89' S2. When I got the car it would work about 50% of the time, but eventually began to mash the pedal to the floor when set. I checked all my inputs to the computer and they all read their expected values, so I replaced the control computer assuming that was the problem. This new computer worked for a couple of months, but began to fail when it got cold out. After many trials with a heat gun and even using a third computer, I got tired of trying to make these old boards work. Considering that the factory computers in the car are fairly basic I/O devices, I feel that this is definitely something that has the potential to be replaced by an Arduino. So I went and bought myself an Arduino Uno (ok maybe it was an off-brand one) and got to work.
The first hurdle I found was getting the 5V Arduino pins to control the 12V, relatively high current system of the servo. At first I thought I could work around this using mosfet transistors, but, as the "load" of the servo is downstream of the location of the computer and, thus, where the mosfets would be, I would need to use some fairly complicated P-channel mosfets that really made it impractical. As a result, I decided on good old electromechanical relays to do the job instead and bought this:
This makes it simple enough to control with 5V Arduino pins. The biggest downside is that these relays are LOUD for use inside the cabin, but its the best I can come up with for now. They also make 12V relay boards like these:
to act as input control so that the Arduino pins are not fed 12V from the car. The board itself can technically be powered by 12V, but I think it wound be better to wire it up to a 12V to 5V adapter like a car charger for stable power.
Next comes the code to actually run the logic. I started work on this and saved it to GitHub here:
https://github.com/rhit-hoggatt/Crui...ol_Project.git
I tried using some premade frequency reading libraries, but none of them really did what I was looking for so I began to write my own. Outside of this, the program essentially acts as logic to enable and disable the servo when appropriate.
I do want to reiterate that this project is by no means complete, but this is the start that I have. I haven't had time to get to a lab bench power supply to actually ensure my outputs to the servo are correct, nor have I had time to set up a frequency generator to test the input frequency reading.
At this point I decided to replace the caps on one of my old boards, and that seems to have fixed all the problems that I was having (for now...). I am at a point where I do not really have time to complete this project, but I thought I should offer what I have to others as I know I am not the only one with this problem.
If my current board starts acting up again and I get time I will be revisiting this, but I hope others can make use of what I have!
#2
Ran into this coming home from 944fest this year. Cruise worked perfect for 600 miles St. Louis to Nelson Ledges. Driving home, every time I tired to use the cruise, the gas pedal went to the floor and the car accelerated. Tried to cancel, reset, set resume. every function caused the gas pedal to hit the floor.
I stopped for gas. Of course powered the car off. When I got back on the highway, cruise worked perfect again for the remaining 400 miles.
So for me, power cycle seems to fix the issue.
I stopped for gas. Of course powered the car off. When I got back on the highway, cruise worked perfect again for the remaining 400 miles.
So for me, power cycle seems to fix the issue.
#4
My cruise works but its about 10mph off, so if Im going 60, set the cruise, it will want to accelerate to 70 and stay there. Yes it does want to "mash the gas pedal" but only for about 10mph or so-not to infinity or anything.
I just compensate by setting the cruise 10mph or so below. Havent had time to investigate, and dont use cruise often.
I just compensate by setting the cruise 10mph or so below. Havent had time to investigate, and dont use cruise often.
Last edited by walfreyydo; 09-21-2023 at 10:00 AM.
#6
My cruise works but its about 10mph off, so if Im going 60, set the cruise, it will want to accelerate to 70 and stay there. Yes it does want to "mash the gas pedal" but only for about 10mph or so-not to infinity or anything.
I just compensate by setting the cruise 10mph or so below. Havent had time to investigate, and dont use cruise often.
I just compensate by setting the cruise 10mph or so below. Havent had time to investigate, and dont use cruise often.
The following users liked this post:
walfreyydo (09-21-2023)
#7
The first hurdle I found was getting the 5V Arduino pins to control the 12V, relatively high current system of the servo. At first I thought I could work around this using mosfet transistors, but, as the "load" of the servo is downstream of the location of the computer and, thus, where the mosfets would be, I would need to use some fairly complicated P-channel mosfets that really made it impractical. As a result, I decided on good old electromechanical relays to do the job instead and bought this:
https://www.amazon.com/dp/B09ZQRLD95...t_details&th=1
https://www.amazon.com/dp/B09ZQRLD95...t_details&th=1
Trending Topics
#8
While this is definitely a cool project, I would just send your module to Kris Rose. He'll fix it & knows the common problem items. Mine has been working flawlessly ever since.
Before I sent mine to Kris, I bought one off eBay from a 968 that worked great. They are date coded so you can determine which model it's from. I've always wondered if they improved the components in the later modules.
Before I sent mine to Kris, I bought one off eBay from a 968 that worked great. They are date coded so you can determine which model it's from. I've always wondered if they improved the components in the later modules.