Get Activity Switch for Motion Mode Recognition
Menu: getActivitySwitch
Flutter Example:
/// Get event number for activity switch
getActivitySwitch(
evtBase: _VBusEvtBase.base_app_get,
evtType: _VBusEvtType.app_get_activity_switch),
/// Get activity switch
libManager.send(evt: CmdEvtType.getActivitySwitch, json: jsonEncode(json));
JSON fields received by the app:
Field Name | Field Type | Field Description |
---|---|---|
err_code | int | 0 for success non-zero for error |
auto_identify_sport_walk | int | Auto identify walking switch: 0 for off, 1 for on, -1 for not supported |
auto_identify_sport_run | int | Auto identify running switch: 0 for off, 1 for on, -1 for not supported |
auto_identify_sport_bicycle | int | Auto identify cycling switch: 0 for off, 1 for on, -1 for not supported |
auto_pause_on_off | int | Auto pause switch: 0 for off, 1 for on, -1 for not supported |
auto_end_remind_on_off_on_off | int | End reminder switch: 0 for off, 1 for on, -1 for not supported |
auto_identify_sport_elliptical | int | Auto identify elliptical switch: 0 for off, 1 for on, -1 for not supported |
auto_identify_sport_rowing | int | Auto identify rowing switch: 0 for off, 1 for on, -1 for not supported |
auto_identify_sport_swim | int | Auto identify swimming switch: 0 for off, 1 for on, -1 for not supported |
auto_identify_sport_smart_rope | int | Auto identify smart rope switch: 0 for off, 1 for on, -1 for not supported |
Example:
{
"err_code":0,
"auto_identify_sport_walk":1,
"auto_identify_sport_run":1,
"auto_identify_sport_bicycle":-1,
"auto_pause_on_off":0,
"auto_end_remind_on_off_on_off":0,
"auto_identify_sport_elliptical":0,
"auto_identify_sport_rowing":0,
"auto_identify_sport_swim":-1,
"auto_identify_sport_smart_rope":-1
}