Electronic Projects, forums and more.

Go Back   Electronic Circuits Projects Diagrams Free > Electronics Categories > Micro Controllers


Micro Controllers Discuss all aspects of micro controllers - building them, coding them, etc. All controllers are welcome - PIC, BASIC, Z8 Encore!, etc.

Reply
 
Tools
Old 11th May 2004, 05:58 PM   #1
Default PIC programming question

Hi all, I'm glad to join this forum and hope to get/give some usefull information here!

I have a question about a program, I've wrote for the PIC 16f84
I wantet some leds, connected to all the port B I/O ports to flash from both ends, to the middle and back again. I tried to solve it like this:

Start movlw b'10000001'
movwf PORTB
call DELAY
movlw b'01000010'
movwf PORTB
call DELAY
movlw b'00100100'
movwf PORTB
call DELAY
movlw b'00011000'
movwf PORTB
call DELAY
movlw b'00100100'
movwf PORTB
call DELAY
movlw b'01000010'
movwf PORTB
call DELAY
movlw b'10000001'
movwf PORTB
call DELAY
goto Start

But when I plug the PIC in the circuit, it only does

movlw b'10000001'
movwf PORTB
call DELAY
movlw b'01000010'
movwf PORTB
call DELAY
movlw b'00100100'

and then it starts over! What could the reason for this be?

Thanks for answering, all answers will be appreciated
Deni is offline  
Old 11th May 2004, 06:03 PM   #2
Default

Don't double post...

Like i said in the other post, disable the watchdog...
Exo is offline  
Reply

Tags
pic, programming, question

Thread Tools
Display Modes




All times are GMT. The time now is 10:43 PM.


Electronic Circuits  |  Learning Electronics
eXTReMe Tracker