mirror of
https://github.com/bluekitchen/btstack.git
synced 2025-01-25 18:35:17 +00:00
move custom ATT_ERROR_TIMEOUT to 0x7f
This commit is contained in:
parent
12a5e8daf6
commit
7fa238285e
@ -104,7 +104,8 @@ extern "C" {
|
||||
#define ATT_ERROR_INSUFFICIENT_ENCRYPTION 0x0f
|
||||
#define ATT_ERROR_UNSUPPORTED_GROUP_TYPE 0x10
|
||||
#define ATT_ERROR_INSUFFICIENT_RESOURCES 0x11
|
||||
#define ATT_ERROR_TIMEOUT 0x12
|
||||
// custom BTstack ATT error coders
|
||||
#define ATT_ERROR_TIMEOUT 0x7F
|
||||
|
||||
|
||||
// custom BTstack error codes
|
||||
|
@ -200,11 +200,13 @@ static const char * att_errors[] = {
|
||||
static const char * att_error_reserved = "Reserved";
|
||||
static const char * att_error_application = "Application Error";
|
||||
static const char * att_error_common_error = "Common Profile and Service Error Codes";
|
||||
static const char * att_error_timeout = "Timeout";
|
||||
|
||||
const char * att_error_string_for_code(uint8_t code){
|
||||
if (code >= 0xe0) return att_error_common_error;
|
||||
if (code >= 0xa0) return att_error_reserved;
|
||||
if (code >= 0x80) return att_error_application;
|
||||
if (code == 0x7f) return att_error_timeout;
|
||||
if (code >= 0x12) return att_error_reserved;
|
||||
return att_errors[code];
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user