Hello all,
PROBLEM
********
I'm trying to send 10 consecutive tones using FREQOUT command. Here's my code:
Tone1 VAR Word
...
Tone 10 VAR Word
Loop:
FREQOUT Pin, Period, Tone1
FREQOUT Pin, Period, Tone2
FREQOUT Pin, Period, Tone3
FREQOUT Pin, Period, Tone4
FREQOUT Pin, Period, Tone5
FREQOUT Pin, Period, Tone6
FREQOUT Pin, Period, Tone7
FREQOUT Pin, Period, Tone8
FREQOUT Pin, Period, Tone9
FREQOUT Pin, Period, Tone10
PAUSE 1000
GOTO Loop
QUESTION
*********
Can I use a FOR...NEXT loop in order to use just one FREQOUT statement instead of ten? For example:
Loop:
FOR i = 1 TO 10
Tone = Tone(i)
FREQOUT Pin, Period, Tone
NEXT i
i = 0
PAUSE 1000
GOTO Loop
PS When I try to compile this I get an error. Can anyone give me a clue as to how I might go about solving this problem? Thank you in advance.
--
Sincerest regards,
YZ7REA Vladimir M SKrbic
4N7ATV Repeater Administrator
YU7GHZ Radio Club President
Bookmarks