Need help for PIC16C745


Results 1 to 17 of 17

Threaded View

  1. #2
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default

    Hi christina86,
    Certainly I am not the one to ask about assembly language. That said, it looks to me like your sub routines get locked into a loop and never finish their execution.
    example<p>
    ON
    btfsc PORTB,1 ; Has S2 been press? (Normally high,goes low when pressed.)
    goto ON ; No, <font color=red> goto ON and repeats forever</font color>
    movlw b'00000001' ; move it from register 1 to w.
    movwf PORTB ; move it to PORTB to light up the LED<p>
    I think if you wish to recheck the first line you should use whatever assembly equiv. of a for next loop.
    JS
    Last edited by Archangel; - 12th September 2007 at 07:14.
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts