ehendrix23 / aioharmony

Asyncio Python library for connecting to and controlling the Logitech Harmony
Apache License 2.0
24 stars 14 forks source link

Allow sending multiple commands at once. #31

Closed misku closed 1 year ago

misku commented 2 years ago

Adds the possibility to send multiple harmony commands (separated by spaces) using a single terminal command.

It's useful for passing different commands at once or switching to a single channel with a series of digits.

Examples:

Switch on, volume up twice and switch to channel 6.

$ aioharmony --harmony_ip 'XXX' send_commands --device_id 'XXX' --commands 'PowerOn VolumeUp VolumeUp 6'

Switch to channel 156.

$ aioharmony --harmony_ip 'XXX' send_commands --device_id 'XXX' --commands '1 5 6'

repeat is not supported as I thought it would be an overkill in this case.