Skip to content

[variant] Add Generic F4xx #12

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 55 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
7ab0014
[stm2variant] Add board_entry.txt
fpistm Feb 19, 2021
f18b696
[stm32variant] Add option to generate only one family
fpistm Feb 22, 2021
7420cb1
[stm32variant] Aggregate generated variant if they are the same
fpistm Mar 1, 2021
2af18b8
[stm32variant] Add generic_clock.c generation
fpistm Feb 24, 2021
bf60a95
[stm32variant] Comment option to generate from one mcu file
fpistm Mar 8, 2021
ed9d741
Allow use of a custom peripheral pins file
fpistm Feb 24, 2021
92b30a6
[CI] arduino-builder is replaced by arduino-cli
fpistm Mar 9, 2021
e2881a0
[stm32variant] Change generic variant generation
fpistm Mar 10, 2021
60c2725
[stm32variant] Fix USB mode when AF is not none
fpistm Mar 27, 2021
a17907e
Add all generated STM32F0xx generic variant files
fpistm Mar 15, 2021
eca465a
Add all generated STM32F1xx generic variant files
fpistm Mar 15, 2021
f4942db
Add all generated STM32F2xx generic variant files
fpistm Mar 15, 2021
57d91f5
Add all generated STM32F3xx generic variant files
fpistm Mar 15, 2021
0db9a8a
Add all generated STM32F4xx generic variant files
fpistm Mar 15, 2021
fa70b52
Add all generated STM32F7xx generic variant files
fpistm Mar 15, 2021
7e98117
Add all generated STM32G0xx generic variant files
fpistm Mar 15, 2021
1827a01
Add all generated STM32G4xx generic variant files
fpistm Mar 15, 2021
6322f39
Add all generated STM32H7xx generic variant files
fpistm Mar 15, 2021
fc1d1eb
Add all generated STM32L0xx generic variant files
fpistm Mar 15, 2021
2748545
Add all generated STM32L1xx generic variant files
fpistm Mar 15, 2021
2f630d7
Add all generated STM32L4xx generic variant files
fpistm Mar 15, 2021
792d5fc
Add all generated STM32L5xx generic variant files
fpistm Mar 15, 2021
6290d54
Add all generated STM32MP1xx generic variant files
fpistm Mar 15, 2021
f4ebde5
Add all generated STM32WBxx generic variant files
fpistm Mar 15, 2021
eac2b6c
Add all generated STM32WLxx generic variant files
fpistm Mar 15, 2021
b01e815
Update variant header management
fpistm Mar 11, 2021
c68af71
[variant] Add Generic L4xx
fpistm Mar 12, 2021
0fe2bff
[variant] Add Generic G4xx
ABOSTM Mar 15, 2021
6e2d8f7
[variant] Add support of board B-G431B-ESC1
owennewo Mar 23, 2021
2a59f50
[variant] Add Generic G0xx
fpistm Mar 15, 2021
c97d424
Add Aurora One Variant
jhleekr Sep 15, 2020
8dcd51d
Add Nucleo G031K8 and generic G031Kx
fpistm Mar 15, 2021
989bfe4
[variant] Update Generic F0xx
fpistm Jan 22, 2021
a49be19
Add Generic F042Cx
seeers Mar 10, 2021
d8acf49
Added NUCLEO_F070RB
gbmhunter Sep 10, 2020
811db33
[variant] Update Generic MP1xx
fpistm Jan 27, 2021
ada8a58
[variant] Add Generic F2xx
fpistm Mar 14, 2021
09a72ed
[variant] Add Generic L5xx and Nucleo L552ZE-Q
fpistm Mar 14, 2021
ff0f876
[variant] Add Generic WBxx
fpistm Mar 14, 2021
d19281a
[variant] Add Generic L1xx
fpistm Mar 15, 2021
ef34714
[variant] Update Generic H7xx
fpistm Mar 15, 2021
ad5839d
Added Generic H743Vx
vladkozlov69 Sep 25, 2020
763fcd5
Enable HAL MDMA by default
fpistm Mar 16, 2021
5c76f30
[variant] Add Generic F7xx
ABOSTM Mar 16, 2021
0af8d1d
[variant] Add Generic L0xx
ABOSTM Mar 18, 2021
34eea30
Add Generic L010RB
mkals Mar 23, 2021
955c00b
[PIO]Fix variant header changes
fpistm Mar 12, 2021
8acb260
[variant] Add Generic F3xx
ABOSTM Mar 23, 2021
f9dbaa1
[Variant] Add DISCO F303VC
dnandha Mar 25, 2021
8cccaf1
[Variant] Add OLIMEXINO-STM32F3
Stanimir-Petev Mar 25, 2021
246ca21
[CI] Update configuration to build only one generic per variant
fpistm Mar 16, 2021
9f9e0c5
[variant] Add Generic F4xx
ABOSTM Mar 26, 2021
ffb162c
BlackPill F401CC: add USER_BTN on PA0
ABOSTM Apr 2, 2021
21d6b96
[New variant] STM32F407ZGT6 Mini
dds90 Apr 2, 2021
8f42825
BLACK_F407ZX: invert PF9 and PF10 in digitalPin[]
ABOSTM Apr 6, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
7 changes: 4 additions & 3 deletions .github/actions/pio-build/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ python3 -c "import json; import os; fp=open(os.path.expanduser('~/.platformio/pl
}

# Fix for variant path change while not updated in PIO
python3 -c "import json; import os; fp=open(os.path.expanduser('~/.platformio/platforms/ststm32/boards/remram_v1.json'), 'r+'); data=json.load(fp); data['build']['variant'] = 'STM32F7xx/REMRAM_V1'; fp.seek(0); fp.truncate(); json.dump(data, fp); fp.close()" || {
python3 -c "import json; import os; fp=open(os.path.expanduser('~/.platformio/platforms/ststm32/boards/remram_v1.json'), 'r+'); data=json.load(fp); data['build']['variant'] = 'STM32F7xx/F765V\\\\\(G-I\\\\\)_F767VG_F767VI_F777VI'; data['build']['extra_flags'] = '-DSTM32F765xx -DCUSTOM_PERIPHERAL_PINS -DVARIANT_H=\\\\\"variant_REMRAM_V1.h\\\\\"'; fp.seek(0); fp.truncate(); json.dump(data, fp); fp.close()" || {
exit 1
}
python3 -c "import json; import os; fp=open(os.path.expanduser('~/.platformio/platforms/ststm32/boards/blackpill_f103c8.json'), 'r+'); data=json.load(fp); data['build']['variant'] = 'STM32F1xx/PILL_F103XX'; fp.seek(0); fp.truncate(); json.dump(data, fp); fp.close()" || {
python3 -c "import json; import os; fp=open(os.path.expanduser('~/.platformio/platforms/ststm32/boards/blackpill_f103c8.json'), 'r+'); data=json.load(fp); data['build']['variant'] = 'STM32F1xx/PILL_F103XX'; data['build']['extra_flags'] = '-DSTM32F1 -DSTM32F103xB -DVARIANT_H=\\\\\"variant_PILL_F103XX.h\\\\\"'; fp.seek(0); fp.truncate(); json.dump(data, fp); fp.close()" || {
exit 1
}

Expand All @@ -33,6 +33,7 @@ tar --extract --bzip2 --file="$CMSIS_ARCHIVE" || {
cd "$GITHUB_WORKSPACE/CI/build/" || {
exit 1
}
python3 platformio-builder.py --board=blackpill_f103c8 --board=remram_v1
# python3 platformio-builder.py --board=blackpill_f103c8 --board=remram_v1
python3 platformio-builder.py --board=blackpill_f103c8

exit $?
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ boards.local.txt
platform.local.txt
path_config.json
update_config.json
variant_config.json

# Backup
*.bak
Expand Down Expand Up @@ -34,4 +35,4 @@ __pycache__/
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
*.code-workspace
*.code-workspace
56 changes: 30 additions & 26 deletions CI/build/README.md
Original file line number Diff line number Diff line change
@@ -1,61 +1,65 @@
# arduino-builder.py
# arduino-cli.py

This script manages _[arduino-builder](https://github.com/arduino/arduino-builder)_ command line tool for compiling Arduino sketch(es).
This script manages _[arduino-cli](https://github.com/arduino/arduino-cli)_ command line tool for compiling Arduino sketch(es).

## Requirements
- [Arduino IDE](https://www.arduino.cc/en/Main/Software) (_[arduino-builder](https://github.com/arduino/arduino-builder)_ is included)
- [arduino-cli](https://github.com/arduino/arduino-cli)
- Python version greater than or equal to 3.2 (due to `concurrent.futures` usage)

## Usage

```
usage: arduino-builder.py [-h] [-l [{board,sketch}] | -a] [-b pattern] [-c]
[--arch architecture]
[--config <core configuration file>] [-v]
[--bin | --travis]
[-i <shetch filepath> | -f <sketches list filepath> | -s pattern | -e <excluded sketches list filepath>]
usage: arduino-cli.py [-h] [-l [{board,sketch}] | -a] [-b pattern] [-c]
[--arch architecture]
[--config <core configuration file>] [-u <string>] [-v]
[--ci]
[-i <shetch filepath> | -f <sketches list filepath> | -s pattern | -e <excluded sketches list filepath>]

Manage arduino-builder command line tool for compiling Arduino sketch(es).
Manage arduino-cli to build sketche(s) for STM32 boards.

optional arguments:
-h, --help show this help message and exit
-l [{board,sketch}], --list [{board,sketch}]
list available board(s) or sketch(es)
-a, --all build all sketches found for all available boards
-b pattern, --board pattern
pattern to find one or more board(s) to build
-c, --clean clean output directory
<user path config>/arduinoBuilderOutput
pattern to build one or more board(s)
-c, --clean clean output directory.
--arch architecture core architecture to build. Default build architecture
is stm32
is 'stm32'
--config <core configuration file>
JSON file containing the build configuration for one
or more maintainer/architecture. Board options for
build, applicability of sketches for boards or
required options. If sketch is not listed then
applicable to all board. Default core configuration is
for 'stm32' architecture in: conf/cores_config.json
-v, --verbose enable arduino-builder verbose mode
--bin save binaries
--travis Custom configuration for Travis CI build
for 'stm32 'architecture in:
<core path>\CI\build\conf\cores_config.json
-u <string>, --url <string>
additional URL for the board manager Default url : htt
ps://github.com/stm32duino/BoardManagerFiles/raw/maste
r/STM32/package_stm_index.json
-v, --verbose enable arduino-cli verbose mode
--ci custom configuration for CI build

Sketch(es) options:
By default build <arduino path>/examples/01.Basics/BareMinimum/BareMinimum.ino
By default build C:\STM32\arduino\arduino-1.8.13\portable\packages\STM32\h
ardware\stm32\2.0.0-dev\CI\build\examples\BareMinimum

-i <shetch filepath>, --ino <shetch filepath>
single ino file to build
single sketch file to build
-f <sketches list filepath>, --file <sketches list filepath>
file containing list of sketches to build
-s pattern, --sketches pattern
pattern to find one or more sketch to build
-e <excluded sketches list filepath>, --exclude <excluded sketches list filepath>
file containing pattern of sketches to ignore. Default
path : conf/exclude_list.txt
file containing sketches pattern to ignore. Default
path : <core path>\\CI\build\conf\exclude_list.txt
```

## Cores configuration files

Script is able to uses a JSON configuration file containing the build configuration for one or more maintainer/architecture.
Script is able to uses a JSON configuration file containing the build configuration for one or more maintainer/architecture.
A default configuration file is provided: [cores_config.json](conf/cores_config.json)


Expand Down Expand Up @@ -144,7 +148,7 @@ Will build all sketches available in `09.USB/*` for the listed boards and add `

* List all boards containing `F1` or `L4` (not case sensitive):

`python3 arduino-builder.py -l -b "F1|l4"`
`python3 arduino-cli.py -l -b "F1|l4"`

Will produce on the [stm32](https://github.com/stm32duino/Arduino_Core_STM32) core:
```
Expand All @@ -164,7 +168,7 @@ NUCLEO_L496ZG-P

* List all sketch containing `digital` or `analog` (not case sensitive):

`python3 arduino-builder.py -l sketch -s "Digital|analog"`
`python3 arduino-cli.py -l sketch -s "Digital|analog"`

Will produce on the [stm32](https://github.com/stm32duino/Arduino_Core_STM32) core:
```
Expand Down Expand Up @@ -194,11 +198,11 @@ Build configuration for 'STM32' maintainer and 'stm32' architecture

* Build all sketches containing `digital` or `analog` for all boards containing `F1` or `L4` (not case sensitive):

`python3 arduino-builder.py -s "Digital|analog" -b "F1|l4"`
`python3 arduino-cli.py -s "Digital|analog" -b "F1|l4"`

* List all boards for STM32F1 core:

`python3 arduino-builder.py -l --arch STM32F1`
`python3 arduino-cli.py -l --arch STM32F1`

Will list:
```
Expand Down
Loading