Going on with structure

Added observer/observable for RTC

git-svn-id: https://svn.vbchaos.nl/svn/hsb/trunk@251 05563f52-14a8-4384-a975-3d1654cca0fa
This commit is contained in:
mmi
2017-10-12 20:53:05 +00:00
parent 54b6afe5a3
commit c323bfd04e
23 changed files with 1067 additions and 513 deletions

View File

@@ -44,6 +44,7 @@
#include "stm32f10x_spi.h"
#include "stm32f10x_usart.h"
// -----------------------------------------------------------------------------
// Constant and macro definitions
// -----------------------------------------------------------------------------
@@ -64,6 +65,7 @@ extern struct Logger* mainLog;
// Export of PCBA information
extern struct Pcba* pcba;
extern struct Version* version;
// Export of ADCs
extern struct Adc* const adc1;
// Export of the rtc
@@ -79,6 +81,7 @@ extern struct SpiDevice* const spiDisplay;
extern struct SpiDevice* const spiEEPROM;
// Export of Keypad
extern struct Keypad* const keypad;
extern struct Storm700* const storm700;
// Export of GPIOs
extern struct Gpio* const ledGreen;
extern struct Gpio* const ledOrange;
@@ -94,9 +97,14 @@ extern struct Gpio* const mcp2Relay;
extern struct Gpio* const cat0Relay;
extern struct Gpio* const cat1Relay;
extern struct Gpio* const cat2Relay;
extern struct Interlock* const interlock;
extern struct Interlock* const teslalock;
extern struct NHD0420* const nhd0420;
extern struct MAX5715* const max5715;
// -----------------------------------------------------------------------------
// Function declarations
// -----------------------------------------------------------------------------

View File

@@ -36,6 +36,8 @@
#include "stm32f10x.h"
#include "Observable.h"
// -----------------------------------------------------------------------------
// Constant and macro definitions
// -----------------------------------------------------------------------------
@@ -49,6 +51,7 @@
struct Rtc
{
SemaphoreHandle_t secondSync;
struct Observable observable;
};
@@ -68,4 +71,18 @@ struct Rtc
extern ErrorStatus RTC_construct(struct Rtc* self);
/** ----------------------------------------------------------------------------
* RTC_getObservable
* Description of function
*
* @param self
*
* @return struct Observable*
*
* @todo
* -----------------------------------------------------------------------------
*/
extern struct Observable* RTC_getObservable(struct Rtc* self);
#endif /* INC_RTC_H_ */