ArduinoGotchi is a real Tamagotchi P1 emulator running in Arduino UNO hardware. The emulation core is based on TamaLib with intensive optimization to make it fit into UNO's hardware that only comes with 32K Flash 2K RAM.

The Tamagotchi Emulator is a massive programming achievement for an Arduino Uno. It combines high-resolution graphics, state-machine logic, EEPROM memory saving, and continuous game loops to create a living "virtual pet."
Rendering Graphics
To make the pet look alive, you must use a matrix LCD (like the Nokia 5110 or a 128x64 OLED) instead of a simple 16x2 character display.
- Sprites: You draw the pet's animations (happy, sad, eating) pixel-by-pixel on a PC, convert them to hex arrays, and store them in the Arduino's
PROGMEM(Flash memory). - The Display Library: Libraries like
U8g2orAdafruit_GFXhandle pushing these hex arrays to the screen rapidly to create animations.
The State Engine
The pet has variables like hunger_level, happiness_level, and health.
- Over time (using the
millis()function), these variables degrade. - The user pushes one of three buttons to "Feed," "Clean," or "Play," which restores these variables.
- Using the
EEPROM.hlibrary, the Arduino saves the pet's stats right before you power it off, so the pet "remembers" its state when you turn it back on!
Components
- Arduino Uno: The game console.
- Nokia 5110 / OLED Display: The screen.
- Push Buttons (x3): For interaction.
- Piezo Buzzer: For "beep" notifications when the pet is hungry.