Pages: [1]   Go Down
Author Topic: generating a PRBS  (Read 491 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 2
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

hey all,

i am a new user of the arduino board and cannot find the code to flash the LED on pin 13 on and off at random intervals of time, any help would be greatly appreciated.
regards

gordon.
Logged

0
Offline Offline
Edison Member
*
Karma: 8
Posts: 1411
Arduino rocks
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

After you install Arduino IDE, you will find the example in the folder C:\[arduino-home]\examples\Digital\Blink.

Logged

0
Offline Offline
God Member
*****
Karma: 1
Posts: 588
LumiNet rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

And for your random numbers, have a look at this topic in the reference:
http://arduino.cc/en/Reference/RandomSeed

and the Blink example was already mentioned: http://www.arduino.cc/en/Tutorial/Blink

the random() function in combination with the delay() function can change the interval between on and off of the LED in the range of milliseconds.

If you need something that is more like a candle light, shorter intervals might be more interesting. Please let me know if you want to create a candle light or if the random() function in combination with the Blink example solved your problem.
Logged


Pages: [1]   Go Up
Jump to: