Skip to content

Commit 952eb7d

Browse files
committed
chore: clean up and refactor links
- Refactor some links - Update broken links - Removal of broken links without alternative Signed-off-by: Frederic Pillon <[email protected]>
1 parent 3890e7d commit 952eb7d

31 files changed

+259
-247
lines changed

API.md

Lines changed: 34 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
# API
22

3-
* [Core](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#core)
4-
* [Core version](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#core-version)
5-
* [Core Callback](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#core-callback)
6-
* [Wiring](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#wiring)
7-
* [Analog](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#analog)
8-
* [HardwareSerial](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#hardwareserial)
9-
* [HardwareTimer](https://github.com/stm32duino/Arduino_Core_STM32/wiki/HardwareTimer-library)
10-
* [Built-In Library](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#built-in-library)
11-
* [SPI](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#spi)
12-
* [I2C](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#i2C)
13-
* [CMSIS DSP](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#cmsis-dsp)
14-
* [EEPROM emulation](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#EEPROM-Emulation)
15-
* [Servo](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Servo-library)
16-
* [Other](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#other)
17-
* [Remembering variables across resets](https://github.com/stm32duino/Arduino_Core_STM32/wiki/API#Remembering-variables-across-resets)
3+
* [Core](#core)
4+
* [Core version](#core-version)
5+
* [Core Callback](#core-callback)
6+
* [Wiring](#wiring)
7+
* [Analog](#analog)
8+
* [HardwareSerial](#hardwareserial)
9+
* [[HardwareTimer library]]
10+
* [Built-In Library](#built-in-library)
11+
* [SPI](#spi)
12+
* [I2C](#i2C)
13+
* [CMSIS DSP](#cmsis-dsp)
14+
* [EEPROM emulation](#EEPROM-Emulation)
15+
* [[Servo library]]
16+
* [Other](#other)
17+
* [Remembering variables across resets](#Remembering-variables-across-resets)
1818

1919
# Core
2020

@@ -60,7 +60,7 @@ _Params_ `func` pointer to the callback function
6060

6161
[[/img/Warning-icon.png|alt="Warning"]] By default, the core callback feature is disabled, to enable it `CORE_CALLBACK` must be defined.
6262

63-
`build_opt.h` can be used to define it by adding `-DCORE_CALLBACK`, see [build_opt.h wiki](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Customize-build-options-using-build_opt.h).
63+
[`build_opt.h`][build_opt.h] can be used to define it by adding `-DCORE_CALLBACK`.
6464

6565
# Wiring
6666

@@ -103,7 +103,7 @@ A minimum ADC sampling time is required when reading internal channels so defaul
103103
* `ADC_SAMPLINGTIME_INTERNAL`
104104
to the desired ADC sample time.
105105
106-
`ADC_SAMPLINGTIME` and `ADC_CLOCK_DIV` could also be redefined by the variant or using `build_opt.h`.
106+
`ADC_SAMPLINGTIME` and `ADC_CLOCK_DIV` could also be redefined by the variant or using [`build_opt.h`][build_opt.h].
107107
108108
#### Example
109109
An example which read then convert to proper Unit the 3 internal channels + A0 is provided with [STM32Examples](https://github.com/stm32duino/STM32Examples) library:
@@ -137,12 +137,12 @@ void loop() {
137137
delay(1000);
138138
}
139139
```
140-
Another solution is to add a [build_opt.h](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Customize-build-options-using-build_opt.h) file alongside your main `.ino` file with: `-DENABLE_HWSERIALx`.
140+
Another solution is to add a [`build_opt.h`][build_opt.h] file alongside your main `.ino` file with: `-DENABLE_HWSERIALx`.
141141
This will define the `Serialx` instance using the first `USARTx` instance found in the `PeripheralPins.c` of your variant.
142142

143143
[[/img/Note-icon.png|alt="Note"]] **Note** that only the latter solution allows to use the `serialEventx()` callback in the sketch.
144144

145-
For Example, if you define in the [build_opt.h](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Customize-build-options-using-build_opt.h): `-DENABLE_HWSERIAL3`
145+
For Example, if you define in the [`build_opt.h`][build_opt.h]: `-DENABLE_HWSERIAL3`
146146

147147
This will instantiate `Serial3` with the first Rx and Tx pins found in the `PinMap_UART_RX[]` and `PinMap_UART_TX[]` arrays in the `PeripheralPins.c` of your variant and the `serialEvent3()` will be enabled.
148148

@@ -154,7 +154,7 @@ Example for the `Serial3`:
154154
#define PIN_SERIAL3_RX PB11
155155
#define PIN_SERIAL3_TX PB10
156156
```
157-
- In the `build_opt.h`:
157+
- In the [`build_opt.h`][build_opt.h]:
158158
`-DPIN_SERIAL3_RX=PB11 -DPIN_SERIAL3_TX=PB10`
159159
160160
### New API functions
@@ -289,7 +289,7 @@ void loop() {
289289
}
290290
```
291291
292-
**Note:** Serial Rx/TX buffer size can be changed, see [custom definitions](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Custom-definitions#serial-rxtx-buffer-size)
292+
**Note:** Serial Rx/TX buffer size can be changed, see [[custom definitions|Custom-definitions#serial-rxtx-buffer-size]]
293293
294294
#### Enable hardware flow control
295295
@@ -318,8 +318,8 @@ serial.setRtsCts(PA12, PA11);
318318
serial.begin(460800);
319319
```
320320

321-
## HardwareTimer library
322-
https://github.com/stm32duino/Arduino_Core_STM32/wiki/HardwareTimer-library
321+
## [[HardwareTimer library]]
322+
323323

324324
# Built-In Library
325325

@@ -444,7 +444,7 @@ void loop() {
444444
}
445445
```
446446
447-
Refers to [I2C Timing](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Custom-definitions#i2c-timing) to customize I2C speed if needed.
447+
Refers to [[I2C Timing|Custom-definitions#i2c-timing]] to customize I2C speed if needed.
448448
449449
### Default I2C pins
450450
**The default I2C interface pins are configured inside the PeripheralPins.c file.**
@@ -539,9 +539,9 @@ By default I2C buffers are all aligned on Arduino API: **32 bytes**.
539539
Nevertheless it is possible to transfer up to **255 bytes**:
540540
* In master mode: RX and TX buffers will automatically grow when needed, independently one from each other, and independently from other I2C instances.
541541
Nothing to do from application point of view.
542-
Warning: a bug in STM32 cube HAL (STM32 core v1.8.0) prevents to transfer exactly 255 bytes.(see [#853](https://github.com/stm32duino/Arduino_Core_STM32/pull/853))
542+
Warning: a bug in STM32 cube HAL (STM32 core v1.8.0) prevents to transfer exactly 255 bytes. (see [#853])
543543

544-
* In slave mode: RX and TX buffer size can be statically redefined using [hal_conf_extra.h](https://github.com/stm32duino/Arduino_Core_STM32/wiki/HAL-configuration#core-version--150-1) or [build_opt.h](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Customize-build-options-using-build_opt.h) (at compilation time) thanks to switch `I2C_TXRX_BUFFER_SIZE` (see [#853](https://github.com/stm32duino/Arduino_Core_STM32/pull/853))
544+
* In slave mode: RX and TX buffer size can be statically redefined using [[hal_conf_extra.h|HAL-configuration#core-version--150-1]] or [`build_opt.h`][build_opt.h] (at compilation time) thanks to switch `I2C_TXRX_BUFFER_SIZE` (see [#853])
545545
All I2C instances are impacted by change of this compilation switch.
546546

547547
## CMSIS DSP
@@ -594,11 +594,11 @@ void eeprom_buffered_write_byte(uint32_t pos, uint8_t value); // Function writes
594594
By default, EEPROM emulation storage correspond to the last sector/page of Flash,
595595
and its size correspond to the size of the last sector/page.
596596
Nevertheless it is possible to customize address and size used for EEPROM.
597-
In this case, following switches should be defined (in variant.h or build_opt.h)
597+
In this case, following switches should be defined (in variant.h or [`build_opt.h`][build_opt.h])
598598
* `FLASH_BASE_ADDRESS`
599599
* `FLASH_DATA_SECTOR` or `FLASH_PAGE_NUMBER` (depending on STM32 family used)
600600
601-
see example of variant implementation: https://github.com/stm32duino/Arduino_Core_STM32/pull/938
601+
see example of variant implementation: [#938](../pull/938)
602602
603603
[[/img/Warning-icon.png|alt="Warning"]] **Single/dual bank configuration**:
604604
@@ -608,13 +608,12 @@ For example, NUCLEO_F767ZI is by default configured in single bank. Last sector
608608
If this configuration is changed, it is then mandatory to customize `FLASH_BASE_ADDRESS`/`FLASH_DATA_SECTOR`,
609609
even to use last sector of Flash.
610610
611-
## Servo library
612-
https://github.com/stm32duino/Arduino_Core_STM32/wiki/Servo-library
611+
## [[Servo library]]
613612
614613
# Other
615614
616615
## Remembering variables across resets
617-
Since core version 1.9.0 (see [PR #996](https://github.com/stm32duino/Arduino_Core_STM32/pull/996)), it is possible to mark variables as "noinit", which prevents them from being initialized to a fixed value at startup. This allows using these variables to remember a value across resets (since the reset itself leaves memory unchanged, it is only the startup code that normally resets all variable values, but that is prevented by noinit).
616+
Since core version 1.9.0 (see [#996](../pull/996)), it is possible to mark variables as "noinit", which prevents them from being initialized to a fixed value at startup. This allows using these variables to remember a value across resets (since the reset itself leaves memory unchanged, it is only the startup code that normally resets all variable values, but that is prevented by noinit).
618617
619618
To do this, the variable must be placed in the `.noinit` section by adding `__attribute__((__section__(".noinit")))` (this is exactly the same as how this works on the original Arduino AVR core). Typically, you would also need to check the startup reason register so you can initialize the variable with a default on the first startup. For example, something like:
620619
@@ -638,4 +637,7 @@ void setup() {
638637
void loop() { }
639638
```
640639

641-
This shows the number of boots since the last POR by incrementing a noinit variable across resets. Note that when you first upload this, it might not start at 1 but at some arbitrary value, because typically the first boot after an upload is not a power-on-reset. To start at 1, disconnect and reconnect power.
640+
This shows the number of boots since the last POR by incrementing a noinit variable across resets. Note that when you first upload this, it might not start at 1 but at some arbitrary value, because typically the first boot after an upload is not a power-on-reset. To start at 1, disconnect and reconnect power.
641+
642+
[build_opt.h]: Customize-build-options-using-build_opt.h
643+
[#853]: ../pull/853

Astyle.md

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
# Astyle
22

3-
[AStyle](http://astyle.sourceforge.net/) is used for coding style checking.
3+
[AStyle] is used for coding style checking.
44

55
> Artistic Style is a source code indenter, formatter, and beautifier for the C, C++, C++/CLI, Objective‑C, C# and Java programming languages.
66
7-
GitHub action is used to ensure each PR (Pull Request) and `main` branch of the [STM32 core](https://github.com/stm32duino/Arduino_Core_STM32) follow the code style definition defined.
7+
GitHub action is used to ensure each PR (Pull Request) and `main` branch of the [STM32 core] follow the code style definition defined.
88

9-
Only sources files (`*.h`, `*.hpp`, `*.c`, `*.cpp`) from the following [STM32 core](https://github.com/stm32duino/Arduino_Core_STM32) directory lists are checked:
9+
Only sources files (`*.h`, `*.hpp`, `*.c`, `*.cpp`) from the following [STM32 core] directory lists are checked:
1010
* `cores/`
1111
* `libraries/`
1212
* `variants/`
1313

1414
## Ignored files
15-
[.astyleignore](https://github.com/stm32duino/Arduino_Core_STM32/blob/main/CI/astyle/.astyleignore) file contains list of folder to ignore.
15+
[`.astyleignore`](https://github.com/stm32duino/Arduino_Core_STM32/blob/main/CI/astyle/.astyleignore) file contains list of folder to ignore.
1616

1717
## Code style definition
1818

19-
Hereafter the code style definition applied ([.astylerc](https://github.com/stm32duino/Arduino_Core_STM32/blob/main/CI/astyle/.astylerc))
19+
Hereafter the code style definition applied ([`.astylerc`](https://github.com/stm32duino/Arduino_Core_STM32/blob/main/CI/astyle/.astylerc))
2020

2121
```bash
2222
# STM32duino code style definition file for Astyle
@@ -66,7 +66,7 @@ keep-one-line-statements
6666

6767
## Python script
6868

69-
Python script [astyle.py](https://github.com/stm32duino/Arduino_Core_STM32/blob/main/CI/astyle/astyle.py) is provided to ease use of [AStyle](http://astyle.sourceforge.net/):
69+
Python script [`astyle.py`](https://github.com/stm32duino/Arduino_Core_STM32/blob/main/CI/astyle/astyle.py) is provided to ease use of [AStyle]:
7070

7171
```stdout
7272
usage: astyle.py [-h] [-d <code style definition file>] [-g | -b <branch name>] [-i <ignore file>] [-p <astyle install path>]
@@ -88,3 +88,6 @@ options:
8888
-r <source root path>, --root <source root path>
8989
Source root path to use. Default: <repo path>/Arduino_Core_STM32
9090
```
91+
92+
[AStyle]: http://astyle.sourceforge.net/
93+
[STM32 core]: https://github.com/stm32duino/Arduino_Core_STM32

FAQ.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Checklist:
77
* Verify if a mount point exists and check the mount point name. It should be the same than the one searched by the upload tool.
88

99
If not, then probably you have an older board with a different label used for the mount point.<br>
10-
Update the "_board.txt_" file to add <your_node_label> to the targeted board.<br>
10+
Update the `board.txt` file to add `<your_node_label>` to the targeted board.<br>
1111
Example:<br>
1212
`Nucleo_64.menu.pnum.NUCLEO_xxxxxx.node=NODE_xxxxxx`<br>
1313
becomes<br>
@@ -81,5 +81,5 @@ https://www.stm32duino.com/viewtopic.php?f=62&t=1000
8181

8282
#### When using "BMP (Black Magic Probe)" upload method, error occurs it can't connect to the COM port.
8383

84-
Refers to this [warning](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Upload-methods#bmp-black-magic-probe)
84+
Refers to this [[warning|Upload-methods#bmp-black-magic-probe]]
8585

Getting-Started.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ Then you can find the Nucleo-64 boards available in a sub-menu of the "Tools" me
6060

6161
## Extra step
6262

63-
To upload through SWD (STLink), Serial or DFU, [STM32CubeProgrammer](https://www.st.com/en/development-tools/stm32cubeprog.html) needs to be installed. See [Upload methods](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Upload-methods#stm32cubeprogrammer).
63+
To upload through SWD (STLink), Serial or DFU, [STM32CubeProgrammer](https://www.st.com/en/development-tools/stm32cubeprog.html) needs to be installed. See [[Upload methods|Upload-methods#stm32cubeprogrammer]].
6464

6565
## Troubleshooting
6666

@@ -72,19 +72,19 @@ If you have any issue to download a package, ensure to not be behind a proxy.
7272
Else configure the proxy in the Arduino.cc IDE (open the "**Preferences**" dialog and select "**Network**" tab).
7373

7474
# Configuring IDE
75-
1. Connect a board to the computer USB port. For this example: [Nucleo L476RG](http://www.st.com/en/evaluation-tools/nucleo-l476rg.html)
75+
1. Connect a board to the computer USB port. For this example: [Nucleo L476RG]
7676

7777
2. Launch the Arduino software
7878

7979
[[/img/arduino.png|alt="Arduino icon"]]
8080

81-
3. Select the [Nucleo L476RG](http://www.st.com/en/evaluation-tools/nucleo-l476rg.html) board in two steps:
81+
3. Select the [Nucleo L476RG] board in two steps:
8282

8383
a. From the "**Tools > Board**" menu, select the STM32 boards groups: _Nucleo-64_
8484

8585
[[/img/boardslist.png|alt="Board selection"]]
8686

87-
b. Then from the "**Tools > Board part number**" menu, select the [Nucleo L476RG](http://www.st.com/en/evaluation-tools/nucleo-l476rg.html)
87+
b. Then from the "**Tools > Board part number**" menu, select the [Nucleo L476RG]
8888

8989
[[/img/SelectBoard.png|alt="Board selection"]]
9090

@@ -101,10 +101,13 @@ b. Then from the "**Tools > Board part number**" menu, select the [Nucleo L476RG
101101
## Upload methods
102102
Depending of the board, several upload methods could be proposed, thanks the "**Tools > Upload Method**" menu.
103103

104-
See [Upload methods](https://github.com/stm32duino/Arduino_Core_STM32/wiki/Upload-methods) for more details.
104+
See [[Upload methods]] for more details.
105105

106106
[[/img/UploadMethod.png|alt="Upload Method"]]
107107

108108
# Examples
109109
* [[Blink-example]]
110110
* [[Firmata-example]] (to use with [ScratchX](http://scratchx.org/) for example)
111+
112+
113+
[Nucleo L476RG]: http://www.st.com/en/evaluation-tools/nucleo-l476rg.html

0 commit comments

Comments
 (0)