Class: Seam::Clients::ThermostatsSimulate

Inherits:
Object
  • Object
show all
Defined in:
lib/seam/routes/clients/thermostats_simulate.rb

Instance Method Summary collapse

Constructor Details

#initialize(client:, defaults:) ⇒ ThermostatsSimulate

Returns a new instance of ThermostatsSimulate.



6
7
8
9
# File 'lib/seam/routes/clients/thermostats_simulate.rb', line 6

def initialize(client:, defaults:)
  @client = client
  @defaults = defaults
end

Instance Method Details

#hvac_mode_adjusted(device_id:, hvac_mode:, cooling_set_point_celsius: nil, cooling_set_point_fahrenheit: nil, heating_set_point_celsius: nil, heating_set_point_fahrenheit: nil) ⇒ Object



11
12
13
14
15
# File 'lib/seam/routes/clients/thermostats_simulate.rb', line 11

def hvac_mode_adjusted(device_id:, hvac_mode:, cooling_set_point_celsius: nil, cooling_set_point_fahrenheit: nil, heating_set_point_celsius: nil, heating_set_point_fahrenheit: nil)
  @client.post("/thermostats/simulate/hvac_mode_adjusted", {device_id: device_id, hvac_mode: hvac_mode, cooling_set_point_celsius: cooling_set_point_celsius, cooling_set_point_fahrenheit: cooling_set_point_fahrenheit, heating_set_point_celsius: heating_set_point_celsius, heating_set_point_fahrenheit: heating_set_point_fahrenheit}.compact)

  nil
end

#temperature_reached(device_id:, temperature_celsius: nil, temperature_fahrenheit: nil) ⇒ Object



17
18
19
20
21
# File 'lib/seam/routes/clients/thermostats_simulate.rb', line 17

def temperature_reached(device_id:, temperature_celsius: nil, temperature_fahrenheit: nil)
  @client.post("/thermostats/simulate/temperature_reached", {device_id: device_id, temperature_celsius: temperature_celsius, temperature_fahrenheit: temperature_fahrenheit}.compact)

  nil
end