Skip to content

Commit

Permalink
updated readme
Browse files Browse the repository at this point in the history
  • Loading branch information
merijndewit authored Apr 28, 2022
1 parent d2fd104 commit 8f2d96f
Showing 1 changed file with 29 additions and 80 deletions.
109 changes: 29 additions & 80 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,8 @@

![](https://drive.google.com/uc?export=download&id=1ya2MA8AdjBEed9ltCEVmvmjO0VqLAw5p)

# Welcome to the GitHub page of LED-Engine!
Always wanted pixel art or a playing gif on your wall, then this program is for you!


LED-Engine is a software program that lets you control your led's with a Raspberry Pi from an external device like a laptop or a smartphone (no apps required on external devices :D ). LED-Engine has support for ws2812b (more to be added in the future) LED-strips and LED-panels. LED-Engine has an easy to use interface with a lot of useful features (again more to be added in the future!).
LED-Engine is a software program that lets you control your led's with a Raspberry Pi from an external device like a laptop or a smartphone (no apps required on external devices :D ).

![](https://drive.google.com/uc?export=download&id=1CFfCzoUidTyI6hnm8ohEUrq-_4fWohcS)

Expand All @@ -19,15 +16,21 @@ What can you exactly do in LED-Engine:
|----------------|-------------------------------|------------------------|
|Static Color|✔ | ✔
|Rainbow mode|✔ | ✔
|Sine Wave|✔ | ✔
|Star Effect|✔ | ✔
|Fire Effect|✔ | ✔
|Knight Rider|✔ | ✔
|Conway's Game of Life|✔ |**X**
|Langton's Ant|✔ |**X**
|Brian's Brain|✔ |**X**
|WireWorld|✔ |**X**
|Drawing canvas|✔ |**X**
|Display images (from image url or upload)|✔ |**X**
|Display gif (from gif url)|✔ |**X**
|Text|✔ |**X**
|Fishtank|✔ |**X**

## Extra info about some of the different modes:
### Extra info about some of the different modes:

### WireWorld
With WireWorld you first have to draw your "circuit" on the website. When you click play it will play wireworld with your circuit on the LED-Panel!
Expand All @@ -41,24 +44,30 @@ You can display an image on the LED-Engine. You can simply get the url of the im
### Display gif
Display gif is the same as Display images but then it plays a gif on the LED-Panel.


I hope you will try out LED-Engine. All the info to install/use this program is written into this readme file!

# Hardware
### Supported Raspberry Pi's
All raspberry pi's are supported from the pi 4 to the pi zero w. The pi zero w is reccomended for this project because you dont need more processing power running LED-Engine.
All raspberry pi's are supported from the pi 4 to the pi zero w. The pi zero w is reccomended for this project because you don't need more processing power running LED-Engine (though the pi 4 will be quicker of course!).

### Supported Led's
We are using the [Adafruit neopixel ](https://learn.adafruit.com/neopixels-on-raspberry-pi) module that support WS2811/WS2812 led's. If you have a different module you would like to use then you can change the file: "LedEngine/led_lib.py" and change the module to whatever you want! This is the only place in the program were neopixels is being used (to make it easyer switching between modules). Led-Engine will support multiple modules in the future!

# Add your own modes!
### Still in progress
We are currently working on a document that describes step by step how you can add your own mode.
Expect this coming soon!


# Installing LED-Engine
We have multiple ways for installing LED-Engine.
We have two ways of installing LED-Engine.

- **Installing LED-Engine with bash script**
- **Installing LED-Engine with an image**
- **Installing LED-Engine from scratch**

### Installing LED-Engine with bash script
This way is reccomended if you already have an raspberry pi os on your pi.

### Installing LED-Engine with an image
This way is reccomended if you dont have an os on your pi.

### Installing LED-Engine from scratch
this way is reccomended if you had trouble with **Installing LED-Engine with bash script**.

Expand All @@ -69,78 +78,26 @@ This will guide you installing LED-Engine on a raspberry pi that already has an

First we need to download the bash script:

sudo wget https://github.com/merijndewit/Led-Engine/releases/download/v0.1.1/installLedEngine.sh
git clone https://github.com/merijndewit/Led-Engine.git

Then we can execute the script:

sh installLedEngine.sh
./Led-Engine/installLedEngine.sh

After you see this in the terminal the install was succesfull:

Successfully installed LED-Engine!
Type 'sh /Led-Engine/LedEngine/startLedEngine.sh' to start LED-Engine.
Type './Led-Engine/LedEngine/startLedEngine.sh' to start LED-Engine.
Enjoy using LED-Engine!

Then simply enter:

sh /Led-Engine/LedEngine/startLedEngine.sh

>Note:If you get the import error "ImportError: libopenjp2.so.7: cannot open shared object file: No such file or directory" run this command: sudo apt-get install libopenjp2-7
>Note: If you get the import error "ImportError: libtiff5: cannot open shared object file: No such file or directory" run this command: sudo apt install libtiff5
./Led-Engine/LedEngine/startLedEngine.sh

And the program is running!
And the program should be running!
#### Enjoy LED-Engine!


## Installing LED-Engine with an image
This will guide you installing LED-Engine on a raspberry pi. If you are using another platform or if you dont want to install a custom image on your sd card then please follow the instructions at **"Installing LED-Engine from scratch"**.

First we need to create a bootable sd card from a custom image. Go to [releases](https://github.com/merijndewit/Led-Engine/releases) and download LedEngine_Images_vX.X.X .zip. inside that zip file we can find 2 different images.

LedEngine_Image_ARM6_vX.X.X is for:
- Pi zero W
- Pi 1

LedEngine_Image_ARM7_vX.X.X is for:
- Pi 2
- Pi 3
- Pi 4

Extract the correct image file into a folder and install a program that can create a bootable usb drive/sd card like [Rufus](https://rufus.ie/en/). Create a bootable sd card with the extracted image.

If you want to install the os headless (highly recommended) you can add [These files](https://github.com/merijndewit/Led-Engine/files/8015636/add_containing_files_to_sd_boot_folder.zip) to the boot folder of the sd card so the pi will connect to the internet and we can access it with a SSH like [putty](https://www.putty.org/). When you added the files to the boot folder edit Inside the wpa_config file: "put-your-ssid-here" to your network name and
"put-your-wifi-password-here" to your network password.
>Note: only 2G networks work on the pi zero and pi 1
Now we are all set!
Just put the sd card into the raspberry pi and let the pi boot. Now you should be able to access it with an SSH.

The password and username are default.
- username: pi
- password: raspberry

To start the program just go into the LED-Engine directory:

cd /Led-Engine/LedEngine/

Then we just need to run the shell script. The shell script runs the python and webserver program at the same time:

sh startLedEngine.sh

Now the program is running!

>Note:If you get the import error "ImportError: libopenjp2.so.7: cannot open shared object file: No such file or directory" run this command: sudo apt-get install libopenjp2-7
>Note: If you get the import error "ImportError: libtiff5: cannot open shared object file: No such file or directory" run this command: sudo apt install libtiff5
You can access LED-Engine on any browser by typing the pi's address and default port (8080) for LED-Engine Example: 192.168.x.x:8080

#### Enjoy LED-Engine!



# Installing LED-Engine from scratch
## Installing LED-Engine from scratch

This is a step by step guide to get LED-Engine running from a clean install of raspbian os.
Raspberry Pi OS Lite (bullseye) is reccomended for LED-Engine. The desktop version will also work without any problem but will be a bit slower.
Expand Down Expand Up @@ -191,6 +148,7 @@ Now we want to go cback to the root folder and install the socket<span>.io</span
cd /

sudo npm install socket.io
sudo npm install formidable


### Python Dependencies
Expand All @@ -214,7 +172,7 @@ After we've installed all the python dependencies we can install git and clone t
Now we are ready to run LED-Engine! Follow the steps at "How to run LED-Engine" to run the program!


### Running LED-Engine
## How to run LED-Engine
In order to run LED-Engine we need to run 2 programs: **webserver.js** & <span>**Controller**</span>**.py**.
**webserver** is the frontend and **Controller** is the backend. Both programs need to be running at the same time for everythong to work.

Expand All @@ -241,13 +199,4 @@ You can access LED-Engine on any browser by typing the pi's address and default

#### Enjoy LED-Engine!

# Wiring for the LED-Panel or led strip

The wiring is quite easy.
LED-Engine uses GPIO 21 as default. Feel free to change this in "LedstripController<span>.py</span>"

On the image below we can see how to wire an Led-strip or Led-panel to the raspberry pi.
![](https://drive.google.com/uc?export=download&id=1UtZRdzRrpeSM5KbMVe16H3CQBcbshNfd)
If your led-panel or led strip is small you could try to hook it up directly to the raspberry pi (exactly like on the picture). If you have a bigger led panel (bigger than 8x8) or led strip that has more than 64 led's then i would reccomend using an external power supply.


0 comments on commit 8f2d96f

Please sign in to comment.