Cookies: Our site uses cookies in order to deliver better content. By continuing you accept these cookies.


How to Control Door Locks: Step-by-Step Guide

Updated at 26 May, 2020

— Read our step-by-step guide to find out how to control the obd port lock function on a Ford Mondeo MK4 2009 and unlock/lock the vehicle remotely.

How to Control Door Locks: Step-by-Step Guide
Find the perfect solution service for your business

All solutions are customizable and designed to meet all your needs.

Find the solution

Did you know? Some GM vehicles allows CAN bus access to open and lock doors.

AutoPi: Abilities and Features is specializing in connected car solutions to securely connect vehicles to the internet and gain data of automotive usage to help car owners improve remote access and control over their vehicle’s functionality.

The AutoPi device not just allows users to be connected to the internet, but also to control and create actions via that, like unlocking a car without using a physical key. Therefore in the following article, we will highlight one example, where the AutoPi device connects to a Ford Mondeo MK4 2009.

For this to work, the bus system through which the doors are controlled, has to be exposed on the OBD port. In our case, with the Ford Mondeo, the following article explains that the door control is achieved on MS-CAN with rate 125kbit/s.

Since the OBD connector on Mondeo MK4 is compatible with the AutoPi (read more about AutoPi CAN-BUS User Guide), it is possible to decode the messages on the AutoPi and replay it.

A detailed shot of AutoPi telematics unit generation 2 plugged into obd 2 port

How To Record and Play

Build on the information on how to record and play CAN bus messages provided on ourcommunity site, the process can be accomplished by a couple of steps - see below. All of these actions are within the AutoPi cloud management software.

  1. Once the device is online, go to “Car Explorer” -> “CAN Analyzer”.

  2. In the second step, you need to find the protocol settings required for your specific make and model. For our model, the following article explains the required protocol settings. However, the description yet fails to give up all the information and details such as payload size (#bits) and data length code (DLC) on our Mondeo MK4 are not provided, therefore an experimental approach is required.

  3. Select the bus and protocol you want to use as part of your trial, and then press record. In our case, we have four different MS protocols. Read our CAN Bus sniffer guide for detailed information.

  4. autopi


  5. Click on test in terminal and adjust the duration of recording to a sensible length. In this example, it lasts for 5 seconds. The trick is to save the file as in the screenshot below where the file is named “unlock1.txt”.

  6. The device makes a "beep" sound when the recording begins and another one when the recording ends. Make sure that the CAN command you want to record is happening between the two sounds (like door unlock).

  7. If the right protocol settings were applied for the car model you should see hex messages from the CAN bus in your file. Moreover, the recording is now stored on the device and you can play it back immediately using the CAN player on the right-hand side of the screen

  8. If no message is recorded you have to continue with the next protocol settings, and name a new output file e.g. “unlock2.txt”.

  9. You will see that a lot of data is returned from the bus that finds the specific command for your function. We recommend using the filters. Typically, a lot of the data is repetitions, so you can start out by removing all the duplicates.

  10. Another option is Divide-and-Conquer, i.e. split the file in two using obd play.slice option.

  11. If the first part works - great - repeat slicing the identified segment. If the first part did not work try the second part.

  12. With the filters, narrow down the results to as few as possible. Then you can replay the commands one by one and see if you can find the command controlling the function you are looking for.

  13. When you have found your command you can always resend it by using the

Alternatively, if the exact hex message is known it is possible to apply obd.send, e.g. obd.send 048#801804092002F0A0 protocol=51 baudrate=125000

Not all vehicles may be that easy to allow door lock/unlock control by reading the CAN messages and replaying the same content. However it is possible if the door control is exposed and the reader has an idea which messages are intended for door-specific commands for it to become a reality.

Please note that this is an experimental approach and experimenting with your vehicle is at your own risk.

Let us know what type of Automotive IoT project you are planning. Reach out to for a nonbinding quote on your project or join our Community page and discuss or get inspired by the many ongoing projects there.

Get an advanced IoT platform now. To see the step by step guide watch our Unlock a Ford Focus Complete Guidance Video on YouTube.

Article by

Peter Falkesgaard Ørts

CEO / Co-Founder / Sales / Hardware

Like what we do? Contact us.

Find the perfect solution service for your business

All solutions are customizable and designed to meet all your needs.

Find the solution

Other posts you will like

What is Car Sharing and How does it work?
What is Car Sharing and How does it work?
The Benefits of Fixed Asset Management Software
The Benefits of Fixed Asset Management Software
DBC File Explained Simple (2022)
DBC File Explained Simple (2022)


Get in touch with us – We're ready to answer any and all questions.

* Mandatory fields

Email our engineers

We are here to help!