Pacemaker code Implementation for SFWRENG 3K04
Dependencies: FXOS8700Q Queue mbed-rtos mbed
Fork of Pacemaker by
Diff: interface.cpp
- Revision:
- 8:75c1dd8b0d61
- Parent:
- 7:4eb590c7e064
- Child:
- 9:b48423a135d8
--- a/interface.cpp Mon Nov 14 02:22:40 2016 +0000 +++ b/interface.cpp Tue Nov 15 00:52:39 2016 +0000 @@ -5,6 +5,7 @@ #include "chamberData.h" #include "genData.h" #include "pulse.h" +#include "voor.h" #include <stdlib.h> #include <stdio.h> #include <string> @@ -34,15 +35,18 @@ void interface::startScreen(){ (*pc).printf("\nWelcome to the PACEMAKER DCM.\n"); (*pc).printf("Options:\n"); - (*pc).printf("1. Start pulse\n"); + (*pc).printf("1. Start VOOR Pulse\n"); // temporary test to get VOOR working (*pc).printf("2. View/Change data\n"); (*pc).printf("Please enter a command:"); char command = getChar(); switch (command) { - case '1': - interfacePulse->startPulse(); //problems with this method: you create the pc output twice, once in UI and once in pulse. + case '1':{ + voor v(interfacePulse); //creates new instance of voor + v.startPace(); //starts pacing voor the same way as it used to pace in the user interface + //interfacePulse->startPulse(); //problems with this method: you create the pc output twice, once in UI and once in pulse. startScreen(); //realistically we'll never need to call the serial output in pulse, it should all be done in UI break; + } case '2': interface::dataScreen(); break;