Code Monkey home page Code Monkey logo

bmw_remote_start's Introduction

BMW F30 REMOTE START

BMW F30 Remote start project, made with Arduino

Features

This project allows to do this things:

  • If the engine is off, remote start the car with a triple click on the lock button of the OEM keyfob.
  • After 15 minutes from remote start, if no one started driving, automatically shut off the car
  • If the engine is on, remote stop the car with a triple click on the lock button of the OEM keyfob.
  • You have to unlock the car before driving it (why wouldn't you) or it will perform an emergency anti-thief stop

How it works

The Arduino, thanks to the MCP2515 board, constantly listen to the BMW K-CAN2 bus, looking for a triple lock button click. If found, it starts a 18 seconds long operation, during which it does those steps:

  1. Turns on the in-car keyfob
  2. Unlocks the car
  3. Locks the car
  4. Virtually presses the start button, turning on the ignition
  5. Waits some seconds, to let the engine be ready to start.
  6. Virtually presses the brake and the start button, turning on the engine
  7. Turns off the in-car key.

Security issues

What happens if a thief enter the car (by smashing the window) and tries to steal it?

If someone tries to engage a gear with the car remote started, without unlocking it with a keyfob first, the car automatically shuts off.

The spare key is always in the car. Wouldn't this be enough to allow a thief to turn on the engine?

Yes, but actually no. The Arduino turns on the keyfob only when it needs it to remote start. Normally the key isn't powered so the car doesn't see it and can't be turned on!

Why do the Arduino open and close the car before starting the engine?

The lock and unlock thing is needed to be able to turn on the ignition. This is because of the BMW security protocol, which disables the possibility of turning on the car if the car wasn't opened before. This is not a security issues though, because this process happens in 2 seconds and the car remains open for just 1 second.

Required things

Here's a list of things you need for this project:

  • Arduino Nano
  • LM2596S voltage regulator board, with the output regulated to 5V
  • MCP2515 Canbus board (Niren)
  • 6x Relay Board with 5V relays
  • 2x 560Ω (to replicate the start button internal 560Ω resistor)
  • 1x 1100Ω (to replicate the 12mA current outputted by the hall sensor inside the brake light switch)
  • The spare keyfob

You can get those resistance values by putting more resistors in series and sum the resistance value. For example:

  • to get a 550Ω resistance, you can put 220Ω and 330Ω resistors in series!
  • to get a 1100Ω resistance, you can put 1kΩ and 100Ω resistors in series!

Wiring

You have to do the wiring for:

  • KCan2 bus
  • 12V and GND
  • Brake light switch
  • Start button switches
  • Keyfob battery
  • Keyfob lock switch
  • Keyfob unlock switch

Car Wiring

KCAN2

Attention: the OBD2 port doesn't have KCAN2. You can't use it. You have to take KCAN2 from the FEM

  • KCAN2_H: FEM A173*8B, pin 50
  • KCAN2_L: FEM A173*8B, pin 49

12V and GND

Attention: you can't use the 12V plug as power source, you need an always-powered 12V source. You can find it at the FEM.

  • 12V: FEM A173*3B, pin 33
  • GND: FEM A173*3B, pin 6

Brake Light Switch and Start-Stop Button

Here you can see how to wire break light switch and start/stop button:

  • The start-stop button wiring is right behind the switch button, just pull it out.
  • The break light switch wiring is above the brake pedal.

CAR Wiring

KeyFob Wiring

KeyFob Power

You have to interrupt the battery positive connection, split it in 2 wires and feed them inside the relay:

KEY_POWER wiring

KeyFob Lock and Unlock buttons

You have to simulate the press of the switch using the relay. To do that, just hook to the key switches like that:

KEY_LOCK/UNLOCK wiring

Arduino wiring

Schematic

You can follow this schematic to build everything. Note: this schematic shows a 8x relay board, but you can use a 6x one

arduino wiring

Final look

This is the final look, with the spare key wired. You have to hide it somewhere inside the car. (it's ugly, I know. You can make it definitely better) arduino_final wiring

Credits

autowp for arduino-mcp2515 library

Donate

If you like my work, feel free to donate me! I would highly appreciate it!

bmw_remote_start's People

Contributors

albertomarziali avatar

Stargazers

 avatar Gotti Lee avatar  avatar Joel Langer avatar fr1t2 avatar  avatar Allan Zabecki avatar  avatar  avatar  avatar Alexander avatar Alexandre Swioklo avatar  avatar _c757 avatar Hau Vo avatar  avatar devin avatar Harutyun Hovhannisyan avatar Giorgi Davituliani avatar Siim Haugas avatar  avatar  avatar Adam avatar  avatar Christer Lien avatar Maurice avatar  avatar Alex Martens avatar  avatar 1 Line at a time avatar  avatar Davide Bert avatar Roy Niyongabo avatar  avatar  avatar Search online avatar  avatar

Watchers

Jorge Luis avatar  avatar  avatar  avatar Roy Niyongabo avatar  avatar Search online avatar  avatar  avatar  avatar

bmw_remote_start's Issues

i did all

thx man for what you did i need to ask something after wiring and doing every thing do i need to put software or something on Arduino Nano or it will work sorry for that q and if i do need can you tell me what and how thxxxxxxxxxxxxxxxxxx 100000000000

Light and stereo stays on after remote shutoff

Originally Posted by bnkrupf30 View Post
Thanks Albertsonic, my remote start works great. Only problem I have is turning the car completely off when I do the shutdown procedure. Lights and stereo stays on.
I'm aware of this issue aswell but unfortunately I haven't found a solution yet.

I'm in the process of building this. I know that when the car is locked after engine stop, the radio and lights will turn off. I believe this will fix the issue and I will create a PR with the change. I plan on testing that within the next week or two, but if anybody else tests it: please add a comment to the PR (I will do the same).

activating remote stop sequence while car is in motion

I have concerns that if I do the remote stop sequence while I am driving, that may cause an accident. How can we retrieve data from the car to determine that it is in PARK before stopping the engine? If you don't get back to me soon, I will try to make a PR that supports this.

Start and Stop with input pin

Hello,
can someone help me?
I installed everything, I used the "manual" option. (since I drive stick) I had to redo a few steps because it didn't work at first, clutch settings was wrong.
Now everything is workong fine, I even added the shutdown option to press Start Stop twice and turn off the ignition completely.Now I need an option that I can't get at all. I want to achieve that instead of the original key and by pressing the lock 3 times, I activate the sketch with the input on pin 8, i.e. to start the vehicle on pin 8 (ground switch LOW) and to turn off the vehicle on pin 9 (ground switch LOW) I want to use my device for satellite tracking that I have in the vehicle and to activate the vehicle with an SMS message. That part is fine, I can activate output on my device to send ground with sms message...Just can't seem to get the code to work.
Can someone help with adding that option to sketch?

Thank you in advance

Ii

Hello, first of all: amazing project.
I‘d really like to add this feature to my car.
The problem is I‘m running a manual transmission. Is it possible for you to add another rev. of the code, which presses the clutch virtually instead of the brake?

kind regards, WhiteBimmer

Finding CAN codes

Hi, I really like this project. How did you find the CAN codes? I plan to use a similar setup but read the codes of button presses on the M1 and M2 steering wheel buttons (since they have no use in my car) and then control external devices such as an LED strip or an exhaust valve using a relay.

Also, are the airbags on KCAN2 in a BMW? Is there a chance the wrong code or something could set them off or stop them from working?

I have a 2014 M135i (F21) but I imagine it is similar to the F30.

Thanks
Sam

Adding wifi MQTT support

Nice job with this turning Keyfob to remote starter.
But is it possible to keep all this AND adding support for MQTT via wifi? In my case the Arduino 33 IoT.

That way it will be possible to program timer etc via Home Assistant or similar

Details for pins in FEM connector.

Hey @AlbertoMarziali,

Do you have details on the type/size of the pins in the FEM connectors like FEM A173*8B, pin 50? I'd like to Remove the OEM pin to substitute with my own to piggyback off but I'm struggling to find out exactly what they are.

Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.