0/13v conversion to TTL

Discussion in 'The Projects Forum' started by billuk, Dec 14, 2010.

  1. billuk

    Thread Starter New Member

    Dec 14, 2010
    5
    0
    Hi there,

    First post :)

    I have a domestic intruder alarm which I am trying to interface with a NET-IOM (which is a network connected IO device).

    The NET-IOM has TTL digital inputs, max input of 5V.

    The intruder alarm has outputs e.g. Fire / panic / intruder that are 13V normally and 0V when activated.

    So how can I safely convert the 13V DC output of the alarm to 5V max?

    Hope that makes sense! Thanks in advance :)
     
  2. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    See the attached for one way to do it.

    The regulator can be a 7805 type that's available at your local Radio Shack store (if you're in the States that is).

    The capacitors are required for stability of the regulator. You could probably use 0.1uF (100nF) for both of them.

    R1 is necessary to drain the output capacitor when the input goes low, and also to provide a minimum load on the regulator.
     
  3. #12

    Expert

    Nov 30, 2010
    16,284
    6,797
    How about a resistor in series and a 4.7 zener to ground?
    How about a resistor in series and a diode to the +5 supply on the ttl board, then a series diode to the input?
     
  4. billuk

    Thread Starter New Member

    Dec 14, 2010
    5
    0
    Thanks for your suggestions, would there be any heat issues with the input voltage being at 13V for virtually 100% of the time (i.e. unless there is a alarm)?
     
  5. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Not with a 7805 at such a light loading. 120mW power dissipation in the regulator, 50mW dissipation in R1. Any additional load posed by the input to the alarm could be calculated by 120mW + 8v/loadcurrent.

    #12's suggestion could work, too. You would need to select a correct Zener diode/resistor combination. The Zener could be 4.7v or 5.1v.

    A BZX79-B/C4V7 or BZX79-B/C5V1 250mW Zener in series with a 1.6k 1/10W or higher wattage resistor should work OK.

    Keep in mind that with Zener diodes, the band (cathode) goes towards the more positive voltage.
     
    Last edited: Dec 14, 2010
  6. Wendy

    Moderator

    Mar 24, 2008
    20,766
    2,536
    Don't forget, most TTL level 1 is around 3.4 V. The 5V will work, but true conversion will be a bit less voltage.
     
  7. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Bill,
    It really depends upon what is "inside the box" of the alarm system.

    With the old TTL from the 70's, a logic 0 was anything under 0.8v, and a logic 1 was anything over 2.8v, with the 0.8v to 2.8v being the indeterminate region.

    Nowadays, many TTL IC's are really 74HC versions - but it's more likely that the system is actually using a MCU aka uC aka microcontroller as an input - so they'll still call it TTL levels.
     
  8. billuk

    Thread Starter New Member

    Dec 14, 2010
    5
    0
    Thanks for all the replies, it's most helpful.

    To go into more detail, the alarm panel has a 'communicator output' to connect to a communicator to dial telephone numbers in the event of an alarm. The communicator has several outputs, one for fire alarm, one for panic alarm and one for intruder alarm. Each is held at 13V when not in an alarm state and drops to 0V when an alarm occurs. According to the manual the outputs can source or sink 10mA.

    I want to connect these output to a Net-IOM - http://www.phaedrusltd.com/pages/html/netiom.html
    This will allow me to monitor remotely the state of the alarm and receive emails (or SMS via email) when the alarm is triggered. According to the manual for this device there are 16 digital Inputs - TTL / CMOS / dry contacts (10K ohm pull up), and in the manual it states:

    'Each digital input is connected to a CMOS gate via a 100K resistor. It is pulled up to the internal 5 Volt supply rail via a 10K resistor.
    The input can be directly interfaced to TTL and CMOS outputs. The input voltage should not exceed 5 Volts. In addition the inputs can use clean contacts referenced to 0 Volts or open collector outputs again referenced to 0 Volts.'

    Sorry for so many words but hopefully that will give you a clearer picture of what I'm trying to do.

    Thanks,

    Bill
     
  9. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    So, alarm panel output: 13v=noalarm, 0v=alarm.
    What about the Net-IOM?
    1) 5v in = noalarm, 0v = alarm?
    --Or--
    2) 0v in = noalarm, 5v = alarm?
     
  10. billuk

    Thread Starter New Member

    Dec 14, 2010
    5
    0
    The Net-IOM can be set to trigger alerts either way, so I was planning on doing whatever was easiest electronically, if that makes sense!

    Cheers, Bill
     
  11. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Have a look at the attached; it's pretty simple.

    R1 limits Q1's base current to (13v-Vbe) / 10,000 Ohms = (13-0.7) / 10k = 12.3/10k = ~1.23mA (milliamperes; 1/1000 of an Ampere)

    This enables Q1 to sink up to 12.3mA current and stay in saturation (Vce < 0.2v), which is more than enough, and will be a light load on your system.

    R2 makes certain that Q1 turns OFF completely if there is no signal input. You might get away with omitting R2, but I suggest you keep it in there.

    Since the Net-IOM box has it's own 10k pull-up resistors, there's no need to connect to a 5v source anywhere.

    Note that there must be a common ground between the alarm panel and the Net-IOM. If that isn't possible or is difficult, then you could go with an optoisolator/optocoupler.
     
  12. billuk

    Thread Starter New Member

    Dec 14, 2010
    5
    0
  13. SgtWookie

    Expert

    Jul 17, 2007
    22,182
    1,728
    Yes, that would do it, and would take the place of the circuit I posted.
     
Loading...