All checks were successful
Component Check / Generate_BOM (push) Successful in 54s
220 lines
7.3 KiB
Markdown
220 lines
7.3 KiB
Markdown
# 🧩 Component Check Workflow
|
|
|
|
This GitHub Actions workflow automates the validation of your Bill of Materials (BOM) on every pull request. It generates the BOM from a supported ECAD project file, displays a colorized preview, validates parts, and comments the results back to the PR.
|
|
|
|
```mermaid
|
|
flowchart LR
|
|
A[PCB Project Files] --> B[Generate BOM]
|
|
B --> C[Check BOM Attributes]
|
|
C --> D[Post Component Review Comment<br/>in Design Review]
|
|
|
|
style A fill:#0F375F,color:#FDFDFD,stroke:#0B1F31
|
|
style B fill:#00915B,color:#FDFDFD,stroke:#0B1F31
|
|
style C fill:#F7BD24,color:#0B1F31,stroke:#0B1F31
|
|
style D fill:#EFE9DA,color:#0B1F31,stroke:#0B1F31
|
|
```
|
|
|
|
|
|
|
|
---
|
|
|
|
## 🔧 Workflow Overview
|
|
|
|
**Trigger:**
|
|
This workflow runs automatically on every `pull_request`.
|
|
|
|
**Path:**
|
|
`.allspice/workflows/component-check-demo.yml`
|
|
|
|
---
|
|
|
|
## 🛠️ Steps Performed
|
|
|
|
### 1. ✅ Checkout Repo
|
|
Fetches the repository source code.
|
|
|
|
```yaml
|
|
- uses: actions/checkout@v3
|
|
````
|
|
|
|
---
|
|
|
|
### 2. 📚 Check Out Pretty-Print Utility
|
|
|
|
Clones the reusable colorized print module.
|
|
|
|
```yaml
|
|
- run: git clone https://hub.allspice.io/Actions/pretty-print .allspice/pretty-print
|
|
```
|
|
|
|
---
|
|
|
|
### 3. 🏗️ Generate BOM
|
|
|
|
Uses the [AllSpice `generate-bom`](https://hub.allspice.io/Actions/generate-bom) action to extract BOM data from an ECAD design file.
|
|
|
|
```yaml
|
|
- uses: https://hub.allspice.io/Actions/generate-bom@v0.5
|
|
```
|
|
|
|
**Inputs:**
|
|
|
|
| Input | Value |
|
|
| ------------------ | ---------------------------------------- |
|
|
| `source_path` | `design/BeagleY-AI_SCH_Rev A_240426.DSN` |
|
|
| `columns` | `.allspice/columns.yml` |
|
|
| `output_file_name` | `bom.csv` |
|
|
| `group_by` | `Part Number` |
|
|
|
|
---
|
|
|
|
### 4. 🖨️ Display BOM in Terminal
|
|
|
|
Runs the `display_bom.py` script to show a formatted and colorized BOM table in the Actions logs.
|
|
|
|
```yaml
|
|
- run: python3 .allspice/pretty-print/display_bom.py bom.csv
|
|
```
|
|
|
|
---
|
|
|
|
### 5. 🗃️ Upload BOM Artifact
|
|
|
|
Makes the raw `bom.csv` downloadable via the GitHub Actions UI.
|
|
|
|
```yaml
|
|
- uses: actions/upload-artifact@v3
|
|
```
|
|
|
|
---
|
|
|
|
### 6. 🐍 Set Up Python & Install Dependencies
|
|
|
|
Installs Python 3.11 and required libraries (`jinja2`, `py-allspice`).
|
|
|
|
```yaml
|
|
- uses: actions/setup-python@v5
|
|
- run: pip install jinja2 py-allspice
|
|
```
|
|
|
|
---
|
|
|
|
### 7. 🔍 Component Validation
|
|
|
|
Runs custom BOM validation logic.
|
|
|
|
```yaml
|
|
- run: .allspice/component_validation.py ./bom.csv
|
|
```
|
|
|
|
---
|
|
|
|
### 8. 💬 Comment Results on PR
|
|
|
|
Posts a markdown summary report as an AllSpice Design Review comment.
|
|
|
|
```yaml
|
|
- run: .allspice/review_comment.py ...
|
|
```
|
|
|
|
---
|
|
|
|
## 📁 Required Files
|
|
|
|
Ensure your repo includes the following:
|
|
|
|
| Path | Purpose |
|
|
| ----------------------------------- | ----------------------------------- |
|
|
| `.allspice/columns.yml` | Defines column mapping for BOM gen |
|
|
| `.allspice/component_validation.py` | Custom component validation logic |
|
|
| `.allspice/review_comment.py` | Posts validation results as comment |
|
|
| `.allspice/pretty-print/` | Cloned color-printing utility |
|
|
|
|
---
|
|
|
|
## 📌 Notes
|
|
|
|
* Additional Python dependencies can be added via a `requirements.txt`.
|
|
|
|
---
|
|
|
|
## 📸 Example Output
|
|
|
|
```text
|
|
MPN Manufacturer Quantity Designator
|
|
---------------------------------------------------------------------
|
|
GRM0335C1E150JA01D Murata 2 C17, C16
|
|
DMG1012T Diodes Inc. 1 Q1
|
|
690-005-298-486 EDAC 1 J1
|
|
...
|
|
```
|
|
|
|
---
|
|
|
|
## 💬 Questions?
|
|
|
|
Reach out to the AllSpice team or open an issue in your repository for support.
|
|
|
|
```
|
|
|
|
---
|
|
|
|
Let me know if you'd like this README to include:
|
|
- Screenshots of output in GitHub Actions
|
|
- Instructions for running locally
|
|
- A section on customizing the validation script
|
|
```
|
|
|
|
|
|
|
|
## BeagleY-AI
|
|
BeagleY®-AI is a powerful 64-bit quad core single board computer with GPU, DSP, and vision/deep learning accelerator.
|
|
|
|
| Front | Back |
|
|
| :-------------------------: | :-------------------------: |
|
|
| <img src="images/beagley-ai-board-front.webp" alt="drawing" width="740"/> | <img src="images/beagley-ai-board-back.webp" alt="drawing" width="740"/>|
|
|
|
|
OSHW Certification: https://certification.oshwa.org/us002616.html
|
|
|
|
Features and purchase information at https://beagley-ai.org
|
|
|
|
## Features
|
|
|
|
| Feature | Description |
|
|
|-----------------------|------------------------------------------------------------------------------------------------------------|
|
|
| Processor | TI AM67 with Quad core 64-bit Arm® Cortex®-A53, GPU, DSP, and vision/deep learning accelerators |
|
|
| RAM | 4GB LPDDR4 |
|
|
| Wi-Fi | BeagleBoard BM3301, 802.11ax Wi-Fi |
|
|
| Bluetooth | Bluetooth Low Energy 5.4 (BLE) |
|
|
| USB Ports | 4 x USB 3.0 TypeA ports supporting simultaneous 5Gbps operation, 1 x USB 2.0 TypeC supports USB 2.0 device |
|
|
| Ethernet | Gigabit Ethernet, with PoE+ support (requires separate PoE+ HAT) |
|
|
| Camera/Display | 1 x 4-lane MIPI camera/display transceivers, 1 x 4-lane MIPI camera |
|
|
| Display Output | 1 x HDMI display, 1 x OLDI display |
|
|
| Real-time Clock (RTC) | Supports an external button battery for power failure time retention. it is only populated on EVT samples. |
|
|
| Debug UART | 1 x 3-pin debug UART |
|
|
| Power | 5V/5A DC power via USB-C, with Power Delivery support |
|
|
| Power Button | On/Off included |
|
|
| PCIe Interface | PCI-Express® Gen3 x 1 interface for fast peripherals (requires separate M.2 HAT or other adapter) |
|
|
| Expansion Connector | 40-pin header |
|
|
| Fan connector | 1 x 4-pin fan connector, supports PWM speed control and speed measurement |
|
|
| Storage | microSD card slot, with support for high-speed SDR104 mode |
|
|
| Tag Connect | 1 x JTAG, 1 x Tag Connect for PMIC NVM Programming |
|
|
|
|
## Components location
|
|
|
|
### Front
|
|
|
|

|
|
|
|
|
|
### Back
|
|
|
|

|
|
|
|
## Block diagram
|
|
|
|

|
|
|
|
## Mechanical Drawing
|
|
|
|
 |