Some code to bring the C-Berry Display alive. Updated code from admatec GmbH so it will compile with newer gcc-versions
Go to file
2022-08-21 12:40:12 +02:00
doc updated code to raspi 3 and newer versions of gcc 2022-08-20 21:27:30 +02:00
HW updated code to raspi 3 and newer versions of gcc 2022-08-20 21:27:30 +02:00
SW updated code to raspi 3 and newer versions of gcc 2022-08-20 21:27:30 +02:00
LICENSE Initial commit 2022-08-21 10:09:59 +00:00
README.md beautification of README.md 2022-08-21 12:40:12 +02:00

C-Berry_Display

Some code to bring the C-Berry Display alive. Updated code from admatec GmbH so it will compile with newer gcc-versions

Dependencies:

Raspberry Pi Userland: https://github.com/raspberrypi/userland

$ sudo apt install build-essential pkg-config cmake
$ mkdir /tmp/ramdisk
$ sudo mount -t tmpfs -o size=128M tmpfs /tmp/ramdisk
$ cd /tmp/ramdisk
$ git clone https://github.com/raspberrypi/userland
$ cd userland
$ ./buildme

Add login username to /etc/group for audio, video:

...
audio:x:29:username
video:x:44:username
...

Create '/etc/udev/rules.d/10-local-rpi.rules', to set VC device group and permissions:

SUBSYSTEM=="vchiq", GROUP="video", MODE="0660"
SUBSYSTEM=="vc-sm", GROUP="video", MODE="0660"
SUBSYSTEM=="bcm2708_vcio", GROUP="video", MODE="0660"

Then reboot:

$ sudo reboot

Testing (shows a rotating tiger): $ sudo apt install libfreetype6-dev

$ cd /opt/vc/src/hello_pi
$ sudo sh rebuild.sh
$ export LD_LIBRARY_PATH=/opt/vc/lib
$ ./hello_tiger/hello_tiger.bin

BCM2835 c library for Raspberry Pi:

Look for the latest version (http://www.airspayce.com/mikem/bcm2835/)

$ wget http://www.airspayce.com/mikem/bcm2835/bcm2835-$VERSION.tar.gz

$ tar zxvf bcm2835-$VERSION.tar.gz
$ cd bcm2835-1.36
$ ./configure
$ make
$ sudo make check
$ sudo make install

Compile

  • Complie tft_test and fb2cberry with "make"

  • Go to the root folder

    $ cd SW/tft_test $ make $ sudo ./tft_test # shows some test pictures and waits for touch input (if availabe)

    $ cd SW/fb2cberry $ make $ sudo ./fb2cberry & # copys the HDMI output to the framebuffer (around 2% cpu usage), very slow and runs in the background (because of "&")