Raspberry CM4 USB doesn't work

Creating a bug report/issue

I have searched the existing open and closed issues

Required Information

  • DietPi version | v9.8.0
  • Distro version | downloaded 1 week ago
  • Kernel version | can’t login without keyboard
  • Architecture | can’t login keyboard
  • SBC model | Raspberry Pi CM4 Compute Module 4 - 1GB RAM + 8GB eMMC - CM4001008
  • Power supply used | 5V or 12V 3A
  • SD card used | MMC

Steps to reproduce

  1. Connect CM4 IO Board with PC through usb
  2. Put jumper on J2 to disable boot from emmc
  3. Use RPIBOOT and have access of emmc through USB
  4. Use Imager tool to install latest DietPI
  5. Remove jumper
  6. Boot from MMC
  7. USB doesn’t work correctly

Expected behaviour

  • USB devices should working

Actual behaviour

  • USB devices doesn’t work

Extra details

  • Tested od 2 different CM4 modules
  • Tested on Raspberry Pi CM4IO boad
  • Tested on CM4-IO-BASE-A board
  • Raspbian OS works correctly on both boards.

Could you test it with the “RPi234” image from here: Index of /downloads/images/testing

It comes with the new RPi kernel/firmware stack, that RPi OS Bookworm ships with.

Alternatively you can migrate the image with the script mentioned here: https://github.com/MichaIng/DietPi/issues/6676

I have the same issue: installed the official vi for CM4 from the DietPi website. I see the start screen with the “Please hit ” message. However, two different USB-keyboards dont work. Neither LAN nor WLAN are connected, so I have no possibility to get access. Then tried the RPI234, which Michaing was recommending. Same result. Since the device has an eMMC mass storage, I cannot load the image via SD-card. I use the official Raspi Imager SW. When I switch back to the Raspi image, it works.

Any ideas?

I found a solution, in file /boot/config.txt you need to add this line:

dtoverlay=dwc2,dr_mode=host

That’s cool! However, how do I modify this file without having access? Is there a way to add this to the image before flashing it, so the problem is fixed in the first place?

this file is one a vfat partition that can be access on any Windows computer without issue.

Hm, I am not sure I understand the idea. On one hand, I have the DietPi .img file. I load this onto the eMMC with the Raspberry Pi Imager sw. The flash process works fine and after rebooting, I see the start screen, as described in my first post. The problem: the device is totally unaccessible, since the lan i/f is not configured and the usb doesn’t work. So, my only option seems to be the modification of the .img file.

your are not able to use SD card? Even not as temp workaround?

You can use rpiboot once again afrer DietPi flashing to access boot.txt file in vfat partition.