ShiboSoftwareDev/am69-pi5

A 85×56 mm 10-layer AM69A single-board computer carrier integrates 8 GiB LPDDR4, 32 GB eMMC, Pi-style expansion and multimedia/USB/Ethernet connectors, multi-rail PMIC power, STM32 boot/power control, USB-C PD, SD/fan protection, and HDI-controlled high-speed routing.

Version
0.0.8-engineering-draft-20261107-dqs19
License
unset
Stars
0

Use with the tscircuit CLI

tsci is the tscircuit CLI. Install it with npm install -g tscircuit.

tsci clone ShiboSoftwareDev/am69-pi5  # download the package files into ./am69-pi5
tsci add ShiboSoftwareDev/am69-pi5    # add it to your project as @tsci/ShiboSoftwareDev.am69-pi5

In a cloned or new (tsci init) project: tsci dev starts a local preview, tsci build outputs Circuit JSON, and tsci push publishes to tscircuit.com.

firmware/usb-pd/README.md

# STUSB4500 production programming

The AM69 Pi board uses one fixed5V/5A sink profile. `pd-nvm.py` patches the individual device's NVM dump; it does **not** replace calibration/timing data with a generic40-byte image. Only customer byte26 (PDO1 current/count/data capability) and bits3/4 of byte38 (above5V-only and source-current request) change. Inactive PDO storage is left untouched and the active PDO count is exactly one.

Byte-field encoding is cross-checked with [SparkFun's MIT STUSB4500 library](https://github.com/sparkfun/SparkFun_STUSB4500_Arduino_Library); its license is retained. The FTP command sequence follows [ST's public NVM flasher](https://github.com/usb-c/STUSB4500/blob/55d1109e7ef0cffc2ffef2494095d23306594601/Firmware/Project/Src/USBPD_CUST_NVM_API.c). The programmer erases and restores only sectors3/4. Each I2C/FTP failure rejects the unit, and every request has a bounded timeout.

Use a **fixed, current-limited5V VBUS fixture without PD negotiation** during initial programming. Hold the EC in reset at TP1204 so all power permissions remain low. Connect the fixture I2C adapter's open-drain3.3V SCL/SDA and common ground to TP1600/TP1601/TP1201. Reference the existing AON3.3V rail; do not drive the LDO output at TP1200 from another power supply. A legacy USB-A source can supply5V without offering a higher-voltage PD profile. An unprogrammed STUSB4500 connected to a PD-capable supply may request a higher voltage, so that source is not the initial fixture.

On a Linux fixture host with a supported I2C adapter and `smbus2` installed:

```sh
python3 pd-nvm.py program --bus 1 --backup unit-SERIAL-original.nvm.bin --fixed-5v-fixture
```

The file must not already exist. The script saves the original calibration and derived target, programs once, and compares all40 readback bytes. Preserve both files with the unit's serial number. Remove fixture power, release EC reset, power-cycle on the fixed5V fixture, then run:

```sh
python3 pd-nvm.py verify-live --bus 1
```

This verifies the active profile registers after reset. It does not claim successful negotiation with a particular source. Continue electrical bring-up with a known5V/5A PD source and an e-marked5A cable; check accepted RDO, main/header/fan gating and current consumption. Lower-current fallback, cable detach, hard reset and bus failure must all disable main/header/fan loads. The hardware sink-enable path provides independent detach qualification.

Offline review commands require only Python's standard library:

```sh
python3 pd-nvm.py plan original.nvm.bin target.nvm.bin
python3 pd-nvm.py verify original.nvm.bin readback.nvm.bin
```

The byte encoding passed200 randomized calibration-preservation and idempotence checks. The MCU's PD parser and boot/power policy tests pass ASan/UBSan. No physical device was programmed or measured in this workspace; retain that distinction in assembly records.