Searched refs:p_state (Results 1 – 13 of 13) sorted by relevance
/AliOS-Things-master/components/genie_service/core/src/sig_models/ |
A D | sig_model_transition.c | 54 if (p_state->onoff[TYPE_PRESENT] != p_state->onoff[TYPE_TARGET]) in sig_model_transition_update() 56 p_state->onoff[TYPE_PRESENT] = p_state->onoff[TYPE_TARGET]; in sig_model_transition_update() 62 if (p_state->lightness[TYPE_PRESENT] != p_state->lightness[TYPE_TARGET]) in sig_model_transition_update() 64 if (p_state->lightness[TYPE_TARGET] > p_state->lightness[TYPE_PRESENT]) in sig_model_transition_update() 154 …p_state->lightness[TYPE_PRESENT], p_state->lightness[TYPE_TARGET], p_state->color_temperature[TYPE… in sig_model_transition_update() 157 if (p_state->onoff[TYPE_PRESENT] == p_state->onoff[TYPE_TARGET]) in sig_model_transition_update() 160 if (p_state->lightness[TYPE_PRESENT] == p_state->lightness[TYPE_TARGET]) in sig_model_transition_update() 177 if (p_state->onoff[TYPE_PRESENT] != p_state->onoff[TYPE_TARGET]) in sig_model_transition_update() 179 p_state->onoff[TYPE_PRESENT] = p_state->onoff[TYPE_TARGET]; in sig_model_transition_update() 185 if (p_state->lightness[TYPE_PRESENT] != p_state->lightness[TYPE_TARGET]) in sig_model_transition_update() [all …]
|
A D | sig_model_light_ctl_srv.c | 21 …BT_DBG("color_temperature cur(0x%04x) tar(0x%04x)", p_state->color_temperature[TYPE_PRESENT], p_st… in _ctl_prepare_buf() 32 net_buf_simple_add_le16(p_msg, p_state->lightness[TYPE_TARGET]); in _ctl_prepare_buf() 33 net_buf_simple_add_le16(p_msg, p_state->color_temperature[TYPE_TARGET]); in _ctl_prepare_buf() 37 net_buf_simple_add_le16(p_msg, p_state->lightness[TYPE_PRESENT]); in _ctl_prepare_buf() 43 net_buf_simple_add_le16(p_msg, p_state->lightness[TYPE_TARGET]); in _ctl_prepare_buf() 278 sig_model_state_t *p_state = &p_elem->state; in sig_model_light_ctl_update_by_onoff() local 280 BT_DBG("onoff cur(%d) tar(%d)", p_state->onoff[TYPE_PRESENT], p_state->onoff[TYPE_TARGET]); in sig_model_light_ctl_update_by_onoff() 283 if (p_state->onoff[TYPE_PRESENT] == 0 && p_state->onoff[TYPE_TARGET] == 1) in sig_model_light_ctl_update_by_onoff() 286 …BT_DBG("color_temperature cur(%d) tar(%d)", p_state->color_temperature[TYPE_PRESENT], p_state->col… in sig_model_light_ctl_update_by_onoff() 287 if (p_state->color_temperature[TYPE_PRESENT] != p_state->color_temperature[TYPE_TARGET]) in sig_model_light_ctl_update_by_onoff() [all …]
|
A D | sig_model_onoff_srv.c | 22 BT_DBG("onoff cur(%d) tar(%d)", p_state->onoff[TYPE_PRESENT], p_state->onoff[TYPE_TARGET]); in _gen_onoff_prepear_buf() 259 sig_model_state_t *p_state = &p_elem->state; in sig_model_onoff_update_by_color_temperature() local 261 if (p_state->onoff[TYPE_TARGET] == 0) in sig_model_onoff_update_by_color_temperature() 264 p_state->onoff[TYPE_TARGET] = 1; in sig_model_onoff_update_by_color_temperature() 274 sig_model_state_t *p_state = &p_elem->state; in sig_model_onoff_update_by_lightness() local 278 if (p_state->lightness[TYPE_PRESENT] == 0 && p_state->lightness[TYPE_TARGET] != 0) in sig_model_onoff_update_by_lightness() 281 p_state->onoff[TYPE_TARGET] = 1; in sig_model_onoff_update_by_lightness() 283 else if (p_state->lightness[TYPE_PRESENT] != 0 && p_state->lightness[TYPE_TARGET] == 0) in sig_model_onoff_update_by_lightness() 286 p_state->onoff[TYPE_TARGET] = 0; in sig_model_onoff_update_by_lightness() 291 if (p_state->lightness[TYPE_PRESENT] == 0 && p_state->lightness[TYPE_TARGET] == 0) in sig_model_onoff_update_by_lightness() [all …]
|
A D | sig_model_lightness_srv.c | 22 …BT_DBG("lightness cur(0x%04x) tar(0x%04x)", p_state->lightness[TYPE_PRESENT], p_state->lightness[T… in _lightness_prepare_buf() 33 net_buf_simple_add_le16(p_msg, p_state->lightness[TYPE_TARGET]); in _lightness_prepare_buf() 37 net_buf_simple_add_le16(p_msg, p_state->lightness[TYPE_PRESENT]); in _lightness_prepare_buf() 42 net_buf_simple_add_le16(p_msg, p_state->lightness[TYPE_TARGET]); in _lightness_prepare_buf() 264 sig_model_state_t *p_state = &p_elem->state; in sig_model_lightness_update_by_onoff() local 266 BT_DBG("onoff cur(%d) tar(%d)", p_state->onoff[TYPE_PRESENT], p_state->onoff[TYPE_TARGET]); in sig_model_lightness_update_by_onoff() 269 if (p_state->onoff[TYPE_PRESENT] == 0 && p_state->onoff[TYPE_TARGET] == 1) in sig_model_lightness_update_by_onoff() 278 p_state->lightness[TYPE_TARGET] = LIGHTNESS_DEFAULT; in sig_model_lightness_update_by_onoff() 281 else if (p_state->onoff[TYPE_PRESENT] == 1 && p_state->onoff[TYPE_TARGET] == 0) in sig_model_lightness_update_by_onoff() 284 p_state->lightness[TYPE_TARGET] = 0; in sig_model_lightness_update_by_onoff() [all …]
|
A D | sig_model_scene_srv.c | 18 sig_model_state_t *p_state = &((sig_model_element_state_t *)p_model->user_data)->state; in _scene_prepare_buf() local 21 net_buf_simple_add_le16(p_msg, p_state->scene[TYPE_PRESENT]); in _scene_prepare_buf()
|
/AliOS-Things-master/components/ble_mesh/bt_mesh/mesh_models/common/ |
A D | mesh_model.c | 42 static void _mesh_timer_stop(S_MESH_STATE *p_state) in _mesh_timer_stop() argument 44 k_timer_stop(&p_state->delay_timer); in _mesh_timer_stop() 45 k_timer_stop(&p_state->trans_timer); in _mesh_timer_stop() 121 u8_t get_remain_byte(S_MESH_STATE *p_state, bool is_ack) in get_remain_byte() argument 123 u8_t remain_byte = p_state->trans; in get_remain_byte() 126 if (!is_ack && p_state->trans_start_time < cur_time) { in get_remain_byte() 127 cur_time -= p_state->trans_start_time; in get_remain_byte() 128 bt_u32_t l_trans = get_transition_time(p_state->trans); in get_remain_byte()
|
/AliOS-Things-master/components/genie_service/core/inc/sig_models/ |
A D | sig_model_transition.h | 26 uint8_t sig_model_transition_get_remain_time_byte(sig_model_state_t *p_state, bool is_ack);
|
/AliOS-Things-master/solutions/genie_mesh_demo/light_ctl/ |
A D | light.c | 87 sig_model_state_t *p_state = &p_elem->state; in _mesh_trans_timer_cycle() local 95 if (p_state->trans == 0) { in _mesh_trans_timer_cycle() 98 k_timer_start(&p_state->trans_timer, SIG_MODEL_TRANSITION_INTERVAL); in _mesh_trans_timer_cycle()
|
/AliOS-Things-master/components/ble_mesh/bt_mesh/mesh_models/sig_model/srv/ |
A D | generic_onoff_srv.c | 17 extern u8_t get_remain_byte(S_MESH_STATE *p_state, bool is_ack);
|
A D | generic_level_srv.c | 19 extern u8_t get_remain_byte(S_MESH_STATE *p_state, bool is_ack);
|
A D | light_lightness_srv.c | 12 extern u8_t get_remain_byte(S_MESH_STATE *p_state, bool is_ack);
|
A D | light_ctl_srv.c | 12 extern u8_t get_remain_byte(S_MESH_STATE *p_state, bool is_ack);
|
/AliOS-Things-master/components/ble_mesh/bt_mesh/mesh_models/vendor_model/ |
A D | vendor_model_srv.c | 19 extern u8_t get_remain_byte(S_MESH_STATE *p_state, bool is_ack);
|
Completed in 16 milliseconds