Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The second option you see does the same job but with less objects used. It will send out a Stored IR Code from a Static String object by pressing a button. However you’ll need to know the IR hex codes in advance. You can use an IR code reader and then once you figured out the code you just go to the Static String and type in the value you read before. Also if you are using a device that has the IR codes in our infrared database you can just do this initially to figure out the IR hex codes. Simply connect the “Code Out” port of the Infrared object with the “In” port of the Text object. Then simply copy and paste it into the Static String object.

...

Build the App (Option 1)

Move to your Apps tab on your Q-Server and hit “+ Create New”.

...

So the Initial Trigger is loading the database to the Dropdown menus and you select which brands, devices, configs and actions you want to have. They will be send back to the Infrared object. So we need to connect the Value port of each Dropdown object with the according ports of the Infrared object.

...

Now we need the Static String object. Place it somewhere on the right side below the Dropdown objects.

...

The “String” port of the Static String object will be connected with the “Code Out” port of the Infrared object.

...

The Static String object is basically going to store the IR hex code we chose to use until we trigger it send it out. So to send out and trigger the Static String object we will need a Button object.

...

If you don’t want to use a button you can also use any other digital trigger the Static String object.

...

Lastly we will need the IR emitter hardware object to actually send out our hex codes. Connect the IR Emitter object with the “String” port of the Static String object.

...

As you noticed we also placed a Text object onto the canvas. Connect this to the “Code Out” port of the Infrared object to get the hex codes send out. We can see how they look like and also save them for the second option we are going to build later.

...

Once you finished hit “Save App” and then return to your apps.

...

Map Hardware & Get Hex Codes

Click on the play button of the IR Emitter app to start it.

...

Map the IR emitter hardware object in the application to our IR emitter Client with the firmware file we named IR Emitter.

...

When you are finished click “Save + Run”. The play button should change to green.

...

From there we are going to open the “Dashboard” to see what our app looks like. You will see all your apps running.

...

Click on the IR Emitter to open it.

...

You can see all the dropdown interfaces, the IR Service trigger button and below that the Text object IR Code. In our case we are using a Samsung TV so we select Samsung for the Brand.

...

As you can see we selected the actions and so forth. The IR Code will be shown in blue number in the text box. Once you selected everything you are good to go to hit the button to send out the hex code. In our case the Samsung TV should turn on. This is the hex code we mentioned before. We are going to use this now to build the second option and later on we will show you both options in action. Copy it to your clipboard.

...

Build the App (Option 2)

Move back to your Apps tab and edit the IR Emitter app by clicking on the three dots and select “Edit”.

...

For the second option we need another Button and another Static String object. Connect them like before. Now use the saved hex codes and paste it into the “String” port of the Static String object. Make sure to hit “Save Properties”.

...

Connect the Static String object with the IR Emitter object.

...

To make sure we see when the code is send out we are going to get another Text object and connect it to the second Static String object.

...

Once you finished click on “Save App” again and hit the run button. Since we already mapped the hardware before we don’t need to do this again so we can straight go to the dashboard.

...

Demo

...

As you can see we have both configurations now in our application. The only negative thing is, if you restart the app you will loose the existing settings we made before like brands etc..

...

By clicking on the “Option 2” button the hex code should appear below. Now we know the hex code has been sent out to the IR Emitter. The IR Emitter can now be controlled via your computer, phone or tablet.

...

Now we turn on the TV with the second option via our phone.

...

As you can see via the text box the hex code has been send out and the TV turns back on.