Skip to content

Commit

Permalink
Remote Board (#8)
Browse files Browse the repository at this point in the history
All checks pass, lets merge this
  • Loading branch information
KenwoodFox authored Oct 19, 2023
1 parent 322146d commit 65d15e1
Show file tree
Hide file tree
Showing 13 changed files with 19,781 additions and 59 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/firmware_workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
name: Firmware Builder

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Cache pip
uses: actions/cache@v2
with:
Expand Down Expand Up @@ -47,7 +47,7 @@ jobs:
name: Delinter

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
- name: Cache pip
uses: actions/cache@v2
with:
Expand Down
95 changes: 38 additions & 57 deletions .github/workflows/hardware_workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,27 +15,33 @@ jobs:
runs-on: ubuntu-latest
name: KiCad Hardware

strategy:
matrix:
variant:
- Segment_Display_Board
- Controller

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
fetch-depth: 0
submodules: true

- uses: INTI-CMNB/KiBot@v2_k6
- uses: INTI-CMNB/KiBot@v2_k7
with:
# Config file
config: Hardware/config.kibot.yaml
# Prefix for output in config file.
dir: _hardwareOutput

# Hardware Files
schema: "Hardware/Segment_Display_Board/Segment_Display_Board.kicad_sch"
board: "Hardware/Segment_Display_Board/Segment_Display_Board.kicad_pcb"
schema: "Hardware/${{ matrix.variant }}/${{ matrix.variant }}.kicad_sch"
board: "Hardware/${{ matrix.variant }}/${{ matrix.variant }}.kicad_pcb"

- name: upload results
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: Board-Hardware
name: ${{ matrix.variant }}
path: _hardwareOutput

- name: Discord notification if failed
Expand All @@ -46,63 +52,28 @@ jobs:
webhook_token: ${{ secrets.WEBHOOK_TOKEN }}
args: "Building new board failed, most likely a DRC check."

# make_docs:
# runs-on: ubuntu-latest
# name: Build Docs
# needs: [KiCad_Hardware]

# steps:
# - name: Setup Python
# uses: actions/setup-python@v2
# with:
# python-version: "3.10"
# architecture: x64

# - uses: actions/checkout@v2
# with:
# fetch-depth: 0

# - run: sudo apt update

# - run: sudo apt install texlive-latex-recommended texlive-latex-extra texlive-pictures pandoc rename latexmk inkscape imagemagick

# - name: Install requirements
# run: pip install -r Docs/requirements.txt

# # Download artifacts from other builds
# - uses: actions/download-artifact@v2
# with:
# name: Board-Hardware
# path: _hardwareOutput

# # Convert svg graphics
# - run: convert -density 300 _hardwareOutput/LC-Mainboard-schematic.svg _hardwareOutput/LC-Mainboard-schematic.png

# - run: cd Docs && make latexpdf

# - run: mv Docs/_build/latex/*.pdf Docs/_build/latex/Board-Manual.pdf

# - uses: actions/upload-artifact@v2
# with:
# name: Board-Manual
# path: Docs/_build/latex/Board-Manual.pdf

dev-publish:
# publish only to devs
runs-on: ubuntu-latest
name: Dev-Publish
# needs: [make_docs, KiCad_Hardware]
needs: [KiCad_Hardware]

strategy:
matrix:
variant:
- Segment_Display_Board
- Controller

steps:
# Download artifacts
# - uses: actions/download-artifact@v2
# - uses: actions/download-artifact@v3
# with:
# name: Board-Manual

- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v3
with:
name: Board-Hardware
name: ${{ matrix.variant }}

# - name: send custom message with args
# uses: appleboy/discord-action@master
Expand All @@ -117,7 +88,8 @@ jobs:
with:
webhook_id: ${{ secrets.WEBHOOK_ID }}
webhook_token: ${{ secrets.WEBHOOK_TOKEN }}
file: "Segment_Display_Board-3D_top.png"
file: "${{ matrix.variant }}-3D_top.png"
args: ${{ matrix.variant }}

publish:
# Only run on tags
Expand All @@ -127,20 +99,26 @@ jobs:
# needs: [make_docs, KiCad_Hardware]
needs: [KiCad_Hardware]

strategy:
matrix:
variant:
- Segment_Display_Board
- Controller

steps:
# Be in our repo
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
fetch-depth: 0

# Download artifacts
# - uses: actions/download-artifact@v2
# - uses: actions/download-artifact@v3
# with:
# name: Board-Manual

- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v3
with:
name: Board-Hardware
name: ${{ matrix.variant }}

- run: mkdir -p _staging/

Expand All @@ -149,8 +127,11 @@ jobs:
- run: cp *.step _staging/

# Copy gerbers
- run: cp PCBWay/*.zip _staging/Board-$(git rev-parse --short HEAD)-PCBWay.zip
- run: cp JLCPCB/*.zip _staging/Board-$(git rev-parse --short HEAD)-JLCPCB.zip
- run: cp PCBWay/*.zip _staging/${{ matrix.variant }}-$(git rev-parse --short HEAD)-PCBWay.zip
- run: cp JLCPCB/*.zip _staging/${{ matrix.variant }}-$(git rev-parse --short HEAD)-JLCPCB.zip

# Copy BOMs
- run: cp *.csv _staging/

- name: Upload Docs to release
uses: svenstaro/upload-release-action@v2
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,6 @@
[submodule "Hardware/Segment_Display_Board/Libraries/Panelization.pretty"]
path = Hardware/Segment_Display_Board/Libraries/Panelization.pretty
url = https://github.com/madworm/Panelization.pretty.git
[submodule "Hardware/Controller/Libraries/kenwoodfox-kicad-libraries"]
path = Hardware/Controller/Libraries/kenwoodfox-kicad-libraries
url = https://github.com/KenwoodFox/kenwoodfox-kicad-libraries.git
Loading

0 comments on commit 65d15e1

Please sign in to comment.