diff --git a/doc/img/raspberrypi_internal_wiring.jpg b/doc/img/raspberrypi_internal_wiring.jpg new file mode 100644 index 0000000..db6487d Binary files /dev/null and b/doc/img/raspberrypi_internal_wiring.jpg differ diff --git a/doc/img/raspberrypi_reedsensor_wiring.jpg b/doc/img/raspberrypi_reedsensor_wiring.jpg new file mode 100644 index 0000000..5eeea56 Binary files /dev/null and b/doc/img/raspberrypi_reedsensor_wiring.jpg differ diff --git a/doc/installation.md b/doc/installation.md index b2cee1b..374c7f4 100644 --- a/doc/installation.md +++ b/doc/installation.md @@ -79,15 +79,27 @@ WantedBy=multi-user.target ## Hardware Installation -Basically all that's left to do is hook up your reed sensor to the GPIO pins of the Raspberry Pi. - -todo: add a photo of the wired device +Basically all that's left to do is hook up your sensor to the GPIO pins of the Raspberry Pi. Open Rowing Monitor reads the sensor signal from GPIO port 17 and expects it to pull on GND if the sensor is closed. To get a stable reading you should add a pull-up resistor to that pin. I prefer to use the internal resistor of the Raspberry Pi to keep the wiring simple but of course you can also go with an external circuit. +![Internal wiring of Raspberry Pi](img/raspberrypi_internal_wiring.jpg) +*Internal wiring of Raspberry Pi* + The internal pull-up can be enabled as described [here](https://www.raspberrypi.org/documentation/configuration/config-txt/gpio.md). So its as simple as adding the following to `/boot/config.txt` and then rebooting the device. ``` Properties # configure GPIO 17 as input and enable the pull-up resistor gpio=17=pu,ip ``` + +How to connect this to your rowing machine is specific to your device. You need some kind of mechanism to convert the rotation of the flywheel into impulses. The WRX700 has a reed sensor for this built-in so hooking it up is as simple as connecting the cables. This sensor had one magnet on the wheel, which gives one impulse per rotation. I simply plugged a second magnet to the opposite side of the wheel to double the resolution for more precision. + +![Connecting the reed sensor](img/raspberrypi_reedsensor_wiring.jpg) +*Connecting the reed sensor* + +If your machine does not have something like this or if the sensor is not acessible, you can still build something similar quite easily. Some ideas on what to use: + +* Reed sensor (i.e. of an old bike tachometer) +* PAS sensor (i.e. from an E-bike) +* Optical chopper wheel