Papy's Game for Alice !
In the eyes of my grandchildren, I am at least a handyman Grandpa. One of my granddaughters, Alice, asked me if I could make her a video game. Of course, I took up the challenge without trying to achieve exceptional performance!
I had an old Heltec ESP32 module whose Oled screen was tired.
But of course any ESP32 or ESP8266 module will make the job !
So I bought a larger 1,53" Oled screen (128 x 128 pixels), I added 4 integrated buttons, a piezo buzzer all in a small transparent Hammond box and started programming.
I found some tracks on the internet and I decided to adapt Space Invaders and Tetris on my mini console.
The result is quite impressive, especially since I added sound and you can easily recognize extracts from Star Trek and lightsaber noises when a ship is destroyed.
And I am very surprised to see that my grandchildren love this new toy and that the layout of the buttons, the size of the box and the screen are perfectly adapted to this use.
I took care to make a few holes to ventilate the Oled screen a little because it is sensitive to temperature.
I did not forget to add a small copper shield in place of the old screen that I desoldered. Indeed without this screen the Heltec module radiates quite a bit and sometimes disturbs the image of my Oled screen. With this armor, no more worries!
I haven't published a schematic, and the IO connections are as follows:
- Oled screen: 3V3, GND, MOSI:23, SCLK:18, CS:5 and DC:17
- Piezo buzzer +:IO25 and -:GND
- Buttons: Left:34, Fire/Rotate: 32, Right:35 and Down(Tetris only):33
10K pull-up resistors are mandatory and the common is connected to +3V3.
The hi-scores of each game are stored in EEPROM and can be reset in the corresponding menu.
You can return to the main menu and change games by simultaneously pressing Left and Right when the game has already started.
But of course any ESP32 or ESP8266 module will make the job !
So I bought a larger 1,53" Oled screen (128 x 128 pixels), I added 4 integrated buttons, a piezo buzzer all in a small transparent Hammond box and started programming.
I found some tracks on the internet and I decided to adapt Space Invaders and Tetris on my mini console.
The result is quite impressive, especially since I added sound and you can easily recognize extracts from Star Trek and lightsaber noises when a ship is destroyed.
And I am very surprised to see that my grandchildren love this new toy and that the layout of the buttons, the size of the box and the screen are perfectly adapted to this use.
I took care to make a few holes to ventilate the Oled screen a little because it is sensitive to temperature.
I did not forget to add a small copper shield in place of the old screen that I desoldered. Indeed without this screen the Heltec module radiates quite a bit and sometimes disturbs the image of my Oled screen. With this armor, no more worries!
I haven't published a schematic, and the IO connections are as follows:
- Oled screen: 3V3, GND, MOSI:23, SCLK:18, CS:5 and DC:17
- Piezo buzzer +:IO25 and -:GND
- Buttons: Left:34, Fire/Rotate: 32, Right:35 and Down(Tetris only):33
10K pull-up resistors are mandatory and the common is connected to +3V3.
The hi-scores of each game are stored in EEPROM and can be reset in the corresponding menu.
You can return to the main menu and change games by simultaneously pressing Left and Right when the game has already started.
Discussie (2 opmerking(en))