/r/embeddedlinux

Photograph via snooOG

A place for everything related to Embedded Linux, news, articles, talks etc.

Embedded Linux news, articles, talks... etc.

/r/embeddedlinux

12,981 Subscribers

6

Is i.MX 9 "there yet"?

I started a project in a few years ago and NXP's i.MX 9 line of MPUs were beginning to be released but they were largely unobtainable so I went with a beefy i.MX 8. At this stage, it's way more power than I need and I'd like to move to a much smaller MPU. I was planning on getting the smallest i.MX 8 but the i.MX91 is the smallest cpu they have. I was wondering if I would be better off with the 91 instead of a more mature 8. Thermals are my primary concern so I would assume new is always better, but I just don't know if they are "there yet" since they are still fairly new. A more apples to apples port moving to an 8 could also be a motivator.

3 Comments
2025/01/31
17:47 UTC

3

How to extract vmlinux or vmlinuz from an arm7l embedded install?

Greetings.

I am trying to analyze a crash dump core file from an embedded device. I have System . map for the kernel but no vmlinux or vmlinuz file.

/boot is empty. I tried dd'ing mmcblkboot0 and mmcblkboot1 to files but I can't seem to find anything to unpack. The kernel is a 6.5.11 commit and the device boots from a local block device.

Linux localhost 6.5.11-8ae3366-dirty #1 SMP Fri Nov 10 03:01:40 UTC 2023 armv7l GNU/Linux

Cat of /proc/partitions shows:

major minor #blocks name 31 0 65536 mtdblock0 31 1 896 mtdblock1 31 2 128 mtdblock2 31 3 9216 mtdblock3 31 4 45056 mtdblock4 31 5 10240 mtdblock5 31 6 65536 mtdblock6 31 7 896 mtdblock7 31 8 128 mtdblock8 31 9 9216 mtdblock9 31 10 45056 mtdblock10 31 11 10240 mtdblock11 31 12 32768 mtdblock12 179 0 31080448 mmcblk0 179 8 32256 mmcblk0boot0 179 16 32256 mmcblk0boot1

Here is an output from mount.

dev on /dev type devtmpfs (rw,relatime,size=438236k,nr_inodes=109559,mode=755) sys on /sys type sysfs (rw,relatime) proc on /proc type proc (rw,relatime) tmpfs on /run type tmpfs (rw,nosuid,nodev,mode=755) /dev/mtdblock4 on /run/initramfs/ro type squashfs (ro,relatime,errors=continue) /dev/mtdblock5 on /run/initramfs/rw type jffs2 (rw,relatime) cow on / type overlay (rw,relatime,lowerdir=run/initramfs/ro,upperdir=run/initramfs/rw/cow,workdir=run/initramfs/rw/work) tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev) devpts on /dev/pts type devpts (rw,relatime,gid=5,mode=620,ptmxmode=666) cgroup2 on /sys/fs/cgroup type cgroup2 (rw,nosuid,nodev,noexec,relatime,nsdelegate,memory_recursiveprot) bpf on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime,mode=700) debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime) tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime) tmpfs on /tmp type tmpfs (rw,nosuid,nodev,size=496604k,nr_inodes=1048576) configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime) tmpfs on /var/volatile type tmpfs (rw,relatime) tracefs on /sys/kernel/debug/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)

Given the above, if anyone can tell me how or where I could find or extract a vmlinuz (compressed) or vmlinux file so I can run crash and see why I'm getting core dumps I'd appreciate it. I try running crash with just the core file and System . map file and it doesn't like it, wants vmlinux.

I'm just trying to get to where I can use crash to analyze a core file.

Thanks!

4 Comments
2025/01/31
17:43 UTC

2

What happened to HERE OTA Connect

I've been looking into TUF for updating embedded devices. Alot of resources (e.g. https://github.com/advancedtelematic/meta-updater) point to HERE OTA Connect as the server, but it seems like its out of commission? In addition, it seems like the client (aktualizr) is now in archive (https://github.com/advancedtelematic/aktualizr).

Has the development stopped for this? Is there any forks or similar projects that follows the Uptane framework?

Thanks

0 Comments
2025/01/30
20:08 UTC

3

SeLinux policy in the same git as source code

All the SeLinux policies are in one git and it is pretty hard to catch up with the reason why each allow rule has been applied. What do you think about an idea to bind the policies and related source code in the same git?

2 Comments
2025/01/30
08:12 UTC

7

Is multicodec simple-audio-card possible ?

Hi I've successfully setup a device tree to use an AK4458 DAC as a sound card via simple-audio-card. Now I'd like to add an AK5558 ADC sharing the same SAI peripheral. The idea is to have a single dai cpu (sai1) while having two codecs (ak4458 and ak5558). Is simple-audio-card capable of doing that ? If no, how could I achieve this ?
Thanks !

0 Comments
2025/01/29
14:15 UTC

6

Inconsistent Behavior with GPIO Line Driven by Button

We're attempting to detect interrupts on a GPIO line triggered by rising or falling edges, using a button for testing purposes.

Initially, we configured the gpio-keys in the device tree as follows:

gpio-keys {
    compatible = "gpio-keys";
    #size-cells = <0>;
    button-1 {
        label = "sensor_in";
        linux,code = <KEY_I>;
        interrupt-parent = <&gpiog>;
        interrupts = <5 IRQ_TYPE_EDGE_BOTH>;
        debounce-interval = <5>;
    };
};

However, we observed that it was not detecting state correctly:

root@target:~# evtest /dev/input/event0 
# Press and hold, goes low while still pressed (confirmed line is high on scope)
Event: time 1738094851.907747, type 1 (EV_KEY), code 23 (KEY_I), value 1
Event: time 1738094851.907747, -------------- SYN_REPORT ------------
Event: time 1738094851.912796, type 1 (EV_KEY), code 23 (KEY_I), value 0
Event: time 1738094851.912796, -------------- SYN_REPORT ------------
# Release: goes high and then low
Event: time 1738094853.934165, type 1 (EV_KEY), code 23 (KEY_I), value 1
Event: time 1738094853.934165, -------------- SYN_REPORT ------------
Event: time 1738094853.939207, type 1 (EV_KEY), code 23 (KEY_I), value 0
Event: time 1738094853.939207, -------------- SYN_REPORT ------------

We then tried using gpiomon directly, but it would occasionally "end" on a rising edge after release with rapid button presses:

root@target:~# gpiomon gpiochip6 5
event:  RISING EDGE offset: 5 timestamp: [   11806.403481735]
event: FALLING EDGE offset: 5 timestamp: [   11806.471482465]
event:  RISING EDGE offset: 5 timestamp: [   11806.958207235]
event:  RISING EDGE offset: 5 timestamp: [   11807.029564033]
event:  RISING EDGE offset: 5 timestamp: [   11807.340470570]

The only way we found to reliably get interrupts and an accurate state with rapid button presses is with a combination of gpiomon, wait and gpioget:

#!/bin/sh
while true
do
    # GPIO chip and line to monitor (adjust as needed)
    CHIP="gpiochip6"
    LINE="5"

    # Start gpiomon in the background, wait for the first event
    gpiomon --num-events=1 --silent "${CHIP}" "${LINE}" &

    # Capture the PID of gpiomon to terminate later
    GPIO_PID=$!

    # Wait for gpiomon to detect an edge
    wait "${GPIO_PID}"

    # Read the actual GPIO state
    gpioget "${CHIP}" "${LINE}"
done

Is this a band aid on a larger problem with our build?

What might be causing this behavior?

6 Comments
2025/01/28
20:14 UTC

7

Any DIY Hardware tutorials out there?

I'm looking for something similar for: https://github.com/codecrafters-io/build-your-own-x
Like something with building hardware projects and teaching you how they did it.

It could be any useful general hardware build tutorial not only DIY.

2 Comments
2025/01/28
20:01 UTC

6

What is the cheapest target that can flash yocto image on it?

As a trainer I am usually using beaglebone or Raspberry pi to explain yocto on top of that but wondering if there is any boards are cheaper than that to be handy for students?

6 Comments
2025/01/28
12:11 UTC

2

Building Linux on Arrow DECA Max 10 Evaluation Board

I have an Arrow Max 10 Evaluation board which is based on the 10M50DAF484C6G FPGA. I was following along the instructions for installing linux onto the board: https://www.intel.com/content/dam/support/us/en/programmable/support-resources/fpga-wiki/asset01/deca-linux-tutorial-15-1.pdf and I was able to successfully boot using the image they provided. This is a screen shot of the kernel messages as it boots:

https://preview.redd.it/wjehyed7rnfe1.png?width=911&format=png&auto=webp&s=77cf8dbd162aca0b6dc15e59b034c872f4fdd51d

I then tried moving onto the second part of the tutorial where you can build the kernel and root file system from source. I think I must have either the device tree or kernel mis-configured because it appears to not be able to find any partitions on the flash device.

These are the kernel messages that print out when I attempt to run the kernel I built:

https://preview.redd.it/s8gb476urnfe1.png?width=1390&format=png&auto=webp&s=00bdf5d931db64c178c710c81e458835ad08539e

Can someone give some hints on how I might be able to troubleshoot a problem based on this output? I don't understand why the kernel is unable to locate the root file system. The project files are located here: https://community.intel.com/t5/FPGA-Wiki/DECA/ta-p/735458 under deca_linux_package.zip. Thanks for any help.

2 Comments
2025/01/28
04:15 UTC

5

Seeking Advice: Capturing High-Resolution Waveform Timestamps on Embedded Linux Without HTE

Hey everyone,

We're working on a project that involves decoding some less common protocols. These protocols can be represented as digital waveforms in the KHz range.

We're looking for a way to accurately capture the timing of these signals on an embedded Linux system.

We're inspired by the HTE (Hardware Timestamping Engine) peripheral, which excels at capturing precise timestamps. However, HTE is often not available on embedded processors.

We believe a custom kernel driver could be developed to achieve similar functionality. This driver could utilize timers and DMA to efficiently capture and buffer incoming signal data with high-resolution timestamps.

Before embarking on this development, we'd like to know:

  • Does any existing kernel driver or framework provide similar capabilities for capturing and timestamping waveforms in Linux?

  • Are there any known challenges or limitations in developing such a custom driver?

We're eager to learn from the community's experience and explore any potential alternatives before diving into custom driver development.

Thanks in advance for your insights!

3 Comments
2025/01/24
18:46 UTC

6

how is *Johannes 4GNU Linux*'s device driver series to learn about embedded linux or driver driver in general??

currently learning from his youtube channel to get started into the field of embedded linux.
Wanted to know yours guys opinion..

3 Comments
2025/01/24
05:58 UTC

3

Yocto first project- On Nvidia Orin

Hi is there a "Hello World" like tutorial for Yocto, I have a Nvidia ORIN on which at some point need to customize the linux install, I know this might not be the best beginner friendly board, any tutorial recommendations accepted. Also google search gives out a lot of random things on this and I am absolutely a beginner in doing this.

8 Comments
2025/01/24
00:45 UTC

3

Keyboard access without a tty

Hello, I'm writing an embedded Linux application, that runs as a daemon. I need to support USB keyboard input (keys like arrows, but text input as well). What are my options besides hidraw?

5 Comments
2025/01/23
16:09 UTC

8

I need some guidance for embedded linux career

I'm not sure if this is the right place to make this kind of post. I worked with backend development but I always wanted to work with embedded systems and low-level programming. I often see companies near where I live looking for programmers with experience in Yocto and U-boot, but I don't have the slightest knowledge of how these things work and some jobs require an engineering degree. But the salary is very good and I think it's worth investing in the long term (and high risk). I don't feel happy working with what I do today, many times I'm not doing a good job and I keep prevaricating.

Do you guys think it's worth dedicating myself to studying embedded Linux? Or am I delusional?

8 Comments
2025/01/22
22:43 UTC

3

Version control in embedded linux

My question in general focuses on ways of maintaining the core Linux code for a controller like raspberry pi/Jetson orin. I know that the user space code can be revision controlled on git, it could also be made into Debian packages. But what about layers like kernel, boot, rootfs, bsp. How do I version control it? In raspberry pi using dd to make a backup image of the entire system's current state and uploading it to git might help somewhat but in the long run what do I do so that any developer in my organization can use the source code(probably a bunch of bash instructions with specifications of various rootfs configs) build the Linux image using some sort of CI and use it to package it with developer apps/user apps.

I am open to suggestions, I come from a background where I have used Linux distro to deploy user apps but have never worked on the distro/kernel level

7 Comments
2025/01/22
08:00 UTC

3

LLDP or LSDK Layerscape Secure Boot

Hi Linux Experts!
Has anyone worked with LLDP or LSDK. I am trying to setup secure boot on my LS 1028ARDB board. Kindly help !!!!!!

0 Comments
2025/01/22
04:15 UTC

3

Bring up board from scratch

Can somebody advise robust resources how to bring up board totally from scratch, using only source codes (u-boot, linux kernel,.etc).I am interested especially in that, without usage of pre-built images and so on. Let's it be I.MX8 board

4 Comments
2025/01/22
03:57 UTC

5

Best i.MX6 or i.MX7 Board with the Best Linux Support?

Hi everyone,

I’m looking to start working with i.MX-based devices and was wondering:

Which i.MX6 or i.MX7 board has the best Linux support (BSP, community, and documentation)?

I’ve been working with the MYS-6ULX ( https://www.myirtech.com/list.asp?id=561 ), but I’ve run into issues, including outdated links to kernel sources (e.g., the old CodeAurora link is no longer valid). While I’ve found NXP’s GitHub (https://github.com/nxp-imx/linux-imx), I’d like to avoid boards that require significant manual setup or troubleshooting for basic features.

Any recommendations for boards with solid out-of-the-box support and an active community?

I know about the Raspberry Pi, but I feel like it’s far from the embedded world—it’s great for testing and developing, but I’m looking for something more tailored to real embedded applications.

Thanks in advance!

8 Comments
2025/01/22
00:15 UTC

2

Sudo rm -rf'd my beaglebone black, need help

I am feeling really dumb doing this, i ran the command sudo rm -rf /*, and erased files from emmc, and now my Beaglebone is not booting up, even from SD card. I am trying to get debug access to it but I can't. Please help

8 Comments
2025/01/20
15:02 UTC

2

Embedded ARM Linux board bind mounts - help

I need some assistance in getting my bind mounts to work properly.
I have a small rootfs booted from mmcblk2p1, another rootfs on mmcblk2p2 and would like to make a seperate mmcblk2p3 partition where the user data lives, such as /home/, some configuration files such as NetworkManager connection profiles, etc.

But, I'm having some trouble in getting my programs working properly, such as SSH keys not being generated in the /home/admin folder, which is bind mounted to /data/home/admin.

The idea that I have, is to have a backup OS, and when I switch to the backup OS after a botched update or upgrading to a newer OS version, I would like to have some consistency in the network interface configuration, access to SSH keys, common program configurations across the two OS images on mmcblk2p1 and mmcblk2p2.

Here's the contents of my fstab file:

/dev/mmcblk2p1 / ext4 defaults,noatime 0 1
/dev/mmcblk2p3 /data ext4 defaults,noatime 0 2
/data/home /home none bind 0 0
/data/root /root none bind 0 0
/data/etc/rauc /etc/rauc none bind 0 0
/data/etc/NetworkManager/system-connections /etc/NetworkManager/system-connections none bind 0 0

Any help?

I have tried overlayFS, but that in itself is a hassle.
I just need a simple way to link the common folders to another directory on a seperate partition.

8 Comments
2025/01/20
12:45 UTC

1

An easy way to use a specific usb port as an hid keyboard?

My tv remote broke, and the tv for whatever reason doesn't like other remotes nor phones with ir blaster, it has usb ports, and it can be controlled with key/mouse finely

Now I have one of those cheap khadas sbc, and I wanted to use a specific usb port to simulate keys/mouse, but I don't even know where to start. Or rather from what I've seen I should likely modify the device tree, but I am not too sure.

2 Comments
2025/01/19
18:53 UTC

1

Interface suggestions for data transfer (not ethernet)

I am planning a design around a TI 625x processor. One of the idea is to transfer data between systems (may or may not be TI 625 based) that is relatively "high" speed (10+mbs). I've done work with CANFD and on non-linux systems have seen transfer speeds of up to 12Mb/s. But that is using custom clock tweaks. I doubt I will hit that on linux and I cannot really test it without building custom hardware (I will eventuially, but not at this stage of planning) I've experimented with RS485, but it seems that Linux cannot push this up to 10+Mbs. (one the TI folks told me 3Mbs was the maximum tested under Linux)

I'm looking for suggestions on some other technologies for embedded systems to move data around multiple systems. The reason I want to avoid Ethernet is because not all embedded processors systems have the capability.

7 Comments
2025/01/17
16:41 UTC

15

Looking for a Mentor or Remote Internship in Embedded Linux

Hey everyone,

I’m an embedded dev with a background in bare metal and RTOS, but now I really want to get my hands dirty with Embedded Linux. I learn best by doing, so I’m looking for a mentor or maybe even a remote internship where I can get real tasks, figure things out myself, but also ask for help when I hit a wall.

What I bring to the table:

Experience with C/C++, RTOS (FreeRTOS, Zephyr, etc.), and bare-metal development Some low-level work, but not much hands-on experience with Linux yet A strong willingness to learn and break things (and then fix them) What I’m looking for:

Practical tasks in Embedded Linux (drivers, kernel modules, BSPs, Yocto, build systems—you name it) Some guidance when I’m stuck, but not hand-holding Ideally, a chance to work on real-world stuff If you’re into Embedded Linux and open to mentoring, or if you know of any remote internships where I can get hands-on experience, let’s chat!

Thanks!

1 Comment
2025/01/17
10:42 UTC

5

Need a little guidance with peripheral data

I'm experienced in working with MCU's but now I'm moving into embedded Linux and need some advice on dealing with peripherals. I'm working with an imx8m. I assume the usual way to deal with multiple i2s, i2c, and spi devices that have constant data and timing constraints is by using the built in m7 core. But how is that data passed to the main Linux system running on the A cores? Eg. Capturing data from several i2s devices and keeping them sample accurate to each other to then be processed in Linux, or responding to a spi device that needs immediate handling.

Any advice would be appreciated.

7 Comments
2025/01/12
00:38 UTC

3

Which universities in the US are best for pursuing a masters in embedded systems???

By best, i mean which of them have a curriculum that is focused on the current industry , have a good qs ranking and if it has the potential to attract decent job opportunities.

6 Comments
2025/01/11
18:07 UTC

6

Materials for Embeded Linux

As the title says, I'm looking for the best and most useful materials to learn Embeded Linux and Linux kernel. Thanks

4 Comments
2025/01/10
16:41 UTC

4

[HELP] - Hibernate not working in Yocto

I'm working on a Yocto-based system (Intel architecture) and facing an issue with hibernation. Running:

systemctl hibernate

Throws this error:

Call to Hibernate failed: Not running on EFI and resume= is not set. No available method to resume from hibernation.    

What I've tried:

  1. Added resume=UUID=<swap-uuid> to /boot/EFI/grub.cfg.
  2. Verified swap partition is configured correctly in fstab.
  3. Manually setting /sys/power/resume works, but it doesn’t resume automatically during boot.
  4. The system is running in EFI mode, and Secure Boot/Fast Boot are disabled.

What could I be missing? Any pointers on fixing this would be super helpful. Thanks! 😊

0 Comments
2025/01/06
08:57 UTC

4

New at embedded linux, stm32mp157f-dk2

I try to study embedded linux with stm32mp157f-dk2 board

I got download my image on my board and make dts from stm32cubeide's default board setting

And i compile that in my source's dts folder modified Make file and checked dtb output with decompile

It works with added pwm from cubemx but not working touch

So CONFIG_TOUCHSCREEN_EDT_FT5X06 is being yes in my .config

And it works in default starterpacakge but I changed just dtb with my pwm added

If i echo 0-0038 bind to edt-ft5x06 it works but

I wonder why this builtin module not work with reboot

Thanks

0 Comments
2025/01/06
08:25 UTC

4

MCP23017 Overlay Not Working on Raspberry Pi (Buildroot)

Hello,

I'm having issues with getting an MCP23017 I2C GPIO expander to work on my Raspberry Pi using Buildroot. I am using a custom overlay (mcp23017_remote.dts) that I have compiled into a .dtb file (mcp23017_remote.dtb). However, after booting the system, the MCP23017 isn't initializing, and the dmesg log doesn't show any entries related to the device.

Details: Platform: Raspberry Pi (Basing this on bcm2711 compatibility) Kernel: Custom Buildroot kernel Device Tree Overlay: mcp23017_remote.dtb applied via config.txt GPIO Pins: GPIO 10 (SDA), GPIO 11 (SCL) for I2C; GPIO 18 for interrupt Overlay File: mcp23017_remote.dts (compiled into mcp23017_remote.dtb) What I've Tried: Verified that the .dtb file is located in the /boot/ directory and properly specified in config.txt using dtoverlay=mcp23017_remote. Checked the kernel logs (dmesg | grep -i mcp) but found no references to the MCP23017 or I2C activity. Ensured that GPIO 10 and 11 are available for I2C, and GPIO 18 is free for interrupts. Verified that the MCP23017 overlay is being applied by decompiling the .dtb to .dts using dtc. Checked that the kernel is configured with I2C and GPIO support, as well as GPIO key support. config.txt: Code: Select all

start_file=start.elf fixup_file=fixup.dat kernel=u-boot.bin

gpu_mem_1024=100 enable_uart=1 dtoverlay=miniuart-bt dtoverlay=mcp23017_remote dtparam=krnbt=on

dtoverlay=sharp overscan_left=0 overscan_right=0 overscan_top=0 overscan_bottom=0 framebuffer_width=480 framebuffer_height=800 enable_dpi_lcd=1 display_default_lcd=1 dpi_group=2 dpi_mode=87 dpi_output_format=454678 hdmi_timings=480 0 16 16 24 800 0 4 2 2 0 0 0 60 0 32000000 6 Problem: After booting, the device is not initialized correctly, and the I2C bus isn't appearing as expected. Code: Select all

evtest outputs: No device specified, trying to scan all of /dev/input/event* , indicating that the GPIO button is not being detected. The dmesg log does not show any references to the MCP23017 or I2C initialization. The mcp23017_remote.dtb file seems to be present, but it doesn't appear to be loaded properly. Question: Why is the MCP23017 not initializing or appearing in the logs? Is there anything wrong with my device tree overlay configuration? How can I verify that the overlay is being applied properly? Any suggestions for debugging the device tree or checking if it's being loaded correctly? Any help or suggestions would be appreciated

2 Comments
2025/01/06
00:27 UTC

Back To Top