Skip to content

Commit

Permalink
TicWatch GTH (Pro) added as tracker
Browse files Browse the repository at this point in the history
Co-Authored-By: John <2012161+jgbreezer@users.noreply.github.com>
  • Loading branch information
DigiH and jgbreezer committed Feb 7, 2024
1 parent 608e00e commit 1ed7fc1
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 4 deletions.
6 changes: 2 additions & 4 deletions docs/devices/devices_template.html
Original file line number Diff line number Diff line change
Expand Up @@ -208,10 +208,8 @@ <h4>
</div>
</header>
<div class="container">
<p>Discover the extensive catalog of Bluetooth devices compatible with Theengs ecosystem, including our MQTT gateway, web
parser,
and OpenMQTTGateway. BLE trackers from Tile, Nut, TagIt and iTag will also be recognised and published as device trackers. The table also indicates whether each device has been confirmed to work with our mobile
application.</p>
<p>Discover the extensive catalog of Bluetooth devices compatible with Theengs ecosystem, including our MQTT gateway, web parser,
and OpenMQTTGateway. BLE trackers from Tile, Nut, TagIt, iTag and the TicWatch GTH (Pro) will also be recognised and published as device trackers. The table also indicates whether each device has been confirmed to work with our [mobile application](https://app.theengs.io/).</p>
{table_content_to_replace}
<div class="custom-block warning"><p class="custom-block-title">Note</p> <p>All product and company names are trademarks or registered trademarks of their respective holders. Use of them does not imply any affiliation with or endorsement by or of them.</p></div>
</div>
Expand Down
1 change: 1 addition & 0 deletions src/decoder.h
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,7 @@ class TheengsDecoder {
TILEN,
TheengsIB01,
TheengsIB02,
TICWATCHGTH,
JAALEE,
APPLEWATCH,
APPLEDEVICE,
Expand Down
1 change: 1 addition & 0 deletions src/devices.h
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@ const char* _devices[][2] = {
{_tracker_json_tilename, _tracker_json_props},
{_tracker_json_theengs01, _tracker_json_props},
{_tracker_json_theengs02, _tracker_json_props},
{_tracker_json_TICWATCHGTH, _tracker_json_props},
{_JAALEE_json, _JAALEE_json_props},
{_APPLEWATCH_json, _APPLEWATCH_json_props},
{_APPLEDEVICE_json, _APPLEDEVICE_json_props},
Expand Down
15 changes: 15 additions & 0 deletions src/devices/tracker_json.h
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,21 @@ const char* _tracker_json_theengs02 = "{\"brand\":\"Theengs\",\"model\":\"iBeaco
}
})"""";*/

const char* _tracker_json_TICWATCHGTH = "{\"brand\":\"Mobvoi\",\"model\":\"TicWatch GTH (Pro)\",\"model_id\":\"TICWATCHGTH\",\"tag\":\"100b\",\"condition\":[\"name\",\"index\",0,\"TicWatch GTH\"],\"properties\":{\"device\":{\"decoder\":[\"static_value\",\"TicWatch GTH (Pro) Tracker\"]}}}";
/*R""""(
{
"brand":"Mobvoi",
"model":"TicWatch GTH (Pro)",
"model_id":"TICWATCHGTH",
"tag":"100b",
"condition":["name", "index", 0, "TicWatch GTH"],
"properties":{
"device":{
"decoder":["static_value", "TicWatch GTH (Pro) Tracker"]
}
}
})"""";*/

const char* _tracker_json_props = "{\"properties\":{\"device\":{\"unit\":\"string\",\"name\":\"tracker device\"}}}";
/*R""""(
{
Expand Down
3 changes: 3 additions & 0 deletions tests/BLE/test_ble.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ const char* expected_mfg[] = {
"{\"brand\":\"Apple\",\"model\":\"Apple iPhone/iPad\",\"model_id\":\"APPLEDEVICE\",\"type\":\"TRACK\",\"track\":true,\"prmac\":true,\"unlocked\":true}",
"{\"brand\":\"Theengs\",\"model\":\"iBeacon Tracker\",\"model_id\":\"TheengsIB01\",\"type\":\"TRACK\",\"cidc\":false,\"track\":true,\"device\":\"Theengs iBeacon Tracker\"}",
"{\"brand\":\"Theengs\",\"model\":\"iBeacon Tracker\",\"model_id\":\"TheengsIB02\",\"type\":\"TRACK\",\"cidc\":false,\"track\":true,\"prmac\":true,\"device\":\"Theengs iBeacon Tracker\"}",
"{\"brand\":\"Mobvoi\",\"model\":\"TicWatch GTH (Pro)\",\"model_id\":\"TICWATCHGTH\",\"type\":\"TRACK\",\"cidc\":false,\"acts\":true,\"track\":true,\"device\":\"TicWatch GTH (Pro) Tracker\"}",
};

const char* expected_name_uuid_mfgsvcdata[] = {
Expand Down Expand Up @@ -538,6 +539,7 @@ const char* test_mfgdata[][3] = {
{"Apple", "iPad", "4c0010050b1c93fbf5"},
{"Theengs", "iBeacon Tracker", "4c000215546865656e67732d69426561636f6e31f644000064"},
{"Theengs", "iBeacon Tracker", "4c000215546865656e67732d69426561636f6e32f644000064"},
{"Mobvoi", "TicWatch GTH Pro", "0000aabbccddeeff"},
};

TheengsDecoder::BLE_ID_NUM test_mfgdata_id_num[]{
Expand Down Expand Up @@ -665,6 +667,7 @@ TheengsDecoder::BLE_ID_NUM test_mfgdata_id_num[]{
TheengsDecoder::BLE_ID_NUM::APPLEDEVICE,
TheengsDecoder::BLE_ID_NUM::TheengsIB01,
TheengsDecoder::BLE_ID_NUM::TheengsIB02,
TheengsDecoder::BLE_ID_NUM::TICWATCHGTH,
};

// uuid test input [test name] [device name] [uuid] [manufacturer data] [service data]
Expand Down

0 comments on commit 1ed7fc1

Please sign in to comment.