Shop OBEX P1 Docs P2 Docs Learn Events
problem with program — Parallax Forums

problem with program

PrincPrinc Posts: 12
edited 2013-12-12 11:54 in Propeller 1
Hi,
i made a program but it did´t work so i tried to cut it as mutch as possible to see what actually working
Now i have got just this size of program and i don´t get it when the program starts there are no signal on pins 0-7 (i checked it with osciloskope)
but leds 18 and 19 lights and i don´t know why

thanks for help

CON
_clkmode = xtal1 + pll16x
_xinfreq = 5_000_000


PUB Toggle

cognew(@blikej,0)
repeat


DAT
org 0
blikej

mov dira,pin
mov Time, cnt
add Time, delay
loop xor outa,piny
waitcnt Time,delay
jmp #loop


Time res 1
delay long 80_000
pin long 00_0000_0000_0000_0000_0000_1111_1111

Comments

  • msrobotsmsrobots Posts: 3,709
    edited 2013-12-12 11:45
    Try to put Times res 1 on the end of the file

    all res have to be after declared longs.

    EDIT - what is piny?

    Enjoy!

    Mike
  • MagIO2MagIO2 Posts: 2,243
    edited 2013-12-12 11:45
    Are you sure that your eyes are good enough to see the LEDs blink at a rate of 500Hz? I doubt that very much! ;o)
  • PrincPrinc Posts: 12
    edited 2013-12-12 11:52
    i copied it wrong it shuld be pin everywhere instead of piny but thats not the problem
    yea you got right but the problem is that there is no signal also on osciloscope and i changed the delay and there was also nothing and strange is that lights leds 18 - 19
  • PrincPrinc Posts: 12
    edited 2013-12-12 11:54
    thanks a lot problem was with res :)
Sign In or Register to comment.