PAC1934 currents from the shunt values (R72 to R75, Project-Okapi #21)

Đang mở
#13 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
48/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
arduino, cpp
Lĩnh vực
embedded-iot

Hướng nghiên cứu

Read Okapi.cpp around the comments at lines 182 and 237–239 to trace the PAC1934 voltage reads and current logging row. Check how the existing ADS1115 path populates IBeta and ISolar, then compare the PAC1934 setup with the shunt table and DS20005850B. Completion includes choosing snapshot or accumulated energy and verifying the stated zero-load and 1 A readings on a board.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

The PAC1934 (U32) reads its four VBUS voltages today, but not its currents: Okapi.cpp says they wait on the shunt values (line 182, and the comment at lines 237–239). The values are now on the KiCad board (NorthernWidget/Project-Okapi#21, closed as the hardware half of this issue):

Channel Rail Shunt Full scale LSB
1 V_PRIME (alkaline backup) R73, 20 mΩ 5 A 76 µA
2 V_LI (the LiPo cell) R72, 20 mΩ ±5 A 153 µA (bipolar)
3 V_BETA (the LiPo rail) R75, 20 mΩ 5 A 76 µA
4 V_SOLAR_IN R74, 50 mΩ 2 A 31 µA

The current is VSENSE / R, with VSENSE at 100 mV full scale over 16 bits (DS20005850B). Channel 2 sits across the cell's protection FET with SENSE+ on the board side, so it reads charging as positive when set bipolar.

To do:

  1. Read VSENSE per channel and convert with the table above; replace the two comments.
  2. Decide which currents the row carries. It logs IBeta and ISolar today, from the ADS1115 path that the 2024 board does not have.
  3. Snapshot or accumulated energy: the chip can do either, and the choice is open (NW-Status DECISIONS, B7).

Accept on a board, from Project-Okapi/docs/v0.7-pre-build-checks.md step 5: with no load, each channel within the chip's ±0.02 mV offset (±1 mA on 20 mΩ, ±0.4 mA on 50 mΩ); with a known 1 A through a channel, 20 mV on a 20 mΩ shunt and 50 mV on the 50 mΩ one.

🤖 Generated with Claude Code

https://claude.ai/code/session_017F2gr2axqf8HWh46zhsQyY

Ngôn ngữ chính
C++
Star
1
Fork
0
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của NorthernWidget/Okapi_Library

Tất cả issue của NorthernWidget/Okapi_Library

Issue tương tự

Thêm issue về C++

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.