diff --git a/CI/build/conf/cores_config.json b/CI/build/conf/cores_config.json index 5999ae661b..29c09edae0 100644 --- a/CI/build/conf/cores_config.json +++ b/CI/build/conf/cores_config.json @@ -55,7 +55,7 @@ "BLACKPILL_F303CC", "BLACKPILL_F401CC", "CoreBoard_F401RC", - "DIYMROE_F407VGT", + "DIYMORE_F407VGT", "EEXTR_F030_V1", "Generic_F103R8T6", "Generic_F103RBT6", @@ -106,7 +106,7 @@ { "pattern": "Ethernet/|STM32FreeRTOS", "applicable": false, - "boards": [ "BLUEPILL_F103C6", "EEXTR_F030_V1", "MALYANM200_F103CB", "NUCLEO_L031K6" ] + "boards": [ "BLUEPILL_F103C6", "EEXTR_F030_V1", "MALYANM200_F103CB", "NUCLEO_F030R8", "NUCLEO_L031K6" ] }, { "pattern": "09.USB", @@ -145,7 +145,7 @@ "BLACKPILL_F401CC", "BLUE_F407VE_Mini", "CoreBoard_F401RC", - "DIYMROE_F407VGT", + "DIYMORE_F407VGT", "EEXTR_F030_V1", "Generic_F103R8T6", "Generic_F103RBT6", @@ -220,7 +220,7 @@ { "pattern": "(Alarm)?TimedWak(e)?up|SerialDeepSleep", "applicable": false, - "boards": [ "EEXTR_F030_V1", "MALYANM200_F103CB" ] + "boards": [ "EEXTR_F030_V1", "MALYANM200_F103CB", "STEVAL_MKSBOX1V1" ] }, { "pattern": "ArduinoISP", diff --git a/README.md b/README.md index 358ce11569..9355977cf6 100644 --- a/README.md +++ b/README.md @@ -83,7 +83,7 @@ User can add a STM32 based board following this [wiki](https://github.com/stm32d | :---: | --- | :---: | :--- | | :green_heart: | [32F0308DISCOVERY](http://www.st.com/en/evaluation-tools/32f0308discovery.html) | *1.3.0* | | | :green_heart: | [32F072BDISCOVERY](https://www.st.com/en/evaluation-tools/32f072bdiscovery.html) | *1.5.0* | | -| :green_heart: | [STM32VLDISCOVERY](https://community.st.com/external-link.jspa?url=http%3A%2F%2Fwww.st.com%2Fen%2Fevaluation-tools%2Fstm32vldiscovery.html) | 0.2.1 | | +| :green_heart: | [STM32VLDISCOVERY](https://www.st.com/en/evaluation-tools/stm32vldiscovery.html) | 0.2.1 | | | :green_heart: | [STM32F407G-DISC1](http://www.st.com/en/evaluation-tools/stm32f4discovery.html) | *0.1.0* | | | :green_heart: | [STM32F746G-DISCOVERY](http://www.st.com/en/evaluation-tools/32f746gdiscovery.html) | *0.1.0* | | | :green_heart: | [B-L072Z-LRWAN1](http://www.st.com/en/evaluation-tools/b-l072z-lrwan1.html) | *1.1.0* | | @@ -115,7 +115,7 @@ User can add a STM32 based board following this [wiki](https://github.com/stm32d | :green_heart: | [Black F407VET6](https://stm32-base.org/boards/STM32F407VET6-STM32-F4VE-V2.0) | *1.4.0* | VG/ZE/ZG in *1.5.0* | | :green_heart: | [Blue F407VET6 Mini](https://stm32-base.org/boards/STM32F407VET6-VCC-GND-Small) | *1.4.0* | | | :yellow_heart: | Core Board F401RC | **1.7.0** | | -| :green_heart: | [DIYMROE STM32F407VGT](https://stm32-base.org/boards/STM32F407VGT6-diymore) | *1.5.0* | | +| :green_heart: | [DIYMORE STM32F407VGT](https://stm32-base.org/boards/STM32F407VGT6-diymore) | *1.5.0* | | | :green_heart: | FK407M1 | *1.5.0* | | | Status | 3D printer boards | Release | Comment | diff --git a/boards.txt b/boards.txt index 6060ce7aac..319ec1da34 100644 --- a/boards.txt +++ b/boards.txt @@ -39,7 +39,8 @@ Nucleo_144.menu.pnum.NUCLEO_F429ZI=Nucleo F429ZI Nucleo_144.menu.pnum.NUCLEO_F429ZI.node=NODE_F429ZI Nucleo_144.menu.pnum.NUCLEO_F429ZI.upload.maximum_size=2097152 Nucleo_144.menu.pnum.NUCLEO_F429ZI.upload.maximum_data_size=262144 -Nucleo_144.menu.pnum.NUCLEO_F429ZI.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_144.menu.pnum.NUCLEO_F429ZI.build.mcu=cortex-m4 +Nucleo_144.menu.pnum.NUCLEO_F429ZI.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_144.menu.pnum.NUCLEO_F429ZI.build.board=NUCLEO_F429ZI Nucleo_144.menu.pnum.NUCLEO_F429ZI.build.series=STM32F4xx Nucleo_144.menu.pnum.NUCLEO_F429ZI.build.product_line=STM32F429xx @@ -51,7 +52,8 @@ Nucleo_144.menu.pnum.NUCLEO_F767ZI=Nucleo F767ZI Nucleo_144.menu.pnum.NUCLEO_F767ZI.node=NODE_F767ZI Nucleo_144.menu.pnum.NUCLEO_F767ZI.upload.maximum_size=2097152 Nucleo_144.menu.pnum.NUCLEO_F767ZI.upload.maximum_data_size=524288 -Nucleo_144.menu.pnum.NUCLEO_F767ZI.build.mcu=cortex-m7 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_144.menu.pnum.NUCLEO_F767ZI.build.mcu=cortex-m7 +Nucleo_144.menu.pnum.NUCLEO_F767ZI.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_144.menu.pnum.NUCLEO_F767ZI.build.board=NUCLEO_F767ZI Nucleo_144.menu.pnum.NUCLEO_F767ZI.build.series=STM32F7xx Nucleo_144.menu.pnum.NUCLEO_F767ZI.build.product_line=STM32F767xx @@ -63,7 +65,8 @@ Nucleo_144.menu.pnum.NUCLEO_H743ZI=Nucleo H743ZI Nucleo_144.menu.pnum.NUCLEO_H743ZI.node=NODE_H743ZI Nucleo_144.menu.pnum.NUCLEO_H743ZI.upload.maximum_size=2097152 Nucleo_144.menu.pnum.NUCLEO_H743ZI.upload.maximum_data_size=131072 -Nucleo_144.menu.pnum.NUCLEO_H743ZI.build.mcu=cortex-m7 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_144.menu.pnum.NUCLEO_H743ZI.build.mcu=cortex-m7 +Nucleo_144.menu.pnum.NUCLEO_H743ZI.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_144.menu.pnum.NUCLEO_H743ZI.build.board=NUCLEO_H743ZI Nucleo_144.menu.pnum.NUCLEO_H743ZI.build.series=STM32H7xx Nucleo_144.menu.pnum.NUCLEO_H743ZI.build.product_line=STM32H743xx @@ -74,7 +77,8 @@ Nucleo_144.menu.pnum.NUCLEO_H743ZI2=Nucleo H743ZI2 Nucleo_144.menu.pnum.NUCLEO_H743ZI2.node=NODE_H743ZI Nucleo_144.menu.pnum.NUCLEO_H743ZI2.upload.maximum_size=2097152 Nucleo_144.menu.pnum.NUCLEO_H743ZI2.upload.maximum_data_size=131072 -Nucleo_144.menu.pnum.NUCLEO_H743ZI2.build.mcu=cortex-m7 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_144.menu.pnum.NUCLEO_H743ZI2.build.mcu=cortex-m7 +Nucleo_144.menu.pnum.NUCLEO_H743ZI2.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_144.menu.pnum.NUCLEO_H743ZI2.build.board=NUCLEO_H743ZI2 Nucleo_144.menu.pnum.NUCLEO_H743ZI2.build.series=STM32H7xx Nucleo_144.menu.pnum.NUCLEO_H743ZI2.build.product_line=STM32H743xx @@ -86,7 +90,8 @@ Nucleo_144.menu.pnum.NUCLEO_L496ZG=Nucleo L496ZG Nucleo_144.menu.pnum.NUCLEO_L496ZG.node=NODE_L496ZG Nucleo_144.menu.pnum.NUCLEO_L496ZG.upload.maximum_size=1048576 Nucleo_144.menu.pnum.NUCLEO_L496ZG.upload.maximum_data_size=327680 -Nucleo_144.menu.pnum.NUCLEO_L496ZG.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_144.menu.pnum.NUCLEO_L496ZG.build.mcu=cortex-m4 +Nucleo_144.menu.pnum.NUCLEO_L496ZG.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_144.menu.pnum.NUCLEO_L496ZG.build.board=NUCLEO_L496ZG Nucleo_144.menu.pnum.NUCLEO_L496ZG.build.series=STM32L4xx Nucleo_144.menu.pnum.NUCLEO_L496ZG.build.product_line=STM32L496xx @@ -98,7 +103,8 @@ Nucleo_144.menu.pnum.NUCLEO_L496ZG-P=Nucleo L496ZG-P Nucleo_144.menu.pnum.NUCLEO_L496ZG-P.node=NODE_L496ZG Nucleo_144.menu.pnum.NUCLEO_L496ZG-P.upload.maximum_size=1048576 Nucleo_144.menu.pnum.NUCLEO_L496ZG-P.upload.maximum_data_size=327680 -Nucleo_144.menu.pnum.NUCLEO_L496ZG-P.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_144.menu.pnum.NUCLEO_L496ZG-P.build.mcu=cortex-m4 +Nucleo_144.menu.pnum.NUCLEO_L496ZG-P.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_144.menu.pnum.NUCLEO_L496ZG-P.build.board=NUCLEO_L496ZG_P Nucleo_144.menu.pnum.NUCLEO_L496ZG-P.build.series=STM32L4xx Nucleo_144.menu.pnum.NUCLEO_L496ZG-P.build.product_line=STM32L496xx @@ -110,7 +116,8 @@ Nucleo_144.menu.pnum.NUCLEO_L4R5ZI=Nucleo L4R5ZI Nucleo_144.menu.pnum.NUCLEO_L4R5ZI.node=NODE_L4R5ZI Nucleo_144.menu.pnum.NUCLEO_L4R5ZI.upload.maximum_size=2097152 Nucleo_144.menu.pnum.NUCLEO_L4R5ZI.upload.maximum_data_size=655360 -Nucleo_144.menu.pnum.NUCLEO_L4R5ZI.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_144.menu.pnum.NUCLEO_L4R5ZI.build.mcu=cortex-m4 +Nucleo_144.menu.pnum.NUCLEO_L4R5ZI.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_144.menu.pnum.NUCLEO_L4R5ZI.build.board=NUCLEO_L4R5ZI Nucleo_144.menu.pnum.NUCLEO_L4R5ZI.build.series=STM32L4xx Nucleo_144.menu.pnum.NUCLEO_L4R5ZI.build.product_line=STM32L4R5xx @@ -122,7 +129,8 @@ Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P=Nucleo L4R5ZI-P Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P.node=NODE_L4R5ZI Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P.upload.maximum_size=2097152 Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P.upload.maximum_data_size=655360 -Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P.build.mcu=cortex-m4 +Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P.build.board=NUCLEO_L4R5ZI_P Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P.build.series=STM32L4xx Nucleo_144.menu.pnum.NUCLEO_L4R5ZI-P.build.product_line=STM32L4R5xx @@ -200,7 +208,8 @@ Nucleo_64.menu.pnum.NUCLEO_F302R8=Nucleo F302R8 Nucleo_64.menu.pnum.NUCLEO_F302R8.node=NODE_F302R8 Nucleo_64.menu.pnum.NUCLEO_F302R8.upload.maximum_size=65536 Nucleo_64.menu.pnum.NUCLEO_F302R8.upload.maximum_data_size=16384 -Nucleo_64.menu.pnum.NUCLEO_F302R8.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.NUCLEO_F302R8.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.NUCLEO_F302R8.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.NUCLEO_F302R8.build.board=NUCLEO_F302R8 Nucleo_64.menu.pnum.NUCLEO_F302R8.build.series=STM32F3xx Nucleo_64.menu.pnum.NUCLEO_F302R8.build.product_line=STM32F302x8 @@ -212,7 +221,8 @@ Nucleo_64.menu.pnum.NUCLEO_F303RE=Nucleo F303RE Nucleo_64.menu.pnum.NUCLEO_F303RE.node=NODE_F303RE Nucleo_64.menu.pnum.NUCLEO_F303RE.upload.maximum_size=524288 Nucleo_64.menu.pnum.NUCLEO_F303RE.upload.maximum_data_size=65536 -Nucleo_64.menu.pnum.NUCLEO_F303RE.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.NUCLEO_F303RE.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.NUCLEO_F303RE.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.NUCLEO_F303RE.build.board=NUCLEO_F303RE Nucleo_64.menu.pnum.NUCLEO_F303RE.build.series=STM32F3xx Nucleo_64.menu.pnum.NUCLEO_F303RE.build.product_line=STM32F303xE @@ -224,7 +234,8 @@ Nucleo_64.menu.pnum.NUCLEO_F401RE=Nucleo F401RE Nucleo_64.menu.pnum.NUCLEO_F401RE.node=NODE_F401RE Nucleo_64.menu.pnum.NUCLEO_F401RE.upload.maximum_size=524288 Nucleo_64.menu.pnum.NUCLEO_F401RE.upload.maximum_data_size=98304 -Nucleo_64.menu.pnum.NUCLEO_F401RE.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.NUCLEO_F401RE.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.NUCLEO_F401RE.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.NUCLEO_F401RE.build.board=NUCLEO_F401RE Nucleo_64.menu.pnum.NUCLEO_F401RE.build.series=STM32F4xx Nucleo_64.menu.pnum.NUCLEO_F401RE.build.product_line=STM32F401xE @@ -236,7 +247,8 @@ Nucleo_64.menu.pnum.NUCLEO_F411RE=Nucleo F411RE Nucleo_64.menu.pnum.NUCLEO_F411RE.node="NODE_F411RE,NUCLEO" Nucleo_64.menu.pnum.NUCLEO_F411RE.upload.maximum_size=524288 Nucleo_64.menu.pnum.NUCLEO_F411RE.upload.maximum_data_size=131072 -Nucleo_64.menu.pnum.NUCLEO_F411RE.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.NUCLEO_F411RE.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.NUCLEO_F411RE.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.NUCLEO_F411RE.build.board=NUCLEO_F411RE Nucleo_64.menu.pnum.NUCLEO_F411RE.build.series=STM32F4xx Nucleo_64.menu.pnum.NUCLEO_F411RE.build.product_line=STM32F411xE @@ -248,7 +260,8 @@ Nucleo_64.menu.pnum.NUCLEO_F446RE=Nucleo F446RE Nucleo_64.menu.pnum.NUCLEO_F446RE.node=NODE_F446RE Nucleo_64.menu.pnum.NUCLEO_F446RE.upload.maximum_size=524288 Nucleo_64.menu.pnum.NUCLEO_F446RE.upload.maximum_data_size=131072 -Nucleo_64.menu.pnum.NUCLEO_F446RE.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.NUCLEO_F446RE.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.NUCLEO_F446RE.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.NUCLEO_F446RE.build.board=NUCLEO_F446RE Nucleo_64.menu.pnum.NUCLEO_F446RE.build.series=STM32F4xx Nucleo_64.menu.pnum.NUCLEO_F446RE.build.product_line=STM32F446xx @@ -273,7 +286,8 @@ Nucleo_64.menu.pnum.NUCLEO_G431RB=Nucleo G431RB Nucleo_64.menu.pnum.NUCLEO_G431RB.node=NODE_G431RB Nucleo_64.menu.pnum.NUCLEO_G431RB.upload.maximum_size=131072 Nucleo_64.menu.pnum.NUCLEO_G431RB.upload.maximum_data_size=32768 -Nucleo_64.menu.pnum.NUCLEO_G431RB.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.NUCLEO_G431RB.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.NUCLEO_G431RB.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.NUCLEO_G431RB.build.board=NUCLEO_G431RB Nucleo_64.menu.pnum.NUCLEO_G431RB.build.series=STM32G4xx Nucleo_64.menu.pnum.NUCLEO_G431RB.build.product_line=STM32G431xx @@ -285,7 +299,8 @@ Nucleo_64.menu.pnum.NUCLEO_G474RE=Nucleo G474RE Nucleo_64.menu.pnum.NUCLEO_G474RE.node=NODE_G474RE Nucleo_64.menu.pnum.NUCLEO_G474RE.upload.maximum_size=524288 Nucleo_64.menu.pnum.NUCLEO_G474RE.upload.maximum_data_size=131072 -Nucleo_64.menu.pnum.NUCLEO_G474RE.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.NUCLEO_G474RE.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.NUCLEO_G474RE.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.NUCLEO_G474RE.build.board=NUCLEO_G474RE Nucleo_64.menu.pnum.NUCLEO_G474RE.build.series=STM32G4xx Nucleo_64.menu.pnum.NUCLEO_G474RE.build.product_line=STM32G474xx @@ -335,7 +350,8 @@ Nucleo_64.menu.pnum.NUCLEO_L452RE=Nucleo L452RE Nucleo_64.menu.pnum.NUCLEO_L452RE.node=NODE_L452RE Nucleo_64.menu.pnum.NUCLEO_L452RE.upload.maximum_size=524288 Nucleo_64.menu.pnum.NUCLEO_L452RE.upload.maximum_data_size=163840 -Nucleo_64.menu.pnum.NUCLEO_L452RE.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.NUCLEO_L452RE.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.NUCLEO_L452RE.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.NUCLEO_L452RE.build.board=NUCLEO_L452RE Nucleo_64.menu.pnum.NUCLEO_L452RE.build.series=STM32L4xx Nucleo_64.menu.pnum.NUCLEO_L452RE.build.product_line=STM32L452xx @@ -348,7 +364,8 @@ Nucleo_64.menu.pnum.NUCLEO_L476RG=Nucleo L476RG Nucleo_64.menu.pnum.NUCLEO_L476RG.node=NODE_L476RG Nucleo_64.menu.pnum.NUCLEO_L476RG.upload.maximum_size=1048576 Nucleo_64.menu.pnum.NUCLEO_L476RG.upload.maximum_data_size=98304 -Nucleo_64.menu.pnum.NUCLEO_L476RG.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.NUCLEO_L476RG.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.NUCLEO_L476RG.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.NUCLEO_L476RG.build.board=NUCLEO_L476RG Nucleo_64.menu.pnum.NUCLEO_L476RG.build.series=STM32L4xx Nucleo_64.menu.pnum.NUCLEO_L476RG.build.product_line=STM32L476xx @@ -360,7 +377,8 @@ Nucleo_64.menu.pnum.PNUCLEO_WB55RG=P-Nucleo WB55RG Nucleo_64.menu.pnum.PNUCLEO_WB55RG.node=NODE_WB55RG Nucleo_64.menu.pnum.PNUCLEO_WB55RG.upload.maximum_size=524288 Nucleo_64.menu.pnum.PNUCLEO_WB55RG.upload.maximum_data_size=196604 -Nucleo_64.menu.pnum.PNUCLEO_WB55RG.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_64.menu.pnum.PNUCLEO_WB55RG.build.mcu=cortex-m4 +Nucleo_64.menu.pnum.PNUCLEO_WB55RG.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_64.menu.pnum.PNUCLEO_WB55RG.build.board=PNUCLEO_WB55RG Nucleo_64.menu.pnum.PNUCLEO_WB55RG.build.series=STM32WBxx Nucleo_64.menu.pnum.PNUCLEO_WB55RG.build.product_line=STM32WB55xx @@ -414,7 +432,8 @@ Nucleo_32.menu.pnum.NUCLEO_L412KB=Nucleo L412KB Nucleo_32.menu.pnum.NUCLEO_L412KB.node=NODE_L412KB Nucleo_32.menu.pnum.NUCLEO_L412KB.upload.maximum_size=131072 Nucleo_32.menu.pnum.NUCLEO_L412KB.upload.maximum_data_size=40960 -Nucleo_32.menu.pnum.NUCLEO_L412KB.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_32.menu.pnum.NUCLEO_L412KB.build.mcu=cortex-m4 +Nucleo_32.menu.pnum.NUCLEO_L412KB.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_32.menu.pnum.NUCLEO_L412KB.build.board=NUCLEO_L412KB Nucleo_32.menu.pnum.NUCLEO_L412KB.build.series=STM32L4xx Nucleo_32.menu.pnum.NUCLEO_L412KB.build.product_line=STM32L412xx @@ -426,7 +445,8 @@ Nucleo_32.menu.pnum.NUCLEO_L432KC=Nucleo L432KC Nucleo_32.menu.pnum.NUCLEO_L432KC.node=NODE_L432KC Nucleo_32.menu.pnum.NUCLEO_L432KC.upload.maximum_size=262144 Nucleo_32.menu.pnum.NUCLEO_L432KC.upload.maximum_data_size=65536 -Nucleo_32.menu.pnum.NUCLEO_L432KC.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_32.menu.pnum.NUCLEO_L432KC.build.mcu=cortex-m4 +Nucleo_32.menu.pnum.NUCLEO_L432KC.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_32.menu.pnum.NUCLEO_L432KC.build.board=NUCLEO_L432KC Nucleo_32.menu.pnum.NUCLEO_L432KC.build.series=STM32L4xx Nucleo_32.menu.pnum.NUCLEO_L432KC.build.product_line=STM32L432xx @@ -438,7 +458,8 @@ Nucleo_32.menu.pnum.NUCLEO_F303K8=Nucleo F303K8 Nucleo_32.menu.pnum.NUCLEO_F303K8.node=NODE_F303K8 Nucleo_32.menu.pnum.NUCLEO_F303K8.upload.maximum_size=65536 Nucleo_32.menu.pnum.NUCLEO_F303K8.upload.maximum_data_size=12288 -Nucleo_32.menu.pnum.NUCLEO_F303K8.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_32.menu.pnum.NUCLEO_F303K8.build.mcu=cortex-m4 +Nucleo_32.menu.pnum.NUCLEO_F303K8.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_32.menu.pnum.NUCLEO_F303K8.build.board=NUCLEO_F303K8 Nucleo_32.menu.pnum.NUCLEO_F303K8.build.series=STM32F3xx Nucleo_32.menu.pnum.NUCLEO_F303K8.build.product_line=STM32F303x8 @@ -450,7 +471,8 @@ Nucleo_32.menu.pnum.NUCLEO_G431KB=Nucleo G431KB Nucleo_32.menu.pnum.NUCLEO_G431KB.node=NODE_G431KB Nucleo_32.menu.pnum.NUCLEO_G431KB.upload.maximum_size=131072 Nucleo_32.menu.pnum.NUCLEO_G431KB.upload.maximum_data_size=32768 -Nucleo_32.menu.pnum.NUCLEO_G431KB.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Nucleo_32.menu.pnum.NUCLEO_G431KB.build.mcu=cortex-m4 +Nucleo_32.menu.pnum.NUCLEO_G431KB.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Nucleo_32.menu.pnum.NUCLEO_G431KB.build.board=NUCLEO_G431KB Nucleo_32.menu.pnum.NUCLEO_G431KB.build.series=STM32G4xx Nucleo_32.menu.pnum.NUCLEO_G431KB.build.product_line=STM32G431xx @@ -528,7 +550,8 @@ Disco.menu.pnum.DISCO_F407VG=STM32F407G-DISC1 Disco.menu.pnum.DISCO_F407VG.node=DIS_F407VG Disco.menu.pnum.DISCO_F407VG.upload.maximum_size=1048576 Disco.menu.pnum.DISCO_F407VG.upload.maximum_data_size=196608 -Disco.menu.pnum.DISCO_F407VG.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Disco.menu.pnum.DISCO_F407VG.build.mcu=cortex-m4 +Disco.menu.pnum.DISCO_F407VG.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Disco.menu.pnum.DISCO_F407VG.build.board=DISCO_F407VG Disco.menu.pnum.DISCO_F407VG.build.series=STM32F4xx Disco.menu.pnum.DISCO_F407VG.build.product_line=STM32F407xx @@ -540,7 +563,8 @@ Disco.menu.pnum.DISCO_F746NG=STM32F746G-DISCOVERY Disco.menu.pnum.DISCO_F746NG.node=DIS_F746NG Disco.menu.pnum.DISCO_F746NG.upload.maximum_size=1048576 Disco.menu.pnum.DISCO_F746NG.upload.maximum_data_size=327680 -Disco.menu.pnum.DISCO_F746NG.build.mcu=cortex-m7 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Disco.menu.pnum.DISCO_F746NG.build.mcu=cortex-m7 +Disco.menu.pnum.DISCO_F746NG.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Disco.menu.pnum.DISCO_F746NG.build.board=DISCO_F746NG Disco.menu.pnum.DISCO_F746NG.build.series=STM32F7xx Disco.menu.pnum.DISCO_F746NG.build.product_line=STM32F746xx @@ -552,7 +576,8 @@ Disco.menu.pnum.DISCO_L475VG_IOT=STM32L475VG-DISCOVERY-IOT Disco.menu.pnum.DISCO_L475VG_IOT.node=DIS_L4IOT Disco.menu.pnum.DISCO_L475VG_IOT.upload.maximum_size=1048576 Disco.menu.pnum.DISCO_L475VG_IOT.upload.maximum_data_size=98304 -Disco.menu.pnum.DISCO_L475VG_IOT.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Disco.menu.pnum.DISCO_L475VG_IOT.build.mcu=cortex-m4 +Disco.menu.pnum.DISCO_L475VG_IOT.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Disco.menu.pnum.DISCO_L475VG_IOT.build.board=DISCO_L475VG_IOT Disco.menu.pnum.DISCO_L475VG_IOT.build.series=STM32L4xx Disco.menu.pnum.DISCO_L475VG_IOT.build.product_line=STM32L475xx @@ -606,7 +631,8 @@ Eval.build.extra_flags=-D{build.product_line} {build.enable_usb} {build.xSerial} Eval.menu.pnum.STEVAL_MKSBOX1V1=SensorTile.box Eval.menu.pnum.STEVAL_MKSBOX1V1.upload.maximum_size=2097152 Eval.menu.pnum.STEVAL_MKSBOX1V1.upload.maximum_data_size=655360 -Eval.menu.pnum.STEVAL_MKSBOX1V1.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Eval.menu.pnum.STEVAL_MKSBOX1V1.build.mcu=cortex-m4 +Eval.menu.pnum.STEVAL_MKSBOX1V1.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Eval.menu.pnum.STEVAL_MKSBOX1V1.build.board=STEVAL_MKSBOX1V1 Eval.menu.pnum.STEVAL_MKSBOX1V1.build.series=STM32L4xx Eval.menu.pnum.STEVAL_MKSBOX1V1.build.product_line=STM32L4R9xx @@ -825,7 +851,8 @@ GenF3.build.vid=0x0483 GenF3.build.core=arduino GenF3.build.board=GenF3 GenF3.build.extra_flags=-D{build.product_line} {build.enable_usb} {build.xSerial} {build.bootloader_flags} -GenF3.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +GenF3.build.mcu=cortex-m4 +GenF3.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard GenF3.build.series=STM32F3xx GenF3.build.cmsis_lib_gcc=arm_cortexM4l_math @@ -866,7 +893,8 @@ GenF4.build.vid=0x0483 GenF4.build.core=arduino GenF4.build.board=GenF4 GenF4.build.extra_flags=-D{build.product_line} {build.enable_usb} {build.xSerial} {build.bootloader_flags} -GenF4.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +GenF4.build.mcu=cortex-m4 +GenF4.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard GenF4.build.series=STM32F4xx GenF4.build.cmsis_lib_gcc=arm_cortexM4l_math @@ -910,13 +938,13 @@ GenF4.menu.pnum.BLUE_F407VE_Mini.build.board=BLUE_F407VE_Mini GenF4.menu.pnum.BLUE_F407VE_Mini.build.product_line=STM32F407xx GenF4.menu.pnum.BLUE_F407VE_Mini.build.variant=BLUE_F407VE_Mini -# DIYMROE STM32F407VGT board -GenF4.menu.pnum.DIYMROE_F407VGT=DIYMROE STM32F407VGT -GenF4.menu.pnum.DIYMROE_F407VGT.upload.maximum_size=1048576 -GenF4.menu.pnum.DIYMROE_F407VGT.upload.maximum_data_size=131072 -GenF4.menu.pnum.DIYMROE_F407VGT.build.board=DIYMROE_F407VGT -GenF4.menu.pnum.DIYMROE_F407VGT.build.product_line=STM32F407xx -GenF4.menu.pnum.DIYMROE_F407VGT.build.variant=DIYMROE_F407VGT +# DIYMORE STM32F407VGT board +GenF4.menu.pnum.DIYMORE_F407VGT=DIYMORE STM32F407VGT +GenF4.menu.pnum.DIYMORE_F407VGT.upload.maximum_size=1048576 +GenF4.menu.pnum.DIYMORE_F407VGT.upload.maximum_data_size=131072 +GenF4.menu.pnum.DIYMORE_F407VGT.build.board=DIYMORE_F407VGT +GenF4.menu.pnum.DIYMORE_F407VGT.build.product_line=STM32F407xx +GenF4.menu.pnum.DIYMORE_F407VGT.build.variant=DIYMORE_F407VGT # FK407M1 GenF4.menu.pnum.FK407M1=FK407M1 STM32F407VET @@ -982,7 +1010,8 @@ Sparky.build.extra_flags=-D{build.product_line} {build.enable_usb} {build.xSeria Sparky.menu.pnum.Sparky_V1=Sparky V1 Sparky.menu.pnum.Sparky_V1.upload.maximum_size=262144 Sparky.menu.pnum.Sparky_V1.upload.maximum_data_size=40960 -Sparky.menu.pnum.Sparky_V1.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Sparky.menu.pnum.Sparky_V1.build.mcu=cortex-m4 +Sparky.menu.pnum.Sparky_V1.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Sparky.menu.pnum.Sparky_V1.build.board=Sparky_V1 Sparky.menu.pnum.Sparky_V1.build.series=STM32F3xx Sparky.menu.pnum.Sparky_V1.build.product_line=STM32F303xC @@ -1063,7 +1092,8 @@ RAK.menu.upload_method.dfuMethod.upload.tool=stm32CubeProg 3dprinter.menu.pnum.ARMED_V1=Armed V1 3dprinter.menu.pnum.ARMED_V1.upload.maximum_size=1048576 3dprinter.menu.pnum.ARMED_V1.upload.maximum_data_size=196608 -3dprinter.menu.pnum.ARMED_V1.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +3dprinter.menu.pnum.ARMED_V1.build.mcu=cortex-m4 +3dprinter.menu.pnum.ARMED_V1.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard 3dprinter.menu.pnum.ARMED_V1.build.board=ARMED_V1 3dprinter.menu.pnum.ARMED_V1.build.series=STM32F4xx 3dprinter.menu.pnum.ARMED_V1.build.product_line=STM32F407xx @@ -1076,7 +1106,8 @@ RAK.menu.upload_method.dfuMethod.upload.tool=stm32CubeProg 3dprinter.menu.pnum.REMRAM_V1=RemRam v1 3dprinter.menu.pnum.REMRAM_V1.upload.maximum_size=2097152 3dprinter.menu.pnum.REMRAM_V1.upload.maximum_data_size=524288 -3dprinter.menu.pnum.REMRAM_V1.build.mcu=cortex-m7 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +3dprinter.menu.pnum.REMRAM_V1.build.mcu=cortex-m7 +3dprinter.menu.pnum.REMRAM_V1.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard 3dprinter.menu.pnum.REMRAM_V1.build.board=REMRAM_V1 3dprinter.menu.pnum.REMRAM_V1.build.series=STM32F7xx 3dprinter.menu.pnum.REMRAM_V1.build.product_line=STM32F765xx @@ -1087,7 +1118,8 @@ RAK.menu.upload_method.dfuMethod.upload.tool=stm32CubeProg 3dprinter.menu.pnum.RUMBA32=RUMBA32 3dprinter.menu.pnum.RUMBA32.upload.maximum_size=524288 3dprinter.menu.pnum.RUMBA32.upload.maximum_data_size=131072 -3dprinter.menu.pnum.RUMBA32.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +3dprinter.menu.pnum.RUMBA32.build.mcu=cortex-m4 +3dprinter.menu.pnum.RUMBA32.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard 3dprinter.menu.pnum.RUMBA32.build.board=RUMBA32_F446VE 3dprinter.menu.pnum.RUMBA32.build.series=STM32F4xx 3dprinter.menu.pnum.RUMBA32.build.product_line=STM32F446xx @@ -1098,7 +1130,8 @@ RAK.menu.upload_method.dfuMethod.upload.tool=stm32CubeProg 3dprinter.menu.pnum.ST3DP001_EVAL=STEVAL-3DP001V1 3dprinter.menu.pnum.ST3DP001_EVAL.upload.maximum_size=524288 3dprinter.menu.pnum.ST3DP001_EVAL.upload.maximum_data_size=98304 -3dprinter.menu.pnum.ST3DP001_EVAL.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +3dprinter.menu.pnum.ST3DP001_EVAL.build.mcu=cortex-m4 +3dprinter.menu.pnum.ST3DP001_EVAL.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard 3dprinter.menu.pnum.ST3DP001_EVAL.build.board=ST3DP001_EVAL 3dprinter.menu.pnum.ST3DP001_EVAL.build.series=STM32F4xx 3dprinter.menu.pnum.ST3DP001_EVAL.build.product_line=STM32F401xE @@ -1109,7 +1142,8 @@ RAK.menu.upload_method.dfuMethod.upload.tool=stm32CubeProg 3dprinter.menu.pnum.PRNTR_F407_V1=PRNTR F407 v1 3dprinter.menu.pnum.PRNTR_F407_V1.upload.maximum_size=524288 3dprinter.menu.pnum.PRNTR_F407_V1.upload.maximum_data_size=196608 -3dprinter.menu.pnum.PRNTR_F407_V1.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +3dprinter.menu.pnum.PRNTR_F407_V1.build.mcu=cortex-m4 +3dprinter.menu.pnum.PRNTR_F407_V1.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard 3dprinter.menu.pnum.PRNTR_F407_V1.build.board=PRNTR_F407_V1 3dprinter.menu.pnum.PRNTR_F407_V1.build.series=STM32F4xx 3dprinter.menu.pnum.PRNTR_F407_V1.build.product_line=STM32F407xx @@ -1157,7 +1191,8 @@ RAK.menu.upload_method.dfuMethod.upload.tool=stm32CubeProg 3dprinter.menu.pnum.VAKE_F446VE=VAkE v1.0 3dprinter.menu.pnum.VAKE_F446VE.upload.maximum_size=524288 3dprinter.menu.pnum.VAKE_F446VE.upload.maximum_data_size=131072 -3dprinter.menu.pnum.VAKE_F446VE.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +3dprinter.menu.pnum.VAKE_F446VE.build.mcu=cortex-m4 +3dprinter.menu.pnum.VAKE_F446VE.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard 3dprinter.menu.pnum.VAKE_F446VE.build.board=VAKE403 3dprinter.menu.pnum.VAKE_F446VE.build.series=STM32F4xx 3dprinter.menu.pnum.VAKE_F446VE.build.product_line=STM32F446xx @@ -1266,7 +1301,8 @@ Midatronics.menu.pnum.MKR_SHARKY=MKR Sharky Midatronics.menu.pnum.MKR_SHARKY.node=NODE_WB55CE Midatronics.menu.pnum.MKR_SHARKY.upload.maximum_size=524288 Midatronics.menu.pnum.MKR_SHARKY.upload.maximum_data_size=196604 -Midatronics.menu.pnum.MKR_SHARKY.build.mcu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard +Midatronics.menu.pnum.MKR_SHARKY.build.mcu=cortex-m4 +Midatronics.menu.pnum.MKR_SHARKY.build.flags.fp=-mfpu=fpv4-sp-d16 -mfloat-abi=hard Midatronics.menu.pnum.MKR_SHARKY.build.board=MKR_SHARKY Midatronics.menu.pnum.MKR_SHARKY.build.series=STM32WBxx Midatronics.menu.pnum.MKR_SHARKY.build.product_line=STM32WB55xx diff --git a/libraries/SoftwareSerial/examples/SoftwareSerialExample/SoftwareSerialExample.ino b/libraries/SoftwareSerial/examples/SoftwareSerialExample/SoftwareSerialExample.ino new file mode 100644 index 0000000000..61ce88c629 --- /dev/null +++ b/libraries/SoftwareSerial/examples/SoftwareSerialExample/SoftwareSerialExample.ino @@ -0,0 +1,55 @@ +/* + Software serial multple serial test + + Receives from the hardware serial, sends to software serial. + Receives from software serial, sends to hardware serial. + + The circuit: + * RX is digital pin 10 (connect to TX of other device) + * TX is digital pin 11 (connect to RX of other device) + + Note: + Not all pins on the Mega and Mega 2560 support change interrupts, + so only the following can be used for RX: + 10, 11, 12, 13, 50, 51, 52, 53, 62, 63, 64, 65, 66, 67, 68, 69 + + Not all pins on the Leonardo and Micro support change interrupts, + so only the following can be used for RX: + 8, 9, 10, 11, 14 (MISO), 15 (SCK), 16 (MOSI). + + created back in the mists of time + modified 25 May 2012 + by Tom Igoe + based on Mikal Hart's example + + This example code is in the public domain. + + */ +#include + +SoftwareSerial mySerial(10, 11); // RX, TX + +void setup() { + // Open serial communications and wait for port to open: + Serial.begin(57600); + while (!Serial) { + ; // wait for serial port to connect. Needed for native USB port only + } + + + Serial.println("Goodnight moon!"); + + // set the data rate for the SoftwareSerial port + mySerial.begin(4800); + mySerial.println("Hello, world?"); +} + +void loop() { // run over and over + if (mySerial.available()) { + Serial.write(mySerial.read()); + } + if (Serial.available()) { + mySerial.write(Serial.read()); + } +} + diff --git a/libraries/SoftwareSerial/examples/TwoPortReceive/TwoPortReceive.ino b/libraries/SoftwareSerial/examples/TwoPortReceive/TwoPortReceive.ino new file mode 100644 index 0000000000..8d7f93e8f2 --- /dev/null +++ b/libraries/SoftwareSerial/examples/TwoPortReceive/TwoPortReceive.ino @@ -0,0 +1,91 @@ +/* + Software serial multple serial test + + Receives from the two software serial ports, + sends to the hardware serial port. + + In order to listen on a software port, you call port.listen(). + When using two software serial ports, you have to switch ports + by listen()ing on each one in turn. Pick a logical time to switch + ports, like the end of an expected transmission, or when the + buffer is empty. This example switches ports when there is nothing + more to read from a port + + The circuit: + Two devices which communicate serially are needed. + * First serial device's TX attached to digital pin 10(RX), RX to pin 11(TX) + * Second serial device's TX attached to digital pin 8(RX), RX to pin 9(TX) + + Note: + Not all pins on the Mega and Mega 2560 support change interrupts, + so only the following can be used for RX: + 10, 11, 12, 13, 50, 51, 52, 53, 62, 63, 64, 65, 66, 67, 68, 69 + + Not all pins on the Leonardo support change interrupts, + so only the following can be used for RX: + 8, 9, 10, 11, 14 (MISO), 15 (SCK), 16 (MOSI). + + created 18 Apr. 2011 + modified 19 March 2016 + by Tom Igoe + based on Mikal Hart's twoPortRXExample + + This example code is in the public domain. + + */ + +#include +// software serial #1: RX = digital pin 10, TX = digital pin 11 +SoftwareSerial portOne(10, 11); + +// software serial #2: RX = digital pin 8, TX = digital pin 9 +// on the Mega, use other pins instead, since 8 and 9 don't work on the Mega +SoftwareSerial portTwo(8, 9); + +void setup() { + // Open serial communications and wait for port to open: + Serial.begin(9600); + while (!Serial) { + ; // wait for serial port to connect. Needed for native USB port only + } + + + // Start each software serial port + portOne.begin(9600); + portTwo.begin(9600); +} + +void loop() { + // By default, the last intialized port is listening. + // when you want to listen on a port, explicitly select it: + portOne.listen(); + Serial.println("Data from port one:"); + // while there is data coming in, read it + // and send to the hardware serial port: + while (portOne.available() > 0) { + char inByte = portOne.read(); + Serial.write(inByte); + } + + // blank line to separate data from the two ports: + Serial.println(); + + // Now listen on the second port + portTwo.listen(); + // while there is data coming in, read it + // and send to the hardware serial port: + Serial.println("Data from port two:"); + while (portTwo.available() > 0) { + char inByte = portTwo.read(); + Serial.write(inByte); + } + + // blank line to separate data from the two ports: + Serial.println(); +} + + + + + + diff --git a/libraries/SoftwareSerial/keywords.txt b/libraries/SoftwareSerial/keywords.txt new file mode 100644 index 0000000000..aaea17c202 --- /dev/null +++ b/libraries/SoftwareSerial/keywords.txt @@ -0,0 +1,30 @@ +####################################### +# Syntax Coloring Map for SoftwareSerial +# (formerly NewSoftSerial) +####################################### + +####################################### +# Datatypes (KEYWORD1) +####################################### + +SoftwareSerial KEYWORD1 + +####################################### +# Methods and Functions (KEYWORD2) +####################################### + +begin KEYWORD2 +end KEYWORD2 +read KEYWORD2 +write KEYWORD2 +available KEYWORD2 +isListening KEYWORD2 +overflow KEYWORD2 +flush KEYWORD2 +listen KEYWORD2 +peek KEYWORD2 + +####################################### +# Constants (LITERAL1) +####################################### + diff --git a/libraries/SoftwareSerial/library.properties b/libraries/SoftwareSerial/library.properties new file mode 100644 index 0000000000..4dcebb4106 --- /dev/null +++ b/libraries/SoftwareSerial/library.properties @@ -0,0 +1,10 @@ +name=SoftwareSerial +version=1.0 +author=Arduino, Armin van der Togt +maintainer=stm32duino +sentence=Enables serial communication on any digital pin. +paragraph=The SoftwareSerial library has been developed to allow serial communication on any digital pin of the board, using software to replicate the functionality of the hardware UART. It is possible to have multiple software serial ports. +category=Communication +url=http://www.arduino.cc/en/Reference/SoftwareSerial +architectures=stm32 + diff --git a/libraries/SoftwareSerial/src/SoftwareSerial.cpp b/libraries/SoftwareSerial/src/SoftwareSerial.cpp new file mode 100644 index 0000000000..e15db5b1df --- /dev/null +++ b/libraries/SoftwareSerial/src/SoftwareSerial.cpp @@ -0,0 +1,441 @@ +/* + * SoftwareSerial.cpp (formerly NewSoftSerial.cpp) + * + * Multi-instance software serial library for Arduino/Wiring + * -- Interrupt-driven receive and other improvements by ladyada + * (http://ladyada.net) + * -- Tuning, circular buffer, derivation from class Print/Stream, + * multi-instance support, porting to 8MHz processors, + * various optimizations, PROGMEM delay tables, inverse logic and + * direct port writing by Mikal Hart (http://www.arduiniana.org) + * -- Pin change interrupt macros by Paul Stoffregen (http://www.pjrc.com) + * -- 20MHz processor support by Garrett Mace (http://www.macetech.com) + * -- ATmega1280/2560 support by Brett Hagman (http://www.roguerobotics.com/) + * -- STM32 support by Armin van der Togt + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + * + * The latest version of this library can always be found at + * http://arduiniana.org. + */ + +// +// Includes +// +#include +#include + +#include +#include + +#include +#include "SoftwareSerial.h" +#include +#include +#include + +#define OVERSAMPLE 3 +// defined in bit-periods +#define HALFDUPLEX_SWITCH_DELAY 5 +// It's best to define TIMER_SERIAL in variant.h. If not defined, we choose one here +// The order is based on (lack of) features and compare channels, we choose the simplest available +// because we only need an update interrupt +#if !defined(TIMER_SERIAL) +#if defined (TIM18_BASE) +#define TIMER_SERIAL TIM18 +#elif defined (TIM7_BASE) +#define TIMER_SERIAL TIM7 +#elif defined (TIM6_BASE) +#define TIMER_SERIAL TIM6 +#elif defined (TIM22_BASE) +#define TIMER_SERIAL TIM22 +#elif defined (TIM21_BASE) +#define TIMER_SERIAL TIM21 +#elif defined (TIM17_BASE) +#define TIMER_SERIAL TIM17 +#elif defined (TIM16_BASE) +#define TIMER_SERIAL TIM16 +#elif defined (TIM15_BASE) +#define TIMER_SERIAL TIM15 +#elif defined (TIM14_BASE) +#define TIMER_SERIAL TIM14 +#elif defined (TIM13_BASE) +#define TIMER_SERIAL TIM13 +#elif defined (TIM11_BASE) +#define TIMER_SERIAL TIM11 +#elif defined (TIM10_BASE) +#define TIMER_SERIAL TIM10 +#elif defined (TIM12_BASE) +#define TIMER_SERIAL TIM12 +#elif defined (TIM19_BASE) +#define TIMER_SERIAL TIM19 +#elif defined (TIM9_BASE) +#define TIMER_SERIAL TIM9 +#elif defined (TIM5_BASE) +#define TIMER_SERIAL TIM5 +#elif defined (TIM4_BASE) +#define TIMER_SERIAL TIM4 +#elif defined (TIM3_BASE) +#define TIMER_SERIAL TIM3 +#elif defined (TIM2_BASE) +#define TIMER_SERIAL TIM2 +#elif defined (TIM20_BASE) +#define TIMER_SERIAL TIM20 +#elif defined (TIM8_BASE) +#define TIMER_SERIAL TIM8 +#elif defined (TIM1_BASE) +#define TIMER_SERIAL TIM1 +#else +#error No suitable timer found for SoftwareSerial, define TIMER_SERIAL in variant.h +#endif +#endif +// +// Statics +// +HardwareTimer SoftwareSerial::timer(TIMER_SERIAL); +SoftwareSerial *SoftwareSerial::active_listener = nullptr; +SoftwareSerial *volatile SoftwareSerial::active_out = nullptr; +SoftwareSerial *volatile SoftwareSerial::active_in = nullptr; +int32_t SoftwareSerial::tx_tick_cnt = 0; +int32_t volatile SoftwareSerial::rx_tick_cnt = 0; +uint32_t SoftwareSerial::tx_buffer = 0; +int32_t SoftwareSerial::tx_bit_cnt = 0; +uint32_t SoftwareSerial::rx_buffer = 0; +int32_t SoftwareSerial::rx_bit_cnt = -1; +uint32_t SoftwareSerial::cur_speed = 0; +uint8_t SoftwareSerial::rx_high_count = 0; +uint8_t SoftwareSerial::rx_low_count = 0; + +// +// Private methods +// + +void SoftwareSerial::setSpeed(uint32_t speed) +{ + if (speed != cur_speed) { + timer.pause(); + if (speed != 0) { + // Disable the timer + uint32_t clock_rate, cmp_value; + // Get timer clock + clock_rate = timer.getTimerClkFreq(); + int pre = 1; + // Calculate prescale an compare value + do { + cmp_value = clock_rate / (speed * OVERSAMPLE); + if (cmp_value >= UINT16_MAX) { + clock_rate = clock_rate / 2; + pre *= 2; + } + } while (cmp_value >= UINT16_MAX); + timer.setPrescaleFactor(pre); + timer.setOverflow(cmp_value); + timer.setCount(0); + timer.attachInterrupt(&handleInterrupt); + timer.resume(); + } else { + timer.detachInterrupt(); + } + cur_speed = speed; + } +} + +// This function sets the current object as the "listening" +// one and returns true if it replaces another +bool SoftwareSerial::listen() +{ + if (_receivePin >= 0) { + // wait for any transmit to complete as we may change speed + while (active_out) + ; + if (active_listener) { + active_listener->stopListening(); + } + rx_tick_cnt = 0; + rx_bit_cnt = -1; + setSpeed(_speed); + active_listener = this; + if (!_half_duplex) { + active_in = this; + } + return true; + } + return false; +} + +// Stop listening. Returns true if we were actually listening. +bool SoftwareSerial::stopListening() +{ + if (active_listener == this) { + // wait for any output to complete + while (active_out) + ; + if (_half_duplex) { + setRXTX(false); + } + active_listener = nullptr; + active_in = nullptr; + // turn off ints + setSpeed(0); + return true; + } + return false; +} + +inline void SoftwareSerial::setTX() +{ + if (_inverse_logic) { + LL_GPIO_ResetOutputPin(_transmitPinPort, _transmitPinNumber); + } else { + LL_GPIO_SetOutputPin(_transmitPinPort, _transmitPinNumber); + } + pinMode(_transmitPin, OUTPUT); +} + +inline void SoftwareSerial::setRX() +{ + if (_receivePin > 0) { + pinMode(_receivePin, _inverse_logic ? INPUT_PULLDOWN : INPUT_PULLUP); // pullup for normal logic! + } +} + +inline void SoftwareSerial::setRXTX(bool input) +{ + if (_half_duplex) { + if (input) { + if (active_in != this) { + setRX(); + rx_bit_cnt = -1; + rx_tick_cnt = 1; + active_in = this; + } + } else { + if (active_in == this) { + setTX(); + active_in = nullptr; + } + } + } +} + +inline void SoftwareSerial::send() +{ + if (--tx_tick_cnt < 0) { + if (tx_bit_cnt++ < 10) { + // send data (including start and stop bits) + if (tx_buffer & 1) { + LL_GPIO_SetOutputPin(_transmitPinPort, _transmitPinNumber); + } else { + LL_GPIO_ResetOutputPin(_transmitPinPort, _transmitPinNumber); + + } + tx_buffer >>= 1; + tx_tick_cnt = OVERSAMPLE - 1; // first sample sent, OVERSAMPLE - 1 more samples to go + } else { + tx_tick_cnt = 0; + if (_output_pending || !(_half_duplex && active_listener == this)) { + active_out = nullptr; + // When in half-duplex mode, we wait for HALFDUPLEX_SWITCH_DELAY bit-periods after the byte has + // been transmitted before allowing the switch to RX mode + } else if (tx_bit_cnt > 10 + HALFDUPLEX_SWITCH_DELAY * OVERSAMPLE) { + pinMode(_receivePin, _inverse_logic ? INPUT_PULLDOWN : INPUT_PULLUP); // pullup for normal logic! + rx_bit_cnt = -1; + rx_tick_cnt = 1; + active_in = this; + active_out = nullptr; + } + } + } +} + +// +// The receive routine called by the interrupt handler +// +inline void SoftwareSerial::recv() +{ + if (LL_GPIO_IsInputPinSet(_receivePinPort, _receivePinNumber)) { + rx_high_count++; + } else { + rx_low_count++; + } + if (--rx_tick_cnt < 0) { + bool inbit = (rx_high_count > rx_low_count) ^ _inverse_logic; + rx_high_count = 0; + rx_low_count = 0; + if (rx_bit_cnt == -1) { + // waiting for start bit + if (!inbit) { + // got start bit + rx_bit_cnt = 0; + rx_tick_cnt = OVERSAMPLE - 1; // First sample taken, we will take OVERSAMPLE - 1 more samples + rx_buffer = 0; + } else { + rx_tick_cnt = 0; + } + } else if (rx_bit_cnt >= 8) { + if (inbit) { + // stop bit read complete add to buffer + uint8_t next = (_receive_buffer_tail + 1) % _SS_MAX_RX_BUFF; + if (next != _receive_buffer_head) { + // save new data in buffer: tail points to where byte goes + _receive_buffer[_receive_buffer_tail] = rx_buffer; // save new byte + _receive_buffer_tail = next; + } else { + _buffer_overflow = true; + } + } + rx_tick_cnt = 0; + rx_bit_cnt = -1; + } else { + // data bits + rx_buffer >>= 1; + if (inbit) { + rx_buffer |= 0x80; + } + rx_bit_cnt++; + rx_tick_cnt = OVERSAMPLE - 1; // First sample taken, we will take OVERSAMPLE - 1 more samples + } + } +} + +// +// Interrupt handling +// + +/* static */ +inline void SoftwareSerial::handleInterrupt(HardwareTimer *timer) +{ + if (active_in) { + active_in->recv(); + } + if (active_out) { + active_out->send(); + } +} +// +// Constructor +// +SoftwareSerial::SoftwareSerial(uint16_t receivePin, uint16_t transmitPin, bool inverse_logic /* = false */) : + _receivePin(receivePin), + _transmitPin(transmitPin), + _receivePinPort(digitalPinToPort(receivePin)), + _receivePinNumber(STM_LL_GPIO_PIN(digitalPinToPinName(receivePin))), + _transmitPinPort(digitalPinToPort(transmitPin)), + _transmitPinNumber(STM_LL_GPIO_PIN(digitalPinToPinName(transmitPin))), + _speed(0), + _buffer_overflow(false), + _inverse_logic(inverse_logic), + _half_duplex(receivePin == transmitPin), + _output_pending(0), + _receive_buffer_tail(0), + _receive_buffer_head(0) +{ + /* Enable GPIO clock for tx and rx pin*/ + set_GPIO_Port_Clock(STM_PORT(digitalPinToPinName(transmitPin))); + set_GPIO_Port_Clock(STM_PORT(digitalPinToPinName(receivePin))); +} + +// +// Destructor +// +SoftwareSerial::~SoftwareSerial() +{ + end(); +} + +// +// Public methods +// + +void SoftwareSerial::begin(long speed) +{ +#ifdef FORCE_BAUD_RATE + speed = FORCE_BAUD_RATE; +#endif + _speed = speed; + if (!_half_duplex) { + setTX(); + setRX(); + } else { + setTX(); + } + + listen(); +} + +void SoftwareSerial::end() +{ + stopListening(); +} + +// Read data from buffer +int SoftwareSerial::read() +{ + // Empty buffer? + if (_receive_buffer_head == _receive_buffer_tail) { + return -1; + } + + // Read from "head" + uint8_t d = _receive_buffer[_receive_buffer_head]; // grab next byte + _receive_buffer_head = (_receive_buffer_head + 1) % _SS_MAX_RX_BUFF; + return d; +} + +int SoftwareSerial::available() +{ + return (_receive_buffer_tail + _SS_MAX_RX_BUFF - _receive_buffer_head) % _SS_MAX_RX_BUFF; +} + +size_t SoftwareSerial::write(uint8_t b) +{ + // wait for previous transmit to complete + _output_pending = 1; + while (active_out) + ; + // add start and stop bits. + tx_buffer = b << 1 | 0x200; + if (_inverse_logic) { + tx_buffer = ~tx_buffer; + } + tx_bit_cnt = 0; + tx_tick_cnt = OVERSAMPLE; + setSpeed(_speed); + if (_half_duplex) { + setRXTX(false); + } + _output_pending = 0; + // make us active + active_out = this; + return 1; +} + +void SoftwareSerial::flush() +{ + noInterrupts(); + _receive_buffer_head = _receive_buffer_tail = 0; + interrupts(); +} + +int SoftwareSerial::peek() +{ + // Empty buffer? + if (_receive_buffer_head == _receive_buffer_tail) { + return -1; + } + + // Read from "head" + return _receive_buffer[_receive_buffer_head]; +} diff --git a/libraries/SoftwareSerial/src/SoftwareSerial.h b/libraries/SoftwareSerial/src/SoftwareSerial.h new file mode 100644 index 0000000000..c8cd4aef10 --- /dev/null +++ b/libraries/SoftwareSerial/src/SoftwareSerial.h @@ -0,0 +1,141 @@ +/* + * SoftwareSerial.h (formerly NewSoftSerial.h) + * + * Multi-instance software serial library for Arduino/Wiring + * -- Interrupt-driven receive and other improvements by ladyada + * (http://ladyada.net) + * -- Tuning, circular buffer, derivation from class Print/Stream, + * multi-instance support, porting to 8MHz processors, + * various optimizations, PROGMEM delay tables, inverse logic and + * direct port writing by Mikal Hart (http://www.arduiniana.org) + * -- Pin change interrupt macros by Paul Stoffregen (http://www.pjrc.com) + * -- 20MHz processor support by Garrett Mace (http://www.macetech.com) + * -- ATmega1280/2560 support by Brett Hagman (http://www.roguerobotics.com/) + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA + * + * The latest version of this library can always be found at + * http://arduiniana.org. + */ + +#ifndef SOFTWARESERIAL_H +#define SOFTWARESERIAL_H + +#include +#include +#include +#include +#include + +/****************************************************************************** +* Definitions +******************************************************************************/ + +#define _SS_MAX_RX_BUFF 64 // RX buffer size + +class SoftwareSerial : public Stream { + private: + // per object data + uint16_t _receivePin; + uint16_t _transmitPin; + GPIO_TypeDef *_receivePinPort; + uint32_t _receivePinNumber; + GPIO_TypeDef *_transmitPinPort; + uint32_t _transmitPinNumber; + uint32_t _speed; + + uint16_t _buffer_overflow: 1; + uint16_t _inverse_logic: 1; + uint16_t _half_duplex: 1; + uint16_t _output_pending: 1; + + unsigned char _receive_buffer[_SS_MAX_RX_BUFF]; + volatile uint8_t _receive_buffer_tail; + volatile uint8_t _receive_buffer_head; + + uint32_t delta_start = 0; + + // static data + static bool initialised; + static HardwareTimer timer; + static SoftwareSerial *active_listener; + static SoftwareSerial *volatile active_out; + static SoftwareSerial *volatile active_in; + static int32_t tx_tick_cnt; + static volatile int32_t rx_tick_cnt; + static uint32_t tx_buffer; + static int32_t tx_bit_cnt; + static uint32_t rx_buffer; + static int32_t rx_bit_cnt; + static uint32_t cur_speed; + static uint8_t rx_high_count; + static uint8_t rx_low_count; + + // private methods + void send(); + void recv(); + void setTX(); + void setRX(); + void setSpeed(uint32_t speed); + void setRXTX(bool input); + static void handleInterrupt(HardwareTimer *timer); + + public: + // public methods + + SoftwareSerial(uint16_t receivePin, uint16_t transmitPin, bool inverse_logic = false); + virtual ~SoftwareSerial(); + void begin(long speed); + bool listen(); + void end(); + bool isListening() + { + return active_listener == this; + } + bool stopListening(); + bool overflow() + { + bool ret = _buffer_overflow; + if (ret) { + _buffer_overflow = false; + } + return ret; + } + int peek(); + + virtual size_t write(uint8_t byte); + virtual int read(); + virtual int available(); + virtual void flush(); + operator bool() + { + return true; + } + + using Print::write; + //using HalSerial::write; + +}; + +// Arduino 0012 workaround +#undef int +#undef char +#undef long +#undef byte +#undef float +#undef abs +#undef round + +#endif // SOFTWARESERIAL_H diff --git a/platform.txt b/platform.txt index 0c0d565198..927ee76f0c 100644 --- a/platform.txt +++ b/platform.txt @@ -27,7 +27,7 @@ compiler.c.elf.cmd=arm-none-eabi-gcc compiler.objcopy.cmd=arm-none-eabi-objcopy compiler.elf2hex.cmd=arm-none-eabi-objcopy -compiler.extra_flags=-mcpu={build.mcu} -mthumb "@{build.opt.path}" +compiler.extra_flags=-mcpu={build.mcu} {build.flags.fp} -mthumb "@{build.opt.path}" compiler.S.flags={compiler.extra_flags} -c -x assembler-with-cpp {compiler.stm.extra_include} @@ -37,7 +37,7 @@ compiler.cpp.flags={compiler.extra_flags} -c {build.flags.optimize} {compiler.wa compiler.ar.flags=rcs -compiler.c.elf.flags=-mcpu={build.mcu} -mthumb {build.flags.optimize} {build.flags.ldspecs} -Wl,--defsym=LD_FLASH_OFFSET={build.flash_offset} -Wl,--defsym=LD_MAX_SIZE={upload.maximum_size} -Wl,--defsym=LD_MAX_DATA_SIZE={upload.maximum_data_size} -Wl,--cref -Wl,--check-sections -Wl,--gc-sections -Wl,--entry=Reset_Handler -Wl,--unresolved-symbols=report-all -Wl,--warn-common +compiler.c.elf.flags=-mcpu={build.mcu} {build.flags.fp} -mthumb {build.flags.optimize} {build.flags.ldspecs} -Wl,--defsym=LD_FLASH_OFFSET={build.flash_offset} -Wl,--defsym=LD_MAX_SIZE={upload.maximum_size} -Wl,--defsym=LD_MAX_DATA_SIZE={upload.maximum_data_size} -Wl,--cref -Wl,--check-sections -Wl,--gc-sections -Wl,--entry=Reset_Handler -Wl,--unresolved-symbols=report-all -Wl,--warn-common compiler.objcopy.eep.flags=-O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 @@ -82,6 +82,7 @@ build.xSerial=-DHAL_UART_MODULE_ENABLED build.enable_usb= build.usb_speed= build.startup_file= +build.flags.fp= build.flags.optimize=-Os build.flags.ldspecs=--specs=nano.specs build.flash_offset=0 diff --git a/variants/DIYMROE_F407VGT/PeripheralPins.c b/variants/DIYMORE_F407VGT/PeripheralPins.c similarity index 100% rename from variants/DIYMROE_F407VGT/PeripheralPins.c rename to variants/DIYMORE_F407VGT/PeripheralPins.c diff --git a/variants/DIYMROE_F407VGT/PinNamesVar.h b/variants/DIYMORE_F407VGT/PinNamesVar.h similarity index 100% rename from variants/DIYMROE_F407VGT/PinNamesVar.h rename to variants/DIYMORE_F407VGT/PinNamesVar.h diff --git a/variants/DIYMROE_F407VGT/ldscript.ld b/variants/DIYMORE_F407VGT/ldscript.ld similarity index 100% rename from variants/DIYMROE_F407VGT/ldscript.ld rename to variants/DIYMORE_F407VGT/ldscript.ld diff --git a/variants/DIYMROE_F407VGT/variant.cpp b/variants/DIYMORE_F407VGT/variant.cpp similarity index 99% rename from variants/DIYMROE_F407VGT/variant.cpp rename to variants/DIYMORE_F407VGT/variant.cpp index 8b57d5d505..7b4caeef9b 100644 --- a/variants/DIYMROE_F407VGT/variant.cpp +++ b/variants/DIYMORE_F407VGT/variant.cpp @@ -30,7 +30,7 @@ /* * This version created by Andrew W Symons (AWS), 19-Nov-18 - * for DIYMROE_STM32F407VGT board + * for DIYMORE_STM32F407VGT board */ #include "pins_arduino.h" diff --git a/variants/DIYMROE_F407VGT/variant.h b/variants/DIYMORE_F407VGT/variant.h similarity index 99% rename from variants/DIYMROE_F407VGT/variant.h rename to variants/DIYMORE_F407VGT/variant.h index c5b7da57c1..752da0bb8a 100644 --- a/variants/DIYMROE_F407VGT/variant.h +++ b/variants/DIYMORE_F407VGT/variant.h @@ -30,7 +30,7 @@ /* * This version created by Andrew W Symons (AWS), 19-Nov-18 - * for DIYMROE_STM32F407VGT board + * for DIYMORE_STM32F407VGT board */ #ifndef _VARIANT_ARDUINO_STM32_