Skip to content

vcgencmd: document pmic_read_adc, fix command heading levels - #4330

Closed
manunicholasjacob wants to merge 1 commit into
raspberrypi:masterfrom
manunicholasjacob:vcgencmd-pmic-read-adc
Closed

manunicholasjacob wants to merge 1 commit into
raspberrypi:masterfrom
manunicholasjacob:vcgencmd-pmic-read-adc

Conversation

@manunicholasjacob

Copy link
Copy Markdown
Contributor

The vcgencmd section is missing pmic_read_adc, although vcgencmd commands lists it on Raspberry Pi 5 and the power supply and overclocking pages already tell readers to run it. This PR:

  • adds a pmic_read_adc [channel] entry with real output and a link to "Power supplies and Raspberry Pi OS"
  • notes that measure_temp pmic also works on Raspberry Pi 5 (the text said Raspberry Pi 4 only)
  • notes that mem_oom and mem_reloc_stats are not available on Raspberry Pi 5 (both return error=1 error_msg="Command not registered", and neither is in vcgencmd commands)
  • changes codec_enabled, mem_oom, mem_reloc_stats and read_ring_osc from ===== to ====, so they no longer render as sub-sections of get_mem

All outputs were captured on a Raspberry Pi 5 Model B Rev 1.0, firmware 2025/03/19 cec1d3ae:

  • vcgencmd pmic_read_adc prints 26 lines (12 currents, 14 voltages); vcgencmd pmic_read_adc EXT5V_V prints one line
  • vcgencmd pmic_read_adc bogus prints all 26 channels and exits 0, which is why the entry mentions that an unrecognised name lists every channel
  • vcgencmd measure_temp pmic returns temp=41.6'C (SoC temp=43.3'C)

Build: make on Ubuntu (WSL2) following CONTRIBUTING.md, before and after the change, with no new warnings. In the generated computers/os.html, all 14 commands under vcgencmd are now h4 (before, the last four were h5), and the new cross-link resolves to raspberry-pi.html#power-supplies-and-raspberry-pi-os. scripts/check_line_endings.py passes.

I used an AI assistant (Claude) to help draft this change. I checked every statement against the output from my own Raspberry Pi 5.

Add a pmic_read_adc [channel] entry with output captured on a
Raspberry Pi 5, note that measure_temp pmic also works on Raspberry
Pi 5, and note that mem_oom and mem_reloc_stats are not registered
on Raspberry Pi 5.

codec_enabled, mem_oom, mem_reloc_stats and read_ring_osc used level 5
headings, so they rendered as sub-sections of get_mem. Move them to
level 4 like the other vcgencmd commands.
@stevedavies-rp stevedavies-rp self-assigned this Oct 14, 2026
@stevedavies-rp stevedavies-rp added backlog We'll be getting to it eventually documentation labels Oct 14, 2026
@stevedavies-rp

Copy link
Copy Markdown
Contributor

Thank you for this contribution, Manu. I will talk to the engineers and incorporate it into the main documentation if they approve it.

@stevedavies-rp

Copy link
Copy Markdown
Contributor

Now transferred to our internal repo.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backlog We'll be getting to it eventually documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants