Main Page | Report this Page
 
   
Science Forum Index  »  Electronics - Design Forum  »  Problem with PIC & LCD display
Page 1 of 2    Goto page 1, 2  Next
Author Message
Steve H
Posted: Thu May 01, 2008 11:51 am
Guest
I'm having a problem with a fairly simple project incorporating a
16F877A PIC and a 4x20 alphanumeric display module. The circuit
interfaces with other logic ICs, though these can be removed from the
circuit to isolate the problem.

The circuit is fed, under test conditions, from a linear 12v power
supply. The 5v regulator on the circuit board is decoupled using 100nf
ceramic capacitors. There is similar decoupling on the PIC itself, and
at other places e.g. decoupling the 5v supply on the connector to the
LCD display. I have also fitted a 100uH coil in the supply to the 5v
regulator to reduce any effects from spurious noise on the supply line.

The problem I'm having difficulty solving is that the display will
intermittently go blank. It will go blank, seemingly when the display is
written to by the PIC, either (a) due to a spike/noise on the mains
supply (this can be intermittently reproduced by repeatedly turning on
and off a piece of mains powered equipment on the same circuit), or (b)
when the 0v rail (not even necessarily close to the LCD display) is
touched by for example a multimeter probe. This is the most consistent
way of producing the fault. The multimeter can be turned off and the
other probe not connected to anything for this to happen. The PIC
doesn't appear to be affected by any of this as it can be shown to still
be operating as expected.

I've experienced similar issues before in my limited experience of
building small projects with PICs. I had issues with a 16F84A resetting
itself when the 0v rail close to the IC was touched with a screwdriver.

Can anybody suggest what vital consideration for circuit design I'm
missing. I'm at a bit of a loss as to what I'm doing wrong.

Thanks.

--
Steve H
Guest
Posted: Thu May 01, 2008 11:51 am
On May 1, 5:51�pm, Steve H <ste...@spho.demon.co.uk> wrote:
Quote:
I'm having a problem with a fairly simple project incorporating a
16F877A PIC and a 4x20 alphanumeric display module. The circuit
interfaces with other logic ICs, though these can be removed from the
circuit to isolate the problem.

The circuit is fed, under test conditions, from a linear 12v power
supply. The 5v regulator on the circuit board is decoupled using 100nf
ceramic capacitors. There is similar decoupling on the PIC itself, and
at other places e.g. decoupling the 5v supply on the connector to the
LCD display. I have also fitted a 100uH coil in the supply to the 5v
regulator to reduce any effects from spurious noise on the supply line.

The problem I'm having difficulty solving is that the display will
intermittently go blank. It will go blank, seemingly when the display is
written to by the PIC, either (a) due to a spike/noise on the mains
supply (this can be intermittently reproduced by repeatedly turning on
and off a piece of mains powered equipment on the same circuit), or (b)
when the 0v rail (not even necessarily close to the LCD display) is
touched by for example a multimeter probe. This is the most consistent
way of producing the fault. The multimeter can be turned off and the
other probe not connected to anything for this to happen. The PIC
doesn't appear to be affected by any of this as it can be shown to still
be operating as expected.

I've experienced similar issues before in my limited experience of
building small projects with PICs. I had issues with a 16F84A resetting
itself when the 0v rail close to the IC was touched with a screwdriver.

Can anybody suggest what vital consideration for circuit design I'm
missing. I'm at a bit of a loss as to what I'm doing wrong.

Thanks.

--
Steve H

Put a line filter on the mains input.
Guest
Posted: Thu May 01, 2008 11:51 am
On May 1, 7:31�pm, Steve H <ste...@spho.demon.co.uk> wrote:
Quote:
In message
23e39c45-4c29-40a4-bc96-a12ad5224...@34g2000hsh.googlegroups.com>,
cbarn24...@aol.com writes





On May 1, 5:510 >> I'm having a problem with a fairly simple project incorporating a
16F877A PIC and a 4x20 alphanumeric display module. The circuit
interfaces with other logic ICs, though these can be removed from the
circuit to isolate the problem.

The circuit is fed, under test conditions, from a linear 12v power
supply. The 5v regulator on the circuit board is decoupled using 100nf
ceramic capacitors. There is similar decoupling on the PIC itself, and
at other places e.g. decoupling the 5v supply on the connector to the
LCD display. I have also fitted a 100uH coil in the supply to the 5v
regulator to reduce any effects from spurious noise on the supply line.

The problem I'm having difficulty solving is that the display will
intermittently go blank. It will go blank, seemingly when the display is
written to by the PIC, either (a) due to a spike/noise on the mains
supply (this can be intermittently reproduced by repeatedly turning on
and off a piece of mains powered equipment on the same circuit), or (b)
when the 0v rail (not even necessarily close to the LCD display) is
touched by for example a multimeter probe. This is the most consistent
way of producing the fault. The multimeter can be turned off and the
other probe not connected to anything for this to happen. The PIC
doesn't appear to be affected by any of this as it can be shown to still
be operating as expected.

I've experienced similar issues before in my limited experience of
building small projects with PICs. I had issues with a 16F84A resetting
itself when the 0v rail close to the IC was touched with a screwdriver.

Can anybody suggest what vital consideration for circuit design I'm
missing. I'm at a bit of a loss as to what I'm doing wrong.

Thanks.

--
Steve H

Put a line filter on the mains input.

The commercial linear PSU, I'm guessing, would have a filtered input.
Certainly, I've had these sort of problems with a filtered power supply
being used. That may reduce problems due to noise on the mains, but I'm
not sure about the other effects I'm seeing.

Thanks.
--
Steve H- Hide quoted text -

- Show quoted text -

Alot of linears dont, try a different supply or even a battery.
Jan Panteltje
Posted: Thu May 01, 2008 12:02 pm
Guest
On a sunny day (Thu, 1 May 2008 17:51:39 +0100) it happened Steve H
<steveu@spho.demon.co.uk> wrote in <LJogw4BbUfGIFwa0@spho.demon.co.uk>:

Quote:

I'm having a problem with a fairly simple project incorporating a
16F877A PIC and a 4x20 alphanumeric display module. The circuit
interfaces with other logic ICs, though these can be removed from the
circuit to isolate the problem.

The circuit is fed, under test conditions, from a linear 12v power
supply. The 5v regulator on the circuit board is decoupled using 100nf
ceramic capacitors.

I usually use 10uF tantalum


Quote:
There is similar decoupling on the PIC itself, and
at other places e.g. decoupling the 5v supply on the connector to the
LCD display.

Same 10uF.
How long is the cable to the LCD?


Quote:
I have also fitted a 100uH coil in the supply to the 5v
regulator to reduce any effects from spurious noise on the supply line.

Maybe it tunes with the 100nF Wink
Do you have a scope?
Is the 7805 or whatever oscillating?


Quote:
The problem I'm having difficulty solving is that the display will
intermittently go blank. It will go blank, seemingly when the display is
written to by the PIC, either (a) due to a spike/noise on the mains
supply (this can be intermittently reproduced by repeatedly turning on
and off a piece of mains powered equipment on the same circuit), or (b)
when the 0v rail (not even necessarily close to the LCD display) is
touched by for example a multimeter probe. This is the most consistent
way of producing the fault. The multimeter can be turned off and the
other probe not connected to anything for this to happen. The PIC
doesn't appear to be affected by any of this as it can be shown to still
be operating as expected.

I've experienced similar issues before in my limited experience of
building small projects with PICs. I had issues with a 16F84A resetting
itself when the 0v rail close to the IC was touched with a screwdriver.

Never had any problems like that, neither with F84 or other PICS.
Is your system grounded?
I mean is the top of you workbench live or something?
Steve H
Posted: Thu May 01, 2008 12:24 pm
Guest
In message <fvct37$51r$1@aioe.org>, Jan Panteltje
<PNaonStpealmtje@yahoo.com> writes
Quote:
On a sunny day (Thu, 1 May 2008 17:51:39 +0100) it happened Steve H
steveu@spho.demon.co.uk> wrote in <LJogw4BbUfGIFwa0@spho.demon.co.uk>:


I'm having a problem with a fairly simple project incorporating a
16F877A PIC and a 4x20 alphanumeric display module. The circuit
interfaces with other logic ICs, though these can be removed from the
circuit to isolate the problem.

The circuit is fed, under test conditions, from a linear 12v power
supply. The 5v regulator on the circuit board is decoupled using 100nf
ceramic capacitors.

I usually use 10uF tantalum

There is a 47uf electrolytic on the input and output of the 5v reg. I
can try a tant to see if there's any change.
Quote:


There is similar decoupling on the PIC itself, and
at other places e.g. decoupling the 5v supply on the connector to the
LCD display.

Same 10uF.
How long is the cable to the LCD?

Around 30cm. I'm using equipment wire, I think 16/0.2 (don't have the
project to hand right now). I've added decoupling on the 5v connection
on the module as well.
Quote:


I have also fitted a 100uH coil in the supply to the 5v
regulator to reduce any effects from spurious noise on the supply line.

Maybe it tunes with the 100nF Wink
Do you have a scope?
Is the 7805 or whatever oscillating?



There's certainly something odd happening... I fitted the coil only
after the problems occurred in a seemingly futile attempt to solve it.
The 5v line is indeed very stable, having scoped it.


Quote:
The problem I'm having difficulty solving is that the display will
intermittently go blank. It will go blank, seemingly when the display is
written to by the PIC, either (a) due to a spike/noise on the mains
supply (this can be intermittently reproduced by repeatedly turning on
and off a piece of mains powered equipment on the same circuit), or (b)
when the 0v rail (not even necessarily close to the LCD display) is
touched by for example a multimeter probe. This is the most consistent
way of producing the fault. The multimeter can be turned off and the
other probe not connected to anything for this to happen. The PIC
doesn't appear to be affected by any of this as it can be shown to still
be operating as expected.

I've experienced similar issues before in my limited experience of
building small projects with PICs. I had issues with a 16F84A resetting
itself when the 0v rail close to the IC was touched with a screwdriver.

Never had any problems like that, neither with F84 or other PICS.
Is your system grounded?
I mean is the top of you workbench live or something?

I've run the thing with the 0v connected to earth with no change to the
symptoms. In use, it will run off a 12v supply, isolated from a direct
earth connection.

I've had similar problems in various places around the same area, e.g.
on a bench with an anti-static mat (the circuit insulated directly from
it) as well as other locations in the same room.

--
Steve H
Jan Panteltje
Posted: Thu May 01, 2008 12:53 pm
Guest
On a sunny day (Thu, 1 May 2008 18:24:16 +0100) it happened Steve H
<steveu@spho.demon.co.uk> wrote in <I5egcpDAzfGIFw4c@spho.demon.co.uk>:

Quote:
I usually use 10uF tantalum

There is a 47uf electrolytic on the input and output of the 5v reg. I
can try a tant to see if there's any change.

OK.

Quote:
How long is the cable to the LCD?

Around 30cm. I'm using equipment wire, I think 16/0.2 (don't have the
project to hand right now). I've added decoupling on the 5v connection
on the module as well.


I have something here with about 30cm flat cable, works great...

One more thing, is any PIC input floating, any LCD input floating?
I mean for example PIC reset, and are you using 4 bit to the LCD?


Quote:
I mean is the top of you workbench live or something?

I've run the thing with the 0v connected to earth with no change to the
symptoms. In use, it will run off a 12v supply, isolated from a direct
earth connection.

I've had similar problems in various places around the same area, e.g.
on a bench with an anti-static mat (the circuit insulated directly from
it) as well as other locations in the same room.

I would like to know if the PIC actually resets, or there is just some
LCD signal that gets messed up, did you test that?
Steve H
Posted: Thu May 01, 2008 1:28 pm
Guest
In message <fvd02t$ipq$1@aioe.org>, Jan Panteltje
<PNaonStpealmtje@yahoo.com> writes
Quote:
On a sunny day (Thu, 1 May 2008 18:24:16 +0100) it happened Steve H
steveu@spho.demon.co.uk> wrote in <I5egcpDAzfGIFw4c@spho.demon.co.uk>:

I usually use 10uF tantalum

There is a 47uf electrolytic on the input and output of the 5v reg. I
can try a tant to see if there's any change.

OK.

How long is the cable to the LCD?

Around 30cm. I'm using equipment wire, I think 16/0.2 (don't have the
project to hand right now). I've added decoupling on the 5v connection
on the module as well.


I have something here with about 30cm flat cable, works great...

One more thing, is any PIC input floating, any LCD input floating?
I mean for example PIC reset, and are you using 4 bit to the LCD?

There are no floating inputs to the PIC. The few unused pins are
configured as outputs. The reset pin is connected to 5v via a 100 ohm
resistor.

The LCD is used in 4-wire mode with the unused data lines floating.
Perhaps I should tie them to 0v? I guessed they'd be OK left alone as
it's a bidirectional data bus, but maybe I shouldn't let them float.

Quote:


I mean is the top of you workbench live or something?

I've run the thing with the 0v connected to earth with no change to the
symptoms. In use, it will run off a 12v supply, isolated from a direct
earth connection.

I've had similar problems in various places around the same area, e.g.
on a bench with an anti-static mat (the circuit insulated directly from
it) as well as other locations in the same room.

I would like to know if the PIC actually resets, or there is just some
LCD signal that gets messed up, did you test that?

I'm probably confusing the issue by introducing a second (but perhaps
related in terms of the cause) project I've experienced problems with.

Regarding the current issue with the 16F877A driving the LCD, I'm
certain the PIC does not reset. I can say this because of a function in
code that lights the backlight for a period of time when a button (there
are 4 button inputs pulled up via 4k7 resistors) is pressed. This
function continues to work in a way that indicates the PIC in this
instance has not reset but has continued to run correctly independently
of the LCD blanking out.

A different project I was working on a while ago showed an effect where
if I touched a small screwdriver on a track carrying the 0v rail close
to the PIC, the PIC reset itself. There may have been a reason for this
e.g. I was using a 47k pull-up for the reset at the time - I later
learned was bad practice at the very least. I mentioned this previous
project because in terms of the cause (simply touching 0v) an unwanted
effect occurred. So far as the current LCD project is concerned, I think
I've learned from some mistakes in the past, but still can't get it to
function reliably.


Thanks for your input so far.

--
Steve H
Steve H
Posted: Thu May 01, 2008 1:31 pm
Guest
In message
<23e39c45-4c29-40a4-bc96-a12ad52246cb@34g2000hsh.googlegroups.com>,
cbarn24050@aol.com writes
Quote:
On May 1, 5:510 >> I'm having a problem with a fairly simple project incorporating a
16F877A PIC and a 4x20 alphanumeric display module. The circuit
interfaces with other logic ICs, though these can be removed from the
circuit to isolate the problem.

The circuit is fed, under test conditions, from a linear 12v power
supply. The 5v regulator on the circuit board is decoupled using 100nf
ceramic capacitors. There is similar decoupling on the PIC itself, and
at other places e.g. decoupling the 5v supply on the connector to the
LCD display. I have also fitted a 100uH coil in the supply to the 5v
regulator to reduce any effects from spurious noise on the supply line.

The problem I'm having difficulty solving is that the display will
intermittently go blank. It will go blank, seemingly when the display is
written to by the PIC, either (a) due to a spike/noise on the mains
supply (this can be intermittently reproduced by repeatedly turning on
and off a piece of mains powered equipment on the same circuit), or (b)
when the 0v rail (not even necessarily close to the LCD display) is
touched by for example a multimeter probe. This is the most consistent
way of producing the fault. The multimeter can be turned off and the
other probe not connected to anything for this to happen. The PIC
doesn't appear to be affected by any of this as it can be shown to still
be operating as expected.

I've experienced similar issues before in my limited experience of
building small projects with PICs. I had issues with a 16F84A resetting
itself when the 0v rail close to the IC was touched with a screwdriver.

Can anybody suggest what vital consideration for circuit design I'm
missing. I'm at a bit of a loss as to what I'm doing wrong.

Thanks.

--
Steve H

Put a line filter on the mains input.

The commercial linear PSU, I'm guessing, would have a filtered input.
Certainly, I've had these sort of problems with a filtered power supply
being used. That may reduce problems due to noise on the mains, but I'm
not sure about the other effects I'm seeing.

Thanks.
--
Steve H
Jan Panteltje
Posted: Thu May 01, 2008 1:51 pm
Guest
On a sunny day (Thu, 1 May 2008 19:28:43 +0100) it happened Steve H
<steveu@spho.demon.co.uk> wrote in <634M$QFbvgGIFwP2@spho.demon.co.uk>:

Quote:
The LCD is used in 4-wire mode with the unused data lines floating.
Perhaps I should tie them to 0v?

No. LCD datasheet says leave not connected.


Quote:
I'm probably confusing the issue by introducing a second (but perhaps
related in terms of the cause) project I've experienced problems with.

Regarding the current issue with the 16F877A driving the LCD, I'm
certain the PIC does not reset. I can say this because of a function in
code that lights the backlight for a period of time when a button (there
are 4 button inputs pulled up via 4k7 resistors) is pressed. This
function continues to work in a way that indicates the PIC in this
instance has not reset but has continued to run correctly independently
of the LCD blanking out.

A different project I was working on a while ago showed an effect where
if I touched a small screwdriver on a track carrying the 0v rail close
to the PIC, the PIC reset itself. There may have been a reason for this
e.g. I was using a 47k pull-up for the reset at the time - I later
learned was bad practice at the very least. I mentioned this previous
project because in terms of the cause (simply touching 0v) an unwanted
effect occurred. So far as the current LCD project is concerned, I think
I've learned from some mistakes in the past, but still can't get it to
function reliably.

The thing i have here, now with 4 line LCD too,
http://panteltje.com/panteltje/pic/swr_pic/index.html
has none of those problems.
In fact it runs even OK out of the box in a very strong RF field (27 MHz).
I am personally not using the reset input, but using it for I/O, anyways
that was not your problem.
Is the LCD contrast (pin 3 IIRC) connected?
Very long time agao I had a situation where if I walked with my new shoes on the carpet
it would cause 1 inch sparks if I touched any metal, it would reset an IBM PC:-)
Static charges?
Spehro Pefhany
Posted: Thu May 01, 2008 2:36 pm
Guest
On Thu, 1 May 2008 17:51:39 +0100, Steve H <steveu@spho.demon.co.uk>
wrote:

Quote:

I'm having a problem with a fairly simple project incorporating a
16F877A PIC and a 4x20 alphanumeric display module. The circuit
interfaces with other logic ICs, though these can be removed from the
circuit to isolate the problem.

The circuit is fed, under test conditions, from a linear 12v power
supply. The 5v regulator on the circuit board is decoupled using 100nf
ceramic capacitors. There is similar decoupling on the PIC itself, and
at other places e.g. decoupling the 5v supply on the connector to the
LCD display. I have also fitted a 100uH coil in the supply to the 5v
regulator to reduce any effects from spurious noise on the supply line.

The problem I'm having difficulty solving is that the display will
intermittently go blank. It will go blank, seemingly when the display is
written to by the PIC, either (a) due to a spike/noise on the mains
supply (this can be intermittently reproduced by repeatedly turning on
and off a piece of mains powered equipment on the same circuit), or (b)
when the 0v rail (not even necessarily close to the LCD display) is
touched by for example a multimeter probe. This is the most consistent
way of producing the fault. The multimeter can be turned off and the
other probe not connected to anything for this to happen. The PIC
doesn't appear to be affected by any of this as it can be shown to still
be operating as expected.

Are you sure it's not resetting?

Quote:
I've experienced similar issues before in my limited experience of
building small projects with PICs. I had issues with a 16F84A resetting
itself when the 0v rail close to the IC was touched with a screwdriver.

Can anybody suggest what vital consideration for circuit design I'm
missing. I'm at a bit of a loss as to what I'm doing wrong.

Thanks.

What else EXACTLY is this PIC circuit connected to (off board in
particular)? How long is the cable to the LCD display? What kind of
equipment is this? Can you link to a photo? Is it a proper PCB or a
plugboard?
Best regards,
Spehro Pefhany
--
"it's the network..." "The Journey is the reward"
speff@interlog.com Info for manufacturers: http://www.trexon.com
Embedded software/hardware/analog Info for designers: http://www.speff.com
Steve H
Posted: Thu May 01, 2008 2:37 pm
Guest
In message <fvd3gj$398$1@aioe.org>, Jan Panteltje
<PNaonStpealmtje@yahoo.com> writes
Quote:
On a sunny day (Thu, 1 May 2008 19:28:43 +0100) it happened Steve H
steveu@spho.demon.co.uk> wrote in <634M$QFbvgGIFwP2@spho.demon.co.uk>:

The LCD is used in 4-wire mode with the unused data lines floating.
Perhaps I should tie them to 0v?

No. LCD datasheet says leave not connected.


I'm probably confusing the issue by introducing a second (but perhaps
related in terms of the cause) project I've experienced problems with.

Regarding the current issue with the 16F877A driving the LCD, I'm
certain the PIC does not reset. I can say this because of a function in
code that lights the backlight for a period of time when a button (there
are 4 button inputs pulled up via 4k7 resistors) is pressed. This
function continues to work in a way that indicates the PIC in this
instance has not reset but has continued to run correctly independently
of the LCD blanking out.

A different project I was working on a while ago showed an effect where
if I touched a small screwdriver on a track carrying the 0v rail close
to the PIC, the PIC reset itself. There may have been a reason for this
e.g. I was using a 47k pull-up for the reset at the time - I later
learned was bad practice at the very least. I mentioned this previous
project because in terms of the cause (simply touching 0v) an unwanted
effect occurred. So far as the current LCD project is concerned, I think
I've learned from some mistakes in the past, but still can't get it to
function reliably.

The thing i have here, now with 4 line LCD too,
http://panteltje.com/panteltje/pic/swr_pic/index.html
has none of those problems.
In fact it runs even OK out of the box in a very strong RF field (27 MHz).
I am personally not using the reset input, but using it for I/O, anyways
that was not your problem.
Is the LCD contrast (pin 3 IIRC) connected?
Very long time agao I had a situation where if I walked with my new
shoes on the carpet
it would cause 1 inch sparks if I touched any metal, it would reset an
IBM PC:-)
Static charges?

I used a 16x4 LCD with a 16F877A recently in another project and have

found it to be completely reliable. For some reason this one will not
work. I've got pin 3 connected to a small -ve potential via a pot and a
dc-dc converter used for a +/- 12v supply in another part of the
circuit. I intend to try an alternative 20x4 display to rule out the
possibility of it being over-sensitive to something.

I couldn't completely rule out static, though I'm fairly sure I'm well
discharged before touching anything connected with the circuit.

--
Steve H
RFI-EMI-GUY
Posted: Thu May 01, 2008 2:50 pm
Guest
Steve H wrote:
Quote:
I

A different project I was working on a while ago showed an effect where
if I touched a small screwdriver on a track carrying the 0v rail close
to the PIC, the PIC reset itself.


Thanks for your input so far.


If bringing a screwdriver close to the 0 V rail induced a reset, you
have an electrostatic discharge (ESD) problem on your bench. Which could
cause latent damage to the PIC, which may explain your lock up problems.

For example if you have a piece of carpet on your workbench (nice to
keep from scratching cabinets but bad for ESD) and you place a
screwdriver on the carpet, when you pick up the screwdriver you have a
very nicely charged high voltage capacitor with the plastic handle and
metal shaft.

I would work toward reducing your electrostatic problem on your bench
and the floor below it (Check out 3M's ESD products).

--
Joe Leikhim K4SAT
"The RFI-EMI-GUY"©

"Treason doth never prosper: what's the reason?
For if it prosper, none dare call it treason."

"Follow The Money" ;-P
RFI-EMI-GUY
Posted: Thu May 01, 2008 2:54 pm
Guest
Steve H wrote:

Quote:
I couldn't completely rule out static, though I'm fairly sure I'm well
discharged before touching anything connected with the circuit.


When I lived in Illinois, the humidity was so low that there was a
static charge everywhere I went, now in Florida with this terrible
humidity, it is not so much a concern. Still from your "screwdriver"
report, you have a problem.

--
Joe Leikhim K4SAT
"The RFI-EMI-GUY"©

"Treason doth never prosper: what's the reason?
For if it prosper, none dare call it treason."

"Follow The Money" ;-P
Steve H
Posted: Thu May 01, 2008 3:08 pm
Guest
In message <gp6k14lkhns618g04kgnh3gdiaiipgsn9p@4ax.com>, Spehro Pefhany
<speffSNIP@interlogDOTyou.knowwhat> writes
Quote:
On Thu, 1 May 2008 17:51:39 +0100, Steve H <steveu@spho.demon.co.uk
wrote:


I'm having a problem with a fairly simple project incorporating a
16F877A PIC and a 4x20 alphanumeric display module. The circuit
interfaces with other logic ICs, though these can be removed from the
circuit to isolate the problem.

The circuit is fed, under test conditions, from a linear 12v power
supply. The 5v regulator on the circuit board is decoupled using 100nf
ceramic capacitors. There is similar decoupling on the PIC itself, and
at other places e.g. decoupling the 5v supply on the connector to the
LCD display. I have also fitted a 100uH coil in the supply to the 5v
regulator to reduce any effects from spurious noise on the supply line.

The problem I'm having difficulty solving is that the display will
intermittently go blank. It will go blank, seemingly when the display is
written to by the PIC, either (a) due to a spike/noise on the mains
supply (this can be intermittently reproduced by repeatedly turning on
and off a piece of mains powered equipment on the same circuit), or (b)
when the 0v rail (not even necessarily close to the LCD display) is
touched by for example a multimeter probe. This is the most consistent
way of producing the fault. The multimeter can be turned off and the
other probe not connected to anything for this to happen. The PIC
doesn't appear to be affected by any of this as it can be shown to still
be operating as expected.

Are you sure it's not resetting?


I'm certain the PIC isn't resetting - the LCD module is going blank but
the PIC continues to function. It appears the intelligent LCD module
locks up/resets itself.

Quote:

I've experienced similar issues before in my limited experience of
building small projects with PICs. I had issues with a 16F84A resetting
itself when the 0v rail close to the IC was touched with a screwdriver.

Can anybody suggest what vital consideration for circuit design I'm
missing. I'm at a bit of a loss as to what I'm doing wrong.

Thanks.

What else EXACTLY is this PIC circuit connected to (off board in
particular)? How long is the cable to the LCD display? What kind of
equipment is this? Can you link to a photo? Is it a proper PCB or a
plugboard?

Have no photo to hand and the equipment isn't with me just now. Fully
assembled it comprises the PIC with LCD, 4 control buttons and several
logic inputs/outputs, four of which control 4 to 16-line latches that
switch solenoids via darlington drivers. The unit is part of a gas
sampling multiplexer system.

Currently, a lot of the circuitry is disconnected - there are 3
individual PCBs (etched boards). It's working in a bare-bones sort of
state at the moment, pretty much the PIC and display only

An earlier version of the device, identical but utilising in place of
the 16F877A/LCD a pair of 16F84As and driving a 2 x 7segment LED
display, has worked in the field flawlessly for 3 years.


Quote:
Best regards,
Spehro Pefhany

--
Steve H
David L. Jones
Posted: Thu May 01, 2008 3:14 pm
Guest
On May 2, 2:51 am, Steve H <ste...@spho.demon.co.uk> wrote:
Quote:
I'm having a problem with a fairly simple project incorporating a
16F877A PIC and a 4x20 alphanumeric display module. The circuit
interfaces with other logic ICs, though these can be removed from the
circuit to isolate the problem.

The circuit is fed, under test conditions, from a linear 12v power
supply. The 5v regulator on the circuit board is decoupled using 100nf
ceramic capacitors. There is similar decoupling on the PIC itself, and
at other places e.g. decoupling the 5v supply on the connector to the
LCD display. I have also fitted a 100uH coil in the supply to the 5v
regulator to reduce any effects from spurious noise on the supply line.

The problem I'm having difficulty solving is that the display will
intermittently go blank. It will go blank, seemingly when the display is
written to by the PIC, either (a) due to a spike/noise on the mains
supply (this can be intermittently reproduced by repeatedly turning on
and off a piece of mains powered equipment on the same circuit), or (b)
when the 0v rail (not even necessarily close to the LCD display) is
touched by for example a multimeter probe. This is the most consistent
way of producing the fault. The multimeter can be turned off and the
other probe not connected to anything for this to happen. The PIC
doesn't appear to be affected by any of this as it can be shown to still
be operating as expected.

I've experienced similar issues before in my limited experience of
building small projects with PICs. I had issues with a 16F84A resetting
itself when the 0v rail close to the IC was touched with a screwdriver.

Can anybody suggest what vital consideration for circuit design I'm
missing. I'm at a bit of a loss as to what I'm doing wrong.

Thanks.

--
Steve H

Can you post a photo of your board and setup? That often helps.
Do you have an oscilloscope?

Dave.
 
Page 1 of 2    Goto page 1, 2  Next   All times are GMT - 5 Hours
The time now is Tue Oct 14, 2008 10:26 am