Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependents: TYBLE16_simple_data_logger TYBLE16_MP3_Air
ws_ie_lib.h
00001 /* 00002 * Copyright (c) 2018-2019, Arm Limited and affiliates. 00003 * SPDX-License-Identifier: Apache-2.0 00004 * 00005 * Licensed under the Apache License, Version 2.0 (the "License"); 00006 * you may not use this file except in compliance with the License. 00007 * You may obtain a copy of the License at 00008 * 00009 * http://www.apache.org/licenses/LICENSE-2.0 00010 * 00011 * Unless required by applicable law or agreed to in writing, software 00012 * distributed under the License is distributed on an "AS IS" BASIS, 00013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00014 * See the License for the specific language governing permissions and 00015 * limitations under the License. 00016 */ 00017 00018 #ifndef WS_IE_LIB_H_ 00019 #define WS_IE_LIB_H_ 00020 00021 struct ws_pan_information_s; 00022 struct ws_utt_ie; 00023 struct ws_bt_ie; 00024 struct ws_us_ie; 00025 struct ws_hopping_schedule_s; 00026 00027 /** 00028 * @brief ws_wp_network_name_t WS nested payload network name 00029 */ 00030 typedef struct ws_wp_network_name { 00031 uint8_t network_name_length; 00032 uint8_t *network_name; 00033 } ws_wp_network_name_t; 00034 00035 /* WS_WH HEADER IE */ 00036 uint8_t *ws_wh_utt_write(uint8_t *ptr, uint8_t message_type); 00037 uint8_t *ws_wh_bt_write(uint8_t *ptr); 00038 uint8_t *ws_wh_fc_write(uint8_t *ptr, uint8_t flow_ctrl); 00039 uint8_t *ws_wh_rsl_write(uint8_t *ptr, uint8_t rsl); 00040 uint8_t *ws_wh_vh_write(uint8_t *ptr, uint8_t *vendor_header, uint8_t vendor_header_length); 00041 uint8_t *ws_wh_ea_write(uint8_t *ptr, uint8_t *eui64); 00042 00043 bool ws_wh_utt_read(uint8_t *data, uint16_t length, struct ws_utt_ie *utt_ie); 00044 bool ws_wh_bt_read(uint8_t *data, uint16_t length, struct ws_bt_ie *bt_ie); 00045 bool ws_wh_rsl_read(uint8_t *data, uint16_t length, int8_t *rsl); 00046 bool ws_wh_ea_read(uint8_t *data, uint16_t length, uint8_t *eui64); 00047 00048 /* WS_WP_NESTED PAYLOD IE */ 00049 uint8_t *ws_wp_base_write(uint8_t *ptr, uint16_t length); 00050 uint8_t *ws_wp_nested_hopping_schedule_write(uint8_t *ptr, struct ws_hopping_schedule_s *hopping_schedule, bool unicast_schedule); 00051 uint8_t *ws_wp_nested_vp_write(uint8_t *ptr, uint8_t *vendor_payload, uint16_t vendor_payload_length); 00052 uint8_t *ws_wp_nested_pan_info_write(uint8_t *ptr, struct ws_pan_information_s *pan_congiguration); 00053 uint8_t *ws_wp_nested_netname_write(uint8_t *ptr, uint8_t *network_name, uint8_t network_name_length); 00054 uint8_t *ws_wp_nested_pan_ver_write(uint8_t *ptr, struct ws_pan_information_s *pan_congiguration); 00055 uint8_t *ws_wp_nested_gtkhash_write(uint8_t *ptr, uint8_t *gtkhash, uint8_t gtkhash_length); 00056 uint16_t ws_wp_nested_hopping_schedule_length(struct ws_hopping_schedule_s *hopping_schedule, bool unicast_schedule); 00057 00058 bool ws_wp_nested_us_read(uint8_t *data, uint16_t length, struct ws_us_ie *us_ie); 00059 bool ws_wp_nested_bs_read(uint8_t *data, uint16_t length, struct ws_bs_ie *bs_ie); 00060 bool ws_wp_nested_pan_read(uint8_t *data, uint16_t length, struct ws_pan_information_s *pan_congiguration); 00061 bool ws_wp_nested_pan_version_read(uint8_t *data, uint16_t length, uint16_t *pan_version); 00062 bool ws_wp_nested_network_name_read(uint8_t *data, uint16_t length, ws_wp_network_name_t *network_name); 00063 uint8_t *ws_wp_nested_gtkhash_read(uint8_t *data, uint16_t length); 00064 00065 00066 #endif /* WS_IE_LIB_H_ */
Generated on Tue Jul 12 2022 13:55:04 by
