Shop OBEX P1 Docs P2 Docs Learn Events
test — Parallax Forums

test

br0eselbr0esel Posts: 1
edited 2014-01-01 04:19 in General Discussion
{Object_Title_and_Purpose}

CON
        _clkmode = xtal1 + pll16x                                               'Standard clock mode * crystal frequency = 80 MHz
        _xinfreq = 5_000_000
VAR
  long  symbol
   
PUB public_method_name
  dira[16] := 1
  cognew(@entry,0)
  cognew(blink,0)
  repeat
    waitcnt(cnt + 20_000_000)
    !outa[16]  
PUB blink
  dira[18] := 1
  repeat
    waitcnt(cnt + 20_000_000)
    !outa[18]     
DAT
              org
entry                   mov     r0,#1
                        shl     r0,#17
                        mov     dira,r0
loop                    xor     outa,r0
                        mov     r1,cnt
                        add     r1,wait
                        waitcnt r1,#0
                        jmp     #loop                    
                        

r0      long  1
r1      long  1
wait    long  20_000_000
        
jkljkljkljkltesttesttest
Sign In or Register to comment.