Hello forum
My setup:
I am using a 16f877a with 11.0592MHz crytal and MPLAB IDE ver 8.92
Programmer is PICkit3.
Configuration :
HS OSC , WDT-disabled , PWRT-disabled, BOR-disabled,RB3-dig i/o,&MCLR pulled up to VCC=5v
All memory protections are off
I am driving 8 nos of 7 segment displays and 4 keys as input (all keys individual and not in a 2x2 matrix)
I am using a couple of unsigned long variables and no re-entrants in ISR's.
I also have an LED toggling in a one second TMR0 interrupt to show that the MCU is alive.
I am trying to display an 8-digit BCD number on the display on few key-presses.
Simulation works fine in proteus.
Display shows 0 0 0 0 0 0 0 0 - on reset
Press SET key
Display shows S E t
Press ENTER key
Display shows 1 2 3 4 5 6 7 8 (converted from decimal 12345678 or 0xBC614E)
On actual hardware
Display shows 0 0 0 0 0 0 0 0 - on reset
Press SET key
Display shows S E t
Press ENTER key
Display turns blank
MCU freezes
One second tick LED stops ticking.
I thought that this might be related to stack overflow , but I don't have re-entrant levels in ISR as I mentioned earlier.
I am now unable to understand this phenomenon, so requesting some learned members help on this one.
Thanks in advance
My setup:
I am using a 16f877a with 11.0592MHz crytal and MPLAB IDE ver 8.92
Programmer is PICkit3.
Configuration :
HS OSC , WDT-disabled , PWRT-disabled, BOR-disabled,RB3-dig i/o,&MCLR pulled up to VCC=5v
All memory protections are off
I am driving 8 nos of 7 segment displays and 4 keys as input (all keys individual and not in a 2x2 matrix)
I am using a couple of unsigned long variables and no re-entrants in ISR's.
I also have an LED toggling in a one second TMR0 interrupt to show that the MCU is alive.
I am trying to display an 8-digit BCD number on the display on few key-presses.
Simulation works fine in proteus.
Display shows 0 0 0 0 0 0 0 0 - on reset
Press SET key
Display shows S E t
Press ENTER key
Display shows 1 2 3 4 5 6 7 8 (converted from decimal 12345678 or 0xBC614E)
On actual hardware
Display shows 0 0 0 0 0 0 0 0 - on reset
Press SET key
Display shows S E t
Press ENTER key
Display turns blank
MCU freezes
One second tick LED stops ticking.
I thought that this might be related to stack overflow , but I don't have re-entrant levels in ISR as I mentioned earlier.
I am now unable to understand this phenomenon, so requesting some learned members help on this one.
Thanks in advance