Connecting PIRs to a PIC12F675

Status
Not open for further replies.

Yobortsa

Member
I'm trying to connect security system PIRs (movement detectors) to a PIC12F675 microcontroller.

Attached is my proposed schematic. Does it look ok?

How do I calculate appropriate values for the resisters?

What transistor should I use?

Does it matter that the transister isn't amplifying the current? (ie. am I correct in saying that Hfe will be less than 1?).

Thanks in advance,

David
 

Attachments

  • proposed.png
    85.8 KB · Views: 163
If the PIR detectors are located a distance away from the 12F675 it is better to use an optocoupler in place of the transistor. This is to eliminate noise pickup.
 
The PIR has a reed switch. Connect it to the PIC via a small-value resistor as a pull-up or pull-down. A low-value will reduce noise being picked up.
 
Agreed. NEVER leave the base of a transistor floating. Always reference it to either GND or Vdd via a pull up/pull down resistor. But as colin55 mentioned above, the transistor isn't even needed.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…