51 52 with same code
Dependencies: MtSense06
Fork of MtConnect04S_MtSense06 by
Diff: PulseOximeterService.h
- Revision:
- 1:0ec0e5694c4a
- Parent:
- 0:528034040a12
--- a/PulseOximeterService.h Wed Feb 22 09:45:51 2017 +0000 +++ b/PulseOximeterService.h Thu Feb 23 09:31:56 2017 +0000 @@ -106,9 +106,15 @@ void updatePlxSpotCheckMeasurement(float spo2, float pr) { uint16_t sfloat_spo2 = ieee11073_SFLOAT(spo2); uint16_t sfloat_pr = ieee11073_SFLOAT(pr); - +#if 0 memcpy(&bytes[OFFSET_OF_SPO2], &sfloat_spo2, sizeof(uint16_t)); memcpy(&bytes[OFFSET_OF_PR], &sfloat_pr, sizeof(uint16_t)); +#else + bytes[OFFSET_OF_SPO2+0] = (uint8_t)(sfloat_spo2 >> 8); + bytes[OFFSET_OF_SPO2+1] = (uint8_t)(sfloat_spo2 >> 0); + bytes[OFFSET_OF_PR+0] = (uint8_t)(sfloat_pr >> 8); + bytes[OFFSET_OF_PR+1] = (uint8_t)(sfloat_pr >> 0); +#endif } uint8_t *getPointer(void) { return bytes; }