Python LimitlessLED via RF

Diff
Login

Diff

Differences From Artifact [567595d90c]:

To Artifact [d8bdeeb998]:


607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
607
608
609
610
611
612
613

614
615

616
617
618
619

620
621
622
623
624
625
626







-


-




-







			final_steps = initial_value - target_value

		step_command = {'button': "{}_{}".format(button_prefix, final_direction)}
		if zone is not None:
			step_command['zone'] = zone

		transition_delay = None
		self._debug("[FINAL] t = {}, fs = {}".format(transition, final_steps))
		if transition is not None and final_steps > 1:
			transition_delay = transition / (final_steps - 1)
		self._debug("[FINAL] td = {}".format(transition_delay))

		for step in range(final_steps):
			if step == (final_steps - 1):
				transition_delay = None
				self._debug("[FINAL] ftd = {}".format(transition_delay))

			self._debug("[FINAL] Stepping {} {} with a delay of {} (ms) afterwards".format(button_prefix, final_direction, transition_delay))
			self._send_button(step_command, post_delay = transition_delay)

		return True

	def _step_brightness(self, brightness, brightness_min, brightness_max, zone = None, transition = None):