Class: DmmUtil::Meter
- Inherits:
-
Object
- Object
- DmmUtil::Meter
- Defined in:
- lib/dmm_util/meter.rb
Instance Attribute Summary collapse
-
#driver ⇒ Object
readonly
Returns the value of attribute driver.
Instance Method Summary collapse
-
#initialize(driver) ⇒ Meter
constructor
A new instance of Meter.
- #measure_now ⇒ Object
- #recordings ⇒ Object
- #saved_measurements ⇒ Object
- #saved_min_max ⇒ Object
- #saved_peak ⇒ Object
Constructor Details
#initialize(driver) ⇒ Meter
Returns a new instance of Meter.
5 6 7 |
# File 'lib/dmm_util/meter.rb', line 5 def initialize(driver) @driver = driver end |
Instance Attribute Details
#driver ⇒ Object (readonly)
Returns the value of attribute driver.
3 4 5 |
# File 'lib/dmm_util/meter.rb', line 3 def driver @driver end |
Instance Method Details
#measure_now ⇒ Object
25 26 27 |
# File 'lib/dmm_util/meter.rb', line 25 def measure_now Measurement.new(driver.qddb) end |
#recordings ⇒ Object
9 10 11 |
# File 'lib/dmm_util/meter.rb', line 9 def recordings Cursor.new(driver, :recording, :qrsi, Recording) end |
#saved_measurements ⇒ Object
13 14 15 |
# File 'lib/dmm_util/meter.rb', line 13 def saved_measurements Cursor.new(driver, :measurement, :qsmr, Measurement) end |
#saved_min_max ⇒ Object
17 18 19 |
# File 'lib/dmm_util/meter.rb', line 17 def saved_min_max Cursor.new(driver, :min_max, :qmmsi, Measurement) end |
#saved_peak ⇒ Object
21 22 23 |
# File 'lib/dmm_util/meter.rb', line 21 def saved_peak Cursor.new(driver, :peak, :qpsi, Measurement) end |