Skip to content

Commit c26731c

Browse files
committed
Garmin: Add the Descent X50i to the List of Recognised Devices.
Also add device ids for the rest of the Descent family, according to data in https://developer.garmin.com/connect-iq/reference-guides/devices-reference/ Signed-off-by: Michael Keller <[email protected]>
1 parent 6f19abf commit c26731c

File tree

2 files changed

+15
-10
lines changed

2 files changed

+15
-10
lines changed

src/descriptor.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -493,7 +493,7 @@ static const dc_descriptor_t g_descriptors[] = {
493493
/* for the Mk2/Mk3 we are using the model of the Mk2 global model */
494494
/* see garmin_parser.c for a more comprehensive list of models */
495495
{"Garmin", "Descent Mk1", DC_FAMILY_GARMIN, 2859, DC_TRANSPORT_USBSTORAGE, NULL},
496-
{"Garmin", "Descent Mk2(i)/Mk3(i)", DC_FAMILY_GARMIN, 3258, DC_TRANSPORT_USBSTORAGE, NULL},
496+
{"Garmin", "Descent Mk2(i)/Mk3(i)(S)/G1/G2/X50i", DC_FAMILY_GARMIN, 3258, DC_TRANSPORT_USBSTORAGE, NULL},
497497
{"FIT", "File import", DC_FAMILY_GARMIN, 0, DC_TRANSPORT_USBSTORAGE, NULL },
498498
};
499499

src/garmin_parser.c

+14-9
Original file line numberDiff line numberDiff line change
@@ -1648,18 +1648,23 @@ static void add_sensor_string(garmin_parser_t *garmin, const char *desc, const s
16481648
static dc_status_t
16491649
garmin_parser_set_data (garmin_parser_t *garmin, const unsigned char *data, unsigned int size)
16501650
{
1651-
// This list is empirical and somewhat speculative
1652-
// will have to be confirmed with Garmin
1651+
// Ids can be found at https://developer.garmin.com/connect-iq/reference-guides/devices-reference/
1652+
// (look for 'Part Number')
16531653
static const struct {
1654-
int id;
16551654
const char *name;
1655+
int id;
16561656
} models[] = {
1657-
{ 2859, "Descent Mk1" },
1658-
{ 2991, "Descent Mk1 APAC" },
1659-
{ 3258, "Descent Mk2(i)" },
1660-
{ 3542, "Descent Mk2s" },
1661-
{ 3702, "Descent Mk2 APAC" },
1662-
{ 4223, "Descent Mk3" },
1657+
{ "Descent™ G1 / G1 Solar", 4005 },
1658+
{ "Descent™ G2", 4588 },
1659+
{ "Descent™ Mk1", 2859 },
1660+
{ "Descent™ Mk1 APAC", 2991 },
1661+
{ "Descent™ Mk2(i)", 3258 },
1662+
{ "Descent™ Mk2(i) APAC", 3702 },
1663+
{ "Descent™ Mk2 S", 3542 },
1664+
{ "Descent™ Mk2 S", 3930 },
1665+
{ "Descent™ Mk3(i) 43mm", 4222 },
1666+
{ "Descent™ Mk3(i) 51mm", 4223 },
1667+
{ "Descent™ X50i", 4518 },
16631668
};
16641669

16651670
/* Walk the data once without a callback to set up the core fields */

0 commit comments

Comments
 (0)