How To Create a Custom Keyboard Shortcuts Remote

If you want a remote that can execute different keyboard shortcuts on your computer then you can create a Custom Remote for this.

1

The latest version of Unified Remote Server comes with some basic custom remote examples, including an example of a custom Keys remote. We will use that has a starting point. They are located in:

Windows: 
    C:\ProgramData\Unified Remote\Remotes\Bundled\Examples
Mac:
    ~/Library/Application Support/Unified Remote/Remotes/Bundled/Examples

2

Start by creating a copy of the Keyboard example remote. Copy the "Keys" folder and give it a name. For example, let's create a custom Keyboard Shortcut remote for "Windows".

3

Open the folder, and you should see four files. The layout file defines how your remote should look, the meta file describes the name/author etc. The remote file contains the keyboard shortcuts code for each button.

4

Start by opening the meta file in a text editor. Give it a fitting name, author, and description. You must give it a new name (two remotes can't have the same name). Save and close the file.

5

Next, have a look at the layout file, also in a text editor. Layouts typically include some rows, and each row has one or more buttons. The text field gives it a name, and "ontap" tells the remote which action to run (we'll get to that later). Let's close the file for now.

6

Now open the remote file in a text editor. This file defines what Keyboard shortcuts to run for each action. Note how the "ontap" field matches the action names. This is important if you wish to add more buttons and actions.

7

Now if you do not already know the keyboard shortcuts for the program, you like to control you need to start searching. Normally searching for " keyboard shortcuts" works well.

In this case I was looking for windows keyboard shortcuts and searched for "Windows Keyboard shortcuts".

8

I found that the second link returned the information I needed. Now we need to decide what keyboard shortcuts we need. I find that I use "Copy", "Paste", "Cut" and "Undo" a lot so lets use these in our example.

9

Time to edit our Layout for what we like to control. A button can either have a text or a icon (You can find all the possible icons here). As you see in the image below the first three buttons have a text and the last button have a Icon.

10

Now we need to create the logic for what should happen when you push one of the buttons in the remote. To change this go to the remote.lua file. Here you need to change the name of the actions to match what you wrote in your layout. You also need to change the keys in each "stroke" (You find available keys here). Also change the help text to reflect what the action do.

11

You are now ready to use your remote! Just open Unified Remote on your phone test what you have made.