#Zepir Raspberry Pi Zero mini computer

on rpi GPIO is enough signals to direct button matrix + 2" IPS 320x240 display.

Similar projects worth following
Starting from
bobricius has 1548 orders / 74reviews
Ships from Slovakia
I love my keyboards, looks on RPI GPIO is enough signals for direct keyboard matrix scan
+ 2" IPS 320x240 display ST7789

No extra manufacturing, front panel is made in PCB factory + mainboard

Keeping my KISS philosophy make it stupid simple = one order = one device

First preview :)

There nothing, just display and buttons ;)

  • Display configuration
sudo apt-get install cmake
cd ~
git clone
cd fbcp-ili9341

mkdir build
cd build

cd fbcp-ili9341/build
rm -r *


make -j
sudo ./fbcp-ili9341

For autorun on startup put this line before exit 0 in your sudo nano /etc/rc.local

sudo /home/pi/fbcp-ili9341/build/fbcp-ili9341 &
sudo modprobe -i uinput &
sudo python /home/pi/keyboard/ &
sudo setfont /usr/share/consolefonts/Lat2-Terminus20x10.psf.gz &

 These lines are in my sudo nano /boot/config.txt file:

hdmi_cvt=320 240 60 1 0 0 0

Change in driver before compilation st7735r.h

#if defined(ST7789) || defined(ST7789VW)
#elif defined(ST7735R)
#elif defined(ST7735S)

 Change in driver before compilation st7735r.cpp

#ifdef ST7789
    // The ST7789 controller is actually a unit with 320x240 graphics memory area, but only 240x240 portion
    // of it is displayed. Therefore if we wanted to swap row address mode above, writes to Y=0...239 range will actually land in
    // memory in row addresses Y = 319-(0...239) = 319...80 range. To view this range, we must scroll the view by +80 units in Y
    // direction so that contents of Y=80...319 is displayed instead of Y=0...239.
    //  SPI_TRANSFER(0x37/*VSCSAD: Vertical Scroll Start Address of RAM*/, 0, 320 - DISPLAY_WIDTH);
  • Keyboard reading is based on:

x-python - 6.25 kB - 06/27/2021 at 21:43


sch - 512.11 kB - 06/23/2021 at 21:03


brd - 149.24 kB - 06/23/2021 at 21:03


Portable Network Graphics (PNG) - 39.99 kB - 06/23/2021 at 21:02


  • Installation v2 - My private notes ;)

    bobricius10/01/2021 at 21:04 0 comments

    My private notes ;)

    My steps:

    Write image: 2021-05-07-raspios-buster-armhf-lite.img

    copy to boot:

    empty file ssh


    ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev

    add in to config.txt

    hdmi_cvt=320 240 60 1 0 0 0

    via ssh

    Login: pi
    password: raspberry

    $ sudo raspi-config

    SET AUDIO > headphones
    boot console autologin pi


    sudo apt-get update
    sudo apt-get install cmake
    sudo apt-get install git
    cd ~
    git clone
    cd fbcp-ili9341
    cd fbcp-ili9341/build
    rm -r *
    make -j
    sudo ./fbcp-ili9341

    Extra toys

    sudo apt-get mc
    sudo apt-get w3m
    sudo apt-get mpg123


    cd ~
    git clone
    pip3 install python-uinput

    For autorun on startup put this line before exit 0 in your sudo nano /etc/rc.local

    sudo /home/pi/fbcp-ili9341/build/fbcp-ili9341 &
    sudo modprobe -i uinput &
    sudo python3 /home/pi/gpiokeyboard/ &
    sudo setfont /usr/share/consolefonts/Lat2-Terminus20x10.psf.gz &

View project log

Enjoy this project?



Trevor O'D wrote 02/28/2022 at 22:37 point

what are the dimentions of the device I am trying to make a case for mine so I can carry it around

  Are you sure? yes | no

bobricius wrote 03/01/2022 at 11:42 point

Dimension:97.79 mm* 82.56 mm

  Are you sure? yes | no

Trevor O'D wrote 02/18/2022 at 02:26 point

Is there a  case out there for this or would I need to make my own

  Are you sure? yes | no

bobricius wrote 02/18/2022 at 07:36 point

No case designed

  Are you sure? yes | no

teraz wrote 11/03/2021 at 21:36 point

how long this device work on one charging? is possible add solar panel?

  Are you sure? yes | no

John Hind wrote 05/29/2021 at 10:17 point

Love the keyboard concept - might have to steal it for my next-gen calculator project! But this would be a lot neater as an IO board for the Compute Module 4. The whole assembly could be much more compact (depending on how many and what type of connectors you chose to implement).

  Are you sure? yes | no

bobricius wrote 06/07/2021 at 21:13 point

Zepir is specially designed to be max. simple, zero integrated circuits, TH soldering :)

  Are you sure? yes | no

Sam Garfield wrote 04/16/2021 at 20:22 point

Will you be selling a complete version on tindie?

  Are you sure? yes | no

xxx wrote 04/15/2021 at 17:07 point

Where i can download gerberbers for repeat this project?

  Are you sure? yes | no

bobricius wrote 04/15/2021 at 21:17 point

I preparing share next version (bot is untested now), this have some bugs.

  Are you sure? yes | no

xxx wrote 04/16/2021 at 08:00 point

Great! I will wait for relaese gerbers.

  Are you sure? yes | no

marazm wrote 02/04/2021 at 11:54 point

Dodaj kilka diód. Chodzi o informacje czy wciśnieęto capslock, ins, czy przyszła poczta itp. 

Myślę, że warto też zrobić miejsce by można było tam wstawić raspbery pi pico 2040 lub jakieś inne procesory. Jak by było to autonomiczne bez zasilania po kablu to wiele osób by chciało miec komputer na swoim *(tu wpisz procesor) ulubionym procesorze

  Are you sure? yes | no

aldolo wrote 01/28/2021 at 06:39 point

keyboard is always the toughest part. cheap and brilliant solution.

  Are you sure? yes | no

xxx wrote 01/27/2021 at 08:28 point

In general, it could be diluted through Atmega32u4, making both the mouse and the keyboard at once, and dissolve on the board itself USB-HUB FE1.1s for 4 ports

  Are you sure? yes | no

xxx wrote 01/27/2021 at 08:25 point

looks very interesting, the only thing I would add at the place where the palm is shown is a trackball or joystick  to control the mouse cursor

  Are you sure? yes | no

Anthony DiGirolamo wrote 01/19/2021 at 06:31 point

Looks great!!! I like your key layout. If it helps free up GPIO pins you could use a TCA8418 which has linux kernel module support. Kicad and links here

Your design is a perfect form factor for coding & gaming on the go with

  Are you sure? yes | no

bobricius wrote 01/19/2021 at 12:34 point

Thanks, Yes I know this, but look like I have exactly enough GPIO for full keyboard. I love simplicity :-) I just ordered 2 Boards batch (maybe next revision can fit over RPI 3/4), receive soon.

  Are you sure? yes | no

ptrav wrote 01/10/2021 at 02:37 point

Interesting project.

On your keyboard wiring diagram, one problem is obvious.

Let say, you keep all "columns" high and set all "rows" as "input-pullup". Then, you scan  the columns by setting one column "low" in a cycle and testing all inputs one-by-one. The pressed button will be on the crossing between the column pulled "low" and the row showing "low". As far as the user presses one button at the time, all good and sound.

What happens, however, if the user presses 2 buttons of the same row? Let say, column #1  is momentary "low" and column #5 is "high". Then, column #5 will feed 3.3V at unlimited current into the column #1. One of the digital outputs - most likely the column #5 - will fry. It is a good idea to put a diode at each column to prevent this.

The way of circumventing is not to use pins as digital inputs but use the internal resistors:

GPIO.setup(button, GPIO.IN, GPIO.PUD_UP)

All 6 columns are set to GPIO.PUD_UP and one of them set to GPIO.PUD_DOWN at any given time. The internal 50k resistor will limit the current and the outputs will not fry.

One more problem remains. If the user presses 3 buttons simultaneously, a "ghost" (unpressed) button will register. For example if the user holds buttons C1R3, C2R2, and C2R3 - button C1R2 is registered. That's why each key should have its own diode. However, on a tiny keyboard like yours people are unlikely to touch-type, so may be these diodes are excessive.

The good explanation of matrix keyboards is here:

Good luck with your project.

  Are you sure? yes | no

Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates