Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

[Moved]Proteus 8.1 Simulator: LED NOT FLASHING

Status
Not open for further replies.

thandana

Junior Member level 1
Joined
Nov 27, 2014
Messages
19
Helped
0
Reputation
0
Reaction score
0
Trophy points
1
Activity points
367
Hi,

I have a simple circuit that i created on the proteus8.1 simulator and have written code to flash LED connected to the PIC16F84A device.

When i simulate, the LED is NOT flashing and NO ERRORS on the simulator. Please assist

Code:
void main() {
TRISB=0b11111101;
while (1)
{
PORTB.f1=1;
delay_ms(500);
PORTB.f1=0;
delay_ms(500);
}
}
 

Attachments

  • LED.pdf
    249.8 KB · Views: 122

What is ".f1" ?

Try replacing it with just the number 1, "PORTB.1" and see what happens.

In a real program you would also configure the clock source and other registers, I'm not sure if MikroC and Proteus respect that though.

Brian.
 

At the schematic attached, there is nothing connected to the Oscillator pins.
According to datasheet, there is no internal oscillator available for this uC in particular.
 

    V

    Points: 2
    Helpful Answer Positive Rating
Hi,

This can be closed now. I connected the oscillator and applied 5V and now works OK. Thanks for the help.
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top