InertiaSDK

Loading...
Searching...
No Matches
DeviceInfo.h
1#pragma once
2
3#include "data/InertiaService.h"
4
5 namespace inertia
6{
7
12 enum class DeviceConnection
13{
14 UNKNOWN,
15 USB,
16 RADIO,
17 BLUETOOTH,
18 BLUETOOTH_LE,
19 EHTERNET,
20 REPLAY,
21 EXTERNAL
22};
23
24
29 struct INERTIA_API DeviceInfo
30 : ServiceResponseGetVersion
31 , ServiceResponseGetSerialNr
32{
33 private:
34 unsigned addressingID;
35 DeviceConnection deviceConnection;
36
37 public:
38 DeviceInfo(uint64_t const& serialNumber = 0);
39 DeviceInfo(unsigned const addrID, DeviceConnection const connType, ServiceResponseGetVersion const& devInfo, ServiceResponseGetSerialNr const& serialInfo);
40
41 unsigned GetAddressingID() const;
42 DeviceConnection GetConnectionType() const;
43
44 bool IsGateway(bool includeGwFw = true) const;
45 unsigned GetNodeID() const;
46
47 bool IsProMoveMini() const;
48 bool IsProMoveV() const;
49 bool IsBluetooth() const;
50
51 static ServiceHardwareTypeID ToHardwareID(uint64_t const& serialNr);
52 static uint64_t ToSerialNr(ServiceHardwareTypeID const& hardwareType, unsigned const& nodeID);
53};
54
55}
inertia
Definition FlashCommands.h:6
inertia::DeviceConnection
DeviceConnection
Device Connection.
Definition DeviceInfo.h:13
inertia::ServiceHardwareTypeID
ServiceHardwareTypeID
Definition InertiaService.h:130