Comments on: Random scribbles http://www.polargraph.co.uk/2013/03/random-scribbles/ drawing by robot Mon, 14 May 2018 00:33:14 +0000 hourly 1 https://wordpress.org/?v=4.9.7 By: sandy http://www.polargraph.co.uk/2013/03/random-scribbles/#comment-7856 Sun, 28 Apr 2013 10:01:01 +0000 http://www.polargraph.co.uk/?p=732#comment-7856 Yes, once I found it out, I was immediately in a dilemma about whether it was a problem or not!

]]>
By: John Cliff http://www.polargraph.co.uk/2013/03/random-scribbles/#comment-7830 Fri, 26 Apr 2013 18:05:16 +0000 http://www.polargraph.co.uk/?p=732#comment-7830 If its like the C++ one you need to seed the generator, doing a quick google it looks like you want ot add a
randomSeed(analogRead(0));

to the start of the code, which will fire the random number generator up using an analog read from pin 0 to get a properly random seed for the generator.

if you dont seed the generator (or you seed it with a consistant value) you’ll get the same sequence of numbers every time
(We actually use the fact it will give the same thing every time to make the random functions in inkscape behave the same when you reload a file.)

see for ref: http://arduino.cc/de/Reference/RandomSeed

]]>