Hello everyone ! You are like me, you have received your Raspberry Pi 4 and you want to directly program the hardware without Linux ? You are in the right place.
The Raspberry Pi 4 has changed since previous versions, essential components no longer work with current programs, such as USB and Videocore :-( Therefore I thought it's an opportunity to start from scratch. You know the famous blank sheet ...
In this post, we will see how to create our very first program. And also how to use the mailbox.
Hello readers, the site has been unavailable for a few days. Sorry.
Everything is restored today. I take this opportunity to tell you that I received my Raspberry Pi 4, and you will have some posts about it.Comments : 2
For information, the RSS feed allows you to be informed quickly of a modification of my site, or the publication of a new article.Comments : 1
Hello everyone. After two months of work (intermittently), here is a new post on Videocore.
In the previous post Videocore : textured cube in rotation, we saw how to program the Videocore to display a cube in 3D. The Videocore was responsible for the display, but the compute of the vertices was done on the ARM cpu side. I optimize the 3D calculation, entrusting this task to Videocore directly. To achieve this, you must use the Videocore in GL mode, which allows the vertex shading.
In this tutorial, I show you how to get a move and rotation of shapes step by step. With first, the filigree shape, then with colors, and textures.
The icing on the cake is the interactive demo, which allows you to test on your Raspberry, and rotate the spaceship yourself with the keyboard. An overview below :
It interests you ? It's over there.
Comments : 9
That's it, I finally managed to make 3D with the Videocore. I made a program that displays a cube with a texture on each side. In addition, it is rotated.
I had to learn some notions of 3D to display the cube in perspective correctly. You can see below a video of the result obtained with my Raspberry Pi.
It interests you ? The tutorial here.Comments : 4
The Raspberry Pi is equipped with a powerful graphics processor Videocore 4. Nothing better to have a rich and fluid graphical interface. But you have to know how to program it ;-)
In this post, I show you how to program it to display three overlapped triangles, as in the screenshot below (done on my Raspberry Pi).
Comments : 1
Quickly when coding the GUI, I realized that a window manager was needed. The number one issue is taking into account the overlap of the windows. I display a window A, and then I display a window B on top: what happens to the part covered ?
Second issue, if I reduce the window B, I have to erase it, so you have to save it somewhere else. Also if there is background processing in this window, this one must be updated (including if it is minimized).
And then we have to restore the area that was covered by window B.
I explain to you how I did : hereComments : 1
Here is a list of components that I intend to develop for Spider-OS. Most of them are indispensable because they are basic components of the system.
This kernel allows the execution of several tasks at the same time. The preemptive kernel gives a CPU time to run, after the time elapses, the process is suspended, and another process is executed. Which gives the illusion of simultaneous execution. The big advantage, too, is that if a process stops responding, the system still keeps the hand. I have already developed a kernel in this sense, but I must see it for the load distribution on several processors.
This module is already created. It allows me to allocate memory space for any program that needs it. It also manages the release, or the reallocation in the event of a change in size.
Read and write a file on the SD card taking into account a hierarchy of directories. I would like to create a new file system, other than FAT32, because this one incorporates many fields not really useful and it is split up. The idea is to be able to write the data rather brutally, with a descriptive field succint. I think I am inspired by the memory allocation module for changing the location of files, in case of change in size.
When the Pi starts, a console appears and allows you to directly type commands in text mode. This module must interpret the commands entered and execute the programs accordingly. At this level, you can also type the instructions of a new programming language, for example to create variables and initialize them with a value.
I created a module that allows you to view and overlay windows. This module works thanks to Neon, which allows a fast copy of the data in memory. The typed text appears in a text box, and you can move the cursor or erase the text.Good news, I no longer exclude the Videocore for the realization of the window manager. I managed to take into account the Z depth. So I will continue the development with the Videocore.
The purpose of this system is to be able to create programs in a structured, easy and powerful language. I think I am inspired by the syntax of a new language that is emerging: Julia. So you have to create a system that analyzes the typed code, to make the transcription in machine language : this is called compilation. Any program will be composed of the code in user language with the associated machine code.
In correlation with the multitask kernel, each program can be executed x times (for example a text editor). For this, a resource reservation module will assign a process number and a memory area for the program instance. A small program should allow to visualize the processes in progress.
Once all these basic modules are in place, we can move to additional modules for home automation:
And now a little logo for Spider-OS. I was inspired by the Raspberry Pi logo.
Comments : 0
I started programming Spider-OS, more than a year ago before this website, and several elements are now realized.
The system runs on Raspberry Pi 2 and Pi 3 (the Neon component is needed).Here is the list of modules made in assembly language ;-) :
One of the many documentations I used for this work : BCM2835-ARM-Peripherals.pdf
This is the documentation on the main component of Raspberry Pi.
Here I am now designing the keypad command interpreter.Comments : 0