Repository navigation
Add portable flight-computer self-test and datasheet-backed checks - #138
Merged
Merged
Conversation
Add bounded probe scheduling, battery validity and heartbeat contracts, five datasheet-backed SPI checks, host tests, CI and component mapping. Hardware adapters and STM32 task integration remain explicit follow-up work.
8 tasks
Remove committed conflict markers while retaining board ID 41, matching the DAQ server configuration. This restores configuration parsing for the failing firmware CI job.
Contributor
|
i will review this tonight! |
inez9
pushed a commit
that referenced
this pull request
Oct 29, 2026
) * feat: add portable flight-computer self-test checks Add bounded probe scheduling, battery validity and heartbeat contracts, five datasheet-backed SPI checks, host tests, CI and component mapping. Hardware adapters and STM32 task integration remain explicit follow-up work. * fix: resolve load-cell PlatformIO configuration conflict Remove committed conflict markers while retaining board ID 41, matching the DAQ server configuration. This restores configuration parsing for the failing firmware CI job.
inez9
pushed a commit
that referenced
this pull request
Nov 3, 2026
) * feat: add portable flight-computer self-test checks Add bounded probe scheduling, battery validity and heartbeat contracts, five datasheet-backed SPI checks, host tests, CI and component mapping. Hardware adapters and STM32 task integration remain explicit follow-up work. * fix: resolve load-cell PlatformIO configuration conflict Remove committed conflict markers while retaining board ID 41, matching the DAQ server configuration. This restores configuration parsing for the failing firmware CI job.
inez9
added a commit
that referenced
this pull request
Nov 3, 2026
* cubemx setup * update pins on cube mx * More changes * Add portable flight-computer self-test and datasheet-backed checks (#138) * feat: add portable flight-computer self-test checks Add bounded probe scheduling, battery validity and heartbeat contracts, five datasheet-backed SPI checks, host tests, CI and component mapping. Hardware adapters and STM32 task integration remain explicit follow-up work. * fix: resolve load-cell PlatformIO configuration conflict Remove committed conflict markers while retaining board ID 41, matching the DAQ server configuration. This restores configuration parsing for the failing firmware CI job. * firmware: match flight-computer .ioc to the rev 1 schematic - Pyro 1: PYRO_1_EN (PC14) is now an output starting low and PYRO_1_PG (PC15) an input, matching the TPS25974 and pyro 2. - ALT_ARM_SET/RESET (PB6/PB7) start high: the optos are active-low, so driving them low at boot armed the altimeter. - Chip selects PD5/PD6/PD7/PE4/PE14 start high. - GPS_RST (PD11) is open-drain and starts released. - SPI1-4: 8-bit frames; SX1262 mode 0 ~8 MHz, W5500 mode 0 ~16 MHz, sensor bus mode 3 ~8 MHz, SD NAND mode 0 250 kHz for init. - UART9 at 38400 (u-blox M10 default). - ADC1 sampling 387.5 cycles for the TLV9004-buffered inputs. - Label PD12/PD13 SPARE_I2C (I2C4 goes to J4, not the GPS). Generated code is not regenerated yet; open in CubeMX and generate. * format.sh: skip CubeMX-generated files in firmware/Core main, freertos and stm32h7xx_* files are regenerated by STM32CubeMX from firmware.ioc in its own style, so clang-formatting them fails again on the next Generate Code. Hand-written self_test* files are still checked. * ci: pin DAQ Playwright E2E job to ubuntu-24.04 ubuntu-latest moved to Ubuntu 26.04 and Playwright 1.59 has no Chromium build for it, so 'npx playwright install chromium' fails before any test runs. Pin until @playwright/test supports 26.04. --------- Co-authored-by: inez9 <inez9@berkeley.edu> Co-authored-by: Pranay Dogra <63373660+pranayD21@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The flight-computer branch initializes peripherals but has no self-test coordinator or device-level health checks. This adds portable C self-test logic and five datasheet-backed SPI checks, with explicit unsupported/unconfigured results for missing integrations.
Changes
Resolve the existing load-cell PlatformIO configuration conflict that blocked firmware CI.
Coordinate bounded attempts, round-robin probes, required/optional results, raw battery sample validity and periodic heartbeat callbacks. Reset starts a fresh test session.
Check ISM330DHCX and H3LIS100DL identity registers, MS5611 calibration PROM CRC, W5500 chip version, and SX1262 status/errors through an injected, bounded SPI transport.
Add host tests and a separate sanitizer CI job. Tests cover exact wire messages, manufacturer CRC vectors, corrupt replies, timeout/error handling, reset and scheduling behavior.
Document component-to-pin mappings, datasheet references, adapter requirements and unresolved hardware questions in
firmware/Core/DEVICE_CHECKS.mdandfirmware/Core/README.md.Validation
git diff --checkpass.b42f7541removes those markers while retaining board ID 41, matching the DAQ configuration. The load-cell firmware now builds locally. Both push and pull-request Firmware CI reruns pass all seven jobs (five firmware builds, native unit tests and sanitized self-test); the large-file check also passes. Successful PR run.Integration limits
This PR is reviewable as portable, host-tested self-test infrastructure. It does not yet run on the STM32. The checkout lacks a complete target build and the hardware transport, ADC and telemetry adapters. Existing generated SPI configuration also needs correction before integration. No STM32 build, hardware timing or board behavior is claimed as verified.
The probes check communication and limited internal status/calibration integrity. They do not prove sensor accuracy, network/RF connectivity or flight readiness. Generated startup settings, state transitions, storage contents and actuator controls are unchanged.
Follow-up questions for Inez: #137. That issue should remain open after this PR merges until the hardware and interface decisions are recorded.