Skip to content

IR Remotes supported? #16

Answered by thatbrainiac
haavardmeling asked this question in Q&A
Discussion options

You must be logged in to vote

Hello,

Yes, the library supports pretty much anything you can do through the Tuya API, including IR remotes.

To do that you will have to first obtain the instruction set for your device, which you'll have to convert to a Command and then send it back to the API to control it. Below is an example with an air conditioning entity that is controlled via a remote IR:

// ...
const string testDeviceId = "your_ac_device_id_here";
var deviceInstructions = await client.DeviceManager.GetDeviceInstructionsAsync(testDeviceId);

deviceInstructions will return a list of Instructions that your device supports. Here's a screenshot from the debugger of what possible values look like:

You'll have to take the

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@haavardmeling
Comment options

Answer selected by haavardmeling
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
question Question on how to use the library
2 participants