Skip to content

Commit

Permalink
Resolve issue with input for demo.py on Linux systems.
Browse files Browse the repository at this point in the history
  • Loading branch information
flip-dots committed May 12, 2024
1 parent de9429a commit b4cf07e
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions examples/demo.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,19 +94,19 @@ async def main():
# Set brightness
case 2:
print("Enter brightness value (0-255)")
await light.set_brightness(int(input()))
await light.set_brightness(int(await ainput()))

# Set colour temp
case 3:
print("Enter colour temp (153-500)")
await light.set_colour_temp(int(input()))
await light.set_colour_temp(int(await ainput()))

# Set XY colour
case 4:
print("Enter X value of color (0.0-1.0)")
x = float(input())
x = float(await ainput())
print("Enter Y value of color (0.0-1.0)")
y = float(input())
y = float(await ainput())
await light.set_colour_xy(x, y)
# Print all light metadata
case 5:
Expand Down

0 comments on commit b4cf07e

Please sign in to comment.