Giter Site home page Giter Site logo

rachel's Introduction

RaCheL

RAspberry pi CHEss cLock

This project provides the necessary software and hardware-wiring-schematics for running a (hopefully) functional chess clock on a Raspberry Pi.

The hardware wiring consists of a resistor (we used 12k ohm, reasonable deviation should be fine), a switch and some wires. Connect the resistor via a wire to a 3.3V pin. On the other side of the resistor, connect another wire, which 'splits' up into two wires. Connect one end to a GPIO pin (by default, pin 13 (GPIO 2 according to the wiringPi library) is expected). Attach the switch to the other wire and connect the other side of the switch to one of the 'ground' pins. In the end, the result should look something like this: (NOTE: The schematics make more sense in a raw .txt format)

3.3V----
|
R
|
GP02---|
|
S
|
GRND----

where R is a resistor, S a switch and 3.3, G02 and GND the pins. We used pins 1 (3.3V), 13 (GPIO) and 39 (ground). The pin for detecting the input can be changed, but this also requires a change in the code. In particular, the value 2 in pinMode(2, INPUT) in main.cpp and digitalRead(2) in clock.cpp needs to be changed to whatever pin you choose. Make sure to use the values from the wiringPi library, which you can get by calling 'gpio readall' in the terminal/console. For checking if the switch works, 'gpio read 2' (with 2 being the number of the pin) can be called in the terminal.

rachel's People

Contributors

asgorlas avatar wombilisk avatar

Stargazers

 avatar

Watchers

 avatar

rachel's Issues

write time to files

write times for white and black in respective files ('io/time_white', 'io/time_black'); time in seconds, double (.3f)

Bug with getMode()

Marked the line that seems to cause the problem with "TODO: ERROR!!!" in getMode()

Config File

  • name | time | increment
  • expandable
  • superbullet with -time

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.