From 2d4b553a97e0a365b804625381283595ed891b98 Mon Sep 17 00:00:00 2001 From: ziteh Date: Sat, 13 Nov 2021 13:43:46 +0800 Subject: [PATCH 1/7] Move submodule 'libopencm3' to folder lib --- .gitmodules | 2 +- libopencm3 => lib/libopencm3 | 0 2 files changed, 1 insertion(+), 1 deletion(-) rename libopencm3 => lib/libopencm3 (100%) diff --git a/.gitmodules b/.gitmodules index c4a0df1..80b6c43 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,3 +1,3 @@ [submodule "libopencm3"] - path = libopencm3 + path = lib/libopencm3 url = https://github.com/libopencm3/libopencm3.git diff --git a/libopencm3 b/lib/libopencm3 similarity index 100% rename from libopencm3 rename to lib/libopencm3 From 2cfac4d82d9ce0de463ad6b36344591c0aea2771 Mon Sep 17 00:00:00 2001 From: ziteh Date: Sat, 13 Nov 2021 13:44:47 +0800 Subject: [PATCH 2/7] Move 'main.cc' into folder 'examples' --- {src => examples}/main.cc | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename {src => examples}/main.cc (100%) diff --git a/src/main.cc b/examples/main.cc similarity index 100% rename from src/main.cc rename to examples/main.cc From 6d745a65b50749047a5d23e47ba3552262a34e93 Mon Sep 17 00:00:00 2001 From: ziteh Date: Sat, 13 Nov 2021 13:46:36 +0800 Subject: [PATCH 3/7] Move stm32_oop_lib files into src and include --- {lib/stm32_oop_lib => include}/stm32_oop_lib_gpio.h | 0 {lib/stm32_oop_lib => include}/stm32_oop_lib_gpio_mapping.h | 0 {lib/stm32_oop_lib => src}/stm32_oop_lib_gpio.cc | 0 3 files changed, 0 insertions(+), 0 deletions(-) rename {lib/stm32_oop_lib => include}/stm32_oop_lib_gpio.h (100%) rename {lib/stm32_oop_lib => include}/stm32_oop_lib_gpio_mapping.h (100%) rename {lib/stm32_oop_lib => src}/stm32_oop_lib_gpio.cc (100%) diff --git a/lib/stm32_oop_lib/stm32_oop_lib_gpio.h b/include/stm32_oop_lib_gpio.h similarity index 100% rename from lib/stm32_oop_lib/stm32_oop_lib_gpio.h rename to include/stm32_oop_lib_gpio.h diff --git a/lib/stm32_oop_lib/stm32_oop_lib_gpio_mapping.h b/include/stm32_oop_lib_gpio_mapping.h similarity index 100% rename from lib/stm32_oop_lib/stm32_oop_lib_gpio_mapping.h rename to include/stm32_oop_lib_gpio_mapping.h diff --git a/lib/stm32_oop_lib/stm32_oop_lib_gpio.cc b/src/stm32_oop_lib_gpio.cc similarity index 100% rename from lib/stm32_oop_lib/stm32_oop_lib_gpio.cc rename to src/stm32_oop_lib_gpio.cc From 9462645dc282e22f4497523e69b6b7ff20e316af Mon Sep 17 00:00:00 2001 From: ziteh Date: Sat, 13 Nov 2021 13:57:53 +0800 Subject: [PATCH 4/7] Create 'library.json' files for PlatformIO --- library.json | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 library.json diff --git a/library.json b/library.json new file mode 100644 index 0000000..c165cb4 --- /dev/null +++ b/library.json @@ -0,0 +1,17 @@ +{ + "name": "stm32_oop_lib", + "version": "0.2.1", + "description": "The basic OOP library of STM32.", + "keywords": "STM32, STM32F1xx", + "repository": { + "type": "git", + "url": "https://github.com/ziteh/stm32-oop-lib" + }, + "authors": { + "name": "ZiTe", + "email": "honmonoh@gmail.com" + }, + "license": "LGPL-2.1-or-later", + "frameworks": "libopencm3", + "platforms": "ststm32" +} \ No newline at end of file From 470a9741e47d2a3e6693a794ee54c33a9d0c3645 Mon Sep 17 00:00:00 2001 From: ziteh Date: Sat, 13 Nov 2021 14:22:39 +0800 Subject: [PATCH 5/7] Move old file to 'src' folder (#1) --- {lib => src}/f103rb_adc.cpp | 0 {lib => src}/f103rb_adc.hpp | 0 {lib => src}/f103rb_pwm.cpp | 0 {lib => src}/f103rb_pwm.hpp | 0 {lib => src}/f103rb_usart.cpp | 0 {lib => src}/f103rb_usart.hpp | 0 6 files changed, 0 insertions(+), 0 deletions(-) rename {lib => src}/f103rb_adc.cpp (100%) rename {lib => src}/f103rb_adc.hpp (100%) rename {lib => src}/f103rb_pwm.cpp (100%) rename {lib => src}/f103rb_pwm.hpp (100%) rename {lib => src}/f103rb_usart.cpp (100%) rename {lib => src}/f103rb_usart.hpp (100%) diff --git a/lib/f103rb_adc.cpp b/src/f103rb_adc.cpp similarity index 100% rename from lib/f103rb_adc.cpp rename to src/f103rb_adc.cpp diff --git a/lib/f103rb_adc.hpp b/src/f103rb_adc.hpp similarity index 100% rename from lib/f103rb_adc.hpp rename to src/f103rb_adc.hpp diff --git a/lib/f103rb_pwm.cpp b/src/f103rb_pwm.cpp similarity index 100% rename from lib/f103rb_pwm.cpp rename to src/f103rb_pwm.cpp diff --git a/lib/f103rb_pwm.hpp b/src/f103rb_pwm.hpp similarity index 100% rename from lib/f103rb_pwm.hpp rename to src/f103rb_pwm.hpp diff --git a/lib/f103rb_usart.cpp b/src/f103rb_usart.cpp similarity index 100% rename from lib/f103rb_usart.cpp rename to src/f103rb_usart.cpp diff --git a/lib/f103rb_usart.hpp b/src/f103rb_usart.hpp similarity index 100% rename from lib/f103rb_usart.hpp rename to src/f103rb_usart.hpp From eb8af31d1da6a666f1be071eb6d145cd12982a43 Mon Sep 17 00:00:00 2001 From: ziteh Date: Sat, 13 Nov 2021 14:22:56 +0800 Subject: [PATCH 6/7] Remove 'f103rb_lib.hpp' (#1) --- lib/f103rb_lib.hpp | 15 --------------- 1 file changed, 15 deletions(-) delete mode 100644 lib/f103rb_lib.hpp diff --git a/lib/f103rb_lib.hpp b/lib/f103rb_lib.hpp deleted file mode 100644 index a1c0240..0000000 --- a/lib/f103rb_lib.hpp +++ /dev/null @@ -1,15 +0,0 @@ -/** - * @file f103rb_lib.hpp - * @author ZiTe - * @brief Include all F103RB libraries. - */ - -#ifndef F103RB_LIB_HPP_ -#define F103RB_LIB_HPP_ - -#include "f103rb_gpio.hpp" -#include "f103rb_pwm.hpp" -#include "f103rb_usart.hpp" -#include "f103rb_adc.hpp" - -#endif /* F103RB_LIB_HPP_ */ \ No newline at end of file From ec6f0737696fe7afd7e4343f6579493e0a8b3550 Mon Sep 17 00:00:00 2001 From: ziteh Date: Sat, 13 Nov 2021 14:23:56 +0800 Subject: [PATCH 7/7] Rename example code to 'blink.cc' (#1) --- examples/{main.cc => blink.cc} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename examples/{main.cc => blink.cc} (100%) diff --git a/examples/main.cc b/examples/blink.cc similarity index 100% rename from examples/main.cc rename to examples/blink.cc