iMX8MP on Mallow Carrier detection problem


I’m trying to use an iMX8MP on a Mallow carrier board, but it seems as if the bootloader doesn’t detect the carrier boar correctly.

As a result I’m not able to use the UserLEDs for a simple HelloWorld :wink:


U-Boot 2022.04-6.5.0+git.28dc906f6107 (Jan 01 1970 - 00:00:00 +0000)

CPU:   i.MX8MP[8] rev1.1 1600 MHz (running at 1200 MHz)
CPU:   Industrial temperature grade (-40C to 105C) at 28C
Reset cause: POR
DRAM:  4 GiB
Core:  89 devices, 23 uclasses, devicetree: separate
WDT:   Started watchdog@30280000 with servicing (60s timeout)
Loading Environment from MMC... OK
In:    serial
Out:   serial
Err:   serial
Model: Toradex 0063 Verdin iMX8M Plus Quad 4GB IT V1.1B
Serial#: 15230479
SEC0:  RNG instantiated
Software summary
Bootloader:               U-Boot
Kernel version:           5.15.129-6.5.0+git.6f8fd49366db #1-TorizonCore SMP PREEMPT Fri Dec 22 11:15:52 UTC 2023
Kernel command line:      root=LABEL=otaroot rootfstype=ext4 quiet logo.nologo vt.global_cursor_default=0 plymouth.ignore-serial-consoles splash fbcon=map:3 ostree=/ostree/boot.1/torizon/fe091cbe7b665ff6d9d5d618cb20c42c90c242fffeaceccf204eacd186b2f597/0
Distro name:              NAME="TorizonCore"
Distro version:           VERSION_ID=6.5.0-build.8
Distro variant:           VARIANT="Docker"
Hostname:                 verdin-imx8mp-15230479

Hardware info
HW model:                 Toradex Verdin iMX8M Plus on Verdin Development Board
Toradex version:          0063 V1.1B
Serial number:            15230479
Processor arch:           aarch64

Hello @TheSealion,

The devicetree is not automatically selected based on the carrier board. By default the module will always boot with the Development Board’s devicetree.

For production, we recommend the use of TorizonCore builder to create images which will use the Mallow device tree by default: TorizonCore Builder Tool - Customizing Torizon OS Images | Toradex Developer Center

For prototyping, you can simply set the “ftdfile” u-boot variable to the correct value:

sudo fw_setenv fdtfile imx8mp-verdin-nonwifi-mallow.dtb

This command can be run directly on Torizon OS, after which a reboot is required.

Best regards,

@bruno.tx Thank you for your help.

With the correct device tree I could now see the LEDs (when using the gpiod container and the command gpioinfo 0)

line   0:  "SODIMM_52" "red:debug-1" output active-high [used]

but is it normal, that I’m not able to set the pin via

# gpioset 2 0=1
gpioset: error setting the GPIO line values: Device or resource busy

Hello @TheSealion,

Yes, this is normal. The Mallow devicetree configures these LEDs to use the LED driver.
Therefore, to toggle them, you need to write to the respective driver interfaces under /sys/class/leds.
For the red:debug-1 example, you can use the following commands to turn it on and off:

echo 1 > /sys/class/leds/red\:debug-1/brightness # turns the LED on
echo 0 > /sys/class/leds/red\:debug-1/brightness # turns the LED off

Best Regards,