Snake Slithers Onto Raspberry Pi Pico

Snake playing on a tiny OLED screen
(Image credit: Hari Wiguna)

The worst thing about modern smartphones and handheld videogame consoles is the lack of Snake. If you can’t play a quick game of Snake during meetings, then what’s the point? Enter Hari Wiguna, who has, via Hackaday, got the game running on a Raspberry Pi Pico and a tiny OLED screen.

The Raspberry Pi Pico, a $4 programmable microcontroller board from the Raspberry Pi Foundation, features a  a dual-core Arm Cortex-M0+ processor with 264KB internal RAM (compared to 1KB on the Nokia 3310, the home of Nokia’s Snake II). And of course, what else could you code Snake in but MicroPython?

Wiguna’s code is fully available on Github for anyone who fancies having a go themselves. Along with the Raspberry Pi Pico, Wiguna used an I2C 128 x 64 OLED screen and five buttons - four for movement and the fifth to start a new game. 

The snake’s slithery undulating movement is a fine showcase for both the Pico’s abilities and Wiguna’s coding ability - and the design drawings documented on the site give an insight into the amount of work it takes just to chase apples across 8,000 pixels.

Ian Evenden
Freelance News Writer

Ian Evenden is a UK-based news writer for Tom’s Hardware US. He’ll write about anything, but stories about Raspberry Pi and DIY robots seem to find their way to him.