2

I need to build a circuit that closes when it detects the passing of a magnetic card. It should open again when the card passes again.

So I need a simple magnetic reed (like this one). And some kind of switch component that closes when it detects a current pulse from the magnetic reed (right?).

Can someone tell me what kind of component I should use?

JYelton
  • 32,302
  • 33
  • 134
  • 249
  • I don't know your knowlege level about electronics, but it is good to learn more on: 1)Magnetic Tape Recording Principles 2)Digital Tape recorders 2)Magnetic Stripe Cards standards 3)How to modify your old tape recorder into a card reader....then you refine your question – GR Tech Jan 25 '14 at 12:47
  • It is customary in English to capitalize "I" when referring to yourself. I have edited your question accordingly. – JYelton Jan 26 '14 at 05:58

3 Answers3

1

You could use reed switch output to toggle a flip-flop such as a 74LV74.

Simply connect the /Q output to the D input and the clock input to the debounce circuit output. /CLR and /PRE must be tied high (along with any other unused inputs from the other half of the chip).

schematic

The Q output will go high and low alternately each time the switch opens. It will not start up in any particular state, to do that requires a bit more circuitry and the use of the /CLR or the /PRE input.

Do not substitute a flip-flop that does not have a schmitt trigger clock input or you may get false operation.

Spehro Pefhany
  • 376,485
  • 21
  • 320
  • 842
1

If you are expecting the magnetic field from the stripe on a credit card (or similar card) to operate a reed switch, I think you are going to be sadly disappointed.

You need something like the tape head from an audio cassette deck, a sensitive audio amplifier with gain of 40 to 60dB, an audio level detector of some kind (to distinguish between random noise or interference) and a switch (relay or MOSFET) to close the output circuit. Tape head amplifiers are quite similar to microphone amplifiers in ther needs for high gain and low noise.

If you use a microcontroller with an ADC to detect the audio level, it can control the opening and closing of the output circuit, and maybe provide some validation that the correct card is used.

If you must use a reed switch as you suggest, you will need to embed a much more powerful magnet in the card (perhaps where the chip would be?) and then it poses a serious danger of erasing the stripes on any other cards in your pocket!

  • Thanks for the info. But the idea was to just use a flat magnet (credit card size). I will not bring it to close to my real credit cards :) – Baksteendegeweldige Jan 25 '14 at 11:51
  • 1
    The flat magnets I've seen (flexible like rubber) often have an interesting magnetisation pattern : rub 2 over each other and they alternately attract and repel; a flux reversal every 3-5mm. So with a reed switch and a relay you may get multiple switch closures per card swipe... –  Jan 26 '14 at 11:19
1

Instead of the reed switch, consider a Hall-effect switch (or Hall-effect sensor, but the switch is more appropriate for your task). They're far more sensitive, much smaller, consume much less power and (in switch form) typically integrate debounce filtering as well.

markt
  • 4,936
  • 2
  • 15
  • 13