13
13
#include " src/config/ContextProvider.h"
14
14
#include " src/app/io/communication/SerialInterface.h"
15
15
16
+ #define SERIAL_INTERFACE_BAUD_RATE 115200
17
+
16
18
void setup () {
17
19
System::getInstance ()->init ();
18
20
List<Event*>* const eventList = new List<Event*>();
19
21
Command* startCommand = nullptr ;
20
22
Command** currentCommand = &startCommand;
21
- SerialInterface::getInstance ()->init (115200 );
23
+ SerialInterface::getInstance ()->init (SERIAL_INTERFACE_BAUD_RATE );
22
24
23
25
System::getInstance ()->addTask (new CommandListener (COMMAND_LISTENER_PERIOD, getCommandListenerContext (SerialInterface::getInstance (), currentCommand)));
24
26
System::getInstance ()->addTask (new TemperatureHumidityMonitoring (TEMPERATURE_HUMIDITY_PERIOD, getTemperatureHumidityMonitoringContext (eventList)));
@@ -28,8 +30,9 @@ void setup() {
28
30
System::getInstance ()->addTask (new ORAdvancedMonitoring (OR_ADVANCE_MONITORING_PERIOD, getORAdvancedMonitoringContext (eventList)));
29
31
System::getInstance ()->addTask (new HvacSystem (HVAC_SYSTEM_PERIOD, getHvacSystemContextOperatingRoom (eventList, currentCommand)));
30
32
System::getInstance ()->addTask (new HvacSystem (HVAC_SYSTEM_PERIOD, getHvacSystemContextPreOperatingRoom (eventList, currentCommand)));
31
- System::getInstance ()->addTask (new AmbientLightSystem (AMBIENT_LIGHT_PERIOD, getAmbientLightContextOperatingRoom (eventList, currentCommand)));
32
- System::getInstance ()->addTask (new AmbientLightSystem (AMBIENT_LIGHT_PERIOD, getAmbientLightContextPreOperatingRoom (eventList, currentCommand)));
33
+ System::getInstance ()->addTask (new AmbientLightSystem (AMBIENT_LIGHT_PERIOD, getAmbientLightSystemContextOperatingRoom (eventList, currentCommand)));
34
+ System::getInstance ()->addTask (new AmbientLightSystem (AMBIENT_LIGHT_PERIOD, getAmbientLightSystemContextPreOperatingRoom (eventList, currentCommand)));
35
+ System::getInstance ()->addTask (new ORSurgicalLightSystem (OR_SURGICAL_LIGHT_PERIOD, getORSurgicalLightSystemContext (eventList, currentCommand)));
33
36
System::getInstance ()->addTask (new GatewayExporter (GATEWAY_EXPORTER_PERIOD, getGatewayExporterContext (eventList, SerialInterface::getInstance ())));
34
37
}
35
38
0 commit comments