Searching \ for '[EE] Automotive environment' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/language/index.htm?key=environ
Search entire site for: 'Automotive environment'.

Exact match. Not showing close matches.
PICList Thread
'[EE] Automotive environment'
2011\11\12@124026 by Electron

flavicon
face

It's a motorbike, really, not a car.

I'm exploring noise and EMI issues, here's a very simple example, I hope You
can help me understand how to make the system more robust.

So, let's talk about a specific example: the motorbike has a reed-like sensor
on the front wheel. The brake disc contains a small magnet. When the wheel
make a full revolution, the magnet passes by the reed, and this is shorted.

Measuring the digital odometer showed a very small current (~100uA IIRC),
and also because I have important power consumption constraints, I decided
(as I want to measure those wheel revolutions) to use a pull-up resistor
value of 100 kohm on T1CK input of a PIC24. T1CK is a schmitt trigger input..
The reed will short it at each wheel revolution, and the Timer1 counter will
increment.

It works.. however, when the engine is running I get spurious additional
counts. Even when the electric starter is cranking (but I keep the engine
kill to ground, so the engine won't start).

Looks like EMI, but I can't shield the cable, as it has to remain the original
cable.

I wonder, how does the original digital odometer cope with the noise? True
I could lower the pull up resistance and probably solve the problem this way
(as long as current draw doesn't become excessive, but as it is normally
open, and the pulse is short, it's unlikely to be a problem) but it puzzles
me that measuring the original digital odometer current I get such a low
value. Is it really that low, or may I suspect something clever is in place?
(e.g. it does draw larger currents but only for a very short time?).

More generally, what are Your thoughts on this matter? How would you interface
the reed with T1CK in a noisy environment?

I'm thinking about all..:

1) one single ground to my electronic circuit (to avoid ground loops) - the
reed is grounded somewhere and I get the "hot" wire.

2) shield the circuit if necessary (but this doesn't seem to be the problem,
as noise seems to come from the bike's odometer wire, which I cannot shield).

3) bigger bypass? Ferrite beads? Would they help for the EMI? Sure filtering
the power wouldn't help, as I get interference even using a stand alone battery.

4) bypass/bead on the sensor wire then? It should improve things but do I
still get a nice pulse then? T1CK is a schmitt trigger, that should help at
least with the slower rising edge.

Anyhow, if You experienced automotive or more in general EMI-issues people
can give me some hints and insights, I'd appreciate it a lot.

With kind regards,
Mario

2011\11\12@132523 by Electron

flavicon
face

PS:

>I wonder, how does the original digital odometer cope with the noise? True
>I could lower the pull up resistance and probably solve the problem this way
>(as long as current draw doesn't become excessive, but as it is normally
>open, and the pulse is short, it's unlikely to be a problem) but it puzzles
>me that measuring the original digital odometer current I get such a low
>value. Is it really that low, or may I suspect something clever is in place?
>(e.g. it does draw larger currents but only for a very short time?).

I measured the thing.. 400 uA peak, BUT much less (~9 uA) sustained, looks
like I was right in my assumption, i.e. it provides a "high" current but then
the current lowers.

A resistor + capacitor in place?

Moreover, I thought I should also use a lower value cap FIRST in parallel to
filter the high frequency noise coming from the environment. I will try with
10 nF first, and then change value until (with the wheel not running) I get
no noise anymore. Then I will go back to the "source current" issue, although
400 uA could be sourced continuously IMHO, as the reed is normally open.

I'd still like to hear about Your comments though!

Cheers,
Mario

2011\11\12@165329 by Walter Banks

flavicon
face
Automotive (including motorbikes) a bad environment electrically, physically
and environment.  A starting point might be to do everything that you have
ever learned about noise reduction.

Cranking currents can create current and voltage spikes. Voltage spikes
close to the battery voltage plus the inductive kick of the starter and current
spikes that can reach perhaps 100amps in a motor bike and 2-300 amps
in an automobile. The current spikes can introduce considerable current in
close completely separate circuits.

Ignition noise has lots of high frequency components.

I would make sure that everything on the odometer was bypassed and
probably would use a small cap across the reed switch to effectively
lower the signal impedance.

Shielding the PIC24 board will help quite a bit. The noise can be induced
on the circuit board. Metal box with good contact between parts and
solidly grounded on the bike.

Walter Banks
--
Byte Craft Limited
http://www.bytecraft.com





Electron wrote:

{Quote hidden}

>

2011\11\12@181105 by IVP

face picon face
> 3) bigger bypass? Ferrite beads? Would they help for the EMI? Sure
> filtering the power wouldn't help

Feed-through caps and chokes on power and signal lines are common
in car audio systems to filter out ignition noise. For your application it
would be a LPF or BPF based on the duration of the closure

Is it possible to add a low-Z driver down at the reed switch ? Like
some paralleled low-power CMOS gates ? That would also allow
you to extend the pulse (eg one-shot), which would help discriminate
between signal and noise

It can still be two-wire (or one if the frame is used as Vss) by super-
imposing the closure signal onto Vcc. Or smart switching between
the line as Vcc to the reed (held up with a reservoir cap) and a
conditioning circuit for it and then as signal back

Jo

2011\11\13@014700 by Richard Prosser

picon face
On 13 November 2011 12:10, IVP <spam_OUTjoecolquittTakeThisOuTspamclear.net.nz> wrote:
>> 3) bigger bypass? Ferrite beads? Would they help for the EMI? Sure
>> filtering the power wouldn't help
>
> Feed-through caps and chokes on power and signal lines are common
> in car audio systems to filter out ignition noise. For your application it
> would be a LPF or BPF based on the duration of the closure
>
> Is it possible to add a low-Z driver down at the reed switch ? Like
> some paralleled low-power CMOS gates ? That would also allow
> you to extend the pulse (eg one-shot), which would help discriminate
> between signal and noise
>
> It can still be two-wire (or one if the frame is used as Vss) by super-
> imposing the closure signal onto Vcc. Or smart switching between
> the line as Vcc to the reed (held up with a reservoir cap) and a
> conditioning circuit for it and then as signal back
>
> Joe
>

2011\11\13@052940 by Electron

flavicon
face
At 22.50 2011.11.12, you wrote:
>Automotive (including motorbikes) a bad environment electrically, physically
>and environment.  A starting point might be to do everything that you have
>ever learned about noise reduction.
>
>Cranking currents can create current and voltage spikes. Voltage spikes
>close to the battery voltage plus the inductive kick of the starter and current
>spikes that can reach perhaps 100amps in a motor bike and 2-300 amps
>in an automobile. The current spikes can introduce considerable current in
>close completely separate circuits.

By magnetic induction, right? Not electric and not electromagnetic.


>Ignition noise has lots of high frequency components.

And that (spark) generates electric induction if I get it right.


>I would make sure that everything on the odometer was bypassed and
>probably would use a small cap across the reed switch to effectively
>lower the signal impedance.

At high frequences. Yes, looks like it's necessary to say the least. Even the
original digital odometer may have one, in fact the "peak current of 400uA vs
average current of 9uA" I measured may well be due to a cap in parallel to the
reed input which gets charged by a high value pull-up resistor (math suggests
330kohm), the pulse closes the reed only for few degrees of wheel rotation,
so in the open state the capacitor is charged (albeit relatively slowly) by
the resistor, the input at the microcontroller raises (slowly, but as it's a
schmitt trigger this doesn't cause problems) and the capacitor opposes a low
impedance to eventual high frequency transients. When the reed closes, the
capacitor discharge (with relatively high current) and the digital pin goes
low very quickly.


>Shielding the PIC24 board will help quite a bit. The noise can be induced
>on the circuit board. Metal box with good contact between parts and
>solidly grounded on the bike.

Just one ground wire to the circuit, right? And then inside the circuit box,
every board connected to this entry point (ground) in a star fashion, i.e.
each board (it's a multi PCB system) will have its own separate ground wire
that goes toward this unique ground entry point in the box, from which only
one wire connects to the motorbike ground.

Also, I will strongly bypass power inputs (as I'm gonna take power from the
bike's battery then) and use caps on every other input (push-buttons, etc..)
of course the caps at the circuit side, not at the console-button side. Caps
as big as my circuit will tolerate.

Greets,
Mario


{Quote hidden}

>> -

2011\11\13@052941 by Electron

flavicon
face
At 00.10 2011.11.13, you wrote:
>> 3) bigger bypass? Ferrite beads? Would they help for the EMI? Sure
>> filtering the power wouldn't help
>
>Feed-through caps and chokes on power and signal lines are common
>in car audio systems to filter out ignition noise. For your application it
>would be a LPF or BPF based on the duration of the closure
>
>Is it possible to add a low-Z driver down at the reed switch ? Like
>some paralleled low-power CMOS gates ? That would also allow
>you to extend the pulse (eg one-shot), which would help discriminate
>between signal and noise
>
>It can still be two-wire (or one if the frame is used as Vss) by super-
>imposing the closure signal onto Vcc. Or smart switching between
>the line as Vcc to the reed (held up with a reservoir cap) and a
>conditioning circuit for it and then as signal back
>
>Joe

No modifications are possible on the bike.. but I'll certainly bypass
and use ferrite beads both on power and inputs. I think that may be
sufficient to eliminate all malfunction as it's a digital circuit after
all, if it was an analog hifi amp then "the more the better", but in my
case "when it's enough, you're done". Hopefully. :P

Cheers,
Mario

2011\11\13@053631 by Electron

flavicon
face
At 07.46 2011.11.13, you wrote:
>On 13 November 2011 12:10, IVP <.....joecolquittKILLspamspam@spam@clear.net.nz> wrote:
>>> 3) bigger bypass? Ferrite beads? Would they help for the EMI? Sure
>>> filtering the power wouldn't help
>>
>> Feed-through caps and chokes on power and signal lines are common
>> in car audio systems to filter out ignition noise. For your application it
>> would be a LPF or BPF based on the duration of the closure
>>
>> Is it possible to add a low-Z driver down at the reed switch ? Like
>> some paralleled low-power CMOS gates ? That would also allow
>> you to extend the pulse (eg one-shot), which would help discriminate
>> between signal and noise
>>
>> It can still be two-wire (or one if the frame is used as Vss) by super-
>> imposing the closure signal onto Vcc. Or smart switching between
>> the line as Vcc to the reed (held up with a reservoir cap) and a
>> conditioning circuit for it and then as signal back
>>
>> Joe
>> -

2011\11\13@081939 by Walter Banks

flavicon
face


Electron wrote:

> Just one ground wire to the circuit, right? And then inside the circuit box,
> every board connected to this entry point (ground) in a star fashion, i.e..
> each board (it's a multi PCB system) will have its own separate ground wire
> that goes toward this unique ground entry point in the box, from which only
> one wire connects to the motorbike ground.

For multi board systems use cables between boards. You have a bad
physical environment with lots of vibration and wide temperature range.
A bad or loose connection between boards is just as bad as a induced
electrical signals. Vibration peaks of 50g is in the right ballpark.



w..

2011\11\13@101852 by Geo

picon face
Electron wrote:

> Even the
> original digital odometer may have one, in fact the "peak current of 400uA vs
> average current of 9uA" I measured may well be due to a cap in parallel to the
> reed input which gets charged by a high value pull-up resistor (math suggests
> 330kohm), the pulse closes the reed only for few degrees of wheel rotation,
> so in the open state the capacitor is charged (albeit relatively slowly) by
> the resistor, the input at the microcontroller raises (slowly, but as it's a
> schmitt trigger this doesn't cause problems) and the capacitor opposes a low
> impedance to eventual high frequency transients. When the reed closes, the
> capacitor discharge (with relatively high current) and the digital pin goes
> low very quickly.

I suggest being careful with the discharge current. I have replaced 100s of reed relays which have been cold welded in the closed position by a small excess current flow (they could be cleared by vibration). I think you need to work out the maximum frequency of the reed opening and closing (i.e. using max speed and wheel diameter) then choose a capacitor with an additional resistor in series with the reed to limit the current flow on closure. This resistor will also form a low-pass filter in conjunction with the capacitor which should help with your noise problem.

George Smith

2011\11\13@111145 by Dave

picon face
Definitely.  Even a 0.1uf will weld the contacts or wear them out prematurely.
Geo <buggiesmithspamKILLspamgmail.com> wrote:

{Quote hidden}

>

2011\11\13@120924 by Electron

flavicon
face
At 16.18 2011.11.13, you wrote:
{Quote hidden}

I would like to simulate it, but after 3+ hours (really!) I still can't get a
working voltage/current controlled switch, or a relay, to work with LT Spice. :-(

The symbols are there, but it just doesn't work. I watched and re-watched the
video many times, but I couldn't manage to get it to work.

The model should be this:
..model MyRelay SW(Ron=1 Roff=1G Vt=3.0 Vh=.4)
I get the symbol, but I can't make the model work (the best I reached was the
error message Can't find definition of model "NC_01".

I then gave up and decided to simulate the reed using a MOSFET.. but it doesn't
look like the real thing. :(

2011\11\13@121446 by Sean Breheny

face picon face
The cap doesn't have to go directly across the relay contacts - you
could still have a pull-up to Vdd and then at the node where you would
normally attach the PIC input pin, instead put a single pole RC LPF
between the pullup+switch node and the PIC pin. This way, the reed
relay never sees a high current pulse but you still slow down the edge
as far as the PIC sees it so that the PIC will not respond to
microsecond pulses but will respond to millisecond pulses (like the
relay closure).

Sean


On Sun, Nov 13, 2011 at 11:11 AM, Dave <.....microbrixKILLspamspam.....gmail.com> wrote:
{Quote hidden}

>>

2011\11\13@125908 by Electron

flavicon
face
>At 16.18 2011.11.13, you wrote:
>>Electron wrote:
>I would like to simulate it, but after 3+ hours (really!) I still can't get a
>working voltage/current controlled switch, or a relay, to work with LT
>Spice. :-(
>
>The symbols are there, but it just doesn't work. I watched and re-watched the
>video many times, but I couldn't manage to get it to work.
>
>The model should be this:
>.model MyRelay SW(Ron=1 Roff=1G Vt=3.0 Vh=.4)
>
>I get the symbol, but I can't make the model work (the best I reached was the
>error message Can't find definition of model "NC_01".
>
>I then gave up and decided to simulate the reed using a MOSFET.. but it doesn't
>look like the real thing. :(

OK, at the fifth hour I managed to make it work. I had to use the sw symbol,
not the relay one. :/

Now it's the turn of subcircuits. :P


At 18.14 2011.11.13, you wrote:
{Quote hidden}

OK, logical, pullup to reed, resistor to PIC which has the cap in parallel to
its input. Reed never stressed, cap near PIC input pin.. that shall work best.

Cheers,
MarI/O

More... (looser matching)
- Last day of these posts
- In 2011 , 2012 only
- Today
- New search...