Skip to content

Commit

Permalink
add a picture to read me
Browse files Browse the repository at this point in the history
  • Loading branch information
jcksnvllxr80 committed Dec 5, 2021
1 parent 2e0ecaa commit 5eb5ac5
Showing 1 changed file with 12 additions and 16 deletions.
28 changes: 12 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,28 +6,26 @@
[![GitHub issues](https://img.shields.io/github/issues/jcksnvllxr80/raspi_pico_christmas_tree.svg)](lib-issues)
[![License](https://img.shields.io/badge/license-MIT-blue.svg)](lib-licence)

## Image of project in its current phase (WIP)
## Imagea of project // still a WIP

<p align="center">
<img src="https://live.staticflickr.com/65535/51725697269_1f4f05c453_k.jpg" width="800">
</p>

<p align="center">
<img src="https://live.staticflickr.com/65535/51717997987_277b59fbd0_k.jpg" width="800">
</p>

## Description

This project was designed for a decorative Christmas tree made out of cedar which stands about two feet in height. It consists of a Raspberry Pi Pico, a string of ws2812 neopixels, a 128x64 pixel (model: SSD1306) OLED display, an EEPROM (model: 24LS512), a standard push-button, and a esp8266 es01 module. The string of lights serve as the lights on the wooden Christmas tree and are controlled by one wire sending data in series to the lights. each new received value pushes the previous down the line to the next light. The different patterns of the lights are cycled through by pressing the push-button. The OLED display communication protocol is SPI and this display is used to give feedback to the user in form of the name of the LED string lighting style name. The time will be displayed after no button activity has occurred in a certain number of seconds (TBD). The time is obtained by using the esp8266 module to connect to the internet through the LAN wifi and obtain the time from a time server. Each time the led string lighting style changes, the array index of that style is stored in the EEPROM so that on next start up that setting is immediately recalled and used. I2C protocol is used to talk to the EEPROM. There is also a standalone LED that indicates whether wifi is connected or not (red/green common cathode LED).

## Prerequisites
This project was designed for a decorative Christmas tree made out of cedar which stands about two feet in height. It consists of a Raspberry Pi Pico, a string of ws2812 neopixels, a 128x64 pixel (model: SSD1306) OLED display, an EEPROM (model: 24LS512), a standard push-button, and a esp8266 es01 module. The string of lights serve as the lights on the wooden Christmas tree and are controlled by one wire sending data in series to the lights. each new received value pushes the previous down the line to the next light. The different patterns of the lights are cycled through by pressing the push-button. The OLED display communication protocol is SPI and this display is used to give feedback to the user in form of the name of the LED string lighting style name. The time will be displayed after no button activity has occurred in a certain number of seconds (TBD). The time is obtained by using the esp8266 module to connect to the internet through the LAN wifi and obtain the time from a time server. Each time the led string lighting style changes, the array index of that style is stored in the EEPROM so that on next start up that setting is immediately recalled and used. I2C protocol is used to talk to the EEPROM.

The following classes (which are all in this repo) must be manually loaded onto the pico for this project to work:
## Drive a set of WS2812 LEDs

- base64.py
- EEPROM_24LC512.py
- esp8266.py
- httpParser.py
- image_utils.py
- neopixel.py
- ssd1306.py
- main.py
- Use a micropython IDE to upload the script file, examples/led_strip/main.py, to the pico and connect 3 pins to the light strip
- data --> GPIO22
- vcc --> vcc
- gnd --> gnd

## Text Image Creation

Expand All @@ -40,9 +38,7 @@ The following classes (which are all in this repo) must be manually loaded onto

## TODO

- make a clock by utilizing the datetime object of the RTC (which was set from the internet API)
- thread the initial connecting to wifi and setting time so those processes don't delay LED string from starting // threading seems broken on the pi pico right now
- on a timer, check wifi connection status (threaded)... if connection, use time API to set RTC, otherwise reconnect and then set time once connected // need a thread for this too but threading seems broken on the pi pico right now
- get wifi working with the ESP8266

### Template for code

Expand Down

0 comments on commit 5eb5ac5

Please sign in to comment.