Dokit 0.5.2-pre
Internal development documentation
Loading...
Searching...
No Matches
PokitPro Namespace Reference

Encapsulates details specific to Pokit Pro devices. More...

Enumerations

enum class  CapacitanceRange : quint8 { _100nF = 0 , _10uF = 1 , _1mF = 2 , AutoRange = 255 }
 Values supported by the Pokit Pro's Range attributes in Capacitance mode. More...
 
enum class  CurrentRange : quint8 {
  _500uA = 0 , _2mA = 1 , _10mA = 2 , _125mA = 3 ,
  _300mA = 4 , _3A = 5 , _10A = 6 , AutoRange = 255
}
 Values supported by the Pokit Pro's Range attributes in *Current modes. More...
 
enum class  ResistanceRange : quint8 {
  _30 = 0 , _75 = 1 , _400 = 2 , _5K = 3 ,
  _10K = 4 , _15K = 5 , _40K = 6 , _500K = 7 ,
  _700K = 8 , _1M = 9 , _3M = 10 , AutoRange = 255
}
 Values supported by the Pokit Pro's Range attributes in Resistance mode. More...
 
enum class  VoltageRange : quint8 {
  _250mV = 0 , _2V = 1 , _10V = 2 , _30V = 3 ,
  _60V = 4 , _125V = 5 , _400V = 6 , _600V = 7 ,
  AutoRange = 255
}
 Values supported by the Pokit Pro's Range attributes in *Voltage modes. More...
 

Functions

QTPOKIT_EXPORT QString toString (const CapacitanceRange &range)
 Returns range as a user-friendly string.
 
QTPOKIT_EXPORT QVariant maxValue (const CapacitanceRange &range)
 Returns the maximum value for range in (integer) nanofarads, or the string "Auto".
 
QTPOKIT_EXPORT QString toString (const CurrentRange &range)
 Returns range as a user-friendly string.
 
QTPOKIT_EXPORT QVariant maxValue (const CurrentRange &range)
 Returns the maximum value for range in (integer) microamps, or the string "Auto".
 
QTPOKIT_EXPORT QString toString (const ResistanceRange &range)
 Returns range as a user-friendly string.
 
QTPOKIT_EXPORT QVariant maxValue (const ResistanceRange &range)
 Returns the maximum value for range in (integer) ohms, or the string "Auto".
 
QTPOKIT_EXPORT QString toString (const VoltageRange &range)
 Returns range as a user-friendly string.
 
QTPOKIT_EXPORT QVariant maxValue (const VoltageRange &range)
 Returns the maximum value for range in (integer) millivolts, or the string "Auto".
 

Detailed Description

Encapsulates details specific to Pokit Pro devices.

Enumeration Type Documentation

◆ CapacitanceRange

enum class PokitPro::CapacitanceRange : quint8
strong

Values supported by the Pokit Pro's Range attributes in Capacitance mode.

Pokit Bluetooth API errata
These Pokit Pro enumeration values are as-yet undocumented by Pokit Innovations. @pcolby reverse-engineered them as part of the dokit project.
Enumerator
_100nF 

Up 100nF.

_10uF 

Up 10μF.

_1mF 

Up 1mF.

AutoRange 

Auto-range.

Definition at line 22 of file pokitpro.h.

22 : quint8 {
23 _100nF = 0, ///< Up 100nF.
24 _10uF = 1, ///< Up 10μF.
25 _1mF = 2, ///< Up 1mF.
26 AutoRange = 255 ///< Auto-range.
27 };

◆ CurrentRange

enum class PokitPro::CurrentRange : quint8
strong

Values supported by the Pokit Pro's Range attributes in *Current modes.

Pokit Bluetooth API errata
These Pokit Pro enumeration values are as-yet undocumented by Pokit Innovations. @pcolby reverse-engineered them as part of the dokit project.
Enumerator
_500uA 

Up to 5µA.

_2mA 

Up to 2mA.

_10mA 

Up to 10mA.

_125mA 

Up to 125mA.

_300mA 

Up to 300mA.

_3A 

Up to 3A.

_10A 

Up to 10A.

AutoRange 

Auto-range.

Definition at line 33 of file pokitpro.h.

33 : quint8 {
34 _500uA = 0, ///< Up to 5µA.
35 _2mA = 1, ///< Up to 2mA.
36 _10mA = 2, ///< Up to 10mA.
37 _125mA = 3, ///< Up to 125mA.
38 _300mA = 4, ///< Up to 300mA.
39 _3A = 5, ///< Up to 3A.
40 _10A = 6, ///< Up to 10A.
41 AutoRange = 255 ///< Auto-range.
42 };
@ _125mA
Up to 125mA.

◆ ResistanceRange

enum class PokitPro::ResistanceRange : quint8
strong

Values supported by the Pokit Pro's Range attributes in Resistance mode.

Pokit Bluetooth API errata
These Pokit Pro enumeration values are as-yet undocumented by Pokit Innovations. @pcolby reverse-engineered them as part of the dokit project.
Enumerator
_30 

Up to 30Ω.

_75 

Up to 75Ω.

_400 

Up to 400Ω.

_5K 

Up to 5KΩ.

_10K 

Up to 10KΩ.

_15K 

Up to 15KΩ.

_40K 

Up to 40KΩ.

_500K 

Up to 500KΩ.

_700K 

Up to 700KΩ.

_1M 

Up to 1MΩ.

_3M 

Up to 3MΩ.

AutoRange 

Auto-range.

Definition at line 47 of file pokitpro.h.

47 : quint8 {
48 _30 = 0, ///< Up to 30Ω.
49 _75 = 1, ///< Up to 75Ω.
50 _400 = 2, ///< Up to 400Ω.
51 _5K = 3, ///< Up to 5KΩ.
52 _10K = 4, ///< Up to 10KΩ.
53 _15K = 5, ///< Up to 15KΩ.
54 _40K = 6, ///< Up to 40KΩ.
55 _500K = 7, ///< Up to 500KΩ.
56 _700K = 8, ///< Up to 700KΩ.
57 _1M = 9, ///< Up to 1MΩ.
58 _3M = 10, ///< Up to 3MΩ.
59 AutoRange = 255 ///< Auto-range.
60 };

◆ VoltageRange

enum class PokitPro::VoltageRange : quint8
strong

Values supported by the Pokit Pro's Range attributes in *Voltage modes.

Pokit Bluetooth API errata
These Pokit Pro enumeration values are as-yet undocumented by Pokit Innovations. @pcolby reverse-engineered them as part of the dokit project.
Enumerator
_250mV 

Up to 250mV.

_2V 

Up to 2V.

_10V 

Up to 10V.

_30V 

Up to 30V.

_60V 

Up to 60V.

_125V 

Up to 125V.

_400V 

Up to 400V.

_600V 

Up to 600V.

AutoRange 

Auto-range.

Definition at line 65 of file pokitpro.h.

65 : quint8 {
66 _250mV = 0, ///< Up to 250mV.
67 _2V = 1, ///< Up to 2V.
68 _10V = 2, ///< Up to 10V.
69 _30V = 3, ///< Up to 30V.
70 _60V = 4, ///< Up to 60V.
71 _125V = 5, ///< Up to 125V.
72 _400V = 6, ///< Up to 400V.
73 _600V = 7, ///< Up to 600V.
74 AutoRange = 255 ///< Auto-range.
75 };
@ _250mV
Up to 250mV.

Function Documentation

◆ maxValue() [1/4]

QVariant PokitPro::maxValue ( const CapacitanceRange & range)

Returns the maximum value for range in (integer) nanofarads, or the string "Auto".

If range is not a known valid value, then an null QVariant is returned.

Definition at line 40 of file pokitpro.cpp.

41{
42 switch (range) {
43 case CapacitanceRange::_100nF: return 100;
44 case CapacitanceRange::_10uF: return 10'000;
45 case CapacitanceRange::_1mF: return 1'000'000;
46 case CapacitanceRange::AutoRange: return QCoreApplication::translate("PokitPro", "Auto", "CapacitanceRange");
47 default: return QVariant();
48 }
49}
QString translate(const char *context, const char *sourceText, const char *disambiguation, int n)

References _100nF, _10uF, _1mF, AutoRange, and QCoreApplication::translate().

Referenced by CapacitanceRange::maxValue(), CurrentRange::maxValue(), ResistanceRange::maxValue(), and VoltageRange::maxValue().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ maxValue() [2/4]

QVariant PokitPro::maxValue ( const CurrentRange & range)

Returns the maximum value for range in (integer) microamps, or the string "Auto".

If range is not a known valid value, then an null QVariant is returned.

Definition at line 80 of file pokitpro.cpp.

81{
82 switch (range) {
83 case CurrentRange::_500uA: return 500;
84 case CurrentRange::_2mA: return 2'000;
85 case CurrentRange::_10mA: return 10'000;
86 case CurrentRange::_125mA: return 125'000;
87 case CurrentRange::_300mA: return 300'000;
88 case CurrentRange::_3A: return 3'000'000;
89 case CurrentRange::_10A: return 10'000'000;
90 case CurrentRange::AutoRange: return QCoreApplication::translate("PokitPro", "Auto", "CurrentRange");
91 default: return QVariant();
92 }
93}

References _10A, _10mA, _125mA, _2mA, _300mA, _3A, _500uA, AutoRange, and QCoreApplication::translate().

Here is the call graph for this function:

◆ maxValue() [3/4]

QVariant PokitPro::maxValue ( const ResistanceRange & range)

Returns the maximum value for range in (integer) ohms, or the string "Auto".

If range is not a known valid value, then an null QVariant is returned.

Definition at line 128 of file pokitpro.cpp.

129{
130 switch (range) {
131 case ResistanceRange::_30: return 30;
132 case ResistanceRange::_75: return 75;
133 case ResistanceRange::_400: return 400;
134 case ResistanceRange::_5K: return 5'000;
135 case ResistanceRange::_10K: return 10'000;
136 case ResistanceRange::_15K: return 15'000;
137 case ResistanceRange::_40K: return 40'000;
138 case ResistanceRange::_500K: return 500'000;
139 case ResistanceRange::_700K: return 700'000;
140 case ResistanceRange::_1M: return 1'000'000;
141 case ResistanceRange::_3M: return 3'000'000;
142 case ResistanceRange::AutoRange: return QCoreApplication::translate("PokitPro", "Auto", "ResistanceRange");
143 default: return QVariant();
144 }
145}

References _10K, _15K, _1M, _30, _3M, _400, _40K, _500K, _5K, _700K, _75, AutoRange, and QCoreApplication::translate().

Here is the call graph for this function:

◆ maxValue() [4/4]

QVariant PokitPro::maxValue ( const VoltageRange & range)

Returns the maximum value for range in (integer) millivolts, or the string "Auto".

If range is not a known valid value, then an null QVariant is returned.

Definition at line 177 of file pokitpro.cpp.

178{
179 switch (range) {
180 case VoltageRange::_250mV: return 250;
181 case VoltageRange::_2V: return 2'000;
182 case VoltageRange::_10V: return 10'000;
183 case VoltageRange::_30V: return 30'000;
184 case VoltageRange::_60V: return 60'000;
185 case VoltageRange::_125V: return 125'000;
186 case VoltageRange::_400V: return 400'000;
187 case VoltageRange::_600V: return 600'000;
188 case VoltageRange::AutoRange: return QCoreApplication::translate("PokitPro", "Auto", "VoltageRange");
189 default: return QVariant();
190 }
191}

References _10V, _125V, _250mV, _2V, _30V, _400V, _600V, _60V, AutoRange, and QCoreApplication::translate().

Here is the call graph for this function:

◆ toString() [1/4]

QString PokitPro::toString ( const CapacitanceRange & range)

Returns range as a user-friendly string.

Definition at line 25 of file pokitpro.cpp.

26{
27 switch (range) {
28 case CapacitanceRange::_100nF: return QCoreApplication::translate("PokitPro", "Up to 100nF", "CapacitanceRange");
29 case CapacitanceRange::_10uF: return QCoreApplication::translate("PokitPro", "Up to 10μF", "CapacitanceRange");
30 case CapacitanceRange::_1mF: return QCoreApplication::translate("PokitPro", "Up to 1mF", "CapacitanceRange");
31 case CapacitanceRange::AutoRange: return QCoreApplication::translate("PokitPro", "Auto-range", "CapacitanceRange");
32 default: return QString();
33 }
34}

References _100nF, _10uF, _1mF, AutoRange, and QCoreApplication::translate().

Referenced by CapacitanceRange::toString(), CurrentRange::toString(), ResistanceRange::toString(), and VoltageRange::toString().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ toString() [2/4]

QString PokitPro::toString ( const CurrentRange & range)

Returns range as a user-friendly string.

Definition at line 61 of file pokitpro.cpp.

62{
63 switch (range) {
64 case CurrentRange::_500uA: return QCoreApplication::translate("PokitPro", "Up to 500μA", "CurrentRange");
65 case CurrentRange::_2mA: return QCoreApplication::translate("PokitPro", "Up to 2mA", "CurrentRange");
66 case CurrentRange::_10mA: return QCoreApplication::translate("PokitPro", "Up to 10mA", "CurrentRange");
67 case CurrentRange::_125mA: return QCoreApplication::translate("PokitPro", "Up to 125mA", "CurrentRange");
68 case CurrentRange::_300mA: return QCoreApplication::translate("PokitPro", "Up to 300mA", "CurrentRange");
69 case CurrentRange::_3A: return QCoreApplication::translate("PokitPro", "Up to 3A", "CurrentRange");
70 case CurrentRange::_10A: return QCoreApplication::translate("PokitPro", "Up to 10A", "CurrentRange");
71 case CurrentRange::AutoRange: return QCoreApplication::translate("PokitPro", "Auto-range", "CurrentRange");
72 default: return QString();
73 }
74}

References _10A, _10mA, _125mA, _2mA, _300mA, _3A, _500uA, AutoRange, and QCoreApplication::translate().

Here is the call graph for this function:

◆ toString() [3/4]

QString PokitPro::toString ( const ResistanceRange & range)

Returns range as a user-friendly string.

Definition at line 105 of file pokitpro.cpp.

106{
107 switch (range) {
108 case ResistanceRange::_30: return QCoreApplication::translate("PokitPro", "Up to 30Ω", "ResistanceRange");
109 case ResistanceRange::_75: return QCoreApplication::translate("PokitPro", "Up to 75Ω", "ResistanceRange");
110 case ResistanceRange::_400: return QCoreApplication::translate("PokitPro", "Up to 400Ω", "ResistanceRange");
111 case ResistanceRange::_5K: return QCoreApplication::translate("PokitPro", "Up to 5KΩ", "ResistanceRange");
112 case ResistanceRange::_10K: return QCoreApplication::translate("PokitPro", "Up to 10KΩ", "ResistanceRange");
113 case ResistanceRange::_15K: return QCoreApplication::translate("PokitPro", "Up to 15KΩ", "ResistanceRange");
114 case ResistanceRange::_40K: return QCoreApplication::translate("PokitPro", "Up to 40KΩ", "ResistanceRange");
115 case ResistanceRange::_500K: return QCoreApplication::translate("PokitPro", "Up to 500KΩ", "ResistanceRange");
116 case ResistanceRange::_700K: return QCoreApplication::translate("PokitPro", "Up to 700KΩ", "ResistanceRange");
117 case ResistanceRange::_1M: return QCoreApplication::translate("PokitPro", "Up to 1MΩ", "ResistanceRange");
118 case ResistanceRange::_3M: return QCoreApplication::translate("PokitPro", "Up to 3MΩ", "ResistanceRange");
119 case ResistanceRange::AutoRange: return QCoreApplication::translate("PokitPro", "Auto-range", "ResistanceRange");
120 default: return QString();
121 }
122}

References _10K, _15K, _1M, _30, _3M, _400, _40K, _500K, _5K, _700K, _75, AutoRange, and QCoreApplication::translate().

Here is the call graph for this function:

◆ toString() [4/4]

QString PokitPro::toString ( const VoltageRange & range)

Returns range as a user-friendly string.

Definition at line 157 of file pokitpro.cpp.

158{
159 switch (range) {
160 case VoltageRange::_250mV: return QCoreApplication::translate("PokitPro", "Up to 250mV", "VoltageRange");
161 case VoltageRange::_2V: return QCoreApplication::translate("PokitPro", "Up to 2V", "VoltageRange");
162 case VoltageRange::_10V: return QCoreApplication::translate("PokitPro", "Up to 10V", "VoltageRange");
163 case VoltageRange::_30V: return QCoreApplication::translate("PokitPro", "Up to 30V", "VoltageRange");
164 case VoltageRange::_60V: return QCoreApplication::translate("PokitPro", "Up to 60V", "VoltageRange");
165 case VoltageRange::_125V: return QCoreApplication::translate("PokitPro", "Up to 125V", "VoltageRange");
166 case VoltageRange::_400V: return QCoreApplication::translate("PokitPro", "Up to 400V", "VoltageRange");
167 case VoltageRange::_600V: return QCoreApplication::translate("PokitPro", "Up to 600V", "VoltageRange");
168 case VoltageRange::AutoRange: return QCoreApplication::translate("PokitPro", "Auto-range", "VoltageRange");
169 default: return QString();
170 }
171}

References _10V, _125V, _250mV, _2V, _30V, _400V, _600V, _60V, AutoRange, and QCoreApplication::translate().

Here is the call graph for this function: