EXOTIC SILICON
“Putting a BSD system in your pocket”
Starting to debug USB issues
WARNING
The information presented on these pages is NOT intended to be followed as a guide to installing OpenBSD on your own Pinephone device, and must not be used for this purpose.
Unlike most SBCs, the Pinephone contains a rechargeable battery intended to power the device. Correct configuration of the charging circuits, including various safety features such as thermal protection will not be enabled by the current OpenBSD kernel as of the time of writing.
Series navigation
THIS IS PART THREE OF SEVEN (3/7) - CHECK OUT THE INDEX
Part 2
Part 4
Website themes
The Exotic Silicon website is available in ten themes, but you haven't chosen one yet!
TESTING VOLTAGES ON THE USB CONNECTOR
Using a USB analyser we can test the voltage present on the power supply pins of the USB-C connector, which might help to diagnose why connected devices are not detected or responding when running OpenBSD.
In the picture above, the Pinephone is actually booted into the MP kernel, which we know crashes during boot. There is no measurable power output from the USB port at all.
The USB analyser passes through the power and data signals, allowing us to daisy chain another USB device and monitor the voltage and current that it draws. With the USB dock connected, we still don't see a voltage reading:
With the dock connected and the mp kernel crashed, we don't measure a voltage on the usb connector.
Further testing using the bsd.sp kernel
With the Pinephone booted into the SP kernel, we can see that the power supply output on the USB-C connector is now measuring at 3.56 volts. This is clearly not in the expected 5 volts range, and would certainly explain why none of the connected devices work.
Zoom image
Running the openbsd single processor kernel, we measure 3.56 volts on the USB connector.
Connecting the USB dock, the voltage is virtually unchanged at 3.54 volts, although the current draw almost doubles.
Zoom image
After connecting the dock, the voltage drops slightly to 3.54 volts, and the current increases to 0.1 amps.
Testing using a Linux kernel
Booting a Linux kernel, we measure no power output with just the analyser connected.
Zoom image
Booted into a Linux kernel, we see no measurable power output with just the analyser connected
However, with the dock connected, we see a power supply output of 5.15 volts, at a current of 0.05 amps, and of course the dock is operational.
Zoom image
Correct voltages were measured with the dock connected and the pinephone booted into a Linux kernel, so we can assume that the previous readings are genuine and not a mis-calibration or fault with the analyser
Interpretation of the results
It seems that the USB controller in the Pinephone is not being correctly initialized by the OpenBSD kernel.
Series navigation
Part 1 - Building the installation media and installing.
Part 2 - Booting the completed installation and initial information gathering.
Part 3 - Starting to debug USB issues.
Part 4 - Investigating errors from sxirsb.
Part 5 - Controlling the LEDs and vibration motor.
Part 6 - PMIC and battery charging.
Part 7 - External keyboard battery.