Faulty USB ports on 4 different HC4 units

Post Reply
SentianLuke
Posts: 9
Joined: Thu Apr 07, 2022 5:48 pm
languages_spoken: english
ODROIDs: HC2, HC4
Has thanked: 7 times
Been thanked: 1 time
Contact:

Faulty USB ports on 4 different HC4 units

Post by SentianLuke »

I recently started developing a hardware platform with the Odroid HC4. Recently when trying to implement a bootable usb recovery stick I discovered that the USB ports are faulty. I diagnosed the issue using this forum post. Things like keyboards work but any sort of USB flash drive fails to read. The only time the flash drives correctly attach is when I use an externally powered USB hub. I have tested with three seperate USB flash drives. All of them work when plugged into a windows laptop and a raspberry pi but not on the HC4's. This issue is happening across all four HC4's that I have received from hardkernel. The RMA process is not feasible due to our location and the shipping costs. We intend to put hundreds of these devices in the field and this throws a major spanner in the works. If we order more can the USB port be tested before shipping? We can't be sending every unit back as the lead time would be ridiculous. I have emailed hardkernel and they said I should make a forum post for technical advise.

dmesg output when connecting a usb flash drive directly into the Odroid USB (USB fails to read):

Code: Select all

 [Tue Apr  5 13:04:57 2022] usb 1-2: new high-speed USB device number 12 using xhci-hcd
[Tue Apr  5 13:04:57 2022] usb 1-2: New USB device found, idVendor=0781, idProduct=5581
[Tue Apr  5 13:04:57 2022] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[Tue Apr  5 13:04:57 2022] usb 1-2: Product:  SanDisk 3.2Gen1
[Tue Apr  5 13:04:57 2022] usb 1-2: Manufacturer:  USB
[Tue Apr  5 13:04:57 2022] usb 1-2: SerialNumber: 0401b2fffcf4510666665fd29fdd8aaf8ccd4ac28d8831cc7274aa65d10d21793ff500000000000000000000adcb669aff95551881558107b82b7e25
[Tue Apr  5 13:04:57 2022] usb-storage 1-2:1.0: USB Mass Storage device detected
[Tue Apr  5 13:04:57 2022] scsi host2: usb-storage 1-2:1.0
[Tue Apr  5 13:04:58 2022] scsi 2:0:0:0: Direct-Access      USB      SanDisk 3.2Gen1 1.00 PQ: 0 ANSI: 6
[Tue Apr  5 13:04:58 2022] sd 2:0:0:0: Attached scsi generic sg2 type 0
[Tue Apr  5 13:04:58 2022] sd 2:0:0:0: [sdc] 60088320 512-byte logical blocks: (30.8 GB/28.7 GiB)
[Tue Apr  5 13:04:58 2022] sd 2:0:0:0: [sdc] Write Protect is off
[Tue Apr  5 13:04:58 2022] sd 2:0:0:0: [sdc] Mode Sense: 43 00 00 00
[Tue Apr  5 13:04:58 2022] sd 2:0:0:0: [sdc] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[Tue Apr  5 13:04:58 2022] usb 1-2: reset high-speed USB device number 12 using xhci-hcd
[Tue Apr  5 13:05:29 2022] usb 1-2: reset high-speed USB device number 12 using xhci-hcd
[Tue Apr  5 13:06:00 2022] usb 1-2: reset high-speed USB device number 12 using xhci-hcd
[Tue Apr  5 13:06:37 2022] sd 2:0:0:0: Device offlined - not ready after error recovery
[Tue Apr  5 13:06:37 2022] sd 2:0:0:0: [sdc] tag#0 FAILED Result: hostbyte=DID_ABORT driverbyte=DRIVER_OK
[Tue Apr  5 13:06:37 2022] sd 2:0:0:0: [sdc] tag#0 CDB: Read(10) 28 00 00 00 00 00 00 00 08 00
[Tue Apr  5 13:06:37 2022] blk_update_request: I/O error, dev sdc, sector 0
[Tue Apr  5 13:06:37 2022] buffer_io_error: 22 callbacks suppressed
[Tue Apr  5 13:06:37 2022] Buffer I/O error on dev sdc, logical block 0, async page read
[Tue Apr  5 13:06:37 2022] sd 2:0:0:0: rejecting I/O to offline device
[Tue Apr  5 13:06:37 2022] blk_update_request: I/O error, dev sdc, sector 0
[Tue Apr  5 13:06:37 2022] Buffer I/O error on dev sdc, logical block 0, async page read
[Tue Apr  5 13:06:37 2022]  sdc: unable to read partition table
[Tue Apr  5 13:06:37 2022] sd 2:0:0:0: [sdc] Attached SCSI removable disk 
dmesg output when connecting a usb flash drive with an externally powered usb hub (USB reads successfully):

Code: Select all

[Tue Apr  5 12:54:57 2022] usb 1-2.1: new full-speed USB device number 11 using xhci-hcd
[Tue Apr  5 12:54:57 2022] usb 1-2.1: not running at top speed; connect to a high speed hub
[Tue Apr  5 12:54:57 2022] usb 1-2.1: New USB device found, idVendor=0781, idProduct=5581
[Tue Apr  5 12:54:57 2022] usb 1-2.1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[Tue Apr  5 12:54:57 2022] usb 1-2.1: Product:  SanDisk 3.2Gen1
[Tue Apr  5 12:54:57 2022] usb 1-2.1: Manufacturer:  USB
[Tue Apr  5 12:54:57 2022] usb 1-2.1: SerialNumber: 0401b2fffcf4510666665fd29fdd8aaf8ccd4ac28d8831cc7274aa65d10d21793ff500000000000000000000adcb669aff95551881558107b82b7e25
[Tue Apr  5 12:54:57 2022] usb-storage 1-2.1:1.0: USB Mass Storage device detected
[Tue Apr  5 12:54:57 2022] scsi host2: usb-storage 1-2.1:1.0
[Tue Apr  5 12:54:58 2022] scsi 2:0:0:0: Direct-Access      USB      SanDisk 3.2Gen1 1.00 PQ: 0 ANSI: 6
[Tue Apr  5 12:54:58 2022] sd 2:0:0:0: Attached scsi generic sg2 type 0
[Tue Apr  5 12:54:58 2022] sd 2:0:0:0: [sdc] 60088320 512-byte logical blocks: (30.8 GB/28.7 GiB)
[Tue Apr  5 12:54:58 2022] sd 2:0:0:0: [sdc] Write Protect is off
[Tue Apr  5 12:54:58 2022] sd 2:0:0:0: [sdc] Mode Sense: 43 00 00 00
[Tue Apr  5 12:54:58 2022] sd 2:0:0:0: [sdc] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[Tue Apr  5 12:54:58 2022]  sdc:
[Tue Apr  5 12:54:58 2022] sd 2:0:0:0: [sdc] Attached SCSI removable disk
When plugged directly into the usb port the flash drives show up in lsusb but do not show in parted, fdsisk or lsblk.

User avatar
tobetter
Posts: 10968
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 737 times
Been thanked: 1868 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by tobetter »

Could you please share the out of lsusb and lsusb -t?
Also, did you remove the SPI flash memory?
These users thanked the author tobetter for the post:
SentianLuke (Thu Apr 07, 2022 6:47 pm)

SentianLuke
Posts: 9
Joined: Thu Apr 07, 2022 5:48 pm
languages_spoken: english
ODROIDs: HC2, HC4
Has thanked: 7 times
Been thanked: 1 time
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by SentianLuke »

tobetter wrote:
Thu Apr 07, 2022 6:36 pm
Could you please share the out of lsusb and lsusb -t?
Also, did you remove the SPI flash memory?
Thanks for the quick reply.

Code: Select all

pi@sentian4o:~$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 000: ID 058f:6387 Alcor Micro Corp. Flash Drive
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
pi@sentian4o:~$ lsusb -t
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/2p, 480M
    |__ Port 2: Dev 3, If 0, Class=Mass Storage, Driver=usb-storage, 480M
I have not removed the SPI flash. Petitboot runs fine when no drive is plugged in. NOTE: The pi user is just what we use as default on the HC4's

User avatar
tobetter
Posts: 10968
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 737 times
Been thanked: 1868 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by tobetter »

SentianLuke wrote:
Thu Apr 07, 2022 6:42 pm
tobetter wrote:
Thu Apr 07, 2022 6:36 pm
Could you please share the out of lsusb and lsusb -t?
Also, did you remove the SPI flash memory?
Thanks for the quick reply.

Code: Select all

pi@sentian4o:~$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 000: ID 058f:6387 Alcor Micro Corp. Flash Drive
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
pi@sentian4o:~$ lsusb -t
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/2p, 480M
    |__ Port 2: Dev 3, If 0, Class=Mass Storage, Driver=usb-storage, 480M
I have not removed the SPI flash. Petitboot runs fine when no drive is plugged in. NOTE: The pi user is just what we use as default on the HC4's
I've looked for the USB storage if we need a driver patch, but no luck.

What I am concerning is if your USB stick is not compatible with the ODROID USB port. We had 1-2 Sandisk USB storage and a couple of random storage which are not compatible, incomplete connection or slow data throughput happened with them. Unfortunately, we didn't find out the solutions even after consulting with SoC vendor.

Meanwhile, what I found with the VID/PID of your USB storage is that it's been added to the Linux driver and this file lists the devices with special attention according to this.
https://github.com/hardkernel/linux/blo ... evs.h#L783

Would you please test with another USB storage product to judge if it's really a USB host port issue?

User avatar
mctom
Posts: 2253
Joined: Wed Nov 11, 2020 4:44 am
languages_spoken: english, polish
ODROIDs: OGA, XU4, C2, M1, H3+, SP3, Vu8M
Location: Gdansk, Poland
Has thanked: 279 times
Been thanked: 368 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by mctom »

SentianLuke wrote:
Thu Apr 07, 2022 6:10 pm
Things like keyboards work but any sort of USB flash drive fails to read. The only time the flash drives correctly attach is when I use an externally powered USB hub.
I wonder if that's the U23 chip problem as well - appears to be still working, but only with low current?
Punk ain't no religious cult, punk means thinking for yourself!

Maintainer of PiStackMon

SentianLuke
Posts: 9
Joined: Thu Apr 07, 2022 5:48 pm
languages_spoken: english
ODROIDs: HC2, HC4
Has thanked: 7 times
Been thanked: 1 time
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by SentianLuke »

Here are two other flash drives I tested this morning with the same problem. I want to reiterate that no single flash drive has worked on any of the HC4's. I have posted the outputs of the two I had at the office but I have tested more and none of them work.

Verbatim USB 2.0 flash drive:

dmesg:

Code: Select all

[Fri Apr  8 09:15:41 2022] usb 1-2: new high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:41 2022] usb 1-2: New USB device found, idVendor=18a5, idProduct=0302
[Fri Apr  8 09:15:41 2022] usb 1-2: New USB device strings: Mfr=1, Product=2, SerialNumber=3
[Fri Apr  8 09:15:41 2022] usb 1-2: Product: STORE N GO
[Fri Apr  8 09:15:41 2022] usb 1-2: Manufacturer: Verbatim
[Fri Apr  8 09:15:41 2022] usb 1-2: SerialNumber: 9000818F25155991
[Fri Apr  8 09:15:41 2022] usb-storage 1-2:1.0: USB Mass Storage device detected
[Fri Apr  8 09:15:41 2022] scsi host2: usb-storage 1-2:1.0
[Fri Apr  8 09:15:42 2022] scsi 2:0:0:0: Direct-Access     Verbatim STORE N GO       PMAP PQ: 0 ANSI: 2
[Fri Apr  8 09:15:42 2022] sd 2:0:0:0: Attached scsi generic sg2 type 0
[Fri Apr  8 09:15:44 2022] sd 2:0:0:0: [sdc] 60626944 512-byte logical blocks: (31.0 GB/28.9 GiB)
[Fri Apr  8 09:15:44 2022] sd 2:0:0:0: [sdc] Write Protect is off
[Fri Apr  8 09:15:44 2022] sd 2:0:0:0: [sdc] Mode Sense: 23 00 00 00
[Fri Apr  8 09:15:44 2022] sd 2:0:0:0: [sdc] No Caching mode page found
[Fri Apr  8 09:15:44 2022] sd 2:0:0:0: [sdc] Assuming drive cache: write through
[Fri Apr  8 09:15:44 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:45 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:45 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:45 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:45 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:46 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:46 2022] sd 2:0:0:0: [sdc] tag#0 FAILED Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[Fri Apr  8 09:15:46 2022] sd 2:0:0:0: [sdc] tag#0 CDB: Read(10) 28 00 00 00 00 00 00 00 08 00
[Fri Apr  8 09:15:46 2022] blk_update_request: I/O error, dev sdc, sector 0
[Fri Apr  8 09:15:46 2022] Buffer I/O error on dev sdc, logical block 0, async page read
[Fri Apr  8 09:15:46 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:46 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:47 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:47 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:47 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:47 2022] usb 1-2: reset high-speed USB device number 2 using xhci-hcd
[Fri Apr  8 09:15:48 2022] sd 2:0:0:0: [sdc] tag#0 FAILED Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
[Fri Apr  8 09:15:48 2022] sd 2:0:0:0: [sdc] tag#0 CDB: Read(10) 28 00 00 00 00 00 00 00 08 00
[Fri Apr  8 09:15:48 2022] blk_update_request: I/O error, dev sdc, sector 0
[Fri Apr  8 09:15:48 2022] Buffer I/O error on dev sdc, logical block 0, async page read
[Fri Apr  8 09:15:48 2022]  sdc: unable to read partition table
lsusb:

Code: Select all

pi@sentian4o:~$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 18a5:0302 Verbatim, Ltd Flash Drive
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
pi@sentian4o:~$ lsusb -t
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/2p, 480M
    |__ Port 2: Dev 3, If 0, Class=Mass Storage, Driver=usb-storage, 480M
Sandisk USB 3.2 flash drive:

dmesg:

Code: Select all

[Fri Apr  8 09:31:04 2022] usb-storage 1-2:1.0: USB Mass Storage device detected
[Fri Apr  8 09:31:04 2022] scsi host1: usb-storage 1-2:1.0
[Fri Apr  8 09:31:05 2022] scsi 1:0:0:0: Direct-Access      USB      SanDisk 3.2Gen1 1.00 PQ: 0 ANSI: 6
[Fri Apr  8 09:31:05 2022] sd 1:0:0:0: Attached scsi generic sg1 type 0
[Fri Apr  8 09:31:05 2022] sd 1:0:0:0: [sdb] 60088320 512-byte logical blocks: (30.8 GB/28.7 GiB)
[Fri Apr  8 09:31:05 2022] sd 1:0:0:0: [sdb] Write Protect is off
[Fri Apr  8 09:31:05 2022] sd 1:0:0:0: [sdb] Mode Sense: 43 00 00 00
[Fri Apr  8 09:31:05 2022] sd 1:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[Fri Apr  8 09:31:05 2022] usb 1-2: reset high-speed USB device number 4 using xhci-hcd
[Fri Apr  8 09:31:36 2022] usb 1-2: reset high-speed USB device number 4 using xhci-hcd
[Fri Apr  8 09:32:45 2022] usb 1-2: reset high-speed USB device number 4 using xhci-hcd
[Fri Apr  8 09:32:45 2022] sd 1:0:0:0: Device offlined - not ready after error recovery
[Fri Apr  8 09:32:45 2022] sd 1:0:0:0: [sdb] tag#0 FAILED Result: hostbyte=DID_ABORT driverbyte=DRIVER_OK
[Fri Apr  8 09:32:45 2022] sd 1:0:0:0: [sdb] tag#0 CDB: Read(10) 28 00 00 00 00 00 00 00 08 00
[Fri Apr  8 09:32:45 2022] blk_update_request: I/O error, dev sdb, sector 0
[Fri Apr  8 09:32:45 2022] Buffer I/O error on dev sdb, logical block 0, async page read
[Fri Apr  8 09:32:45 2022] sd 1:0:0:0: rejecting I/O to offline device
[Fri Apr  8 09:32:45 2022] blk_update_request: I/O error, dev sdb, sector 0
[Fri Apr  8 09:32:45 2022] Buffer I/O error on dev sdb, logical block 0, async page read
[Fri Apr  8 09:32:45 2022]  sdb: unable to read partition table
[Fri Apr  8 09:32:45 2022] sd 1:0:0:0: [sdb] Attached SCSI removable disk
lsusb:

Code: Select all

pi@sentian4o:~$ lsusb
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 004: ID 0781:5581 SanDisk Corp. Ultra
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
pi@sentian4o:~$ lsusb -t
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/2p, 480M
    |__ Port 2: Dev 4, If 0, Class=Mass Storage, Driver=usb-storage, 480M

User avatar
mctom
Posts: 2253
Joined: Wed Nov 11, 2020 4:44 am
languages_spoken: english, polish
ODROIDs: OGA, XU4, C2, M1, H3+, SP3, Vu8M
Location: Gdansk, Poland
Has thanked: 279 times
Been thanked: 368 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by mctom »

Could you measure voltage on C256 (Or Vbus on USB port) when the USB port works okay and misbehaves?
A oscilloscope measurement would be perfect if you have access to it, to see if there are any deviations from 5V.
These users thanked the author mctom for the post:
SentianLuke (Fri Apr 08, 2022 5:18 pm)
Punk ain't no religious cult, punk means thinking for yourself!

Maintainer of PiStackMon

SentianLuke
Posts: 9
Joined: Thu Apr 07, 2022 5:48 pm
languages_spoken: english
ODROIDs: HC2, HC4
Has thanked: 7 times
Been thanked: 1 time
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by SentianLuke »

mctom wrote:
Fri Apr 08, 2022 4:55 pm
Could you measure voltage on C256 (Or Vbus on USB port) when the USB port works okay and misbehaves?
A oscilloscope measurement would be perfect if you have access to it, to see if there are any deviations from 5V.
Unfortunately I will only have access to an oscilloscope on Monday. Voltage readings across C256 remain at 5.27V when a usb flash drive is plugged in and not working, when an externally powered hub with a flash drive in it is plugged in and working and when there is nothing in the usb port.

User avatar
odroid
Site Admin
Posts: 40074
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English, Korean
ODROIDs: ODROID
Has thanked: 2841 times
Been thanked: 1602 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by odroid »

We've shipped over several thousand of HC4 units. But we've not seen those USB storage enumeration issue so far.
According to your "dmesg" output, the host controller and power look okay while there was a couple of errors while mounting the mass storage device.

Because that is very weird issue and we have to investigate why all of your four HC4 units have the strange issue.
Our sales team will contact you to help you directly early next week because here Korea is already Friday evening.
Please let me know where / when you purchased the HC4 units.
These users thanked the author odroid for the post:
SentianLuke (Fri Apr 08, 2022 5:45 pm)

SentianLuke
Posts: 9
Joined: Thu Apr 07, 2022 5:48 pm
languages_spoken: english
ODROIDs: HC2, HC4
Has thanked: 7 times
Been thanked: 1 time
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by SentianLuke »

odroid wrote:
Fri Apr 08, 2022 5:29 pm
We've shipped over several thousand of HC4 units. But we've not seen those USB storage enumeration issue so far.
According to your "dmesg" output, the host controller and power look okay while there was a couple of errors while mounting the mass storage device.

Because that is very weird issue and we have to investigate why all of your four HC4 units have the strange issue.
Our sales team will contact you to help you directly early next week because here Korea is already Friday evening.
Please let me know where / when you purchased the HC4 units.
Thanks for all the help and the quick responses. I ordered them directly from Hardkernel. Order dates and order numbers below:
Order #HK2202078437 was placed on 2022/02/07
Order #HK2202162165 was placed on 2022/02/16

User avatar
tobetter
Posts: 10968
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 737 times
Been thanked: 1868 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by tobetter »

@SentianLuke, can you please share the photo of Sandisk USB 3.2 flash disk which you've tested today?
Also, I wonder if you can share the product page of Alcor flash memory in the first post.

SentianLuke
Posts: 9
Joined: Thu Apr 07, 2022 5:48 pm
languages_spoken: english
ODROIDs: HC2, HC4
Has thanked: 7 times
Been thanked: 1 time
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by SentianLuke »

I don't have the Alcor flash disk on hand at the moment. Here is the Sandisk:

Image

Image
These users thanked the author SentianLuke for the post:
tobetter (Fri Apr 08, 2022 6:53 pm)

User avatar
odroid
Site Admin
Posts: 40074
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English, Korean
ODROIDs: ODROID
Has thanked: 2841 times
Been thanked: 1602 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by odroid »

Our sales division might contact you to collected the HC4 units for our investigation.
When our contracted couriers visit you, please send us a couple of problematic(?) USB flash devices together for our testing.
We will send back all the items to you once we finish the test process.
These users thanked the author odroid for the post:
SentianLuke (Mon Apr 11, 2022 11:41 pm)

User avatar
tobetter
Posts: 10968
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 737 times
Been thanked: 1868 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by tobetter »

@SentianLuke, I am helping to debug your ODROID-HC4 with USB sticks, please help me to understand your situation correctly.

1. USB issue happens when you want to run your recovery software installed on a USB stick and boot from Petitboot.
2. USB does not have an issue at all when your software is operating on ODROID-HC4 and its OS is installed SD or HDD/SSD.
3. What's the kernel version running in your recovery software and product software?
4. Do you use a multimedia feature or just good enough to run a Linux system that runs certain services?

Also, I wonder if there is a method or a possibility to launch your recovery software through a network if it's supported?

Thank you.

User avatar
neal
Posts: 294
Joined: Fri Apr 14, 2017 10:02 am
languages_spoken: Korean, English
Has thanked: 16 times
Been thanked: 28 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by neal »

Hi @SentianLuke,

I have tested your four HC4 and reproduced the same issues you explained.
It doesn't work with the released image which is using kernel 4.9. I think that there are some compatibility issues.
On the other hand, there's figured out that when I use the higher version kernel 5.10, It works properly.
So, I recommend you install the 3rd party OS to use USB storage via USB2.0 Host on HC4.
https://wiki.odroid.com/odroid-hc4/trou ... nown_issue
Thanks
These users thanked the author neal for the post:
SentianLuke (Thu Jun 09, 2022 5:38 pm)

SentianLuke
Posts: 9
Joined: Thu Apr 07, 2022 5:48 pm
languages_spoken: english
ODROIDs: HC2, HC4
Has thanked: 7 times
Been thanked: 1 time
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by SentianLuke »

neal wrote:
Fri Apr 22, 2022 12:16 pm
Hi @SentianLuke,

I have tested your four HC4 and reproduced the same issues you explained.
It doesn't work with the released image which is using kernel 4.9. I think that there are some compatibility issues.
On the other hand, there's figured out that when I use the higher version kernel 5.10, It works properly.
So, I recommend you install the 3rd party OS to use USB storage via USB2.0 Host on HC4.
https://wiki.odroid.com/odroid-hc4/trou ... nown_issue
Thanks
Hi @neal,

Thanks for finding the issue. It's unfortunately far to late for us to switch OS at this point. When can we expect to get an Odroid Ubuntu image with a newer kernal version?

User avatar
tobetter
Posts: 10968
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 737 times
Been thanked: 1868 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by tobetter »

SentianLuke wrote:
Thu Jun 09, 2022 5:45 pm
neal wrote:
Fri Apr 22, 2022 12:16 pm
Hi @SentianLuke,

I have tested your four HC4 and reproduced the same issues you explained.
It doesn't work with the released image which is using kernel 4.9. I think that there are some compatibility issues.
On the other hand, there's figured out that when I use the higher version kernel 5.10, It works properly.
So, I recommend you install the 3rd party OS to use USB storage via USB2.0 Host on HC4.
https://wiki.odroid.com/odroid-hc4/trou ... nown_issue
Thanks
Hi @neal,

Thanks for finding the issue. It's unfortunately far to late for us to switch OS at this point. When can we expect to get an Odroid Ubuntu image with a newer kernal version?
Can you please let us know when the USB stick is being used?
Does it have an OS image running on it or is it attached while OS is running?
This is why important is that we have two kernel layers, Petitboot and Main OS (Ubuntu). Currently, both OS are based on a 4.9 kernel which has a USB problem. Petitboot won't change the kernel version but Ubuntu could be with another kernel if it works with your application. If the USB stick is attached to Petitboot and being accessed, the problem could not be resolved easily.

SentianLuke
Posts: 9
Joined: Thu Apr 07, 2022 5:48 pm
languages_spoken: english
ODROIDs: HC2, HC4
Has thanked: 7 times
Been thanked: 1 time
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by SentianLuke »

We intended to use the USB stick as a method to flash an SSD (with Our main OS and code on it) if it needed to be replaced by a third party. We initially intended to use an SD card but I couldn't find a way on petit boot to get the SD card to have a higher boot priority. I saw that you could bump a USB boot stick up the boot priority so we went with that. So to answer the question we wanted the USB to to be recognized as a bootable drive, petit boot to then boot up the OS on the USB and then for the OS to flash an SSD mounted in one of the hdd slots. Is there another way to accomplish this?

User avatar
tobetter
Posts: 10968
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 737 times
Been thanked: 1868 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by tobetter »

SentianLuke wrote:
Fri Jun 10, 2022 8:17 pm
We intended to use the USB stick as a method to flash an SSD (with Our main OS and code on it) if it needed to be replaced by a third party. We initially intended to use an SD card but I couldn't find a way on petit boot to get the SD card to have a higher boot priority. I saw that you could bump a USB boot stick up the boot priority so we went with that. So to answer the question we wanted the USB to to be recognized as a bootable drive, petit boot to then boot up the OS on the USB and then for the OS to flash an SSD mounted in one of the hdd slots. Is there another way to accomplish this?
Thanks for the detail. As I mentioned in the previous post, it's not likely possible to make your USB stick to boot from it. If you are fine to flash an OS from SD card to SSD, I would help you to achieve this. I have two idea what you can achieve this as of now, let me introduce you after testing on my end. Here, my question is whether your flash application is a script or an executible binary, and what's the base OS to perform the update. Why I am curious this is to guess the capacity to run the OS with your update program.
These users thanked the author tobetter for the post:
SentianLuke (Fri Jun 10, 2022 10:59 pm)

SentianLuke
Posts: 9
Joined: Thu Apr 07, 2022 5:48 pm
languages_spoken: english
ODROIDs: HC2, HC4
Has thanked: 7 times
Been thanked: 1 time
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by SentianLuke »

Thanks for the help! I was running the latest headless Ubuntu 20.04 HC4 image on the SD. The flash application is a python script. It flashes the drive, hits a few of our API endpoints and also displays the progress and troubleshooting logs on the oled. I've tested the script and it works. The only issue was that you had to unplug the ssd before turning on power for the SD card to boot and then plug it back in before the program ran. I could see also sorts of problems cropping up from that.

User avatar
tobetter
Posts: 10968
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 737 times
Been thanked: 1868 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by tobetter »

SentianLuke wrote:
Fri Jun 10, 2022 10:54 pm
Thanks for the help! I was running the latest headless Ubuntu 20.04 HC4 image on the SD. The flash application is a python script. It flashes the drive, hits a few of our API endpoints and also displays the progress and troubleshooting logs on the oled. I've tested the script and it works. The only issue was that you had to unplug the ssd before turning on power for the SD card to boot and then plug it back in before the program ran. I could see also sorts of problems cropping up from that.
Well noted, let me try to figure out the solution using SD for you next week.

User avatar
tobetter
Posts: 10968
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 737 times
Been thanked: 1868 times
Contact:

Re: Faulty USB ports on 4 different HC4 units

Post by tobetter »

@SentianLuke, let me update you on how your HC4 can boot from an SD card in higher priority in Petitboot but this method will only work with the Petitboot version v2022017 and afterward.

Firstly, download this script as userscript.sh.

Code: Select all

  1 #!/bin/sh
  2 
  3 clear
  4 figlet "UPDATE SCRIPT"
  5 
  6 DISK=$(mount | grep mmcblk1p1 | cut -d' ' -f3)
  7 KERNEL=${DISK}/Image.gz
  8 DTB=${DISK}/amlogic/meson64_odroidhc4.dtb
  9 INITRD=${DISK}/uInitrd
 10 APPEND="root=/dev/mmcblk1p2 rootwait rw console=ttyS0,115200n8 no_console_suspend fsck.repair=yes net.ifnames=0 elevator=noop hdmimode=custombuilt cvbsmode=576cvbs max_freq_a55=1800 maxcpus=4 voutmode=hdmi modeline=1920,1080,148500,67500,60,1920,2008,2052,2200,1080,1084,1089,1125,1,1,1 disablehpd=false cvbscable=0  overscan=100  monitor_onoff=false logo=osd0,loaded hdmitx=cec3f sdrmode=auto enable_wol=0"
 11 
 12 echo DISK=${DISK}
 13 echo KERNEL=${KERNEL}
 14 echo DTB=${DTB}
 15 echo INITRD=${INITRD}
 16 echo APPEND=${APPEND}
 17 
 18 sleep 5
 19 
 20 kexec -l --dtb=$DTB --initrd=$INITRD --append="$APPEND" --no-checks $KERNEL
 21 kexec -e
 
Secondly, replace line 10 with a kernel command line from your update image after booting from the Petitboot, this command line can be captured by a command cat /proc/cmdline.
Thirdly, check out the kernel image, device tree file and ramdisk if they are in the right path on your SD card. If your updating OS image is based on Hardkernel's Ubuntu image and nothing changed by you, there is no need to change it.
Lastly, copy this file to the first partition of your SD card and try to boot from your ODROID-HC4. If everything works, your OS on SD card will boot without showing the Petitboot at all. Removes lines 12-19 when it boots and performs your updating process, they just need to debug the script to see on booting.

I wish this method works for your project/product.

Post Reply

Return to “Hardware and peripherals”

Who is online

Users browsing this forum: No registered users and 4 guests