Skip to content

Commit ca6a80e

Browse files
committed
Merge branch 'main' into develop
2 parents 89898b2 + 866c894 commit ca6a80e

21 files changed

+3888
-376
lines changed

.clang-format

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ Standard: c++17
44
ColumnLimit: 100
55
UseTab: Never
66
IndentWidth: 2
7-
ReflowComments: false
7+
ReflowComments: true
88
AlignConsecutiveBitFields: AcrossEmptyLinesAndComments
99
AlignConsecutiveMacros: AcrossComments
1010
AlignConsecutiveAssignments: AcrossEmptyLines
11-
IndentPPDirectives: AfterHash
11+
IndentPPDirectives: AfterHash

.github/workflows/arduino-ci.yml

Lines changed: 0 additions & 15 deletions
This file was deleted.

.github/workflows/build.yml

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
name: build
2+
3+
on: [pull_request, push]
4+
5+
jobs:
6+
PlatformIO:
7+
runs-on: ubuntu-latest
8+
strategy:
9+
matrix:
10+
example:
11+
- examples/analogRead_Mux/analogRead_Mux.ino
12+
- examples/analogRead_Scan/analogRead_Scan.ino
13+
- examples/analogRead_Scan_Differential/analogRead_Scan_Differential.ino
14+
- examples/analogReadContinuous_Scan/analogReadContinuous_Scan.ino
15+
steps:
16+
- uses: actions/checkout@v2
17+
- name: Cache pip
18+
uses: actions/cache@v2
19+
with:
20+
path: ~/.cache/pip
21+
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
22+
restore-keys: ${{ runner.os }}-pip-
23+
- name: Cache PlatformIO
24+
uses: actions/cache@v2
25+
with:
26+
path: ~/.platformio
27+
key: ${{ runner.os }}-${{ hashFiles('**/lockfiles') }}
28+
- name: Set up Python
29+
uses: actions/setup-python@v2
30+
- name: Install PlatformIO
31+
run: |
32+
python -m pip install --upgrade pip
33+
pip install --upgrade platformio
34+
- name: Run PlatformIO
35+
run: pio ci -c platformio.ini --lib=lib/MCP3x6x
36+
env:
37+
PLATFORMIO_CI_SRC: ${{ matrix.example }}
38+
39+
# ArduinoCI:
40+
# name: ArduinoCI (${{ matrix.sketch-names }})
41+
# runs-on: ubuntu-latest
42+
## env:
43+
## PLATFORM_DEFAULT_URL: ""
44+
# strategy:
45+
# matrix:
46+
# arduino-boards-fqbn:
47+
# - arduino:avr:uno
48+
# - esp8266:esp8266:nodemcuv2
49+
# - samd:samd:metro m0
50+
# sketch-names:
51+
# - examples/analogRead_Mux/analogRead_Mux.ino
52+
# - examples/analogRead_Scan/analogRead_Scan.ino
53+
# - examples/analogRead_ContinuousScan/analogRead_ContinuousScan.ino
54+
# include:
55+
# - arduino-boards-fqbn: arduino:avr:uno
56+
# platform-url: https://arduino.esp8266.com/stable/package_esp8266com_index.json
57+
# - arduino-boards-fqbn: esp8266:esp8266:nodemcuv2
58+
# platform-url: https://arduino.esp8266.com/stable/package_esp8266com_index.json
59+
# - arduino-boards-fqbn: esp32:esp32:esp32 dev
60+
# platform-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
61+
# - arduino-boards-fqbn: avr:avr:metro m0
62+
# platform-url: https://adafruit.github.io/arduino-board-index/package_adafruit_index.json
63+
# - arduino-boards-fqbn: avr:avr:pro micro
64+
# platform-url: https://raw.githubusercontent.com/sparkfun/Arduino_Boards/master/IDE_Board_Manager/package_sparkfun_index.json
65+
# steps:
66+
# - name: Checkout
67+
# uses: actions/checkout@v2
68+
# - name: Compile all examples
69+
# uses: ArminJo/arduino-test-compile@v3
70+
# with:
71+
# arduino-board-fqbn: ${{ matrix.arduino-boards-fqbn }}
72+
## platform-default-url: ${{ env.PLATFORM_DEFAULT_URL }}
73+
# platform-url: ${{ matrix.platform-url }}
74+
# sketch-names: ${{ matrix.sketch-names }}
75+
#

.github/workflows/lint.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: lint
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
reuse:
7+
runs-on: ubuntu-latest
8+
name: REUSE Compliance Check
9+
steps:
10+
- uses: actions/checkout@v3
11+
- name: REUSE Compliance Check
12+
uses: fsfe/reuse-action@v1
13+
14+
Arduino:
15+
name: ${{ matrix.example }}
16+
runs-on: ubuntu-latest
17+
strategy:
18+
matrix:
19+
examples:
20+
- examples/analogRead_Mux/analogRead_Mux.ino
21+
- examples/analogRead_Scan/analogRead_Scan.ino
22+
- examples/analogRead_Scan_Differential/analogRead_Scan_Differential.ino
23+
- examples/analogReadContinuous_Scan/analogReadContinuous_Scan.ino
24+
steps:
25+
- uses: actions/checkout@v3
26+
- uses: arduino/arduino-lint-action@v1
27+
with:
28+
path: ${{ matrix.examples }}
29+
library-manager: update
30+
# compliance: specification

.github/workflows/platformio.yml

Lines changed: 0 additions & 45 deletions
This file was deleted.

.github/workflows/release.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: release
2+
3+
on:
4+
push:
5+
tags:
6+
- "v*"
7+
8+
jobs:
9+
Github:
10+
runs-on: ubuntu-latest
11+
steps:
12+
# release
13+
- uses: "marvinpinto/action-automatic-releases@latest"
14+
with:
15+
repo_token: "${{ secrets.GITHUB_TOKEN }}"
16+
prerelease: false
17+
# Doxygen
18+
- name: Add version to doxyfile
19+
run: echo "PROJECT_NUMBER = $(git describe --tags --abbrev=0 | cut -c2-)" >> Doxyfile
20+
- name: Run Doxygen
21+
uses: mattnotmitt/doxygen-action@v1.9.4
22+
with:
23+
doxyfile-path: 'Doxyfile'
24+
- uses: peaceiris/actions-gh-pages@v3
25+
with:
26+
github_token: ${{ secrets.GITHUB_TOKEN }}
27+
publish_dir: ./docs
28+
29+
PlatformIO:
30+
runs-on: ubuntu-latest
31+
steps:
32+
- uses: bojit/platformio-publish@main
33+
with:
34+
token: ${{ secrets.PLATFORMIO_TOKEN }}

.github/workflows/reuse.yml

Lines changed: 0 additions & 15 deletions
This file was deleted.

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
.pio
22
.vscode/*
3+
docs/*

.pre-commit-config.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# See https://pre-commit.com for more information
2+
# See https://pre-commit.com/hooks.html for more hooks
3+
repos:
4+
- repo: https://github.com/pre-commit/pre-commit-hooks
5+
rev: v4.3.0
6+
hooks:
7+
- id: trailing-whitespace
8+
- id: end-of-file-fixer
9+
- id: check-yaml
10+
# - id: check-added-large-files
11+
- repo: https://github.com/pocc/pre-commit-hooks
12+
rev: v1.3.5
13+
hooks:
14+
- id: clang-format
15+
# - id: clang-tidy
16+
# - id: oclint
17+
# - id: uncrustify
18+
# - id: cppcheck
19+
# - id: cpplint
20+
# - id: include-what-you-use

0 commit comments

Comments
 (0)