Shop OBEX P1 Docs P2 Docs Learn Events
Using BS2sx in a car — Parallax Forums

Using BS2sx in a car

ArchiverArchiver Posts: 46,084
edited 2003-04-09 19:37 in General Discussion
I am using a BS2sx and a Javelin stamp in a project in a car, and I
need to have the following things:

1. Detect the presence of +12VDC and represent it as +5vdc to the
stamp.

2. Detect the presence of chassis GND and represent it as GND to the
Stamp.

3. Ability to control a 5VDC 30mA relay coil using either a GND or
+5vdc source.

4. Noise resistant two way communications on a twisted pair shielded
cable.

I have ideas on what to use for these problems, but I figure that
others are using stamps in automotive apps, and I am curious on how
it is being done with the smallest component count.

What I have figured out so far:

regarding #1 I think an optoisolator will do the best job, but how do
I do these things, does anyone have a schematic for my specific
application. I dont want to fry parts, or worse, have the parts fry
over time while I am driving down the road...

Regarding #2 It seems that stamps like to work using ground, it draws
virtually nothing from the stamp, and is a great way to provide
signals to the stamp with relative safety. one question - how do I
keep noise and transient spikes out of this circuit?

Reagrding #3 ULN2803 seems to be able to drive a relay? no extra
parts needed? just a diode on the coil leads?

Regarding #4 - RS485? anyone have luck with this? In my situation I
only have 2 signal wires and a ground to work with.

I am looking for workable schematics of these circuits involving
working in a 12VDC environment. I am also looking into viable
power sources for the BS2 and have found that the 7805A seems to fit
the bill, has anyone found a schematic with 12VDC in, 5VDC out? I
know these are all simple questions, but I just want to make sure I
am completely headed in the right direction. thanks in advance for
any advice, feel free to tell me I am doing it all wrong [noparse];)[/noparse]

Brian

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2003-04-09 04:53
    In a message dated 4/8/2003 8:50:13 PM Pacific Daylight Time,
    briancase1972@y... writes:

    > I am using a BS2sx and a Javelin stamp in a project in a car, and I
    > need to have the following things:
    >
    > 1. Detect the presence of +12VDC and represent it as +5vdc to the
    > stamp.
    >
    > 2. Detect the presence of chassis GND and represent it as GND to the
    > Stamp.
    >
    > 3. Ability to control a 5VDC 30mA relay coil using either a GND or
    > +5vdc source.
    >
    > 4. Noise resistant two way communications on a twisted pair shielded
    > cable.
    >
    > I have ideas on what to use for these problems, but I figure that
    > others are using stamps in automotive apps, and I am curious on how
    > it is being done with the smallest component count.
    >
    > What I have figured out so far:
    >
    > regarding #1 I think an optoisolator will do the best job, but how do
    > I do these things, does anyone have a schematic for my specific
    > application. I dont want to fry parts, or worse, have the parts fry
    > over time while I am driving down the road...
    >
    > Regarding #2 It seems that stamps like to work using ground, it draws
    > virtually nothing from the stamp, and is a great way to provide
    > signals to the stamp with relative safety. one question - how do I
    > keep noise and transient spikes out of this circuit?
    >
    > Reagrding #3 ULN2803 seems to be able to drive a relay? no extra
    > parts needed? just a diode on the coil leads?
    >
    > Regarding #4 - RS485? anyone have luck with this? In my situation I
    > only have 2 signal wires and a ground to work with.
    >
    > I am looking for workable schematics of these circuits involving
    > working in a 12VDC environment. I am also looking into viable
    > power sources for the BS2 and have found that the 7805A seems to fit
    > the bill, has anyone found a schematic with 12VDC in, 5VDC out? I
    > know these are all simple questions, but I just want to make sure I
    > am completely headed in the right direction. thanks in advance for
    > any advice, feel free to tell me I am doing it all wrong [noparse];)[/noparse]
    >
    > Brian
    >

    You are on the right track. You can reply off the post directly to me with a
    fax # and I can send a schematic.


    [noparse][[/noparse]Non-text portions of this message have been removed]
  • ArchiverArchiver Posts: 46,084
    edited 2003-04-09 15:46
    Brian, A few items need to be mentioned. In a vehicle, 12 volts is not 12
    volts but usually up to 14.5 volts dc or so when the engine is running. A
    7805 regulator is OK to cut the voltage down if you use a heat sink or a
    resistor to drop some of the voltage coming in to keep the heat down on the
    chip. Stamp ground should be at vehicle ground potential. Optical
    isolators would work for incomming 12 volt signals to convert to 5 volts but
    a simple voltage divider will also work for less cost and complexity. Pick
    values to see 4 volts at the junction of the two resistors with 14.5 volts
    in and you should have no problems. Place a .1 uF cap to ground on the
    input to the stamp to knock down some of the high frequency noise. You can
    eliminate a relay on the output and just switch a transistor instead and
    save the cost of the relay. You can also talk to the stamp serially if you
    wish and have it respond to external serial commands or transfer data out to
    your computer. For some controller applications and schematics, and links
    to parts suppliers where you can get data sheets, check my web site:
    http://www.geocities.com/jimforkin2003

    Jim

    Original Message
    From: Brian [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=ZgvS-FYBEuSYrWLTcJd6ED0NOZKcOQELMDLw-l8U_kX_Id8jQMbityo-3hlEW6V1Jq57rlarHjOlDGybxoOs]briancase1972@y...[/url
    Sent: Tuesday, April 08, 2003 11:49 PM
    To: basicstamps@yahoogroups.com
    Subject: [noparse][[/noparse]basicstamps] Using BS2sx in a car


    I am using a BS2sx and a Javelin stamp in a project in a car, and I
    need to have the following things:

    1. Detect the presence of +12VDC and represent it as +5vdc to the
    stamp.

    2. Detect the presence of chassis GND and represent it as GND to the
    Stamp.

    3. Ability to control a 5VDC 30mA relay coil using either a GND or
    +5vdc source.

    4. Noise resistant two way communications on a twisted pair shielded
    cable.

    I have ideas on what to use for these problems, but I figure that
    others are using stamps in automotive apps, and I am curious on how
    it is being done with the smallest component count.

    What I have figured out so far:

    regarding #1 I think an optoisolator will do the best job, but how do
    I do these things, does anyone have a schematic for my specific
    application. I dont want to fry parts, or worse, have the parts fry
    over time while I am driving down the road...

    Regarding #2 It seems that stamps like to work using ground, it draws
    virtually nothing from the stamp, and is a great way to provide
    signals to the stamp with relative safety. one question - how do I
    keep noise and transient spikes out of this circuit?

    Reagrding #3 ULN2803 seems to be able to drive a relay? no extra
    parts needed? just a diode on the coil leads?

    Regarding #4 - RS485? anyone have luck with this? In my situation I
    only have 2 signal wires and a ground to work with.

    I am looking for workable schematics of these circuits involving
    working in a 12VDC environment. I am also looking into viable
    power sources for the BS2 and have found that the 7805A seems to fit
    the bill, has anyone found a schematic with 12VDC in, 5VDC out? I
    know these are all simple questions, but I just want to make sure I
    am completely headed in the right direction. thanks in advance for
    any advice, feel free to tell me I am doing it all wrong [noparse];)[/noparse]

    Brian



    To UNSUBSCRIBE, just send mail to:
    basicstamps-unsubscribe@yahoogroups.com
    from the same email address that you subscribed. Text in the Subject and
    Body of the message will be ignored.


    Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
  • ArchiverArchiver Posts: 46,084
    edited 2003-04-09 16:36
    Hello

    I would also like to add that during starp up, there can be very
    large spikes on the nominal 12V supply. These spikes can be up to
    40V and carry enough energy to damage unprotected eqiupment.

    This can also happen if there happens to be a 'loose battery'
    terminal, which means that the alternator can be intermitantly
    disonnected from the battery resulting in a large spiked, again
    posing damage to the verlunerable parts.

    So, keep these facts in mind when designing a power supply.

    Best Regards

    Ashfaq



    --- In basicstamps@yahoogroups.com, "Jim Forkin" <jjf@p...> wrote:
    > Brian, A few items need to be mentioned. In a vehicle, 12 volts
    is not 12
    > volts but usually up to 14.5 volts dc or so when the engine is
    running. A
    > 7805 regulator is OK to cut the voltage down if you use a heat sink
    or a
    > resistor to drop some of the voltage coming in to keep the heat
    down on the
    > chip. Stamp ground should be at vehicle ground potential. Optical
    > isolators would work for incomming 12 volt signals to convert to 5
    volts but
    > a simple voltage divider will also work for less cost and
    complexity. Pick
    > values to see 4 volts at the junction of the two resistors with
    14.5 volts
    > in and you should have no problems. Place a .1 uF cap to ground on
    the
    > input to the stamp to knock down some of the high frequency noise.
    You can
    > eliminate a relay on the output and just switch a transistor
    instead and
    > save the cost of the relay. You can also talk to the stamp
    serially if you
    > wish and have it respond to external serial commands or transfer
    data out to
    > your computer. For some controller applications and schematics,
    and links
    > to parts suppliers where you can get data sheets, check my web site:
    > http://www.geocities.com/jimforkin2003
    >
    > Jim
    >
    >
    Original Message
    > From: Brian [noparse][[/noparse]mailto:briancase1972@y...]
    > Sent: Tuesday, April 08, 2003 11:49 PM
    > To: basicstamps@yahoogroups.com
    > Subject: [noparse][[/noparse]basicstamps] Using BS2sx in a car
    >
    >
    > I am using a BS2sx and a Javelin stamp in a project in a car, and I
    > need to have the following things:
    >
    > 1. Detect the presence of +12VDC and represent it as +5vdc to the
    > stamp.
    >
    > 2. Detect the presence of chassis GND and represent it as GND to
    the
    > Stamp.
    >
    > 3. Ability to control a 5VDC 30mA relay coil using either a GND or
    > +5vdc source.
    >
    > 4. Noise resistant two way communications on a twisted pair
    shielded
    > cable.
    >
    > I have ideas on what to use for these problems, but I figure that
    > others are using stamps in automotive apps, and I am curious on how
    > it is being done with the smallest component count.
    >
    > What I have figured out so far:
    >
    > regarding #1 I think an optoisolator will do the best job, but how
    do
    > I do these things, does anyone have a schematic for my specific
    > application. I dont want to fry parts, or worse, have the parts fry
    > over time while I am driving down the road...
    >
    > Regarding #2 It seems that stamps like to work using ground, it
    draws
    > virtually nothing from the stamp, and is a great way to provide
    > signals to the stamp with relative safety. one question - how do I
    > keep noise and transient spikes out of this circuit?
    >
    > Reagrding #3 ULN2803 seems to be able to drive a relay? no extra
    > parts needed? just a diode on the coil leads?
    >
    > Regarding #4 - RS485? anyone have luck with this? In my situation
    I
    > only have 2 signal wires and a ground to work with.
    >
    > I am looking for workable schematics of these circuits involving
    > working in a 12VDC environment. I am also looking into viable
    > power sources for the BS2 and have found that the 7805A seems to fit
    > the bill, has anyone found a schematic with 12VDC in, 5VDC out? I
    > know these are all simple questions, but I just want to make sure I
    > am completely headed in the right direction. thanks in advance for
    > any advice, feel free to tell me I am doing it all wrong [noparse];)[/noparse]
    >
    > Brian
    >
    >
    >
    > To UNSUBSCRIBE, just send mail to:
    > basicstamps-unsubscribe@yahoogroups.com
    > from the same email address that you subscribed. Text in the
    Subject and
    > Body of the message will be ignored.
    >
    >
    > Your use of Yahoo! Groups is subject to
    http://docs.yahoo.com/info/terms/
  • ArchiverArchiver Posts: 46,084
    edited 2003-04-09 16:44
    In a message dated 4/9/2003 8:01:35 AM Pacific Daylight Time, jjf@p...
    writes:

    > A
    > 7805 regulator is OK to cut the voltage down if you use a heat sink or a
    > resistor to drop some of the voltage coming in to keep the heat down on the
    > chip.

    Beware of using a resistor in series with the input to a 7805 regulator. If
    the current consumption is constant, there will not be a problem.
    However, if you install an in-series resistor to the regulator is "minimal"
    circuit current, then some loads draw more current, the voltage drop across
    the in-series resistor will increase and reduce available voltage to the
    regulator, which may fall out of regulation.

    In summary, if you use an in-series resistor, be sure its value is chosen for
    the worst case current consuption.

    Somebody please correct me if I don't see the entire picture here. A certain
    amount of power will be dissipated dropping the vehicle voltage to the
    regulator.
    You can choose to have the regulator dissipate all the power, or share some
    of the dissipation with a resistor, regardless, a certain amount of power
    must be dissipated. What is the advantage to an in-series resistor????? The
    high wattage resistor is cheaper than the heat sink for the
    regulator??????That is the only advantage I see.
    If using the resistor however, it must be chosen using the worst case current
    consumption, otherwise the regulator may fall out of regulation when the
    regulated current increases due to some load being controlled on.

    Ken


    [noparse][[/noparse]Non-text portions of this message have been removed]
  • ArchiverArchiver Posts: 46,084
    edited 2003-04-09 19:04
    The advantage of the external dropping resistor is that the linear regulator
    (7805) has a maximum temprature that is easy to exceed when regulating 15
    volts. Of course, the amount of voltage drop in heat is the same, it
    however is shared between the regulator and resistor. Remember that in an
    automotive application you are starting with a high ambient temperature. A
    better choice would be a switching regulator that runs more efficiently.
    The load seen by the regulator would be the stamp current and drive to the
    transistors and they should be darlingtons or mosfets for low drive
    requirements. Relays or sensors should be powered by 12v.
    Jim

    Original Message
    From: smartdim@a... [noparse]/noparse]mailto:[url=http://forums.parallaxinc.com/group/basicstamps/post?postID=T2wMcPfI2qA6koYkUcbcQ6bpq-MTsh6Z0jaQ2ECx9gEkUTNPLl7GPk0feFjphGwL3Z6lY4GmGUg]smartdim@a...[/url
    Sent: Wednesday, April 09, 2003 11:44 AM
    To: basicstamps@yahoogroups.com
    Subject: Re: [noparse][[/noparse]basicstamps] Using BS2sx in a car


    In a message dated 4/9/2003 8:01:35 AM Pacific Daylight Time,
    jjf@p...
    writes:

    > A
    > 7805 regulator is OK to cut the voltage down if you use a heat sink or a
    > resistor to drop some of the voltage coming in to keep the heat down on
    the
    > chip.

    Beware of using a resistor in series with the input to a 7805 regulator. If
    the current consumption is constant, there will not be a problem.
    However, if you install an in-series resistor to the regulator is "minimal"
    circuit current, then some loads draw more current, the voltage drop across
    the in-series resistor will increase and reduce available voltage to the
    regulator, which may fall out of regulation.

    In summary, if you use an in-series resistor, be sure its value is chosen
    for
    the worst case current consuption.

    Somebody please correct me if I don't see the entire picture here. A certain
    amount of power will be dissipated dropping the vehicle voltage to the
    regulator.
    You can choose to have the regulator dissipate all the power, or share some
    of the dissipation with a resistor, regardless, a certain amount of power
    must be dissipated. What is the advantage to an in-series resistor????? The
    high wattage resistor is cheaper than the heat sink for the
    regulator??????That is the only advantage I see.
    If using the resistor however, it must be chosen using the worst case
    current
    consumption, otherwise the regulator may fall out of regulation when the
    regulated current increases due to some load being controlled on.

    Ken


    [noparse][[/noparse]Non-text portions of this message have been removed]


    To UNSUBSCRIBE, just send mail to:
    basicstamps-unsubscribe@yahoogroups.com
    from the same email address that you subscribed. Text in the Subject and
    Body of the message will be ignored.


    Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
  • ArchiverArchiver Posts: 46,084
    edited 2003-04-09 19:37
    In a message dated 4/9/2003 11:18:36 AM Pacific Daylight Time,
    jjf@p... writes:

    > The advantage of the external dropping resistor is that the linear regulator
    > (7805) has a maximum temprature that is easy to exceed when regulating 15
    > volts. Of course, the amount of voltage drop in heat is the same, it
    > however is shared between the regulator and resistor. Remember that in an
    > automotive application you are starting with a high ambient temperature. A
    > better choice would be a switching regulator that runs more efficiently.
    > The load seen by the regulator would be the stamp current and drive to the
    > transistors and they should be darlingtons or mosfets for low drive
    > requirements. Relays or sensors should be powered by 12v.
    > Jim

    Thanks for the explanation


    [noparse][[/noparse]Non-text portions of this message have been removed]
Sign In or Register to comment.