Marcus Folkesson

Embedded Linux Artist

Lund Linux Conference 2023

Lund Linux Conference 2023 The conference Lund Linux Conference (LLC) [1] is a "half-open" conference located in Lund. It's a conference with with high quality and I appreciate that the athmosphere is more familiar than at the larger conferences. I've been at the conference a couple of times before and the quality on the talks this year was as good as usual. ( The talks are by the way availalble on Youtube [3]. cover

Encrypted storage on i.MX

Encrypted storage on i.MX Brief Many embedded Linux systems does have some kind of sensitive information on a file storage. It could be private keys, passwords or whatever. It's always a risk that this information could be revealed by an unauthorized person that got their physical hands on the device. The only protection against attackers that who simply bypass the system and access the data storage directly is encryption. cover

Bug in the iMX8MP ECSPI module?

Bug in the iMX8MP ECSPI module? Background I do have a system where I can swap between iMX8M Mini and iMX8M Plus CPU modules on the same carrier board. I did write a a SPI driver for a device on the carrier board. The device is connected to the ECSPI1 (the CPU contains several ECSPI modules) and use the hardware chipselect 0 (SS0). The driver has been used with the iMX8MM CPU module for a while, but as soon I swapped to the iMX8MP it certainly stopped working. cover

Route traffic with NAT

Route traffic with NAT Long time ago I wrota a blog post [1] about how to use NAT to route traffic to your embedded device via your host computer. Back then we were using iptables to achieve it, nowadays nftables is the preferred successor, so it's time for an update. What is NAT anyway? Network Address Translation, or NAT, does map an address space into another by modifying the network address infromation in the IP header for each packet. cover

Use custom EDID in Linux

Use custom EDID in Linux Extended Display Identification Data (EDID) is a metadata format for display devices to describe their capabilities such as resolution, display size, timing, bit depth and update frequency. It's a 128-byte (EDID) or 256-byte (Enhanced-EDID) structure transferred from the display device over the Display Data Channel (DDC) protocol, which is a layer on top of the I2C specification. The EDID is accessible via the I2C address 0x50 and can usually be read even if the display is turned off, which is quite nice. cover

Raspberry Pi and QEMU

Raspberry Pi and QEMU What is QEMU? QEMU is a generic and open source machine emulator and visualizer. It emulates full machines (boards) of different architectures and is useful for both application and kernel development. The CPU itself could be fully emulated (together with devices, memories and so on) or work with a hypervisor such as KVM or Xen. If support for your hardware is missing, then it's a fairly easy task to write a stub driver that your application can interface. cover

Crosscompile libcamera for RPi

Crosscompile libcamera for RPi Goal The goal is to cross-compile libcamera [1] and libcamera-apps [2] for Raspberry Pi using the latest Raspbian [3] (Bullseye) release. Usually you setup the root filesystem with Buildroot [4] or Yocto [5] and generate a SDK that you can use to compile your application. The Raspbian distribution does not come with a SDK so we have to setup our own. We will use a Raspberry Pi 3b for this. cover

Mounting with systemd and udev

Mounting with systemd and udev Systemd hasn't always been my first choice as init system for embedded system, but I cannot ignore that it has many good and handy things that other init systems don't. At the same time, that is just what I don't like with systemd, it does not follow the "Do one thing and do it well"-philosophy that I like so much. I'm very thorn about it. cover

This website setup

This website setup This post is more for my own good if I have to setup my website once again. Maybe someone find it useful. Tools Hugo I use Hugo [1] to generate my website. Hugo is a fantastic tool for generate static web pages in an flexible way. All pages is written in reStructured Text [2] which is the markup syntax I strongly prefer. Docker The web server [4] and traefik [5] server is running in docker [3] containers. cover

Parsing command line options

Parsing command line options Parsing command line options is something almost every command or applications needs to handle in some way, and there is too many home-made argument parsers out there. As so many programs needs to parse options from the command line, this facility is encapsulated in a standard library function getopt(2). The GNU C library provides an even more sophisticated API for parsing the command line, argp(), and is described in the glibc manual [1].