https://github.com/dr-mod/blackout-logger
https://github.com/dr-mod/blackout-logger
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/dr-mod/blackout-logger
- Owner: dr-mod
- License: gpl-3.0
- Created: 2022-11-13T14:23:11.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-01-18T19:22:02.000Z (over 3 years ago)
- Last Synced: 2025-04-04T16:41:53.297Z (about 1 year ago)
- Language: Python
- Size: 354 KB
- Stars: 81
- Watchers: 5
- Forks: 6
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Blackout Logger
A miniature device that's keeping track of power outages.

### [Video in action](https://twitter.com/dr2mod/status/1591815766994980866)
### Hardware
* Raspberry Pi Pico
* Precision RTC Module (DS3231)
* Waveshare eink 3.7
### Software
#### MicroPython
The software is written in MicroPython 1.19.1
1. Download the MicroPython UF2.
2. Push and hold the BOOTSEL button and plug your Pico into the USB port of your computer. Release the BOOTSEL button after your Pico is connected.
3. It will mount as a Mass Storage Device called RPI-RP2.
4. Drag and drop the MicroPython UF2 file onto the RPI-RP2 volume.
#### rshell
To upload and configure your Pico Solar System you will need to install rshell. Make sure you have _pip_ installed.
```
pip3 install rshell
```
#### Installing Pico Solar System
1. Download Pico Solar System
```
git clone https://github.com/dr-mod/blackout-logger.git
```
2. Open the directory with the source code
```
cd blackout-logger
```
3. Copy required python files to your pico
```
rshell
cp *.py /pyboard/
```
4. Set time & configure the RTC module
```
repl
import time
import ds3231
rtc = ds3231.ds3231()
rtc.set_time(time.time())
```
To account for a timezone you might want to apply an offset to the UTC timestamp in seconds:
```
rtc.set_time(time.time() + 60 * 60 * (+ OFFSET_IN_HOURS) )
```
### Support the project
If you would like to support what I do and keep me caffeinated, you can do it here:
[](https://www.buymeacoffee.com/drmod)