From 75aa68bae2bb30c8ad17e98644abae55574423e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Heredero?= Date: Thu, 15 Jun 2023 20:55:49 +0200 Subject: [PATCH] polish --- .../ch/kb28/blinkerProject/app/factory/factory.c | 12 +++++------- .../ch/kb28/blinkerProject/app/factory/factory.h | 10 +++++----- .../ch/kb28/blinkerProject/board/button/button.h | 6 ++---- 03-software/ch/kb28/blinkerProject/board/led/led.h | 2 +- .../ch/kb28/blinkerProject/middleware/blinker.c | 5 ++--- .../ch/kb28/blinkerProject/middleware/blinker.h | 7 +++---- .../ch/kb28/blinkerProject/middleware/clickHandler.c | 5 ++--- .../ch/kb28/blinkerProject/middleware/clickHandler.h | 5 ++--- 8 files changed, 22 insertions(+), 30 deletions(-) diff --git a/03-software/ch/kb28/blinkerProject/app/factory/factory.c b/03-software/ch/kb28/blinkerProject/app/factory/factory.c index 7803dee..3133334 100755 --- a/03-software/ch/kb28/blinkerProject/app/factory/factory.c +++ b/03-software/ch/kb28/blinkerProject/app/factory/factory.c @@ -1,3 +1,8 @@ +/** + * @author Rémi Heredero (remi@heredero.ch) + * @version. 0.0.6 + * @date 2023-06-15 + */ #include "factory.h" @@ -64,12 +69,6 @@ BLINKER* blB() { return &theFactory.blB_; } - - -LEDBlinker* lb() { - return &theFactory.lb_; -} - //initialize all objects void Factory_init() { LED_init(l1(), 1); @@ -137,7 +136,6 @@ void Factory_build() { //start all state machines void Factory_start() { - //LEDBlinker_startBehaviour(lb()); BUTTON_startBehaviour(b1()); BUTTON_startBehaviour(b2()); BUTTON_startBehaviour(b3()); diff --git a/03-software/ch/kb28/blinkerProject/app/factory/factory.h b/03-software/ch/kb28/blinkerProject/app/factory/factory.h index 0945190..4db7530 100755 --- a/03-software/ch/kb28/blinkerProject/app/factory/factory.h +++ b/03-software/ch/kb28/blinkerProject/app/factory/factory.h @@ -1,5 +1,8 @@ -/* this is the Factory class */ - +/** + * @author Rémi Heredero (remi@heredero.ch) + * @version. 0.0.6 + * @date 2023-06-15 + */ #ifndef FACTORY_H #define FACTORY_H @@ -9,7 +12,6 @@ #include "../../board/led/led.h" #include "../../board/button/button.h" -#include "../ledblinker.h" #include "../../middleware/clickHandler.h" #include "../../middleware/blinker.h" @@ -32,8 +34,6 @@ typedef struct { CLICK_HANDLER ch3_; BLINKER blA_; BLINKER blB_; - - LEDBlinker lb_; } Factory; diff --git a/03-software/ch/kb28/blinkerProject/board/button/button.h b/03-software/ch/kb28/blinkerProject/board/button/button.h index 6bd8fe9..c3cfbf0 100644 --- a/03-software/ch/kb28/blinkerProject/board/button/button.h +++ b/03-software/ch/kb28/blinkerProject/board/button/button.h @@ -1,9 +1,7 @@ /** - * @file button.h * @author Rémi Heredero (remi@heredero.ch) - * @version 1 - * @date 2023-06-13 - * + * @version. 1.0.0 + * @date 2023-06-15 */ #ifndef BUTTON_H #define BUTTON_H diff --git a/03-software/ch/kb28/blinkerProject/board/led/led.h b/03-software/ch/kb28/blinkerProject/board/led/led.h index e66254d..5255053 100644 --- a/03-software/ch/kb28/blinkerProject/board/led/led.h +++ b/03-software/ch/kb28/blinkerProject/board/led/led.h @@ -1,9 +1,9 @@ /** - * @file led.h * @author Rémi Heredero (remi@heredero.ch) * @version. 1.0.0 * @date 2023-06-15 */ + #ifndef LED_H #define LED_H diff --git a/03-software/ch/kb28/blinkerProject/middleware/blinker.c b/03-software/ch/kb28/blinkerProject/middleware/blinker.c index 73d5894..4ae1419 100644 --- a/03-software/ch/kb28/blinkerProject/middleware/blinker.c +++ b/03-software/ch/kb28/blinkerProject/middleware/blinker.c @@ -1,8 +1,7 @@ /** - * @file blinker.c * @author Rémi Heredero (remi@heredero.ch) - * @version 0 - * @date 2023-06-14 + * @version. 1.0.0 + * @date 2023-06-15 */ #include "blinker.h" diff --git a/03-software/ch/kb28/blinkerProject/middleware/blinker.h b/03-software/ch/kb28/blinkerProject/middleware/blinker.h index 565ec63..4c12fbb 100644 --- a/03-software/ch/kb28/blinkerProject/middleware/blinker.h +++ b/03-software/ch/kb28/blinkerProject/middleware/blinker.h @@ -1,8 +1,7 @@ /** - * @file blinker.h * @author Rémi Heredero (remi@heredero.ch) - * @version 0 - * @date 2023-06-14 + * @version. 1.0.0 + * @date 2023-06-15 */ #ifndef BLINKER_H @@ -32,7 +31,7 @@ typedef struct { } blinkerCallBack; typedef struct { - BLINKER_STATES state; + BLINKER_STATES state; // Actual state uint16_t tON; // Time on uint16_t tOFF; // Time off uint8_t nBlink; // Number of blink for this blinker when start with blinkN diff --git a/03-software/ch/kb28/blinkerProject/middleware/clickHandler.c b/03-software/ch/kb28/blinkerProject/middleware/clickHandler.c index 5c7632d..4068de8 100644 --- a/03-software/ch/kb28/blinkerProject/middleware/clickHandler.c +++ b/03-software/ch/kb28/blinkerProject/middleware/clickHandler.c @@ -1,8 +1,7 @@ /** - * @file clickHandler.c * @author Rémi Heredero (remi@heredero.ch) - * @version 0 - * @date 2023-06-13 + * @version. 1.0.0 + * @date 2023-06-15 */ #include "clickHandler.h" diff --git a/03-software/ch/kb28/blinkerProject/middleware/clickHandler.h b/03-software/ch/kb28/blinkerProject/middleware/clickHandler.h index 5d8598d..d48b3a8 100644 --- a/03-software/ch/kb28/blinkerProject/middleware/clickHandler.h +++ b/03-software/ch/kb28/blinkerProject/middleware/clickHandler.h @@ -1,8 +1,7 @@ /** - * @file clickHandler.h * @author Rémi Heredero (remi@heredero.ch) - * @version 1 - * @date 2023-06-14 + * @version. 1.0.0 + * @date 2023-06-15 */ #ifndef CLICKHANDLER_H