Skip to content

About

A fully autonomus dice-roller for determining if a dice is "fair"

Resources

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

diceroller

A fully autonomus dice-roller for determining if a dice is "fair"

The end

I've spent way too much time on this project, and I no longer believe it serves its purpose, but is a time-waste for me. There is many problems, of which most could be solved easily, but im quite unvilling to at the moment. The major issues are listed below:

Issues

  • The stepper reset routine is not consistent, resulting in inconsistent lighting(which causes further problems)
  • the tresholding alg is simple but doesnt work for certain dice and is incredibly sensitive to lighing
  • the current models(found in this Github Repo) are imperfect, due to trashy data(caused by issues above)
  • while workable, the code itself is mostly slop.
  • collecting data/training for other dice types is a huge pain.

Status

The results: example result

cumilative chi-sq cumilative rolls

The Cool gifs: a GIF with a different dice-roll every frame

The machine: CAD design and the built version:

Project goals

There is 2 distrinct subsystems, the "mechanisim" and the "software", the former is the physical part and the motor controls while the latter is the image-detection pipeline

Must

  • the mechanisim must be able to able to roll all standard dice(4,6,8,10/100,12,20) in a way that's similar to how a human would.
  • the software must read the dice and record the results(all except D4's)

Should

  • The mechanisim should be able to accomodate larger than standard dice
  • The mechanisim should be able to roll multiple dice at once
  • The mechanisim shouldn't rely on too many actuators less than 2 motors is optimal
  • The mechanisim should be mostly custom-made
  • The software should support both dice with dots and numerals
  • Should also include lights etc. for usage in all env's
  • Make the system double-sided for measuring both sides
  • add ridges/slopes to the inside to increase entropty or something
  • The software should support rolling D4's
  • The software should auto-detect the amount of dice rolled and record accordingly

Could

  • The software could detect dice size, or maybe it doesnt need to know it at all?
  • The dots-vs-numbers could be automatic?
  • Could include a magazine and load the dice one set at a time for overnight tests?
  • Could Detect multiple dice with different colours and record them independtly?
  • Could use a RP-zero-2-w as the processor?

Won't

  • No custom electronics
  • No display/GUI past running scripts

Hardware

Hardware used:

CAD

  • The cad is hosted on onshape, Public Link. If you'd like to contribute, let me know!

Software

  • Model Training has been done for D6 and D6 with pips, the architecture is there for the rest but i dont have the data yet

Acknowledgements

This project takes heavy inspiration from the following projects:

About

A fully autonomus dice-roller for determining if a dice is "fair"

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages