RFID Cat Flap computer connection

Pop your questions regarding Home automation Domotica hardware here.....
Darwusch
Member
Member
Posts: 164
Joined: Sun Dec 21, 2008 10:25 pm
Location: Netherlands

Re: RFID Cat Flap computer connection

Post by Darwusch »

I received the exact same email :)
After that I sent an email to Radio Systems Corporation, which is the same as PetSafe as I mentioned in an earlier post.
They told me that they will receive the technical data from Petporte at the end of this month, after which they would inform me.

Building an alternative controller board would be a great idea! But first I'll keep trying to connect th existing board.
Bastiaan
Senior Member
Senior Member
Posts: 1257
Joined: Sat May 24, 2008 11:36 am
Location: Netherlands
Contact:

Re: RFID Cat Flap computer connection

Post by Bastiaan »

I have put up the pressure by also emailing them. :-)
Also ordered the door for 139,- incl delivery.

Lets wait a bit and hope there will be a positive answer.
Bastiaan
Senior Member
Senior Member
Posts: 1257
Joined: Sat May 24, 2008 11:36 am
Location: Netherlands
Contact:

Re: RFID Cat Flap computer connection

Post by Bastiaan »

Ik heb hem inmiddels binnen, maandag eerst maar eens de tag's halen bij de dierenarts om te checken of het werkt voordat ik drie katten laat bewerken.

Ben je al iets verder gekomen met de aansluitingen? Wat en hoe heb je getest?
(dan sla ik die over).

gr Bastiaan
Darwusch
Member
Member
Posts: 164
Joined: Sun Dec 21, 2008 10:25 pm
Location: Netherlands

Re: RFID Cat Flap computer connection

Post by Darwusch »

I only know the connections of jumper J5 as described in my earlier post, later I'll follow the connections of J3 which I believe is needed too for ICSP programming.
With a simple PIC-programmer I want to measure the outputs when our cat gets scanned and the port unlocks. Maybe the rfid tag number can also be read.
This will probably take some more weeks as I don't have enough time lately.
Last edited by Darwusch on Sun Apr 18, 2010 12:58 pm, edited 1 time in total.
Darwusch
Member
Member
Posts: 164
Joined: Sun Dec 21, 2008 10:25 pm
Location: Netherlands

Re: RFID Cat Flap computer connection

Post by Darwusch »

Here you can see the back of the print. With this I'll try to discover the pinout of J3, in order to make the connection to the board.
DSC00780.JPG
DSC00780.JPG (158.27 KiB) Viewed 19017 times
Darwusch
Member
Member
Posts: 164
Joined: Sun Dec 21, 2008 10:25 pm
Location: Netherlands

Re: RFID Cat Flap computer connection

Post by Darwusch »

The connections of JP3, JP4 and JP5:

JP3:
Pin 1: Vcc2
Pin 2: GND
Pin 3: Connected to L293DNE (DC Motor controller) pin 9: (3,4EN function) enables Motor 2
Pin 4: Connected to L293DNE (DC Motor controller) pin 15: (Motor 2 RUN if Logical High)
Pin 5: Connected to PIC pin 6 (RA4)
Pin 6: Connected to right RFID-coil connection and also connected to pin 21 (RB0) of the PIC

JP4: (only solder points present, no pins)
Pin 1: pin 28 PIC (RB7) and ?
Pin 2: pin 27 PIC (RB6)
Pin 3: GND
Pin 4: pin 1 PIC (MCLR)
Pin 5: pin 1 PIC (MCLR) and pin 2 JP8

JP5:
Pin 1: +5 volt
Pin 2: GND
Pin 3: pin 18 PIC (RC7/RX/DT)
Pin 4: pin 17 PIC (RC6/TX/CK)
Pin 5: pin 16 PIC (RC5/SDO) Serial Data Out

So my guess is that with only JP5 and a RS232 cable it is enough to read the data, only the extra circuit for the RS232 connection I'm still figuring out, as most connectors use other pins of the PIC than the ones connected to JP5.
For example here is another connection, using the MCLR-pin of the PIC:
http://www.circuitsonline.net/schakelin ... eding.html
or
http://members.aon.at/electronics/pic/p ... PROGRAMMER

JP4 which only has solder points without pins, seems to be for programming the PIC because it is connected to RB6 and RB7 of the PIC. We won't need this I guess because we don't want to reprogram the PIC.
Last edited by Darwusch on Sat Apr 24, 2010 12:45 pm, edited 10 times in total.
Bastiaan
Senior Member
Senior Member
Posts: 1257
Joined: Sat May 24, 2008 11:36 am
Location: Netherlands
Contact:

Re: RFID Cat Flap computer connection

Post by Bastiaan »

Great start! Thanks.
I will extend the RS232 connector out of the housing for further research. Also thinking about adding a Visonic wireless switch to the two solonoids to know when they are triggered. Very basic, so the RS232 way should be more interesting.
Lucky the petdoor is in the neighbourhood of my wireless curtains so I already had a good electronic 12V powersupply there because they deliver the door with the very old fashioned power adapter.
Darwusch
Member
Member
Posts: 164
Joined: Sun Dec 21, 2008 10:25 pm
Location: Netherlands

Re: RFID Cat Flap computer connection

Post by Darwusch »

With the max232 chip it is probably the easiest method to connect the catflap to the rs232 port.
From JP5, these pins can be connected via the max232 to the rs232 port:
Pin 1: +5V
Pin 2: GND
Pin 3: pin 18 PIC (RC7/RX/DT)
Pin 4: pin 17 PIC (RC6/TX/CK)

See:
http://hades.mech.northwestern.edu/index.php/PIC_RS232
and picture.

And then we can read out the chip with either matlab or a Serial Port Monitor.
Attachments
circuit_232.jpg
circuit_232.jpg (23.79 KiB) Viewed 18965 times
Darwusch
Member
Member
Posts: 164
Joined: Sun Dec 21, 2008 10:25 pm
Location: Netherlands

Re: RFID Cat Flap computer connection

Post by Darwusch »

Yesterday I built the schematic above.
I connected a serial cable and the smartflap to that circuit as described.
Then I started a serial port monitor to see if there is some information on the TX output of the PIC when you press for instance the red button of the flap.
Nothing to see however. I have to wait for my Cat to come back from it's trip outside to see if there is something on the TX output when he gets scanned by the rfid reader, otherwise I have to think of something else.
Bastiaan
Senior Member
Senior Member
Posts: 1257
Joined: Sat May 24, 2008 11:36 am
Location: Netherlands
Contact:

Re: RFID Cat Flap computer connection

Post by Bastiaan »

Good News, saves me from making it this week.
Last time I borrowed some chips from the vet for testing. They were OK with this becaue you can keep them sealed. I could use three of them to preprogram before they went into the cats.

Curious about the results when a cat goes through. Our one has been working great, after we switched of the beep, because it scared the cats.
I guess there will be no indication of direction so probably the next step will be a reed contact on the door.
My tunnel is 25cm long so it is pritty easy to detect if the door goes before the detection or the detection goes first.
Darwusch
Member
Member
Posts: 164
Joined: Sun Dec 21, 2008 10:25 pm
Location: Netherlands

Re: RFID Cat Flap computer connection

Post by Darwusch »

Is there somebody with experience with PICs on this forum?
The main issue I have is with choosing the right pins to read out data from the chip. I don't see any output of it on my Serial Port Monitor.
Now I used the Rx/Tx pins but I didn't change any input level of other pins. Might be some pins require to be set to High/Low in order to let the Tx pin transmit an ouput to my PC for instance. I have to do some searching on the web to learn about reading out this PIC 16F886.

I measured that the Rx, Tx and SDO are alle logical High +5V on idle, which seems to be right after reading about the RS232 protocol. This only proofs that the connection itself is working, only I don't see any data on my pc when there is an event in the smartflap, such as a button press or when my cat gets scanned and the smartflap unlocks.
User avatar
Fantic
Member
Member
Posts: 201
Joined: Sat Feb 21, 2009 2:11 pm
Location: Loenen, UT, Netherlands
Contact:

Re: RFID Cat Flap computer connection

Post by Fantic »

Keep in mind that TX = Transmit should be a 5 V signal on the side that is sending only the other end should NOT show any voltage, so check without the 2 connected that you have the tx from the one connected to the RX from the other and vise versa.
Regards, Maarten.
Never let a computer know you're in a hurry.
Darwusch
Member
Member
Posts: 164
Joined: Sun Dec 21, 2008 10:25 pm
Location: Netherlands

Re: RFID Cat Flap computer connection

Post by Darwusch »

Thanks for your reply.
I measured the following voltages:
Rx of PIC (Grey disconnected): 0,93 V measured at PIC-side
Tx of PIC (Orange disconnected): +5 V measured at PIC-side
Rx of RS232 (Green disconnected): -5,85 V measured at RS232-side
Tx of RS232 (Blue disconnected): 0 V measured at RS232-side

I have the connection to the PIC as follows:
Pin 18 of the PIC is connected to pin 12 of the max232
Pin 17 of the PIC is connected to pin 11 of the max232
The rest is connected as the figure above describes.

I also did a loop back test. Herefore I connected Rx and Tx at the PIC-side. Then I sent some characters from the PC. They al echoed as expected, so the circuit seems to be fine.
Maybe the PIC is programmed to only respond to a certain input code, but I don't know which code.
User avatar
Fantic
Member
Member
Posts: 201
Joined: Sat Feb 21, 2009 2:11 pm
Location: Loenen, UT, Netherlands
Contact:

Re: RFID Cat Flap computer connection

Post by Fantic »

once youre sure the TX and RX between PIC and MAX232 are ok just try to sned data to it and try to find anything that works, the correct speed and parity setting should give you at least some response.
Regards, Maarten.
Never let a computer know you're in a hurry.
Darwusch
Member
Member
Posts: 164
Joined: Sun Dec 21, 2008 10:25 pm
Location: Netherlands

Re: RFID Cat Flap computer connection

Post by Darwusch »

The right speed and parity and other settings are unknown for me.
I tried 9600 and 19200 baud with 8 bits data, 1 stopbit and parity:none.
Might be these are incorrect. I'll try some more settings, thanks.
Post Reply

Return to “Questions & Discussions Forum”