Doton and cili

I had to take a long break but I hope everything is back on track and I can resume GfxLCD in C project.
After such a long time, I have no idea what was the plan and what was the next step ๐Ÿ˜‰ I think we will try and runย Doton on our new driver to see what is wrong.
So this is a good time to name this project, I call itย cili.
(more…)

Advertisements

GFXLCD AND ILIs โ€“ PART 4 images in C

Today we will try and draw images from our C lib. This is the next step with the wrapper. Why? Because we will be sending Python Object to C code and use it there.

It is getting weirder ๐Ÿ™‚

Source @ GitHub

GFXLCD AND ILI9325 C DRIVER โ€“ PART 3
GFXLCD AND ILI9325 C DRIVER โ€“ PART 2
โ€“ย GFXLCD AND ILI9325 C DRIVER โ€“ PART 1

(more…)

GfxLCD and ILI9486 C driver โ€“ part 3

This time we will add an ILI9486 via SPI support to our C code. And while doing it we will refactor structure and clean up the code (or do more mess :P).
I was thinking that C wrapper should be part of GfxLCD package but maybe it is better to create it as a separate module? We will see but this time the code is available @GitHub.

GFXLCD AND ILI9325 C DRIVER โ€“ PART 2
GFXLCD AND ILI9325 C DRIVER โ€“ PART 1

(more…)

GfxLCD and ILI9325 C driver – part 2

This time we will work with drawing functions. Displaying pixel is easy but next, we have a line, circle and arc. I wonder how hard or easy moving functions from Python to C gonna be.

In Python implementation of GfxLCD, we use @property to access width, height or set colours. We need to do same with C implementation. I see two ways, one we will use Python class that would translate property to function call in C or maybe we can use some ability of Python-C wrapper.

GfxLCD and ILI9325 C driver – part 1

(more…)

ILI9325 in Python and C – performance

I have some crazy idea but before we need to do something with GfxLCD performance. Using ILI9325 with Python is a way to slow:

pi@raspberrypi2b:~/workspace/gfxlcd/gfxlcd/demos $ time python3 ili9325.py
real    0m14.528s
user    0m14.080s
sys     0m0.070s

Filling screen with size 240×320 in 14s is not impressive. Let’s see what happens when we move a layer down to C.

(more…)

Doton – cleanup

Some time ago my RPi with running Doton crashed. It was quite a surprise but happens:) Reason was trivial, I moved it and SD card was pressed against the wall and ejected ๐Ÿ™‚ But after a restart, it crashed again but this time with a fatal error. This hits me! We have no way of showing a temperature that is under zero!
This also remembered me that I didn’t do anything with the project for some time. I still have a window manager to redesign and rewrite.
But let’s start low and first clean up a GIT repository by removing submodules and changing a readme.

This project started its life with Daj siฤ™ poznaฤ‡ competition but competition is over. Time to clean it up from additional modules and leave only files that are used.
The fastest method was to manually delete .gitsubmodule and directories ๐Ÿ™‚

(more…)

RC522 reader and configuration – anything is good

I mentioned a magical switch to enable configuration mode. In this post, we will write a configuration module for RFID node. Why not for boilerplate?
Because first, we will analyse the problem and create a tailored solution. After gaining some experience we will rewrite module and create a universal configurator.
What is to configure? An AP credentials and an URL for a server.
(more…)