Index: firmware/App/Controllers/BPModule.c =================================================================== diff -u -rf376257c406e8b4f61ef4ad10f0b0f84831932d2 -rb4fa063812ba80ecf4f59f6d6c4394aaf22fdb03 --- firmware/App/Controllers/BPModule.c (.../BPModule.c) (revision f376257c406e8b4f61ef4ad10f0b0f84831932d2) +++ firmware/App/Controllers/BPModule.c (.../BPModule.c) (revision b4fa063812ba80ecf4f59f6d6c4394aaf22fdb03) @@ -54,9 +54,8 @@ static BOOL requestAdultBPReading; ///< Adult BP reading request static BOOL requestPedsBPReading; ///< Pediatric BP reading request static BOOL requestAbortBPReading; ///< Abort BP reading request -static BP_VITALS_DATA_T bpResults; +static BP_VITALS_DATA_T bpResults; ///< Current blood pressure measurement results - // ********** private function prototypes ********** static void checkBloodPressureReading( BP_VITALS_DATA_T *bpResults ); @@ -77,6 +76,9 @@ initBPDriver(); bpModuleState = BP_MODULE_IDLE_STATE; lowSystolicCount = 0; + bpResults.systolic = 0; + bpResults.diastolic = 0; + bpResults.heartRate = 0; requestAdultBPReading = FALSE; requestPedsBPReading = FALSE; requestAbortBPReading = FALSE; @@ -159,7 +161,7 @@ * measurement results against configured thresholds and activates * corresponding blood pressure alarms. * @details \b Inputs: bpResults - * @details \b Outputs: lowSystolicCount, activateAlarm + * @details \b Outputs: lowSystolicCount * @return none ***************************************************************************/ static void checkBloodPressureReading( BP_VITALS_DATA_T *bpResults ) @@ -199,8 +201,7 @@ * state handling. * @details \b Inputs: requestAdultBPReading, requestPedsBPReading, * requestAbortBPReading - * @details \b Outputs: startAdultBPMeasurement, startPedsBPMeasurement, - * abortBPMeasurement + * @details \b Outputs: none * @return next BP module state ***************************************************************************/ static BP_MODULE_STATE_T handleBPModuleIdleState( void ) @@ -232,7 +233,7 @@ * @brief * The handleBPModuleMeasureState function executes the BP module * measurement state - * @details \b Inputs: isBPMeasurementReady, hasBPDriverError + * @details \b Inputs: none * @details \b Outputs: bpModuleState * @return next BP module state ***************************************************************************/ @@ -335,9 +336,9 @@ { BP_VITALS_DATA_T data; - data.systolic = (U32)bpResults.systolic; - data.diastolic = (U32)bpResults.diastolic; - data.heartRate = (U32)bpResults.heartRate; + data.systolic = bpResults.systolic; + data.diastolic = bpResults.diastolic; + data.heartRate = bpResults.heartRate; broadcastData( MSG_ID_TD_BLOOD_PRESSURE_DATA, COMM_BUFFER_OUT_CAN_TD_BROADCAST, (U08*)&data, sizeof( BP_VITALS_DATA_T ) ); } Index: firmware/App/Drivers/BPDriver.c =================================================================== diff -u -rf376257c406e8b4f61ef4ad10f0b0f84831932d2 -rb4fa063812ba80ecf4f59f6d6c4394aaf22fdb03 --- firmware/App/Drivers/BPDriver.c (.../BPDriver.c) (revision f376257c406e8b4f61ef4ad10f0b0f84831932d2) +++ firmware/App/Drivers/BPDriver.c (.../BPDriver.c) (revision b4fa063812ba80ecf4f59f6d6c4394aaf22fdb03) @@ -82,7 +82,7 @@ * @brief * The initBPDriver function initializes the blood pressure driver. * @details \b Inputs: none - * @details \b Outputs: BPDriver variables initialized + * @details \b Outputs: BPDriver unit is initialized * @return none ***************************************************************************/ void initBPDriver( void ) @@ -104,7 +104,7 @@ /*********************************************************************//** * @brief * The getBPResponseCode function returns the FPGA NIBP response code. - * @details \b Inputs: getNIBPStatusResponse + * @details \b Inputs: none * @details \b Outputs: none * @return FPGA NIBP response code. ***************************************************************************/ @@ -215,7 +215,7 @@ * @brief * The handleBPDriverClearCmdState function clears the BP command ready bit. * @details \b Inputs: none -* @details \b Outputs: setNIBPCommand, bpCommandClearCtr +* @details \b Outputs: bpCommandClearCtr * @return next BP driver state ***************************************************************************/ static BP_DRIVER_STATE_T handleBPDriverClearCmdState( void ) @@ -254,7 +254,7 @@ * @brief * The handleBPDriverSendCmdState function sends the pending BP command. * @details \b Inputs: pendingBPCommand -* @details \b Outputs: setNIBPCommand +* @details \b Outputs: none * @return next BP driver state ***************************************************************************/ static BP_DRIVER_STATE_T handleBPDriverSendCmdState( void ) @@ -270,7 +270,7 @@ * @brief * The handleBPDriverWaitFpgaAckState function waits for FPGA command * acknowledge. -* @details \b Inputs: getNIBPControlStatus +* @details \b Inputs: none * @details \b Outputs: none * @return next BP driver state ***************************************************************************/ @@ -291,7 +291,7 @@ * The handleBPDriverClearCmdAfterAckState function clears the BP command * ready bit after FPGA acknowledge. * @details \b Inputs: none -* @details \b Outputs: setNIBPCommand +* @details \b Outputs: none * @return next BP driver state ***************************************************************************/ static BP_DRIVER_STATE_T handleBPDriverClearCmdAfterAckState( void ) @@ -307,7 +307,7 @@ * @brief * The handleBPDriverWaitModuleStartState function waits for the BP module * to signal that the command started. -* @details \b Inputs: getNIBPStatusResponse, pendingBPCommand +* @details \b Inputs: pendingBPCommand * @details \b Outputs: none * @return next BP driver state ***************************************************************************/ @@ -338,7 +338,7 @@ * @brief * The handleBPDriverWaitMeasurementCompleteState function waits for the * BP measurement command to complete. -* @details \b Inputs: getNIBPStatusResponse +* @details \b Inputs: none * @details \b Outputs: pendingBPCommand, bpDriverError * @return next BP driver state ***************************************************************************/ @@ -364,7 +364,7 @@ * @brief * The handleBPDriverGetDataState function retrieves blood pressure * measurement results. -* @details \b Inputs: FPGA NIBP blood pressure registers +* @details \b Inputs: none * @details \b Outputs: bpResults, bpMeasurementReady, pendingBPCommand * @return next BP driver state ***************************************************************************/