|
1 | 1 | // Derived from ArduinoBLE.
|
2 | 2 | // Copyright 2020 Dan Halbert for Adafruit Industries
|
3 | 3 |
|
| 4 | +// Some functions here are unused now, but may be used in the future. |
| 5 | +// Don't warn or error about this, and depend on the compiler & linker to |
| 6 | +// eliminate the associated code. |
| 7 | +#pragma GCC diagnostic ignored "-Wunused" |
| 8 | +#pragma GCC diagnostic ignored "-Wunused-function" |
| 9 | + |
4 | 10 | /*
|
5 | 11 | This file is part of the ArduinoBLE library.
|
6 | 12 | Copyright (c) 2018 Arduino SA. All rights reserved.
|
@@ -857,7 +863,7 @@ STATIC void process_find_info_req(uint16_t conn_handle, uint16_t mtu, uint8_t dl
|
857 | 863 | }
|
858 | 864 | }
|
859 | 865 |
|
860 |
| -int att_find_info_req(uint16_t conn_handle, uint16_t start_handle, uint16_t end_handle, uint8_t response_buffer[]) { |
| 866 | +static int att_find_info_req(uint16_t conn_handle, uint16_t start_handle, uint16_t end_handle, uint8_t response_buffer[]) { |
861 | 867 | struct __packed req {
|
862 | 868 | struct bt_att_hdr h;
|
863 | 869 | struct bt_att_find_info_req r;
|
@@ -925,7 +931,7 @@ STATIC void process_find_type_req(uint16_t conn_handle, uint16_t mtu, uint8_t dl
|
925 | 931 | }
|
926 | 932 | }
|
927 | 933 |
|
928 |
| -void process_read_group_req(uint16_t conn_handle, uint16_t mtu, uint8_t dlen, uint8_t data[]) { |
| 934 | +static void process_read_group_req(uint16_t conn_handle, uint16_t mtu, uint8_t dlen, uint8_t data[]) { |
929 | 935 | struct bt_att_read_group_req *req = (struct bt_att_read_group_req *)data;
|
930 | 936 | uint16_t type_uuid = req->uuid[0] | (req->uuid[1] << 8);
|
931 | 937 |
|
@@ -1009,7 +1015,7 @@ void process_read_group_req(uint16_t conn_handle, uint16_t mtu, uint8_t dlen, ui
|
1009 | 1015 | }
|
1010 | 1016 | }
|
1011 | 1017 |
|
1012 |
| -int att_read_group_req(uint16_t conn_handle, uint16_t start_handle, uint16_t end_handle, uint16_t uuid, uint8_t response_buffer[]) { |
| 1018 | +static int att_read_group_req(uint16_t conn_handle, uint16_t start_handle, uint16_t end_handle, uint16_t uuid, uint8_t response_buffer[]) { |
1013 | 1019 |
|
1014 | 1020 | typedef struct __packed {
|
1015 | 1021 | struct bt_att_hdr h;
|
@@ -1305,7 +1311,7 @@ STATIC void process_read_type_req(uint16_t conn_handle, uint16_t mtu, uint8_t dl
|
1305 | 1311 | }
|
1306 | 1312 | }
|
1307 | 1313 |
|
1308 |
| -int att_read_type_req(uint16_t conn_handle, uint16_t start_handle, uint16_t end_handle, uint16_t type, uint8_t response_buffer[]) { |
| 1314 | +static int att_read_type_req(uint16_t conn_handle, uint16_t start_handle, uint16_t end_handle, uint16_t type, uint8_t response_buffer[]) { |
1309 | 1315 | typedef struct __packed {
|
1310 | 1316 | struct bt_att_hdr h;
|
1311 | 1317 | struct bt_att_read_type_req r;
|
@@ -1715,7 +1721,7 @@ void att_process_data(uint16_t conn_handle, uint8_t dlen, uint8_t data[]) {
|
1715 | 1721 | }
|
1716 | 1722 |
|
1717 | 1723 | // FIX Do we need all of these?
|
1718 |
| -void check_att_err(uint8_t err) { |
| 1724 | +static void check_att_err(uint8_t err) { |
1719 | 1725 | const compressed_string_t *msg = NULL;
|
1720 | 1726 | switch (err) {
|
1721 | 1727 | case 0:
|
|
0 commit comments