Skip to content

Commit bce419e

Browse files
committed
Merge branch 'release/v2.1.0'
2 parents 6655bea + b0d6370 commit bce419e

File tree

28 files changed

+207
-611
lines changed

28 files changed

+207
-611
lines changed

.github/workflows/examples.yml

+7-9
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,7 @@ jobs:
77
strategy:
88
fail-fast: false
99
matrix:
10-
os: [ubuntu-16.04, windows-latest, macos-latest]
11-
python-version: [3.7]
10+
os: [ubuntu-latest, windows-latest, macos-latest]
1211
example:
1312
- "examples/arduino-fade-all-pins"
1413
- "examples/arduino-internal-lib"
@@ -20,18 +19,17 @@ jobs:
2019
- "examples/native-blink"
2120
runs-on: ${{ matrix.os }}
2221
steps:
23-
- uses: actions/checkout@v2
22+
- uses: actions/checkout@v3
2423
with:
2524
submodules: "recursive"
26-
- name: Set up Python ${{ matrix.python-version }}
27-
uses: actions/setup-python@v1
25+
- name: Set up Python
26+
uses: actions/setup-python@v3
2827
with:
29-
python-version: ${{ matrix.python-version }}
28+
python-version: "3.9"
3029
- name: Install dependencies
3130
run: |
32-
python -m pip install --upgrade pip
3331
pip install -U https://github.com/platformio/platformio/archive/develop.zip
34-
platformio platform install file://.
32+
pio pkg install --global --platform symlink://.
3533
- name: Build examples
3634
run: |
37-
platformio run -d ${{ matrix.example }}
35+
pio run -d ${{ matrix.example }}

README.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
# ST STM8: development platform for [PlatformIO](http://platformio.org)
1+
# ST STM8: development platform for [PlatformIO](https://platformio.org)
22

33
[![Build Status](https://github.com/platformio/platform-ststm8/workflows/Examples/badge.svg)](https://github.com/platformio/platform-ststm8/actions)
44

55
The STM8 is an 8-bit microcontroller family by STMicroelectronics an extended variant of the ST7 microcontroller architecture. STM8 microcontrollers are particularly low cost for a full-featured 8-bit microcontroller.
66

7-
* [Home](http://platformio.org/platforms/ststm8) (home page in PlatformIO Platform Registry)
8-
* [Documentation](http://docs.platformio.org/page/platforms/ststm8.html) (advanced usage, packages, boards, frameworks, etc.)
7+
* [Home](https://registry.platformio.org/platforms/platformio/ststm8) (home page in the PlatformIO Registry)
8+
* [Documentation](https://docs.platformio.org/page/platforms/ststm8.html) (advanced usage, packages, boards, frameworks, etc.)
99

1010
# Usage
1111

12-
1. [Install PlatformIO](http://platformio.org)
13-
2. Create PlatformIO project and configure a platform option in [platformio.ini](http://docs.platformio.org/page/projectconf.html) file:
12+
1. [Install PlatformIO](https://platformio.org)
13+
2. Create PlatformIO project and configure a platform option in [platformio.ini](https://docs.platformio.org/page/projectconf.html) file:
1414

1515
## Stable version
1616

@@ -32,4 +32,4 @@ board = ...
3232

3333
# Configuration
3434

35-
Please navigate to [documentation](http://docs.platformio.org/page/platforms/ststm8.html).
35+
Please navigate to [documentation](https://docs.platformio.org/page/platforms/ststm8.html).

builder/frameworks/spl.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -37,14 +37,14 @@
3737

3838

3939
def get_core_files():
40-
if not isfile(join(env.subst("$PROJECTSRC_DIR"), "stm8s_conf.h")):
40+
if not isfile(join(env.subst("$PROJECT_SRC_DIR"), "stm8s_conf.h")):
4141
print("Warning! Couldn't find stm8s_conf.h file!")
4242
return []
4343

4444
command = [
4545
env.subst("$CC"), "-m%s" % board_config.get("build.cpu"),
4646
"-D%s" % board_config.get("build.mcu")[0:8].upper(),
47-
"-I.", "-I", "%s" % env.subst("$PROJECTSRC_DIR"),
47+
"-I.", "-I", "%s" % env.subst("$PROJECT_SRC_DIR"),
4848
"-Wp-MM", "-E", "stm8s.h"
4949
]
5050

@@ -80,7 +80,7 @@ def get_core_files():
8080

8181
CPPPATH=[
8282
join(FRAMEWORK_DIR, "Libraries", "STM8S_StdPeriph_Driver", "inc"),
83-
"$PROJECTSRC_DIR",
83+
"$PROJECT_SRC_DIR",
8484
]
8585
)
8686

builder/main.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737

3838
ARFLAGS=["rcs"],
3939

40-
ASFLAGS=["-x", "assembler-with-cpp", "-flto"],
40+
ASPPFLAGS=["-x", "assembler-with-cpp", "-flto"],
4141

4242
CFLAGS=[
4343
"-m%s" % board_config.get("build.cpu")
@@ -63,7 +63,7 @@
6363

6464
LIBS=["stm8"],
6565

66-
SIZEPROGREGEXP=r"^(?:HOME|GSINIT|GSFINAL|CODE|INITIALIZER)\s+([0-9]+).*",
66+
SIZEPROGREGEXP=r"^(?:HOME|GSINIT|GSFINAL|CONST|CODE|INITIALIZER)\s+([0-9]+).*",
6767
SIZEDATAREGEXP=r"^(?:DATA|INITIALIZED)\s+([0-9]+).*",
6868
SIZEEEPROMREGEXP=r"^(?:EEPROM)\s+([0-9]+).*",
6969
SIZECHECKCMD="$SIZETOOL -A $SOURCES",

examples/arduino-fade-all-pins/.travis.yml

-67
This file was deleted.

examples/spl-flash/README.rst examples/arduino-fade-all-pins/README.md

+16-16
Original file line numberDiff line numberDiff line change
@@ -12,27 +12,27 @@
1212
How to build PlatformIO based project
1313
=====================================
1414

15-
1. `Install PlatformIO Core <http://docs.platformio.org/page/core.html>`_
16-
2. Download `development platform with examples <https://github.com/platformio/platform-ststm8/archive/develop.zip>`_
15+
1. [Install PlatformIO Core](https://docs.platformio.org/page/core.html)
16+
2. Download [development platform with examples](https://github.com/platformio/platform-ststm8/archive/develop.zip)
1717
3. Extract ZIP archive
1818
4. Run these commands:
1919

20-
.. code-block:: bash
20+
```shell
21+
# Change directory to example
22+
$ cd platform-ststm8/examples/arduino-fade-all-pins
2123

22-
# Change directory to example
23-
> cd platform-ststm8/examples/spl-flash
24+
# Build project
25+
$ pio run
2426

25-
# Build project
26-
> platformio run
27+
# Upload firmware
28+
$ pio run --target upload
2729

28-
# Upload firmware
29-
> platformio run --target upload
30+
# Build specific environment
31+
$ pio run -e stm8sdisco
3032

31-
# Build specific environment
32-
> platformio run -e stm8sdisco
33+
# Upload firmware for the specific environment
34+
$ pio run -e stm8sdisco --target upload
3335

34-
# Upload firmware for the specific environment
35-
> platformio run -e stm8sdisco --target upload
36-
37-
# Clean build files
38-
> platformio run --target clean
36+
# Clean build files
37+
$ pio run --target clean
38+
```

examples/arduino-fade-all-pins/platformio.ini

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
; Library options: dependencies, extra library storages
66
;
77
; Please visit documentation for the other options and examples
8-
; http://docs.platformio.org/page/projectconf.html
8+
; https://docs.platformio.org/page/projectconf.html
99

1010
[env:stm8sdisco]
1111
platform = ststm8

examples/arduino-internal-lib/.travis.yml

-67
This file was deleted.

examples/spl-uart-loopback/README.rst examples/arduino-internal-lib/README.md

+16-16
Original file line numberDiff line numberDiff line change
@@ -12,27 +12,27 @@
1212
How to build PlatformIO based project
1313
=====================================
1414

15-
1. `Install PlatformIO Core <http://docs.platformio.org/page/core.html>`_
16-
2. Download `development platform with examples <https://github.com/platformio/platform-ststm8/archive/develop.zip>`_
15+
1. [Install PlatformIO Core](https://docs.platformio.org/page/core.html)
16+
2. Download [development platform with examples](https://github.com/platformio/platform-ststm8/archive/develop.zip)
1717
3. Extract ZIP archive
1818
4. Run these commands:
1919

20-
.. code-block:: bash
20+
```shell
21+
# Change directory to example
22+
$ cd platform-ststm8/examples/arduino-internal-lib
2123

22-
# Change directory to example
23-
> cd platform-ststm8/examples/spl-uart-loopback
24+
# Build project
25+
$ pio run
2426

25-
# Build project
26-
> platformio run
27+
# Upload firmware
28+
$ pio run --target upload
2729

28-
# Upload firmware
29-
> platformio run --target upload
30+
# Build specific environment
31+
$ pio run -e stm8sdisco
3032

31-
# Build specific environment
32-
> platformio run -e stm8sdisco
33+
# Upload firmware for the specific environment
34+
$ pio run -e stm8sdisco --target upload
3335

34-
# Upload firmware for the specific environment
35-
> platformio run -e stm8sdisco --target upload
36-
37-
# Clean build files
38-
> platformio run --target clean
36+
# Clean build files
37+
$ pio run --target clean
38+
```

examples/arduino-internal-lib/platformio.ini

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
; Library options: dependencies, extra library storages
66
;
77
; Please visit documentation for the other options and examples
8-
; http://docs.platformio.org/page/projectconf.html
8+
; https://docs.platformio.org/page/projectconf.html
99

1010
[env:stm8sdisco]
1111
platform = ststm8

0 commit comments

Comments
 (0)