Dokit
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 47 of file pokitpro.cpp.

48{
49 switch (range) {
50 case CapacitanceRange::_100nF: return 100;
51 case CapacitanceRange::_10uF: return 10'000;
52 case CapacitanceRange::_1mF: return 1'000'000;
53 case CapacitanceRange::AutoRange: return Private::tr("Auto");
54 default: return QVariant();
55 }
56}

References _100nF, _10uF, _1mF, and AutoRange.

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

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 87 of file pokitpro.cpp.

88{
89 switch (range) {
90 case CurrentRange::_500uA: return 500;
91 case CurrentRange::_2mA: return 2'000;
92 case CurrentRange::_10mA: return 10'000;
93 case CurrentRange::_125mA: return 125'000;
94 case CurrentRange::_300mA: return 300'000;
95 case CurrentRange::_3A: return 3'000'000;
96 case CurrentRange::_10A: return 10'000'000;
97 case CurrentRange::AutoRange: return Private::tr("Auto");
98 default: return QVariant();
99 }
100}

References _10A, _10mA, _125mA, _2mA, _300mA, _3A, _500uA, and AutoRange.

◆ 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 135 of file pokitpro.cpp.

136{
137 switch (range) {
138 case ResistanceRange::_30: return 30;
139 case ResistanceRange::_75: return 75;
140 case ResistanceRange::_400: return 400;
141 case ResistanceRange::_5K: return 5'000;
142 case ResistanceRange::_10K: return 10'000;
143 case ResistanceRange::_15K: return 15'000;
144 case ResistanceRange::_40K: return 40'000;
145 case ResistanceRange::_500K: return 500'000;
146 case ResistanceRange::_700K: return 700'000;
147 case ResistanceRange::_1M: return 1'000'000;
148 case ResistanceRange::_3M: return 3'000'000;
149 case ResistanceRange::AutoRange: return Private::tr("Auto");
150 default: return QVariant();
151 }
152}

References _10K, _15K, _1M, _30, _3M, _400, _40K, _500K, _5K, _700K, _75, and AutoRange.

◆ 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 184 of file pokitpro.cpp.

185{
186 switch (range) {
187 case VoltageRange::_250mV: return 250;
188 case VoltageRange::_2V: return 2'000;
189 case VoltageRange::_10V: return 10'000;
190 case VoltageRange::_30V: return 30'000;
191 case VoltageRange::_60V: return 60'000;
192 case VoltageRange::_125V: return 125'000;
193 case VoltageRange::_400V: return 400'000;
194 case VoltageRange::_600V: return 600'000;
195 case VoltageRange::AutoRange: return Private::tr("Auto");
196 default: return QVariant();
197 }
198}

References _10V, _125V, _250mV, _2V, _30V, _400V, _600V, _60V, and AutoRange.

◆ toString() [1/4]

QString PokitPro::toString ( const CapacitanceRange & range)

Returns range as a user-friendly string.

Definition at line 32 of file pokitpro.cpp.

33{
34 switch (range) {
35 case CapacitanceRange::_100nF: return Private::tr("Up to 100nF");
36 case CapacitanceRange::_10uF: return Private::tr("Up to 10μF");
37 case CapacitanceRange::_1mF: return Private::tr("Up to 1mF");
38 case CapacitanceRange::AutoRange: return Private::tr("Auto-range");
39 default: return QString();
40 }
41}

References _100nF, _10uF, _1mF, and AutoRange.

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

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 68 of file pokitpro.cpp.

69{
70 switch (range) {
71 case CurrentRange::_500uA: return Private::tr("Up to 500μA");
72 case CurrentRange::_2mA: return Private::tr("Up to 2mA");
73 case CurrentRange::_10mA: return Private::tr("Up to 10mA");
74 case CurrentRange::_125mA: return Private::tr("Up to 125mA");
75 case CurrentRange::_300mA: return Private::tr("Up to 300mA");
76 case CurrentRange::_3A: return Private::tr("Up to 3A");
77 case CurrentRange::_10A: return Private::tr("Up to 10A");
78 case CurrentRange::AutoRange: return Private::tr("Auto-range");
79 default: return QString();
80 }
81}

References _10A, _10mA, _125mA, _2mA, _300mA, _3A, _500uA, and AutoRange.

◆ toString() [3/4]

QString PokitPro::toString ( const ResistanceRange & range)

Returns range as a user-friendly string.

Definition at line 112 of file pokitpro.cpp.

113{
114 switch (range) {
115 case ResistanceRange::_30: return Private::tr("Up to 30Ω");
116 case ResistanceRange::_75: return Private::tr("Up to 75Ω");
117 case ResistanceRange::_400: return Private::tr("Up to 400Ω");
118 case ResistanceRange::_5K: return Private::tr("Up to 5KΩ");
119 case ResistanceRange::_10K: return Private::tr("Up to 10KΩ");
120 case ResistanceRange::_15K: return Private::tr("Up to 15KΩ");
121 case ResistanceRange::_40K: return Private::tr("Up to 40KΩ");
122 case ResistanceRange::_500K: return Private::tr("Up to 500KΩ");
123 case ResistanceRange::_700K: return Private::tr("Up to 700KΩ");
124 case ResistanceRange::_1M: return Private::tr("Up to 1MΩ");
125 case ResistanceRange::_3M: return Private::tr("Up to 3MΩ");
126 case ResistanceRange::AutoRange: return Private::tr("Auto-range");
127 default: return QString();
128 }
129}

References _10K, _15K, _1M, _30, _3M, _400, _40K, _500K, _5K, _700K, _75, and AutoRange.

◆ toString() [4/4]

QString PokitPro::toString ( const VoltageRange & range)

Returns range as a user-friendly string.

Definition at line 164 of file pokitpro.cpp.

165{
166 switch (range) {
167 case VoltageRange::_250mV: return Private::tr("Up to 250mV");
168 case VoltageRange::_2V: return Private::tr("Up to 2V");
169 case VoltageRange::_10V: return Private::tr("Up to 10V");
170 case VoltageRange::_30V: return Private::tr("Up to 30V");
171 case VoltageRange::_60V: return Private::tr("Up to 60V");
172 case VoltageRange::_125V: return Private::tr("Up to 125V");
173 case VoltageRange::_400V: return Private::tr("Up to 400V");
174 case VoltageRange::_600V: return Private::tr("Up to 600V");
175 case VoltageRange::AutoRange: return Private::tr("Auto-range");
176 default: return QString();
177 }
178}

References _10V, _125V, _250mV, _2V, _30V, _400V, _600V, _60V, and AutoRange.