Skip to content

Commit 07d724e

Browse files
authored
Merge branch 'master' into dfu-util2
2 parents f680382 + dcc66ab commit 07d724e

File tree

3,230 files changed

+5630151
-4989213
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

3,230 files changed

+5630151
-4989213
lines changed

.editorconfig

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
[*.sh]
2+
# like -i=2
3+
indent_style = space
4+
indent_size = 2
5+
6+
#shell_variant = posix # like -ln=posix
7+
#binary_next_line = true # like -bn
8+
switch_case_indent = true # like -ci
9+
space_redirects = true # like -sr
10+
#keep_padding = true # like -kp

.gitattributes

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# Set the default behavior, in case people don't have core.autocrlf set.
2+
* text=auto
3+
4+
# Explicitly declare text files you want to always be normalized and converted
5+
# to native line endings on checkout.
6+
*.c text
7+
*.cpp text
8+
*.h text
9+
*.s text
10+
*.S text
11+
*.ld text
12+
*.txt text
13+
*.xml text
14+
*.py text
15+
*.md text
16+
*.json text
17+
18+
# Denote all files that are truly binary and should not be modified.
19+
*.png binary
20+
*.jpg binary

.github/ISSUE_TEMPLATE/bug_report.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ assignees: ''
1515
- **Avoid** to submit a GitHub issue for project troubleshooting.
1616

1717
Any questions/feedback/suggestions should be discussed on the [stm32duino forum](http://stm32duino.com):
18-
* questions on the [STM32 Core](http://stm32duino.com/viewforum.php?f=48)
19-
* bugs/enhancements on the [STM core: Bugs and enhancements](http://stm32duino.com/viewforum.php?f=49)
18+
* questions on the [STM32 Core](http://stm32duino.com/viewforum.php?f=35)
19+
* bugs/enhancements on the [STM core: Bugs and enhancements](http://stm32duino.com/viewforum.php?f=38)
2020

2121
When reporting any issue, please try to provide all relevant information:
2222

.github/actions/pio-build/Dockerfile

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# Container image that runs your code
2+
FROM ubuntu:latest
3+
4+
ENV LANG C.UTF-8
5+
ENV LC_ALL C.UTF-8
6+
7+
# Install prerequisites
8+
RUN apt-get --quiet=2 update && apt-get install --quiet=2 --assume-yes git python3 python3-pip wget
9+
10+
# Install PlatformIO
11+
RUN pip3 install --quiet --upgrade platformio
12+
CMD /bin/bash
13+
14+
# Copies your code file from your action repository to the filesystem path `/` of the container
15+
COPY entrypoint.sh /entrypoint.sh
16+
17+
# Code file to execute when the docker container starts up (`entrypoint.sh`)
18+
ENTRYPOINT ["/entrypoint.sh"]

.github/actions/pio-build/README.md

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# PlatformIO build action
2+
3+
This action build thanks PIO.
4+
5+
## Inputs
6+
7+
### `cmsis-version`
8+
9+
The CMSIS version to use. Default `"5.5.1"`.
10+
11+
## Example usage
12+
13+
```yaml
14+
uses: ./.github/actions/pio-build
15+
```

.github/actions/pio-build/action.yml

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# action.yml
2+
name: 'PlatformIO Build'
3+
description: 'Compile using PlatformIO'
4+
inputs:
5+
cmsis-version:
6+
description: 'CMSIS package version to use'
7+
default: '5.5.1'
8+
runs:
9+
using: 'docker'
10+
image: 'Dockerfile'
11+
args:
12+
- ${{ inputs.cmsis-version }}
+29
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
#!/bin/bash
2+
3+
readonly CMSIS_VERSION="$1"
4+
readonly CMSIS_ARCHIVE="CMSIS-${CMSIS_VERSION}.tar.bz2"
5+
6+
# Install the development version of ststm32 platform
7+
platformio platform install "https://github.com/platformio/platform-ststm32.git" || {
8+
exit 1
9+
}
10+
# Prepare framework for CI
11+
python3 -c "import json; import os; fp=open(os.path.expanduser('~/.platformio/platforms/ststm32/platform.json'), 'r+'); data=json.load(fp); data['packages']['framework-arduinoststm32']['version'] = '*'; fp.seek(0); fp.truncate(); json.dump(data, fp); fp.close()" || {
12+
exit 1
13+
}
14+
ln --symbolic "$GITHUB_WORKSPACE" "$HOME/.platformio/packages/framework-arduinoststm32" || {
15+
exit 1
16+
}
17+
# Download and unpack CMSIS package
18+
wget --no-verbose "https://github.com/stm32duino/ArduinoModule-CMSIS/releases/download/$CMSIS_VERSION/$CMSIS_ARCHIVE" || {
19+
exit 1
20+
}
21+
tar --extract --bzip2 --file="$CMSIS_ARCHIVE" || {
22+
exit 1
23+
}
24+
cd "$GITHUB_WORKSPACE/CI/build/" || {
25+
exit 1
26+
}
27+
python3 platformio-builder.py --board=blackpill_f103c8 --board=remram_v1
28+
29+
exit $?
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
name: STM32 Core Continuous Integration
2+
on:
3+
push:
4+
branches:
5+
- master
6+
paths-ignore:
7+
- '*.json'
8+
- '**.md'
9+
- keywords.txt
10+
- CI/**
11+
- '!CI/build/arduino-cli.py'
12+
- '!CI/build/platformio-builder.py'
13+
- tools/**
14+
pull_request:
15+
paths-ignore:
16+
- '*.json'
17+
- '**.md'
18+
- keywords.txt
19+
- CI/**
20+
- '!CI/build/arduino-cli.py'
21+
- '!CI/build/platformio-builder.py'
22+
- tools/**
23+
jobs:
24+
astyle_check:
25+
runs-on: ubuntu-latest
26+
name: AStyle check
27+
steps:
28+
# First of all, clone the repo using the checkout action.
29+
- name: Checkout
30+
uses: actions/checkout@master
31+
32+
- name: Astyle check
33+
id: Astyle
34+
uses: stm32duino/actions/astyle-check@master
35+
with:
36+
astyle-definition: 'CI/astyle/.astylerc'
37+
ignore-path-list: 'CI/astyle/.astyleignore'
38+
39+
# Use the output from the `Astyle` step
40+
- name: Astyle Errors
41+
if: failure()
42+
run: |
43+
cat ${{ steps.Astyle.outputs.astyle-result }}
44+
exit 1
45+
core_build:
46+
runs-on: ubuntu-latest
47+
name: Core compilation
48+
steps:
49+
# First of all, clone the repo using the checkout action.
50+
- name: Checkout
51+
uses: actions/checkout@master
52+
53+
- name: Compilation
54+
id: Compile
55+
uses: stm32duino/actions/compile-examples@master
56+
57+
# Use the output from the `Compile` step
58+
- name: Compilation Errors
59+
if: failure()
60+
run: |
61+
cat ${{ steps.Compile.outputs.compile-result }}
62+
exit 1
63+
pio_build:
64+
runs-on: ubuntu-latest
65+
name: PlatformIO test
66+
steps:
67+
# First of all, clone the repo using the checkout action.
68+
- name: Checkout
69+
uses: actions/checkout@master
70+
71+
- name: PlatformIO
72+
id: Compile
73+
uses: ./.github/actions/pio-build

.gitignore

+32-5
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,36 @@
1-
*.orig
2-
*.swp
3-
.DS_Store
1+
# Specific
42
astyle.out
53
boards.local.txt
64
platform.local.txt
7-
*.code-workspace
8-
.vscode
95
path_config.json
6+
7+
# Backup
8+
*.bak
9+
*.gho
10+
*.ori
11+
*.swp
12+
*.tmp
13+
14+
# macOS
15+
# General
16+
.DS_Store
17+
.AppleDouble
18+
.LSOverride
19+
20+
# Patch
21+
*.orig
22+
*.rej
23+
24+
# Python
25+
# Byte-compiled / optimized / DLL files
26+
__pycache__/
27+
*.py[cod]
28+
*$py.class
29+
30+
# VisualStudioCode
31+
.vscode/*
32+
!.vscode/settings.json
33+
!.vscode/tasks.json
34+
!.vscode/launch.json
35+
!.vscode/extensions.json
36+
*.code-workspace

.travis.yml renamed to .travis.yml.old

+23
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,29 @@ matrix:
3434
else
3535
echo "Coding style check OK";
3636
fi
37+
38+
#
39+
# PlatformIO test
40+
#
41+
- env:
42+
- NAME=PlatformIO
43+
- CMSIS_VERSION=5.5.1
44+
install:
45+
# Install PlatformIO
46+
- pip install -U platformio
47+
# Install the development version of ststm32 platform
48+
- platformio platform install https://github.com/platformio/platform-ststm32.git
49+
# Prepare framework for CI
50+
- python -c "import json; import os; fp=open(os.path.expanduser('~/.platformio/platforms/ststm32/platform.json'), 'r+'); data=json.load(fp); data['packages']['framework-arduinoststm32']['version'] = '*'; fp.seek(0); fp.truncate(); json.dump(data, fp); fp.close()"
51+
- sudo ln -sf $TRAVIS_BUILD_DIR ~/.platformio/packages/framework-arduinoststm32
52+
# Download and unpack CMSIS package
53+
- wget https://github.com/stm32duino/ArduinoModule-CMSIS/releases/download/$CMSIS_VERSION/CMSIS-$CMSIS_VERSION.tar.bz2
54+
- tar -xvjf CMSIS-$CMSIS_VERSION.tar.bz2
55+
before_script:
56+
- cd $TRAVIS_BUILD_DIR/CI/build/
57+
script:
58+
- python platformio-builder.py --board=blackpill_f103c8 --board=remram_v1
59+
3760
#
3861
# Build test
3962
#

0 commit comments

Comments
 (0)