Electronic Shelf Label AP Client API. More...
#include "gr_includes.h"
#include "ble_prf_types.h"
#include "custom_config.h"
#include <stdint.h>
#include <stdbool.h>
#include "pawr_adv.h"
Go to the source code of this file.
Classes | |
struct | esls_c_handles_t |
Handles on the connected peer device needed to interact with it. More... | |
struct | esls_c_led_infor_t |
Electronic Shelf Label LED infor type. More... | |
struct | esls_c_evt_t |
Electronic Shelf Label Client event. More... | |
Macros | |
#define | ESL_CTL_PT_TLV_MAX_LEN 17 |
#define | ESL_TLV_CMD_TAG(OPCODE) (OPCODE & 0xF) |
#define | ESL_TLV_CMD_LEN(OPCODE) ((OPCODE>>4) & 0xF) |
#define | ESL_TLV_CMD_CHECK(OPCODE, length) ((ESL_TLV_CMD_LEN(OPCODE)==(length -2))?true:false) |
#define | ESL_BASIC_STATE_SERV_NEED_POS 0 |
#define | ESL_BASIC_STATE_SYNC_POS 1 |
#define | ESL_BASIC_STATE_ACTIVE_LED_POS 2 |
#define | ESL_BASIC_STATE_LED_UPDATE_POS 3 |
#define | ESL_BASIC_STATE_DISP_UPDATE_POS 4 |
#define | ESL_ADDR_ESL_ID_BROAD_ADDR 0xFF |
#define | ESL_ADDR_INVALID_GRP_ID 0xFF |
Typedefs | |
typedef void(* | esls_c_evt_handler_t) (esls_c_evt_t *p_evt) |
Electronic Shelf Label Client event handler type. More... | |
Functions | |
sdk_err_t | esls_client_init (esls_c_evt_handler_t evt_handler) |
Register ESLS Client event handler. More... | |
sdk_err_t | esl_ap_adv_param_fast_set (uint8_t adv_idx, struct ble_per_adv_param_t *per_adv_params_p) |
Set ESL AP PAwR adv paramters. More... | |
void | ble_esl_pawr_evt_on_ble_capture (const ble_evt_t *p_evt) |
Capture PAwR events on BLE. More... | |
sdk_err_t | esls_c_esl_sent_buffer_register (pawr_sent_data_arr_t *esl_sent_data_buff, uint8_t grp_number) |
Set ESL AP PAwR subevt data buffer, the subevt data will temporarily store here until it's sent. More... | |
sdk_err_t | esls_c_disc_srvc_start (uint8_t conn_idx) |
Discovery Electronic Shelf Label service on peer. More... | |
sdk_err_t | esls_c_ctrl_point_notify_set (uint8_t conn_idx, bool is_enable) |
Enable or disable peer Electronic Shelf Label characteristic notify. More... | |
sdk_err_t | esls_c_esl_addr_set (uint8_t conn_idx, uint8_t esl_id, uint8_t group_id) |
Set Electronic Shelf Label service esl address characteristic. More... | |
sdk_err_t | esls_c_esl_key_set (uint8_t conn_idx, esls_c_key_type_t key_flag, uint8_t session_key[16], uint8_t iv[8]) |
Set Electronic Shelf Label service key material characteristic. More... | |
sdk_err_t | esls_c_esl_current_abs_time_set (uint8_t conn_idx, uint32_t abs_time) |
Set Electronic Shelf Label service current absolute time characteristic. More... | |
sdk_err_t | esls_c_disp_info_read (uint8_t conn_idx) |
Set Electronic Shelf Label service display information characteristic. More... | |
sdk_err_t | esls_c_image_info_read (uint8_t conn_idx) |
Set Electronic Shelf Label service image information characteristic. More... | |
sdk_err_t | esls_c_sensor_info_read (uint8_t conn_idx) |
Set Electronic Shelf Label service sensor information characteristic. More... | |
sdk_err_t | esls_c_led_info_read (uint8_t conn_idx) |
Set Electronic Shelf Label service led information characteristic. More... | |
sdk_err_t | esls_c_esl_ping (uint8_t conn_idx, uint8_t esl_id) |
Sent ESL ping cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_unassociate_from_ap (uint8_t conn_idx, uint8_t esl_id) |
Sent ESL unassociate from AP cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_service_reset (uint8_t conn_idx, uint8_t esl_id) |
Sent ESL service reset cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_factory_reset (uint8_t conn_idx, uint8_t esl_id) |
Sent ESL factory reset cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_update_complete (uint8_t conn_idx, uint8_t esl_id) |
Sent ESL update complete cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_read_sensor_data (uint8_t conn_idx, uint8_t esl_id, uint8_t sensor_idx) |
Sent ESL read sensor data cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_refresh_disp (uint8_t conn_idx, uint8_t esl_id, uint8_t disp_idx) |
Sent ESL refresh display cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_disp_image (uint8_t conn_idx, uint8_t esl_id, uint8_t disp_idx, uint8_t image_idx) |
Sent ESL display image cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_disp_time_image (uint8_t conn_idx, uint8_t esl_id, uint8_t disp_idx, uint8_t image_idx, uint32_t abs_tim) |
Sent ESL display image time cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_led_ctl (uint8_t conn_idx, uint8_t esl_id, uint8_t led_idx, uint8_t color_RGB_bright, uint8_t flashing_pattern[7], uint8_t repeat_type, uint16_t repeat_duration) |
Sent ESL LED control cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_led_time_ctl (uint8_t conn_idx, uint8_t esl_id, uint8_t led_idx, uint8_t color_RGB_bright, uint8_t flashing_pattern[7], uint8_t repeat_type, uint16_t repeat_duration, uint32_t abs_tim) |
Sent ESL LED control cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_vendor_cmd (uint8_t conn_idx, uint8_t esl_id, uint16_t value_length, uint8_t *ctrl_value_p) |
Sent ESL vendor cmd by Electronic Shelf Label service control point characteristic. More... | |
sdk_err_t | esls_c_esl_sync_ping (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id) |
Sent ESL ping cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_unassociate_from_ap (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id) |
Sent ESL ESL unassociate from AP cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_service_reset (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id) |
Sent ESL service reset cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_factory_reset (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id) |
Sent ESL factory reset cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_update_complete (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id) |
Sent ESL update complete cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_read_sensor_data (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id, uint8_t sensor_idx) |
Sent ESL read sensor data cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_refresh_disp (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id, uint8_t disp_idx) |
Sent ESL refresh display cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_disp_image (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id, uint8_t disp_idx, uint8_t image_idx) |
Sent ESL display image cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_disp_time_image (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id, uint8_t disp_idx, uint8_t image_idx, uint32_t abs_tim) |
Sent ESL display image time cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_led_ctl (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id, uint8_t led_idx, uint8_t color_RGB_bright, uint8_t flashing_pattern[7], uint8_t repeat_type, uint16_t repeat_duration) |
Sent ESL LED control cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_led_time_ctl (uint8_t grp_id, uint8_t sent_num, uint8_t esl_id, uint8_t led_idx, uint8_t color_RGB_bright, uint8_t flashing_pattern[7], uint8_t repeat_type, uint16_t repeat_duration, uint32_t abs_tim) |
Sent ESL LED control time cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
sdk_err_t | esls_c_esl_sync_vendor_cmd (uint8_t grp_id, uint8_t esl_id, uint8_t *data, uint16_t data_len, uint8_t sent_num) |
Sent ESL vendor cmd by Electronic Shelf Label PAwR Advertising subevt. More... | |
Electronic Shelf Label AP Client API.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. Neither the name of GOODIX nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL COPYRIGHT HOLDERS AND CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
Definition in file esls_c.h.