Need help in Propeller Demo Board (Blinkink an LED)

Hello everybody,
I've taken the great decision to start with Propeller.! (I have already run successfully some amazing damos with sound, TV-monitor, mouse etc.!!! Actually those demos are very sophisticated and amazing!!!)
I have the propeller demo board and I'm trying to Blinkink an LED about once a second
Althought the led lights up it is not blinkink (I use a 220Ω resistor instedad off the 100Ω resistor that suggest the activity. p.p.31 book "Programming the propeller with spin. A beginner's guide to parallel".
(I have aslo changed the Output_pin from 27 to 3 because the Demo doard doesn't have freethe pin27, and I have also connected: Vss---Negative leg of the LED----Positive leg of the LED
220Ω Resistor
PIN 3)
Could you help me please?
What is wrong?
here is the code:
CON
_clkmode = xtal1 + pll2x
_xinfreq = 5_000_000 'Note Clock Speed for your setup!!
inv_hight = 0
inv_low = 1
waitPeriod = 5_000_000 ' 1/2 sec switch cycle
output_pin = 3
VAR
pub go
dira [output_pin]~~
outa [output_pin]~~
repeat
turnOff_LED
wait
turnOn_LED
wait
PRI turnOn_LED
outa[ output_pin]:=inv_hight
PRI turnOff_LED
outa[ output_pin]:=inv_low
PRI wait
waitCnt(waitPeriod+cnt)
Thank you in advance
Nikos.
P.s. I feel a bit embarrassing with this question I know that even 14year old users have achieved this task, But I have stuck.
I've taken the great decision to start with Propeller.! (I have already run successfully some amazing damos with sound, TV-monitor, mouse etc.!!! Actually those demos are very sophisticated and amazing!!!)
I have the propeller demo board and I'm trying to Blinkink an LED about once a second
Althought the led lights up it is not blinkink (I use a 220Ω resistor instedad off the 100Ω resistor that suggest the activity. p.p.31 book "Programming the propeller with spin. A beginner's guide to parallel".
(I have aslo changed the Output_pin from 27 to 3 because the Demo doard doesn't have freethe pin27, and I have also connected: Vss---Negative leg of the LED----Positive leg of the LED
220Ω Resistor
PIN 3)
Could you help me please?
What is wrong?
here is the code:
CON
_clkmode = xtal1 + pll2x
_xinfreq = 5_000_000 'Note Clock Speed for your setup!!
inv_hight = 0
inv_low = 1
waitPeriod = 5_000_000 ' 1/2 sec switch cycle
output_pin = 3
VAR
pub go
dira [output_pin]~~
outa [output_pin]~~
repeat
turnOff_LED
wait
turnOn_LED
wait
PRI turnOn_LED
outa[ output_pin]:=inv_hight
PRI turnOff_LED
outa[ output_pin]:=inv_low
PRI wait
waitCnt(waitPeriod+cnt)
Thank you in advance
Nikos.
P.s. I feel a bit embarrassing with this question I know that even 14year old users have achieved this task, But I have stuck.
Comments
When you post code, place your code between code tags, like what you see below but be sure to remove all of the spaces I placed between the brackets.
[ code ]
[ / code ]
Without the code tags, the indentation is lost and it's hard to read your code.
This works too
At least this would be a very classic mistake.
Good idea! I'm always getting messed up by that pin numbering scheme. I never get used to it.
I didn't expect such response! Thank you all of you!
I copyed -Paste both codes that send Mike on my propeller tool and it works! I don't know what I have done wrong. I kept the same circuit and I only run Mike's code and it works!!!
Anyway I'm thankfull. I'll try to do the best using my propeller. I have been studying propeller and spin for 3-4 days (during Christmas holydays) and I'm fascinated. I feel that I can do a lot of things using this tool. I hope that I will be able to contribute to propeller comunity in the near future!
Happy holydays and Happy New Year!!!!
Thank you "Humanoido"!
I think you are right. This was my fault. I hadn't have any indented instruction under my repeat command.
P.s.
In my case I absolutely need a second brain to correct syntax and spelling mistakes
If you extend your project "Fill the Big Brain" to humans I'll be one of the first customers