Introduction: RFID Car Immobiliser With PIC12629

Ok, so there are heaps of immobilisers out there but with most of them, if someone has your keys, they have you car.  What good is a car alarm with 3+ point immobilisation if someone manages to get the keys and of course the alarm remote. 

This is a simple immobiliser based on a PIC12F629 and an ID-12 chip from innovations.  This can be built for about $50.

Advantages:
The ID-12 chip is/can be remotely mounted away from the main PCB, behind a panel with no external components viewable.

If someone carjacks you or something like that (after you have started the car) then if they stop the car, it will not be startable again.

Cheap and effective

I apologise for the slight lack in detail.  This was a project i done some time ago and it has been a long time since i touched it.  I have posted this on here as it was requested by a few people. I will be happy to answer questions though.

Step 1: The Schematic and How It Works

The PIC and the ID-12 are powered by a 7805 5v regulator via some basic filtering caps.  The PIC is in an endless loop at this point, reading available data from the ID-12.  Once a card/tag is read, it compares the string with up to 10 tags it has in EEPROM.  If one matches, it activates the transistor which in turn activates the relay and the program stops.  If there is no match, it just keeps waiting for data. The bi-colour LED indicates the status.

Initial setup is done by shorting the jumper and then reading up to 10 tags in sequence. This overwrites each tag if it's alreading in eeprom.

I know the schematic is hard to read, click on the 'i' in the top left then click on the  'original file' link for an uncompressed version...

Step 2: PCB

The PCB is fairly straight forward when teamed up with the schematic. There's not much to it...

Print, transfer, etch, drill etc.

The ID12 is wired in standard ASCII mode.  The only connections needed are:
Pin 1: GND
Pin 2: +5v
Pin 7: GND
Pin 9: Data
Pin11: +5v

This means you only need 3 wires going to the ID-12.  The others can be jumpered on the chip.  If the run is long (more than say 20cm), I would suggest the use of shielded cable as cars are electrically noisy and it might cause dodgey readings.

Step 3: All Put Together

Once you have the PCB done, solder it all up and program the chip with your fav. programmer. HEX file attached.

For debugging, you can connect pin 2 (GPIO5) and a ground pin to the serial port of a PC's Rx and ground @ 9600 baud to see the actual tag values and what the chip is doing.  However, it may not work properly on all PC's without the addition of a max232 chip as it is only pseudo RS232 and not true levels.  Not that i have come across any in recent times.

Step 4: Wrapping Up

Programming:  Power up the immobiliser with the jumper in place.  The LED should go green and then go red.  You can then program up to 10 tags.  The LED will go orange when a tag is read, then go back to red (waiting for another tag).  If you want to 'erase' a tag, you must reprogam that position or 'key number'.  Best is to just keep reading the same tag over and over till all 10 positions are filled, or reprogramming the pic will clear the eeprom if needed.

Once you have programmed your tags in, you can remove the jumper.  The unit is now in 'operation' mode and the LED is red.

When a tag is read, the LED will go orange and If a good tag is read, the LED will go green for 1/2 a second, then extinguish totally and the relay will close. If a bad tag is read, it will go back to red waiting for another tag.

Bench test the setup and once you are happy with it, you can wire it into your car.

The main power for the circuit should come from an 'ignition' circuit on the car.  Then connect the 'switched' relay contacts between a feed to the coil(s) or ignition input to your EFI computer.

To operate, turn on the ignition of the car, then swipe the tag over the ID-12, the relay closes, then start the car.  If the car is turned off, the process must be repeated.

Comments

author
CharlesCobb made it!(author)2016-12-11

I have a RFID reader and am attempting to install and an ignition kill on my 93 Honda Accord. It came without wiring instructions. Please help. There are 3 wires, to which I can identify Hot, Ground, and switched. How would I wire this?

author
Maniutek made it!(author)2016-10-10

Hi. I wanna build the immobiliser, but I want study the source code...

Could you upload US files:

INCLUDE "12F629.INC"

INCLUDE "IMMOBL~2.MAC"
INCLUDE "PBPPIC14.LIB"

author
mopanko made it!(author)2016-10-04

Hi,

I wanna build the immo, however do you have a gerber or eagle file for the pcb?
It would be very helpful to do the pcb! :)
thank You!

author
andrew_h made it!(author)2016-10-04

This is one of my early projects and I used PCB123 which does not support Gerber export, sorry.

author
andrew_h made it!(author)2015-03-12

What is it that you would like to know? Bare in mind that this is a VERY old project and I have not touched PIC chips in 5+ years.....

author
Maniutek made it!(author)2015-03-29

Could You check that?

When I have Anscii mode on term I have that.

But when I changed to Ansi mode is no strange characters.

ID-12LA

rfid.PNG
author
lachko973. made it!(author)2015-03-13

Hello Andrew,

Thank you for sharing your project.

I made it with PIC12F629 and it works but I have a problem.

When hooked the D0 pin of the ID-12 chip to USB-TTL RS232 FT232RL converter RXpin the ID-12 gives every single time the same code : 010D69AE01CA for the particular rfid TAG

When I program the tag 10 times and remove the jumper and then read the tag again it works , the PIC activates the relay.

When i hook the FT232RL converter to the pin 2 of the PIC12f629 i see the debug information that you provide

Got : 313044363941453031F9

Rom has: 313044363941453031F9 *** Matched chip 1 ***

But after each power ON/OFF cycle the value I see form the same tag is changing

Got : 313044363941453031D8 //this value is different from the one in the eeprom and the relay is not powered. Then I switch the power and plug it back and receive different reading

Got : 313044363941453031F8 //again not the same value and the relay not operating

Got : 313044363941453031F9 // after many ON/OFF cycles (without additional learning by the jumper) I receive the same code that is stored in the eeprom and the relay is activated

With the same tag I see different reading in the last byte at pin 2 of the PIC.

Please do you know what causes this.

Again thank you for sharing your project.

Best regards.

author
viking25 made it!(author)2014-03-18

I can't get my programmer to accept just the HEX file for the 12F629. Any chance of getting the ASM file?

author
andrew_h made it!(author)2014-03-18

I have added the ASM to the instructable.

author
viking25 made it!(author)2014-03-19

Tried the ASM but it says I need the "IMMOBL~2.MAC" and the "PBPPIC14.LIB" files. Should they be standard files? I'm not really sure since I'm new-ish to programming PICs

author
stretchmame32 made it!(author)2013-03-18

very good

author
rjadhav1 made it!(author)2011-10-20

HI.... CAN ANY ONE TELL ME THE CONNECTION BETWEEN RFID READER AND PC .....

author
andrew_h made it!(author)2011-10-20

See the spec sheet for the ID-12. If you want to connect it directly to a PC serial port, you will likely need a MAX232 or equivalent to convert the 5v TTL to true serial. However, some serial ports or USB to serial adapters will work ok on just the 5v signals.

author
Opus+the+Poet made it!(author)2010-05-06

When I saw this I was hoping for something I could use to shut down a car that had just tried to run me over on my bike. I could use such an item about 3 times a week when I ride as someone tries to "teach me a lesson" about riding in the street about every other ride. BTW I ride in full compliance with the law TX VC 551.100-103, I teach bicycle laws to local cops who would bust me in a nanosecond if they caught me breaking the law.

author
thinkdunson made it!(author)2010-05-06

 dude, this instructable has nothing to do with bicycles.  vent somewhere else.

to kill a car you would need a powerful emp genny.

author
Opus+the+Poet made it!(author)2010-05-24

I was hoping for something a little smaller and lighter than an EMP generator, something that didn't require a semi trailer to haul it around. I just want to be able to shut cars down after they are used as a weapon against me. The most deadly thing in our lives is not a gun, but the family car, by a decimal (close to 4 binary) order of magnitude. The number of people that die inside cars has been decreasing as newer cars replace older cars with less passenger protection, but the people outside cars are dying at the same rate they have since the mid-1990s, in spite of fewer miles travelled in the last 2 years.

author
lukeyj15 made it!(author)2011-06-17

I agree with thinkdunson, RFID will never kill a car. Even lighting won't immobilize a car.
You would be better off just firing an automatic weapon at the engine...

author
chandra03 made it!(author)2011-03-11

im chandra..can i get the source code for this...i cant download it.

author
inst_lom made it!(author)2011-01-12

Sorry I can ask a question "also works with a 12f675?" thanks

author
andrew_h made it!(author)2011-01-15

Should work fine on the 675 too. The only real difference is the analogue input.

author
inst_lom made it!(author)2011-01-16

Thanks for the reply I did not have a 12F629 un12f675 I tried but it seems that does not run the program, the file download is
good or has a problem?? Thanks

author
andrew_h made it!(author)2011-01-18

Hmm, there may be an extra option needed to disable the analogue input. Give me a little time and i will relase a version compatible with 675.

author
inst_lom made it!(author)2011-01-19

ok thanks I'll wait

author
andrew_h made it!(author)2011-01-21

Ok, i have uploaded a hex file for 675 on the last step. Should work but i can not test as i don't have one...

author
inst_lom made it!(author)2011-01-24

No, nothing seems to not work
not yet bought the ID-12 but I can not send your pic in the programming jumper
pin 6 is low and pin 7 is high and does not exceed,
Thanks hello ..........
Sorry for the English but is translated

author
andrew_h made it!(author)2011-01-29

I found that i have a 675 so i will give it a try myself in the next few days.

author
inst_lom made it!(author)2011-01-21

THANK YOU SPEED
UNFORTUNATELY I CAN NOT TRY BEFORE MONDAY
POI TI FARO 'KNOW
HELLO THANKS

author
dragon_shadow88 made it!(author)2010-11-02

thanks for answering, but still the question stays : "how could i extend the reading range?"

should i build a bigger anntena ? How should i build it ? i see that the ID-20 has an option for external anntena , but i didn't find anywhere what cind of antenna ?

author
andrew_h made it!(author)2011-01-15

There is antenna designs in the ID-12 datasheet.

Depending on the application and range you need, your easiest option is to use credit card sized 'tags' - these give about 10cm range on an id12.

author
andrew_h made it!(author)2011-01-15

Im currently working on a much more advanced version of this using a 16F828a. It is designed to be a 3 point passive immobiliser and also controlling the central locking of a car.

It's in the final development and testing stages now, hopefully should be finished in a week or two. Let me know if anyone is interested and i will post it as another instructable.

author
dragon_shadow88 made it!(author)2010-09-22

Hi

I wonder does this circuit can work with ID-40 ? because the ID-40 has a tvice longest range than a ID-20.

If the answer is NO , than , how can I extend the operating range of this RFID reader ?

PS: sorry for my bad English, i'm from Serbia :) (thanks for the answer)

author
andrew_h made it!(author)2010-09-22

Looking at the datasheet for the ID-40, i see two potential problems in using it for this setup. It appears that the ID-40 does not use TTL level serial data but 'true' RS-232. You would likely need a max232 or equivalent between the data wire on the ID-40 and the IC to shift the voltages down. The other problem is that the ID-40 runs on 12v (nominal) whereas the ID-12 is only 5v so you would need an additional power source for the ID-40.

author
calaman25 made it!(author)2010-05-20

hi, i downloaded the file, but the extension is .tmp, is that ok?, or i have to change it to .hex

author
andrew_h made it!(author)2010-05-20

 Yes, just rename the file to .hex and you should be fine.

author
ShadowCowz made it!(author)2010-05-11

 pretty awesome, gotta try this :D

author
andrew_h made it!(author)2010-05-11

Thanks for the replies people.  I really had no idea this would be so popular!

author
mikeyeez made it!(author)2010-05-10

great instructables will help in my auto electrical work,

author
shteef made it!(author)2010-05-10

 Hmm, interesting, best get my soldering iron out. Great inscrutable.

author
Dutch_Razor made it!(author)2010-05-09

 Wow this is great! I was trying to create a door lock using the ID12 and a PIC16F628A but I couldn't get it to work.

Is there any chance you could compile it for a 16F628A?

author
andrew_h made it!(author)2010-05-09

 I suppose i can but it's not just as simple as selecting the different chip and hitting compile.  i/o pins/ports and memory locations etc are different in that chip.

If you can be a little patient then i can recode it for the bigger chip but to be honest, is it really worth it?  The 16f628A is way overkill and you'll have a lot of wasted pins.  The 12f629 is also a lot cheaper and is pretty much fully utilised.

author
Dutch_Razor made it!(author)2010-05-10

Sorry I had no experience in that, thought it was just a recompile.

Nevermind then , I'd be better off ordering the 12f629 and keeping the 16F628 for another project.

Thanks for the quick reply!

author
ian+bernal made it!(author)2010-05-08

Hello!  I really like this idea, but forgive for asking, where can i get a RFID card for this? do i have to program it?  thank you

author
andrew_h made it!(author)2010-05-08

The tags are encoded with a 64bit hex key from factory theoretically garunteed unique.  The tag itself or the reader do not need to be programmed, only the PIC.

The cards/tags are commonly available on Ebay and some electronics stores that sell silicon chip kits (Silicon chip released a somewhat similar kit to this). Just look for 125khz RFID tags. They can also be referred to as 'Manchester' tags.

author
samirsky made it!(author)2010-05-06

What would it take to get rid of the need for keys?
I would like to use an RFID (or even just a magnet and a reed switch) to enable my Jeep to be started with a push putton switch.  (No need for keys for the doors in a topless Jeep.)

That way I wouldn't need my keys, and how to start my Jeep would not be obvious to someone who didn't know the 'trick'.

Kind of a cheap-man's-add-on to emulate the newer cars where you don't put the keys in the ignition (keep in pocket) and just push the button.

author
DavidKaine made it!(author)2010-05-07

Wire the relay in place of the ignition keyswitch, so it switches the "run" circuit.  then you just need a momentary switch to engage the starter. You'll need an additional switch to disengage the relay when you want to shut the car down, though.  Through creative use of a loop circuit and a SPDT relay, you could use the start button as a stop button.

author
sgounaro made it!(author)2010-05-04

Hi , I wried the circuit programmed the pic and it seems like it never goes to the programming mode? It just sits with the Red LED on. I tried to sort the jumper also but nothing happens.

I also wired pin 10 of the RFID module ( ID-20) and it shows me when the RFID actually reads the card.

Thanks

author
andrew_h made it!(author)2010-05-04

Are you able to connect it to a serial port of PC to see what it's doing?

Pin2 of the pic is pseudo RS232 tx.
Connect that with pin 2 on a PC serial port and pin 5 on serial port to gnd on the board.  Open hyperterminal @ 9600 and you should see it spit out data as you read the tag.

Make sure you have the ID chip wired for ascii mode and you are using the TTL pin (9) and not the CMOS data pin (8) for data.

I'll hook mine up to a PC soon and post the screenshots here so you can see what to expect.

There is also a slight possibility that the hex i posted is an old/incomplete version (sry, as i said, this was a long time ago i done this).  Ill compare it to what is in my working one and let you know.

author
andrew_h made it!(author)2010-05-05

I've confirmed the original file I uploaded is infact and incomplete one (apologies for that).  I have uploaded a known working copy. (now v1.2).

For some reason my serial port is not working for me at the moment but i have updated the final stage with LED behaviour.

author
sgounaro made it!(author)2010-05-06

Hi know it seems that nothing works after I uploaded the file. None of the LEDS light up anymore , I will try to hook up a serial to the PIC and see how it goes.  Although the reader is reading the cards...

 

author
sgounaro made it!(author)2010-05-06

Works perfectly . I was able to view everything through the serial.
The problem before was that my chip went bad , so I programmed another and it worked..

Thanks again,

Spyros

About This Instructable

62,980views

202favorites

License:

More by andrew_h:Hacking an LG Ducted Split for Home AutomationIoT Enabled Coffee MachineArduino Powered Gainclone (amplifier)
Add instructable to: