Hello all,
I'm attempting to get a little dead-man's vigilance device working. I've got a handheld-unit with a microcontroller that once activated with a push button, begins to count down, which is reset by pushing the button again. If the counter runs down, then the hand-held device sends a signal to a "main unit" through an 25m extension lead, to set off an alarm.
The switching circuit I'm using to switch the alarm looks similar to this:
The Port-C2 is fed into a output pin of a Teensy LC, whose voltage levels are 3.3V. The BJT I'm using is a BC337, and the mosfet I'm using is a FQD13N10L N-Channel, with a 12V 120mA motorcycle alarm instead of the motor. The idea is is the alarm should only go off if the counter runs down, or the hand held unit is destroyed or the cable is cut somehow. The Teensy's Port pulls it's pin to 3.3v, the BJT conducts, a voltage drop occurs over the R1 10k resistor and so the mosfet is switched off.
The thing is, when I plug in my device, the alarm goes off, fine, the Teensy in the hand held unit needs to power up, run the code and pull it's output pin high to turn on the BJT - it does, but instead of silence I hear a crackling noise from the alarm - it's still kind of running! So I used a oscilloscope to the gate end of the R1 resistor while it was doing so, and I saw:
Since the threshold voltage of the FQD13N10L is 1 V according to the datasheet, the noise I'm seeing here seems large enough to set off the mosfet!
I had problems with noise before, as I simply attempted to pull the mosfet gate to zero directly through the Teensy. The cable I'm using acted as an antenna and the Teensy's sensitive pins picked up the noise, and the alarm ran at full loudness.
I'm concerned that this is still what is happening. Any Ideas on how to deal with this? Thanking you all in advance.
I'm attempting to get a little dead-man's vigilance device working. I've got a handheld-unit with a microcontroller that once activated with a push button, begins to count down, which is reset by pushing the button again. If the counter runs down, then the hand-held device sends a signal to a "main unit" through an 25m extension lead, to set off an alarm.
The switching circuit I'm using to switch the alarm looks similar to this:
The Port-C2 is fed into a output pin of a Teensy LC, whose voltage levels are 3.3V. The BJT I'm using is a BC337, and the mosfet I'm using is a FQD13N10L N-Channel, with a 12V 120mA motorcycle alarm instead of the motor. The idea is is the alarm should only go off if the counter runs down, or the hand held unit is destroyed or the cable is cut somehow. The Teensy's Port pulls it's pin to 3.3v, the BJT conducts, a voltage drop occurs over the R1 10k resistor and so the mosfet is switched off.
The thing is, when I plug in my device, the alarm goes off, fine, the Teensy in the hand held unit needs to power up, run the code and pull it's output pin high to turn on the BJT - it does, but instead of silence I hear a crackling noise from the alarm - it's still kind of running! So I used a oscilloscope to the gate end of the R1 resistor while it was doing so, and I saw:
Since the threshold voltage of the FQD13N10L is 1 V according to the datasheet, the noise I'm seeing here seems large enough to set off the mosfet!
I had problems with noise before, as I simply attempted to pull the mosfet gate to zero directly through the Teensy. The cable I'm using acted as an antenna and the Teensy's sensitive pins picked up the noise, and the alarm ran at full loudness.
I'm concerned that this is still what is happening. Any Ideas on how to deal with this? Thanking you all in advance.