Set the blood oxygen switch
Function table
__IDO_FUNCTABLE__.funcTable20Model.spo2Data
Description of Blood Oxygen Switch Model
- IDOSetSpo2SwitchBluetoothModel
Parameter | Description | Remark |
---|---|---|
onOff | Switch | bool |
startHour | Start (Hour) | int |
startMinute | Start (Minute) | int |
endHour | Finish (Hour) | int |
endMinute | Finish (Minute) | int |
lowOnOff | Low blood oxygen switch | bool |
lowValue | Low blood oxygen threshold | int |
notifyFlag | Notification type | 0 Invalid ; 1:Allow notifications; 2:Silent notification; 3:Turn off notifications funcTable35Model.spo2NotifyFlag Only the function table supports |
Command code
Objc:
IDOSetSpo2SwitchBluetoothModel * model = [IDOSetSpo2SwitchBluetoothModel currentModel];
[IDOFoundationCommand setSpo2SwitchCommand:model
callback:^(int errorCode) {
if (errorCode == 0) {
//Set successfully
}else if (errorCode == 6) {
//Device not supported
}else {
//Setup failed
}
}];
Swift:
let model = IDOSetSpo2SwitchBluetoothModel.current();
IDOFoundationCommand.setSpo2Switch(model) { (errorCode) in
if errorCode == 0 {
//Set successfully
}else if errorCode == 6{
//Device does not support this method
}else {
//Wrong setting
}
};