I’m unable to see the battery stats in QGC.
I’m using a Pixhawk 5X with the Holybro PM02D power module (using 12s battery) connected to the Power 1 port.
it shows the battery voltage when 6s battery is connected but it doesn’t shows in 12 s battery.
We’ve had exactly the same problem with a Holybro Jetson Pixhawk Baseboard and Pixhawk 6X Pro. Do you have the HV version of PM02d? I believe there is or at least used to be a lower voltage version.
For the fix, I’ve tried a few things but have one more thing Grok suggested I need to try. It seems there is an issue of the 2 power channels on our baseboard overwriting each other. I’ll try and dig that out and post here if I have success.
and i have also enabled the SENS_EN_INA226 & disabled the SENS_EN_INA228 and it shows the voltage but wrong readings as ( 40.96v) but my measured battery voltage is 50.4v
Hi Julian - I dont have the pixhawk with me right now but this is an extract I recorded. I can get the full dmesg readout tomorrow:
“INFO [ina228] Failed to init INA228 on bus 1, but will try again periodically.
ina228 #0 on I2C bus 1 (external) address 0x45
INFO [ina228] Failed to init INA228 on bus 2, but will try again periodically.
ina228 #1 on I2C bus 2 (external) address 0x45”
@DeepanSakkaravarthi@JulianOes further to that, I spent some extensive time with ChatGPT trying to fix this issue. Most of the avenues it took me down were dead ends, but this was the last measure it suggested, which I have not yet had time to try - so herewith in case it helps at all - as I said I haven’t tried it and I’ve no idea if it is a solution!
UPDATE - this didn’t work for me.
Quick, reliable fix (no FW rebuild)
Disable the auto-start param and start a single instance on bus 1 only.
In MAVLink shell (or add to rc.autostart):
param set SENS_EN_INA228 0
ina228 start -b 1 -X # bus 1, external, keep-alive retries
Reboot with the battery plugged in.
You should now see just one success line:
ina228 #0 on I2C bus 1 (external) address 0x45
…and QGC will show the correct voltage/current.
(If you ever use POWER 2, start a second instance with -b 2 instead of enabling the global param.)
Permanent fix
PX4 v1.16 (and current master) changed the INA228 driver so each instance gets a unique battery ID and duplicate probes on a shared bus no longer clobber data. Updating to that version (or a 1.15.5 build that cherry-picks the patch) lets you keep SENS_EN_INA228=1 without manual Shell commands.
@JulianOes here is my full dmesg (note this is jsut battery and Pixhawk - GPS and ESCs all unplugged). Any hints or tips greatly appreciated!
nsh> dmesg
HW arch: PX4_FMU_V6X
HW type: V6X
HW FMUM ID: 0x006
HW BASE ID: 0x100
PX4 git-hash: 99c40407ffd7ac184e2d7b4b293f36f10fe561ef
PX4 version: Release 1.15.4 (17761535)
OS: NuttX
OS version: Release 11.0.0 (184549631)
OS git-hash: 5d74bc138955e6f010a38e0f87f34e9a9019aecc
Build datetime: Mar 20 2025 23:04:15
Build uri: localhost
Build variant: default
Toolchain: GNU GCC, 9.3.1 20200408 (release)
PX4GUID: 0006000000003338393630335101002d003c
MCU: STM32H7[4|5]xxx, rev. V
INFO [param] selected parameter default file /fs/mtd_params
INFO [param] importing from ‘/fs/mtd_params’
INFO [parameters] BSON document size 3005 bytes, decoded 3005 bytes (INT32:62, FLOAT:83)
INFO [param] selected parameter backup file /fs/microsd/parameters_backup.bson
Board architecture defaults: /etc/init.d/rc.board_arch_defaults
Board defaults: /etc/init.d/rc.board_defaults
Loading airframe: /etc/init.d/airframes/6001_hexa_x
INFO [dataman] data manager file ‘/fs/microsd/dataman’ size is 68528 bytes
INFO [px4io] IO FW CRC match
Board sensors: /etc/init.d/rc.board_sensors
INFO [ina228] Failed to init INA228 on bus 1, but will try again periodically.
ina228 #0 on I2C bus 1 (external) address 0x45
INFO [ina228] Failed to init INA228 on bus 2, but will try again periodically.
ina228 #1 on I2C bus 2 (external) address 0x45
INFO [adis16470] Serial Number: 0x3C85, Firmware revision: 0x134 Date: Y 2022 DM 423
adis16470 #0 on SPI bus 3
iim42652 #0 on SPI bus 2 rotation 6
icm45686 #0 on SPI bus 1 rotation 10
bmm150 #0 on I2C bus 4 (external) address 0x10
WARN [SPI_I2C] ist8310: no instance started (no device on bus?)
icp201xx #0 on I2C bus 4 (external) address 0x64
bmp388 #0 on I2C bus 2 (external) address 0x76
WARN [SPI_I2C] ms5611: no instance started (no device on bus?)
WARN [vehicle_angular_velocity] no gyro selected, using sensor_gyro_fifo:0 2818066
ekf2 [553:237]
Board mavlink: /etc/init.d/rc.board_mavlink
Starting Main GPS on /dev/ttyS0
Starting MAVLink on /dev/ttyS6
INFO [mavlink] mode: Normal, data rate: 1200 B/s on /dev/ttyS6 @ 57600B
Starting MAVLink on ethernet
INFO [mavlink] mode: Normal, data rate: 100000 B/s on udp port 14550 remote port 14550
Conflicting config for /dev/ttyS6
INFO [cdcacm_autostart] Starting CDC/ACM autostart
WARN [mavlink] no broadcasting address found
INFO [logger] logger started (mode=all)
INFO [uavcan] health_and_arming_checks] Preflight Fail: Yaw estimate error
INFO [mavlink] using network interface eth0, IP: 192.168.0.3
INFO [mavlink] with netmask: 255.255.255.0
INFO [mavlink] and broadcast IP: 192.168.0.255
INFO [mavlink] Starting mavlink shell
Yes, I have the INA228 which I think is withing the Holybro PM02D. I’ve also replaced the PM02D with a new one in case that had failed. Possibly damage on my baseboard? It is a Holybro Jetson baseboard with Pixhawk 6X Pro. No Jetson yet fitted.