B4R Question How to get a good random?

Troberg

Well-Known Member
Licensed User
Longtime User
In another thread (https://www.b4x.com/android/forum/threads/random-number.107844/), a method which use an open pin is used. I'm doing a project with a tiny Arduino board, and don't have any pins to spare.

Is there any way to get a decent random (doesn't have to be good, just different each run) without having to use a pin?

(This is my first project with Arduino and with B4R, and I love it. I used to do electronics as a hobby 30 years ago, but lost interest as it became too much work to get anything advanced done. The combination of Arduino and B4R has made it easy and fun again.)
 

Troberg

Well-Known Member
Licensed User
Longtime User
Ah, then it's complicated.

But, the problem solved itself another way. I had been working on a Nano, expecting to switch to a ATTINY once I got around to soldering up that board, but I couldn't get the ATTINY to work, so I'll do it on the Nano, and have plenty of pins to spare.
 
Upvote 0

Troberg

Well-Known Member
Licensed User
Longtime User
Yep, that's what I ended up doing. I couldn't get the ATTINY85 to work, so I had pins to spare. Didn't add an antenna, though, as it's not that important that it's a really good random, just that I don't get the same every time.
 
Upvote 0
Top