To much!!!
Iguanaman
Posts: 32
in Propeller 1
I am reading the forum from start to finish and It will take me more then a year to do it! There is a lit to take in. I will spend the rest of my worthless, primitive life trying to understand the spin language, to say nothing about understanding Pasm - Assembly - Machine code. So many ways to talk, speak, communicate to the propeller one (1). So many possibilities so little time. Many orders of magnitude a steep up from basic stamp activity kit (90005).
I am sending a query about a forum from Dave Scanlan "Spin code examples for the beginner (Public version) march 2008. My question is about " Example 03 using two cogs ( two processors)". Here be code:
COM
_clkmode = xtal1 + pll16x
_xinfreq = 5_000_000
high = 1
low = 0
VAR
long stack 0[20]
long stack 1[20]
PUB Start
cognew(blinkingled_A16, @stack0)
cognew(blinkingled_A17, @stack1)
PRI Blingingled_A16 | pin
pin:= 16
dira[pin]:=%1
repeat 5
outa[pin]:=high
waitcnt(40_000_000 + cnt)
outa[pin]:= low
waitcnt(40_000_000 + cnt)
PRI Blinkingled_a17 | pin
pin:= 17
dira[pin]:=%1
repeat 5
outa[pin]:= high
waitcnt(40_000_000 + cnt)
outa[pin]:= liw
waitcnt(40_000_000 + cnt)
I have try ed to rewrite the code but I am more of a stinker then a thinker. Also I removed these [noparse] from the code. Are these a part of a by-gone eria?
So much I do not know. Thank you for any input. 29 jan 2019(tue).
I am sending a query about a forum from Dave Scanlan "Spin code examples for the beginner (Public version) march 2008. My question is about " Example 03 using two cogs ( two processors)". Here be code:
COM
_clkmode = xtal1 + pll16x
_xinfreq = 5_000_000
high = 1
low = 0
VAR
long stack 0[20]
long stack 1[20]
PUB Start
cognew(blinkingled_A16, @stack0)
cognew(blinkingled_A17, @stack1)
PRI Blingingled_A16 | pin
pin:= 16
dira[pin]:=%1
repeat 5
outa[pin]:=high
waitcnt(40_000_000 + cnt)
outa[pin]:= low
waitcnt(40_000_000 + cnt)
PRI Blinkingled_a17 | pin
pin:= 17
dira[pin]:=%1
repeat 5
outa[pin]:= high
waitcnt(40_000_000 + cnt)
outa[pin]:= liw
waitcnt(40_000_000 + cnt)
I have try ed to rewrite the code but I am more of a stinker then a thinker. Also I removed these [noparse] from the code. Are these a part of a by-gone eria?
So much I do not know. Thank you for any input. 29 jan 2019(tue).
Comments
[noparse] is not for posting code. [ code ] tags (without the spaces inside the brackets) are. Your code is below, but I fixed a few typos in it; hit the quote button below my post to see the [ code ] tags in it around the code.
Start with Propeller Education Kit (PEK) textbook which introduces you to Spin piece-by-piece.
Working with multiple Cogs is more advanced Spin so start with the basics of learning commands and how to use Methods and Objects.
The only thing I didn't like about the PEK text is that it doesn't teach CONstants for I/O pins or anything else that's fixed.
Code is so much easier to write, change, and understand when you have names instead of numbers.
All of the Spin commands are explained in detail in the Propeller manual including some examples of how to use them.
If you have questions or don't understand something then just ask but learn to walk before trying to do a marathon.
Load the Tachyon binary image onto the Prop, connect a terminal at 115200 baud and type:
The LED on 16 blinks.
Then type: The LED on 17 blinks (as well).
Then type: and the LED on 17 blinks even faster.
Isn't that just "all too much"
http://forums.parallax.com/discussion/169675/propeller-question
As Genetex has suggested I would recommend starting with the Propeller Education Kit textbook. You can find the PDF version in the Propeller tool under HELP
Anyway, your first steps should be small and so ask any question here in the forum and you will get an answer. As this forumistas mostly started as freshmen like you, dont't read to much, as you will get to much information you will never know to solve problems you don't have. It's like reading FrequentlyAskedQuestions, but all questions are asked only once.
But take the right steps and if you want to gain any knowledge, please remember: it's not the way called "The Presidents Path".