tinkerforge 2.1.23 → 2.1.24

Sign up to get free protection for your applications and to get access to all the features.
Files changed (141) hide show
  1. checksums.yaml +4 -4
  2. data/lib/tinkerforge/brick_dc.rb +2 -2
  3. data/lib/tinkerforge/brick_hat.rb +45 -4
  4. data/lib/tinkerforge/brick_hat_zero.rb +69 -3
  5. data/lib/tinkerforge/brick_imu.rb +8 -10
  6. data/lib/tinkerforge/brick_imu_v2.rb +12 -14
  7. data/lib/tinkerforge/brick_master.rb +6 -14
  8. data/lib/tinkerforge/brick_red.rb +2 -2
  9. data/lib/tinkerforge/brick_servo.rb +2 -2
  10. data/lib/tinkerforge/brick_silent_stepper.rb +3 -3
  11. data/lib/tinkerforge/brick_stepper.rb +3 -3
  12. data/lib/tinkerforge/bricklet_accelerometer.rb +7 -16
  13. data/lib/tinkerforge/bricklet_accelerometer_v2.rb +18 -24
  14. data/lib/tinkerforge/bricklet_air_quality.rb +13 -23
  15. data/lib/tinkerforge/bricklet_ambient_light.rb +14 -27
  16. data/lib/tinkerforge/bricklet_ambient_light_v2.rb +4 -8
  17. data/lib/tinkerforge/bricklet_ambient_light_v3.rb +3 -5
  18. data/lib/tinkerforge/bricklet_analog_in.rb +6 -22
  19. data/lib/tinkerforge/bricklet_analog_in_v2.rb +6 -22
  20. data/lib/tinkerforge/bricklet_analog_in_v3.rb +4 -9
  21. data/lib/tinkerforge/bricklet_analog_out.rb +5 -9
  22. data/lib/tinkerforge/bricklet_analog_out_v2.rb +4 -4
  23. data/lib/tinkerforge/bricklet_analog_out_v3.rb +4 -4
  24. data/lib/tinkerforge/bricklet_barometer.rb +10 -33
  25. data/lib/tinkerforge/bricklet_barometer_v2.rb +13 -32
  26. data/lib/tinkerforge/bricklet_can.rb +3 -7
  27. data/lib/tinkerforge/bricklet_can_v2.rb +8 -40
  28. data/lib/tinkerforge/bricklet_co2.rb +5 -13
  29. data/lib/tinkerforge/bricklet_co2_v2.rb +24 -24
  30. data/lib/tinkerforge/bricklet_color.rb +9 -22
  31. data/lib/tinkerforge/bricklet_color_v2.rb +7 -16
  32. data/lib/tinkerforge/bricklet_compass.rb +6 -12
  33. data/lib/tinkerforge/bricklet_current12.rb +6 -18
  34. data/lib/tinkerforge/bricklet_current25.rb +6 -18
  35. data/lib/tinkerforge/bricklet_distance_ir.rb +6 -17
  36. data/lib/tinkerforge/bricklet_distance_ir_v2.rb +5 -16
  37. data/lib/tinkerforge/bricklet_distance_us.rb +6 -16
  38. data/lib/tinkerforge/bricklet_distance_us_v2.rb +4 -10
  39. data/lib/tinkerforge/bricklet_dmx.rb +7 -16
  40. data/lib/tinkerforge/bricklet_dual_button.rb +2 -4
  41. data/lib/tinkerforge/bricklet_dual_button_v2.rb +3 -7
  42. data/lib/tinkerforge/bricklet_dual_relay.rb +3 -5
  43. data/lib/tinkerforge/bricklet_dust_detector.rb +6 -16
  44. data/lib/tinkerforge/bricklet_e_paper_296x128.rb +30 -33
  45. data/lib/tinkerforge/bricklet_energy_monitor.rb +11 -15
  46. data/lib/tinkerforge/bricklet_gps.rb +11 -24
  47. data/lib/tinkerforge/bricklet_gps_v2.rb +10 -28
  48. data/lib/tinkerforge/bricklet_hall_effect.rb +3 -7
  49. data/lib/tinkerforge/bricklet_hall_effect_v2.rb +8 -19
  50. data/lib/tinkerforge/bricklet_humidity.rb +6 -19
  51. data/lib/tinkerforge/bricklet_humidity_v2.rb +6 -20
  52. data/lib/tinkerforge/bricklet_industrial_analog_out.rb +6 -6
  53. data/lib/tinkerforge/bricklet_industrial_analog_out_v2.rb +6 -13
  54. data/lib/tinkerforge/bricklet_industrial_counter.rb +4 -22
  55. data/lib/tinkerforge/bricklet_industrial_digital_in_4.rb +9 -9
  56. data/lib/tinkerforge/bricklet_industrial_digital_in_4_v2.rb +5 -13
  57. data/lib/tinkerforge/bricklet_industrial_digital_out_4.rb +3 -3
  58. data/lib/tinkerforge/bricklet_industrial_digital_out_4_v2.rb +5 -8
  59. data/lib/tinkerforge/bricklet_industrial_dual_0_20ma.rb +6 -15
  60. data/lib/tinkerforge/bricklet_industrial_dual_0_20ma_v2.rb +4 -16
  61. data/lib/tinkerforge/bricklet_industrial_dual_analog_in.rb +5 -13
  62. data/lib/tinkerforge/bricklet_industrial_dual_analog_in_v2.rb +4 -11
  63. data/lib/tinkerforge/bricklet_industrial_dual_relay.rb +5 -7
  64. data/lib/tinkerforge/bricklet_industrial_quad_relay.rb +3 -3
  65. data/lib/tinkerforge/bricklet_industrial_quad_relay_v2.rb +3 -5
  66. data/lib/tinkerforge/bricklet_io16.rb +5 -13
  67. data/lib/tinkerforge/bricklet_io16_v2.rb +6 -16
  68. data/lib/tinkerforge/bricklet_io4.rb +4 -10
  69. data/lib/tinkerforge/bricklet_io4_v2.rb +16 -23
  70. data/lib/tinkerforge/bricklet_isolator.rb +44 -11
  71. data/lib/tinkerforge/bricklet_joystick.rb +7 -19
  72. data/lib/tinkerforge/bricklet_joystick_v2.rb +6 -11
  73. data/lib/tinkerforge/bricklet_laser_range_finder.rb +8 -29
  74. data/lib/tinkerforge/bricklet_laser_range_finder_v2.rb +6 -17
  75. data/lib/tinkerforge/bricklet_lcd_128x64.rb +30 -63
  76. data/lib/tinkerforge/bricklet_lcd_16x2.rb +7 -9
  77. data/lib/tinkerforge/bricklet_lcd_20x4.rb +4 -8
  78. data/lib/tinkerforge/bricklet_led_strip.rb +12 -27
  79. data/lib/tinkerforge/bricklet_led_strip_v2.rb +17 -4
  80. data/lib/tinkerforge/bricklet_line.rb +4 -10
  81. data/lib/tinkerforge/bricklet_linear_poti.rb +5 -16
  82. data/lib/tinkerforge/bricklet_linear_poti_v2.rb +3 -5
  83. data/lib/tinkerforge/bricklet_load_cell.rb +6 -19
  84. data/lib/tinkerforge/bricklet_load_cell_v2.rb +4 -13
  85. data/lib/tinkerforge/bricklet_moisture.rb +6 -16
  86. data/lib/tinkerforge/bricklet_motion_detector.rb +2 -2
  87. data/lib/tinkerforge/bricklet_motion_detector_v2.rb +3 -7
  88. data/lib/tinkerforge/bricklet_motorized_linear_poti.rb +3 -7
  89. data/lib/tinkerforge/bricklet_multi_touch.rb +2 -6
  90. data/lib/tinkerforge/bricklet_multi_touch_v2.rb +3 -13
  91. data/lib/tinkerforge/bricklet_nfc.rb +6 -20
  92. data/lib/tinkerforge/bricklet_nfc_rfid.rb +2 -2
  93. data/lib/tinkerforge/bricklet_oled_128x64.rb +4 -8
  94. data/lib/tinkerforge/bricklet_oled_128x64_v2.rb +12 -18
  95. data/lib/tinkerforge/bricklet_oled_64x48.rb +4 -8
  96. data/lib/tinkerforge/bricklet_one_wire.rb +2 -2
  97. data/lib/tinkerforge/bricklet_outdoor_weather.rb +16 -16
  98. data/lib/tinkerforge/bricklet_particulate_matter.rb +13 -9
  99. data/lib/tinkerforge/bricklet_piezo_buzzer.rb +3 -6
  100. data/lib/tinkerforge/bricklet_piezo_speaker.rb +3 -11
  101. data/lib/tinkerforge/bricklet_piezo_speaker_v2.rb +8 -18
  102. data/lib/tinkerforge/bricklet_ptc.rb +5 -11
  103. data/lib/tinkerforge/bricklet_ptc_v2.rb +4 -8
  104. data/lib/tinkerforge/bricklet_real_time_clock.rb +3 -5
  105. data/lib/tinkerforge/bricklet_real_time_clock_v2.rb +3 -5
  106. data/lib/tinkerforge/bricklet_remote_switch.rb +2 -2
  107. data/lib/tinkerforge/bricklet_remote_switch_v2.rb +2 -2
  108. data/lib/tinkerforge/bricklet_rgb_led.rb +2 -2
  109. data/lib/tinkerforge/bricklet_rgb_led_button.rb +2 -2
  110. data/lib/tinkerforge/bricklet_rgb_led_matrix.rb +2 -2
  111. data/lib/tinkerforge/bricklet_rgb_led_v2.rb +2 -2
  112. data/lib/tinkerforge/bricklet_rotary_encoder.rb +4 -8
  113. data/lib/tinkerforge/bricklet_rotary_encoder_v2.rb +3 -5
  114. data/lib/tinkerforge/bricklet_rotary_poti.rb +5 -11
  115. data/lib/tinkerforge/bricklet_rotary_poti_v2.rb +3 -5
  116. data/lib/tinkerforge/bricklet_rs232.rb +2 -2
  117. data/lib/tinkerforge/bricklet_rs232_v2.rb +6 -5
  118. data/lib/tinkerforge/bricklet_rs485.rb +30 -71
  119. data/lib/tinkerforge/bricklet_segment_display_4x7.rb +2 -2
  120. data/lib/tinkerforge/bricklet_segment_display_4x7_v2.rb +3 -3
  121. data/lib/tinkerforge/bricklet_solid_state_relay.rb +2 -2
  122. data/lib/tinkerforge/bricklet_solid_state_relay_v2.rb +2 -2
  123. data/lib/tinkerforge/bricklet_sound_intensity.rb +4 -8
  124. data/lib/tinkerforge/bricklet_sound_pressure_level.rb +8 -12
  125. data/lib/tinkerforge/bricklet_temperature.rb +6 -14
  126. data/lib/tinkerforge/bricklet_temperature_ir.rb +7 -26
  127. data/lib/tinkerforge/bricklet_temperature_ir_v2.rb +6 -19
  128. data/lib/tinkerforge/bricklet_temperature_v2.rb +4 -8
  129. data/lib/tinkerforge/bricklet_thermal_imaging.rb +16 -26
  130. data/lib/tinkerforge/bricklet_thermocouple.rb +4 -8
  131. data/lib/tinkerforge/bricklet_thermocouple_v2.rb +3 -5
  132. data/lib/tinkerforge/bricklet_tilt.rb +2 -2
  133. data/lib/tinkerforge/bricklet_uv_light.rb +4 -8
  134. data/lib/tinkerforge/bricklet_uv_light_v2.rb +5 -11
  135. data/lib/tinkerforge/bricklet_voltage.rb +5 -11
  136. data/lib/tinkerforge/bricklet_voltage_current.rb +6 -14
  137. data/lib/tinkerforge/bricklet_voltage_current_v2.rb +5 -11
  138. data/lib/tinkerforge/bricklet_xmc1400_breakout.rb +4 -8
  139. data/lib/tinkerforge/ip_connection.rb +3 -0
  140. data/lib/tinkerforge/version.rb +1 -1
  141. metadata +2 -2
@@ -1,8 +1,8 @@
1
1
  # -*- ruby encoding: utf-8 -*-
2
2
  #############################################################
3
- # This file was automatically generated on 2019-08-23. #
3
+ # This file was automatically generated on 2019-11-25. #
4
4
  # #
5
- # Ruby Bindings Version 2.1.23 #
5
+ # Ruby Bindings Version 2.1.24 #
6
6
  # #
7
7
  # If you have a bugfix for this file and want to commit it, #
8
8
  # please fix the bug in the generator. You can find a link #
@@ -99,7 +99,7 @@ module Tinkerforge
99
99
 
100
100
  end
101
101
 
102
- # Returns the distance measured by the sensor. The value is in mm and possible
102
+ # Returns the distance measured by the sensor. Possible
103
103
  # distance ranges are 40 to 300, 100 to 800 and 200 to 1500, depending on the
104
104
  # selected IR sensor.
105
105
  #
@@ -111,7 +111,6 @@ module Tinkerforge
111
111
  end
112
112
 
113
113
  # Returns the value as read by a 12-bit analog-to-digital converter.
114
- # The value is between 0 and 4095.
115
114
  #
116
115
  # .. note::
117
116
  # The value returned by BrickletDistanceIR#get_distance is averaged over several samples
@@ -154,13 +153,11 @@ module Tinkerforge
154
153
  send_request FUNCTION_GET_SAMPLING_POINT, [position], 'C', 2, 'S'
155
154
  end
156
155
 
157
- # Sets the period in ms with which the CALLBACK_DISTANCE callback is triggered
156
+ # Sets the period with which the CALLBACK_DISTANCE callback is triggered
158
157
  # periodically. A value of 0 turns the callback off.
159
158
  #
160
159
  # The CALLBACK_DISTANCE callback is only triggered if the distance has changed since the
161
160
  # last triggering.
162
- #
163
- # The default value is 0.
164
161
  def set_distance_callback_period(period)
165
162
  send_request FUNCTION_SET_DISTANCE_CALLBACK_PERIOD, [period], 'L', 0, ''
166
163
  end
@@ -170,13 +167,11 @@ module Tinkerforge
170
167
  send_request FUNCTION_GET_DISTANCE_CALLBACK_PERIOD, [], '', 4, 'L'
171
168
  end
172
169
 
173
- # Sets the period in ms with which the CALLBACK_ANALOG_VALUE callback is triggered
170
+ # Sets the period with which the CALLBACK_ANALOG_VALUE callback is triggered
174
171
  # periodically. A value of 0 turns the callback off.
175
172
  #
176
173
  # The CALLBACK_ANALOG_VALUE callback is only triggered if the analog value has
177
174
  # changed since the last triggering.
178
- #
179
- # The default value is 0.
180
175
  def set_analog_value_callback_period(period)
181
176
  send_request FUNCTION_SET_ANALOG_VALUE_CALLBACK_PERIOD, [period], 'L', 0, ''
182
177
  end
@@ -197,8 +192,6 @@ module Tinkerforge
197
192
  # "'i'", "Callback is triggered when the distance is *inside* the min and max values"
198
193
  # "'<'", "Callback is triggered when the distance is smaller than the min value (max is ignored)"
199
194
  # "'>'", "Callback is triggered when the distance is greater than the min value (max is ignored)"
200
- #
201
- # The default value is ('x', 0, 0).
202
195
  def set_distance_callback_threshold(option, min, max)
203
196
  send_request FUNCTION_SET_DISTANCE_CALLBACK_THRESHOLD, [option, min, max], 'k S S', 0, ''
204
197
  end
@@ -219,8 +212,6 @@ module Tinkerforge
219
212
  # "'i'", "Callback is triggered when the analog value is *inside* the min and max values"
220
213
  # "'<'", "Callback is triggered when the analog value is smaller than the min value (max is ignored)"
221
214
  # "'>'", "Callback is triggered when the analog value is greater than the min value (max is ignored)"
222
- #
223
- # The default value is ('x', 0, 0).
224
215
  def set_analog_value_callback_threshold(option, min, max)
225
216
  send_request FUNCTION_SET_ANALOG_VALUE_CALLBACK_THRESHOLD, [option, min, max], 'k S S', 0, ''
226
217
  end
@@ -230,7 +221,7 @@ module Tinkerforge
230
221
  send_request FUNCTION_GET_ANALOG_VALUE_CALLBACK_THRESHOLD, [], '', 5, 'k S S'
231
222
  end
232
223
 
233
- # Sets the period in ms with which the threshold callbacks
224
+ # Sets the period with which the threshold callbacks
234
225
  #
235
226
  # * CALLBACK_DISTANCE_REACHED,
236
227
  # * CALLBACK_ANALOG_VALUE_REACHED
@@ -241,8 +232,6 @@ module Tinkerforge
241
232
  # * BrickletDistanceIR#set_analog_value_callback_threshold
242
233
  #
243
234
  # keep being reached.
244
- #
245
- # The default value is 100.
246
235
  def set_debounce_period(debounce)
247
236
  send_request FUNCTION_SET_DEBOUNCE_PERIOD, [debounce], 'L', 0, ''
248
237
  end
@@ -1,8 +1,8 @@
1
1
  # -*- ruby encoding: utf-8 -*-
2
2
  #############################################################
3
- # This file was automatically generated on 2019-08-23. #
3
+ # This file was automatically generated on 2019-11-25. #
4
4
  # #
5
- # Ruby Bindings Version 2.1.23 #
5
+ # Ruby Bindings Version 2.1.24 #
6
6
  # #
7
7
  # If you have a bugfix for this file and want to commit it, #
8
8
  # please fix the bug in the generator. You can find a link #
@@ -117,7 +117,7 @@ module Tinkerforge
117
117
 
118
118
  end
119
119
 
120
- # Returns the distance measured by the sensor. The value is in mm and possible
120
+ # Returns the distance measured by the sensor. Possible
121
121
  # distance ranges are 40 to 300, 100 to 800 and 200 to 1500, depending on the
122
122
  # selected IR sensor.
123
123
  #
@@ -129,7 +129,7 @@ module Tinkerforge
129
129
  send_request FUNCTION_GET_DISTANCE, [], '', 2, 'S'
130
130
  end
131
131
 
132
- # The period in ms is the period with which the CALLBACK_DISTANCE callback is triggered
132
+ # The period is the period with which the CALLBACK_DISTANCE callback is triggered
133
133
  # periodically. A value of 0 turns the callback off.
134
134
  #
135
135
  # If the `value has to change`-parameter is set to true, the callback is only
@@ -154,8 +154,6 @@ module Tinkerforge
154
154
  # "'>'", "Threshold is triggered when the value is greater than the min value (max is ignored)"
155
155
  #
156
156
  # If the option is set to 'x' (threshold turned off) the callback is triggered with the fixed period.
157
- #
158
- # The default value is (0, false, 'x', 0, 0).
159
157
  def set_distance_callback_configuration(period, value_has_to_change, option, min, max)
160
158
  send_request FUNCTION_SET_DISTANCE_CALLBACK_CONFIGURATION, [period, value_has_to_change, option, min, max], 'L ? k S S', 0, ''
161
159
  end
@@ -166,7 +164,6 @@ module Tinkerforge
166
164
  end
167
165
 
168
166
  # Returns the analog value as read by a analog-to-digital converter.
169
- # The value has 21 bit with a range of 0 to 2097151.
170
167
  #
171
168
  # This is unfiltered raw data. We made sure that the integration time
172
169
  # of the ADC is shorter then the measurement interval of the sensor
@@ -183,7 +180,7 @@ module Tinkerforge
183
180
  send_request FUNCTION_GET_ANALOG_VALUE, [], '', 4, 'L'
184
181
  end
185
182
 
186
- # The period in ms is the period with which the CALLBACK_ANALOG_VALUE callback is triggered
183
+ # The period is the period with which the CALLBACK_ANALOG_VALUE callback is triggered
187
184
  # periodically. A value of 0 turns the callback off.
188
185
  #
189
186
  # If the `value has to change`-parameter is set to true, the callback is only
@@ -208,8 +205,6 @@ module Tinkerforge
208
205
  # "'>'", "Threshold is triggered when the value is greater than the min value (max is ignored)"
209
206
  #
210
207
  # If the option is set to 'x' (threshold turned off) the callback is triggered with the fixed period.
211
- #
212
- # The default value is (0, false, 'x', 0, 0).
213
208
  def set_analog_value_callback_configuration(period, value_has_to_change, option, min, max)
214
209
  send_request FUNCTION_SET_ANALOG_VALUE_CALLBACK_CONFIGURATION, [period, value_has_to_change, option, min, max], 'L ? k L L', 0, ''
215
210
  end
@@ -225,13 +220,9 @@ module Tinkerforge
225
220
  # Setting the length to 1 will turn the averaging off. With less averaging, there
226
221
  # is more noise on the data.
227
222
  #
228
- # The range for the averaging is 1-1000.
229
- #
230
223
  # New data is gathered every ~10ms. With a moving average of length 1000 the
231
224
  # resulting averaging window has a length of approximately 10s. If you want to do
232
225
  # long term measurements the longest moving average will give the cleanest results.
233
- #
234
- # The default value is 25.
235
226
  def set_moving_average_configuration(moving_average_length)
236
227
  send_request FUNCTION_SET_MOVING_AVERAGE_CONFIGURATION, [moving_average_length], 'S', 0, ''
237
228
  end
@@ -243,8 +234,6 @@ module Tinkerforge
243
234
 
244
235
  # Configures the distance LED to be either turned off, turned on, blink in
245
236
  # heartbeat mode or show the distance (brighter = object is nearer).
246
- #
247
- # The default value is 3 (show distance).
248
237
  def set_distance_led_config(config)
249
238
  send_request FUNCTION_SET_DISTANCE_LED_CONFIG, [config], 'C', 0, ''
250
239
  end
@@ -1,8 +1,8 @@
1
1
  # -*- ruby encoding: utf-8 -*-
2
2
  #############################################################
3
- # This file was automatically generated on 2019-08-23. #
3
+ # This file was automatically generated on 2019-11-25. #
4
4
  # #
5
- # Ruby Bindings Version 2.1.23 #
5
+ # Ruby Bindings Version 2.1.24 #
6
6
  # #
7
7
  # If you have a bugfix for this file and want to commit it, #
8
8
  # please fix the bug in the generator. You can find a link #
@@ -71,8 +71,8 @@ module Tinkerforge
71
71
 
72
72
  end
73
73
 
74
- # Returns the current distance value measured by the sensor. The value has a
75
- # range of 0 to 4095. A small value corresponds to a small distance, a big
74
+ # Returns the current distance value measured by the sensor.
75
+ # A small value corresponds to a small distance, a big
76
76
  # value corresponds to a big distance. The relation between the measured distance
77
77
  # value and the actual distance is affected by the 5V supply voltage (deviations
78
78
  # in the supply voltage result in deviations in the distance values) and is
@@ -85,13 +85,11 @@ module Tinkerforge
85
85
  send_request FUNCTION_GET_DISTANCE_VALUE, [], '', 2, 'S'
86
86
  end
87
87
 
88
- # Sets the period in ms with which the CALLBACK_DISTANCE callback is triggered
88
+ # Sets the period with which the CALLBACK_DISTANCE callback is triggered
89
89
  # periodically. A value of 0 turns the callback off.
90
90
  #
91
91
  # Der CALLBACK_DISTANCE callback is only triggered if the distance value has changed
92
92
  # since the last triggering.
93
- #
94
- # The default value is 0.
95
93
  def set_distance_callback_period(period)
96
94
  send_request FUNCTION_SET_DISTANCE_CALLBACK_PERIOD, [period], 'L', 0, ''
97
95
  end
@@ -112,8 +110,6 @@ module Tinkerforge
112
110
  # "'i'", "Callback is triggered when the distance value is *inside* the min and max values"
113
111
  # "'<'", "Callback is triggered when the distance value is smaller than the min value (max is ignored)"
114
112
  # "'>'", "Callback is triggered when the distance value is greater than the min value (max is ignored)"
115
- #
116
- # The default value is ('x', 0, 0).
117
113
  def set_distance_callback_threshold(option, min, max)
118
114
  send_request FUNCTION_SET_DISTANCE_CALLBACK_THRESHOLD, [option, min, max], 'k S S', 0, ''
119
115
  end
@@ -123,7 +119,7 @@ module Tinkerforge
123
119
  send_request FUNCTION_GET_DISTANCE_CALLBACK_THRESHOLD, [], '', 5, 'k S S'
124
120
  end
125
121
 
126
- # Sets the period in ms with which the threshold callbacks
122
+ # Sets the period with which the threshold callbacks
127
123
  #
128
124
  # * CALLBACK_DISTANCE_REACHED,
129
125
  #
@@ -132,8 +128,6 @@ module Tinkerforge
132
128
  # * BrickletDistanceUS#set_distance_callback_threshold,
133
129
  #
134
130
  # keep being reached.
135
- #
136
- # The default value is 100.
137
131
  def set_debounce_period(debounce)
138
132
  send_request FUNCTION_SET_DEBOUNCE_PERIOD, [debounce], 'L', 0, ''
139
133
  end
@@ -148,10 +142,6 @@ module Tinkerforge
148
142
  #
149
143
  # Setting the length to 0 will turn the averaging completely off. With less
150
144
  # averaging, there is more noise on the data.
151
- #
152
- # The range for the averaging is 0-100.
153
- #
154
- # The default value is 20.
155
145
  def set_moving_average(average)
156
146
  send_request FUNCTION_SET_MOVING_AVERAGE, [average], 'C', 0, ''
157
147
  end
@@ -1,8 +1,8 @@
1
1
  # -*- ruby encoding: utf-8 -*-
2
2
  #############################################################
3
- # This file was automatically generated on 2019-08-23. #
3
+ # This file was automatically generated on 2019-11-25. #
4
4
  # #
5
- # Ruby Bindings Version 2.1.23 #
5
+ # Ruby Bindings Version 2.1.24 #
6
6
  # #
7
7
  # If you have a bugfix for this file and want to commit it, #
8
8
  # please fix the bug in the generator. You can find a link #
@@ -99,7 +99,7 @@ module Tinkerforge
99
99
 
100
100
  end
101
101
 
102
- # Returns the distance in mm.
102
+ # Returns the distance.
103
103
  #
104
104
  #
105
105
  # If you want to get the value periodically, it is recommended to use the
@@ -109,7 +109,7 @@ module Tinkerforge
109
109
  send_request FUNCTION_GET_DISTANCE, [], '', 2, 'S'
110
110
  end
111
111
 
112
- # The period in ms is the period with which the CALLBACK_DISTANCE callback is triggered
112
+ # The period is the period with which the CALLBACK_DISTANCE callback is triggered
113
113
  # periodically. A value of 0 turns the callback off.
114
114
  #
115
115
  # If the `value has to change`-parameter is set to true, the callback is only
@@ -134,8 +134,6 @@ module Tinkerforge
134
134
  # "'>'", "Threshold is triggered when the value is greater than the min value (max is ignored)"
135
135
  #
136
136
  # If the option is set to 'x' (threshold turned off) the callback is triggered with the fixed period.
137
- #
138
- # The default value is (0, false, 'x', 0, 0).
139
137
  def set_distance_callback_configuration(period, value_has_to_change, option, min, max)
140
138
  send_request FUNCTION_SET_DISTANCE_CALLBACK_CONFIGURATION, [period, value_has_to_change, option, min, max], 'L ? k S S', 0, ''
141
139
  end
@@ -149,8 +147,6 @@ module Tinkerforge
149
147
  #
150
148
  # With 2 Hz update rate the noise is about ±1mm, while with 10 Hz update rate the noise
151
149
  # increases to about ±5mm.
152
- #
153
- # The default update rate is 2 Hz.
154
150
  def set_update_rate(update_rate)
155
151
  send_request FUNCTION_SET_UPDATE_RATE, [update_rate], 'C', 0, ''
156
152
  end
@@ -162,8 +158,6 @@ module Tinkerforge
162
158
 
163
159
  # Configures the distance LED to be either turned off, turned on, blink in
164
160
  # heartbeat mode or show the distance (brighter = object is nearer).
165
- #
166
- # The default value is 3 (show distance).
167
161
  def set_distance_led_config(config)
168
162
  send_request FUNCTION_SET_DISTANCE_LED_CONFIG, [config], 'C', 0, ''
169
163
  end
@@ -1,8 +1,8 @@
1
1
  # -*- ruby encoding: utf-8 -*-
2
2
  #############################################################
3
- # This file was automatically generated on 2019-08-23. #
3
+ # This file was automatically generated on 2019-11-25. #
4
4
  # #
5
- # Ruby Bindings Version 2.1.23 #
5
+ # Ruby Bindings Version 2.1.24 #
6
6
  # #
7
7
  # If you have a bugfix for this file and want to commit it, #
8
8
  # please fix the bug in the generator. You can find a link #
@@ -37,15 +37,7 @@ module Tinkerforge
37
37
  # This callback can only be triggered in slave mode.
38
38
  CALLBACK_FRAME_AVAILABLE = 15
39
39
 
40
- # This callback is called as soon as a new frame is available
41
- # (written by the DMX master).
42
- #
43
- # The size of the array is equivalent to the number of channels in
44
- # the frame. Each byte represents one channel.
45
- #
46
- # This callback can be enabled via BrickletDMX#set_frame_callback_config.
47
- #
48
- # This callback can only be triggered in slave mode.
40
+ # See CALLBACK_FRAME
49
41
  CALLBACK_FRAME_LOW_LEVEL = 16
50
42
 
51
43
  # This callback is called if a new error occurs. It returns
@@ -61,6 +53,9 @@ module Tinkerforge
61
53
  # This callback can be enabled via BrickletDMX#set_frame_callback_config.
62
54
  #
63
55
  # This callback can only be triggered in slave mode.
56
+ #
57
+ # .. note::
58
+ # If reconstructing the value fails, the callback is triggered with nil for frame.
64
59
  CALLBACK_FRAME = -16
65
60
 
66
61
  FUNCTION_SET_DMX_MODE = 1 # :nodoc:
@@ -159,8 +154,6 @@ module Tinkerforge
159
154
  # Sets the DMX mode to either master or slave.
160
155
  #
161
156
  # Calling this function sets frame number to 0.
162
- #
163
- # The default value is 0 (master).
164
157
  def set_dmx_mode(dmx_mode)
165
158
  send_request FUNCTION_SET_DMX_MODE, [dmx_mode], 'C', 0, ''
166
159
  end
@@ -217,7 +210,7 @@ module Tinkerforge
217
210
  send_request FUNCTION_READ_FRAME_LOW_LEVEL, [], '', 64, 'S S C56 L'
218
211
  end
219
212
 
220
- # Sets the duration of a frame in ms.
213
+ # Sets the duration of a frame.
221
214
  #
222
215
  # Example: If you want to achieve 20 frames per second, you should
223
216
  # set the frame duration to 50ms (50ms * 20 = 1 second).
@@ -226,8 +219,6 @@ module Tinkerforge
226
219
  # this value to 0.
227
220
  #
228
221
  # This setting is only used in master mode.
229
- #
230
- # Default value: 100ms (10 frames per second).
231
222
  def set_frame_duration(frame_duration)
232
223
  send_request FUNCTION_SET_FRAME_DURATION, [frame_duration], 'S', 0, ''
233
224
  end
@@ -1,8 +1,8 @@
1
1
  # -*- ruby encoding: utf-8 -*-
2
2
  #############################################################
3
- # This file was automatically generated on 2019-08-23. #
3
+ # This file was automatically generated on 2019-11-25. #
4
4
  # #
5
- # Ruby Bindings Version 2.1.23 #
5
+ # Ruby Bindings Version 2.1.24 #
6
6
  # #
7
7
  # If you have a bugfix for this file and want to commit it, #
8
8
  # please fix the bug in the generator. You can find a link #
@@ -74,8 +74,6 @@ module Tinkerforge
74
74
  # If you just want to set one of the LEDs and don't know the current state
75
75
  # of the other LED, you can get the state with BrickletDualButton#get_led_state or you
76
76
  # can use BrickletDualButton#set_selected_led_state.
77
- #
78
- # The default value is (1, 1).
79
77
  def set_led_state(led_l, led_r)
80
78
  send_request FUNCTION_SET_LED_STATE, [led_l, led_r], 'C C', 0, ''
81
79
  end
@@ -1,8 +1,8 @@
1
1
  # -*- ruby encoding: utf-8 -*-
2
2
  #############################################################
3
- # This file was automatically generated on 2019-08-23. #
3
+ # This file was automatically generated on 2019-11-25. #
4
4
  # #
5
- # Ruby Bindings Version 2.1.23 #
5
+ # Ruby Bindings Version 2.1.24 #
6
6
  # #
7
7
  # If you have a bugfix for this file and want to commit it, #
8
8
  # please fix the bug in the generator. You can find a link #
@@ -117,8 +117,6 @@ module Tinkerforge
117
117
  # If you just want to set one of the LEDs and don't know the current state
118
118
  # of the other LED, you can get the state with BrickletDualButtonV2#get_led_state or you
119
119
  # can use BrickletDualButtonV2#set_selected_led_state.
120
- #
121
- # The default value is (1, 1).
122
120
  def set_led_state(led_l, led_r)
123
121
  send_request FUNCTION_SET_LED_STATE, [led_l, led_r], 'C C', 0, ''
124
122
  end
@@ -136,7 +134,7 @@ module Tinkerforge
136
134
  send_request FUNCTION_GET_BUTTON_STATE, [], '', 2, 'C C'
137
135
  end
138
136
 
139
- # Sets the state of the selected LED (0 or 1).
137
+ # Sets the state of the selected LED.
140
138
  #
141
139
  # The other LED remains untouched.
142
140
  def set_selected_led_state(led, state)
@@ -145,8 +143,6 @@ module Tinkerforge
145
143
 
146
144
  # If you enable this callback, the CALLBACK_STATE_CHANGED callback is triggered
147
145
  # every time a button is pressed/released
148
- #
149
- # By default this callback is disabled.
150
146
  def set_state_changed_callback_configuration(enabled)
151
147
  send_request FUNCTION_SET_STATE_CHANGED_CALLBACK_CONFIGURATION, [enabled], '?', 0, ''
152
148
  end
@@ -1,8 +1,8 @@
1
1
  # -*- ruby encoding: utf-8 -*-
2
2
  #############################################################
3
- # This file was automatically generated on 2019-08-23. #
3
+ # This file was automatically generated on 2019-11-25. #
4
4
  # #
5
- # Ruby Bindings Version 2.1.23 #
5
+ # Ruby Bindings Version 2.1.24 #
6
6
  # #
7
7
  # If you have a bugfix for this file and want to commit it, #
8
8
  # please fix the bug in the generator. You can find a link #
@@ -54,8 +54,6 @@ module Tinkerforge
54
54
  # can use BrickletDualRelay#set_selected_state.
55
55
  #
56
56
  # All running monoflop timers will be aborted if this function is called.
57
- #
58
- # The default value is (*false*, *false*).
59
57
  def set_state(relay1, relay2)
60
58
  send_request FUNCTION_SET_STATE, [relay1, relay2], '? ?', 0, ''
61
59
  end
@@ -67,7 +65,7 @@ module Tinkerforge
67
65
 
68
66
  # The first parameter can be 1 or 2 (relay 1 or relay 2). The second parameter
69
67
  # is the desired state of the relay (*true* means on and *false* means off).
70
- # The third parameter indicates the time (in ms) that the relay should hold
68
+ # The third parameter indicates the time that the relay should hold
71
69
  # the state.
72
70
  #
73
71
  # If this function is called with the parameters (1, true, 1500):