MythTV  master
avcinfo.h
Go to the documentation of this file.
1 #ifndef _AVC_INFO_H_
2 #define _AVC_INFO_H_
3 
4 // C++ headers
5 #include <cstdint>
6 #include <vector>
7 using namespace std;
8 
9 // Qt headers
10 #include <QString>
11 
12 QString guid_to_string(uint64_t guid);
13 uint64_t string_to_guid(const QString &guid);
14 
15 class AVCInfo
16 {
17  public:
18  AVCInfo();
19  AVCInfo(const AVCInfo &o);
20  AVCInfo &operator=(const AVCInfo &o);
21  virtual ~AVCInfo() = default;
22 
23  virtual bool SendAVCCommand(
24  const vector<uint8_t> &/*cmd*/,
25  vector<uint8_t> &/*result*/,
26  int /*retry_cnt*/)
27  {
28  return false;
29  }
30 
31  bool GetSubunitInfo(void);
32 
33  bool IsSubunitType(int subunit_type) const;
34  QString GetSubunitInfoString(void) const;
35  QString GetGUIDString(void) const { return guid_to_string(m_guid); }
36 
37  public:
38  int m_port {-1};
39  int m_node {-1};
40  uint64_t m_guid {0};
41  uint m_specid {0};
42  uint m_vendorid {0};
43  uint m_modelid {0};
44  uint m_firmware_revision {0};
45  QString m_product_name;
46  uint8_t m_unit_table[32];
47 };
48 
49 #endif // _AVC_INFO_H_
unsigned int uint
Definition: compat.h:140
QString m_product_name
Definition: avcinfo.h:45
virtual bool SendAVCCommand(const vector< uint8_t > &, vector< uint8_t > &, int)
Definition: avcinfo.h:23
uint64_t string_to_guid(const QString &guid)
Definition: avcinfo.cpp:14
QString guid_to_string(uint64_t guid)
Definition: avcinfo.cpp:9
QString GetGUIDString(void) const
Definition: avcinfo.h:35