Reference: File Format
This page is a details the saved remote file format. In most cases, the average user should ignore all this.
It is only for reference, and for those that decide to create or edit remote files in a text editor.
Remote files are saved as text, made up of descriptive functions
that when combined in the right order, will build a remote.
The remote files can be opened and modified in any text editor.
An example saved file is shown below:
Keuwlsoft IR Remote File (Version 1)
2019-02-24 22:29:43
new_remote(LED Color Controller,512,1024,11)
title_color(255,110,16)
add_button(396,112,102,2,1,4)
transmit_nec(38000,0x01,0x00,0,0,1,0)
add_button(256,112,102,2,2,3)
transmit_nec(38000,0x02,0x00,0,0,1,0)
add_button(116,252,102,7,6,0)
transmit_nec(38000,0x03,0x00,0,0,1,0)
add_button(116,392,102,8,6,0)
transmit_nec(38000,0x04,0x00,0,0,1,0)
add_button(256,252,102,7,7,0)
transmit_nec(38000,0x05,0x00,0,0,1,0)
add_button(256,392,102,8,7,0)
transmit_nec(38000,0x06,0x00,0,0,1,0)
add_button(396,252,102,7,8,0)
transmit_nec(38000,0x07,0x00,0,0,1,0)
add_button(396,392,102,8,8,0)
transmit_nec(38000,0x08,0x00,0,0,1,0)
add_button(256,572,133,3,3,7)
button_text(Rotate Colors,33,,62,,212,172,112)
transmit_nec(38000,0x09,0x00,0,0,1,0)
add_button(116,732,102,2,10,1)
transmit_nec(38000,0x0A,0x00,0,0,1,0)
add_button(256,732,102,2,15,1)
transmit_nec(38000,0x0B,0x00,0,0,1,0)
add_button(396,732,102,2,5,1)
transmit_nec(38000,0x0C,0x00,0,0,1,0)
add_button(116,872,102,2,6,1)
transmit_nec(38000,0x0D,0x00,0,0,1,0)
add_button(256,872,102,2,7,1)
transmit_nec(38000,0x0E,0x00,0,0,1,0)
add_button(396,872,102,2,8,1)
transmit_nec(38000,0x0F,0x00,0,0,1,0)
Each remote starts with a new_remote() command. Subsequent commands will all apply to that remote until another new_remote() command is reached.
Likewise, each button within a remote starts with an add_button() command.
Subsequent commands specific to buttons will apply to that button until another add_button() command is reached.
If multiple commands of the same are applied to a button, then earlier ones will be overwritten, such that only the last one will apply.
Only one transmit pattern can be applied to each button, so if there is more than one, they will be overwritten so that only the last one is used.
The file header, or at least the first line, should be left unmodified as it tells the app what type of file it is, and what version of the file format it is.
Without the header, the app will assume the file is incompatible.
The date and time the remote file is saved is recorded in the header for reference. It is not used by the app and can be replaced by an empty line.
Syntax
• The commands are lower case with underscores separating the words.• The end of a command is determined with a ; character or newline.
• Arguments/parameters of each command are contained within brackets () and are comma separated.
• Strings are enclosed in quotes "".
• Double slash is used for comments. Anything after // on a line is ignored.
If a command has errors, they are reported on screen and the command ignored. Note that recent errors can also be viewed by going to the main settings and tapping the Recent Error/Other Messages button.
List of Functions
Following is a list of the functions used in remote files.To create a remote, use:
new_remote()
Command that apply to the current remote:
Commands that apply to the current button:
- button_text()
- icon_color(()
- icon_rotate()
- transmit_custom()
- transmit_nec()
- transmit_jvc()
- transmit_sirc(()
- transmit_rc5()
- transmit_rc6()
- transmit_raw()
If a parameter for a command is shown to be enclosed in square brackets [] in the reference below, that parameter is optional. Note that, even if omitting some fields, the comma separator is still required.
new_remote(Name,Width,Height,Background)
First appeared in App version 1.0Initiates creation of a new remote.
Name - A name for the remote. Optionally enclosed in quotes “”. Use \" for quote character. Max length is 150 characters.
Width - The width of the remote design. Note the final remote will be resized to best fit the screen it is used on and width only corresponds to the width of the original design. Width is an integer in the Range of 40 to 100000. Make it sufficiently large to allow for accurate button positioning (button x positions are integers in range of the remote width).
Height - The height of the remote design. Note the final remote will be resized to best fit the screen it is used on and height only corresponds to the height of the original design. Integer in the Range of 40 to 100000.
Background - This can be a HTML colour, #RRGGBB, an integer corresponding to one of the default remote backgrounds, a filename (of background image in same location as remote file), or a full web address of where the background image is found.
When background is a HTML colour, it is optionally enclosed inside quotes. It can be the six digit code, or the three digit code, thus #F82, #FF8822, “#F82” and “#FF8822” are all variants of entering the same color, in this case 0xFF (255 decimal) of red, 0x88 (136 decimal) of green, and 0x22 (34 decimal) of blue, which makes an orange color.
In the case of the first default remote design, an integer from 0 to 17 represents the color filter to apply to the remote. For the second remote design, add 1000. For the third remote design, add 2000. In the following table, the selected option would have a background value of 2005.

Default Remote Code Table
If a filename (preferably enclosed in quotes) is entered, the app will try to open the image file ( jpeg, png, bmp, png, gif or webp) at the same location as the remote file (be that from the ir-remote directory, or a web location where the remote file was found). If a full web address is entered, then the app will try to download the image from the web address given.
title_color(R,G,B)
First appeared in App version 1.0This sets a 24-bit RGB color for the remote title. This color is used for the remote title when it is shown above the remote in Run mode.
R is an integer in the range 0 to 255 corresponding to the amount of red in the colour.
G is an integer in the range 0 to 255 corresponding to the amount of green in the colour.
B is an integer in the range 0 to 255 corresponding to the amount of blue in the colour.
icon_color(R,G,B)
First appeared in App version 1.0This sets the 24-bit RGB color of the icon on the button.
R is an integer in the range 0 to 255 corresponding to the amount of red in the color.
G is an integer in the range 0 to 255 corresponding to the amount of green in the color.
B is an integer in the range 0 to 255 corresponding to the amount of blue in the color.
icon_rotate(Rotation)
First appeared in App version 1.0Applies a rotation to the icon.
Rotation - The angle in degrees to clockwise rotate the button's icon. Accepted rotation values are integers in the range from -1000 to 1000.
transmit_custom(Frequency,Command,Address, Command Bits,Address Bits,Endian,Order,[Repeats],[Interval], Start Edge,Start High,Start Low,End Edge,End High,End Low, Zero Edge,Zero High,Zero Low,One Edge,One High,One Low)
First appeared in App version 1.0Assigns a IR pattern based on the App's custom format to the current button.
Frequency - An integer containing the Carrier Frequency in Hz.
Command - The command/data part of the protocol . The command determines the action/function of the device. If Command starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer.
Address - The address part of the protocol, used to identify a particular device. Generally for each device, the address will be kept constant and the command varied for different functions. If Address starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer.
Command Bits - The number of bits of command data to send. Integer in the range of 0-32.
Address Bits - The number of bits of address data to send. Integer in the range of 0-32.
Endian - Determines if data is sent Least Significant Bit(LSB) or Most Significant Bit (MSB) first. The order bytes are stored or sent is also referred to as Endian, where Big endian is MSB first and Little Endian is LSB first. Set Endian to 0 or “little” for LSB first, or to 1 or “big” for MSB first.
Order - An integer in the range of 1 to 10, corresponding to the order in which to send the command, address and their inverted counterparts. If command has the value 10001001 in binary, the inverted value, command' will be 01110110. The orders selectable are shown below:
1. Command
2. Address
3. Command Address
4. Address Command
5. Command Command'
6. Address Address'
7. Command Address Command' Address'
8. Address Command Address' Command'
9. Command Command' Address Address'
10. Address Address' Command Command'
Repeats - The number of repeats of the signal to combine into one send. It is an integer ranging from 1 to 10. If omitted, the signal will be set to send once.
Interval - Interval in microseconds between repeats. If omitted, or set to zero, the default repeat timing will be used.
Start Edge - For the Start/Header/Leader pulse, it will transition from one state to the other. Set to 1 or “true” for a falling edge (High First, then Low), or to 0 or “false” for a rising edge (Low first, then High).
Start High - For the Start/Header/Leader pulse, the time in microseconds that the signal is high.
Start Low - For the Start/Header/Leader pulse, the time in microseconds that the signal is low.
End Edge - For the End signal, it will transition from one state to the other. Set to 1 or “true” for a falling edge (High First, then Low), or to 0 or “false” for a rising edge (Low first, then High). If no end pulse is required, just set both the end high and low times to zero.
End High - For the end pulse, the time in microseconds that the signal is high.
End Low - For the end pulse, the time in microseconds that the signal is low
Zero Edge - For the zero signal (what is added to the IR pattern for each binary 0 in the transmission), it will change from one state to the other. Set to 1 or “true” for a falling edge (High First, then Low), or to 0 or “false” for a rising edge (Low first, then High).
Zero High - For a zero signal, the time in microseconds that the signal is high.
Zero Low - For a zero signal, the time in microseconds that the signal is low.
One Edge - For the one signal (what is added to the IR pattern for each binary 1 in the transmission), it will change from one state to the other. Set to 1 or “true” for a falling edge (High First, then Low), or to 0 or “false” for a rising edge (Low first, then High).
One High - For a one signal, the time in microseconds that the signal is high.
One Low - For a one signal, the time in microseconds that the signal is low.
transmit_nec(Frequency,Command,Address,Extended,[Repeat Method],[Repeats],[Interval])
First appeared in App version 1.0Assigns a IR pattern based on the nec protocol to the current button.
Frequency - An integer containing the Carrier Frequency in Hz.
Command - The command/data part of the protocol . The command determines the action/function of the device. If Command starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer. Command values are 8 bits, ranging from 00 to FF (hex) or 0 to 255 decimal.
Address - The address part of the protocol, used to identify a particular device. Generally for each device, the address will be kept constant and the command varied for different functions. If Address starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer. Address values are 8 bits, ranging from 00 to FF (hex) or 0 to 255 decimal. A 16 bit value is used for the address when the extended flag is set.
Extended - If set to true, or 1, then 16 bits will be used for the address instead of the usual 8 bits. The extended protocol is altered by removing the inverted address part of the signal and replacing it with the extra address bits.
Repeat Method - Set to 0 (or false) if full signal is to be repeated, or set to 1 (or true) if repeats should just send the repeat bit code.
Repeats - The number of repeats of the signal to combine into one send. It is an integer ranging from 1 to 10. If omitted, the signal will be set to send once.
Interval - Interval in microseconds between repeats. If omitted, or set to zero, the default repeat timing will be used.
transmit_jvc(Frequency,Command,Address,[Repeat Method],[Repeats],[Interval])
First appeared in App version 1.0Assigns a IR pattern based on the jvc protocol to the current button.
Frequency - An integer containing the Carrier Frequency in Hz.
Command - The command/data part of the protocol. If Command starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer. Command values are 8 bits, ranging from 00 to FF (hex) or 0 to 255 decimal.
Address - The address part of the protocol, used to identify a particular device. If Address starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer. Address values are 8 bits, ranging from 00 to FF (hex) or 0 to 255 decimal.
Repeat Method - Set to 0 (or false) if full signal is to be repeated, or set to 1 (or true) if repeats should just send the signal without the header.
Repeats - The number of repeats of the signal to combine into one send. It is an integer ranging from 1 to 10. If omitted, the signal will be set to send once.
Interval - Interval in microseconds between repeats. If omitted, or set to zero, the default repeat timing will be used.
transmit_sirc(Frequency,Command,Address,Mode,[Repeats],[Interval],[Extra],[Extra Bits])
First appeared in App version 1.0Assigns a IR pattern based on the sirc protocol to the current button.
Frequency - An integer containing the Carrier Frequency in Hz.
Command - The command/data part of the protocol . If Command starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer. Command values are 7 bits, ranging from 00 to 7F (hex) or 0 to 127 decimal.
Address - The address part of the protocol, used to identify a particular device. If Address starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer. In the 12-bit or extended modes, Address values are 5 bits, ranging from 00 to 1F (hex) or 0 to 31 decimal. In the 15-bit mode, Address values are 8 bits, ranging from 00 to FF (hex) or 0 to 255 decimal.
Mode - If Mode is set to 0, the 12-bit version of the SIRC protocol is used. If Mode is set to 1, the 15-bit version of the SIRC protocol is used. If Mode is set to 2, extra bits will follow the address. The number of extra bits can be set in the range of 0 to 32. For example, 8 extra bits would correspond to the 20-bit version of the protocol.
Repeats - The number of repeats of the signal to combine into one send. It is an integer ranging from 1 to 10. If omitted, the signal will be set to send once.
Interval - Interval in microseconds between repeats. If omitted, or set to zero, the default repeat timing will be used.
Extra - Extra data to send after the address. It is ignored, unless the Mode is set to 2 (extend) . If Extra starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer.
Extra Bits - The number of bits of extra data to send. Integer in the range of 0-32. Ignored unless in extend mode.
transmit_rc5(Frequency,Command,Address,Extend,[Repeats],[Interval])
First appeared in App version 1.0Assigns a IR pattern based on the rc-5 protocol to the current button.
Frequency - An integer containing the Carrier Frequency in Hz.
Command - The command/data part of the protocol . If Command starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer. Command values are 6 bits, ranging from 00 to 3F (hex) or 0 to 63 decimal.
Address - The address part of the protocol, used to identify a particular device. If Address starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer. Address values are 5 bits, ranging from 00 to 1F (hex) or 0 to 31 decimal.
Extended - When extended, one of the initial start bits is cleared, thus allowing another set of commands to be accessed on the remote device.
Repeats - The number of repeats of the signal to combine into one send. It is an integer ranging from 1 to 10. If omitted, the signal will be set to send once.
Interval - Interval in microseconds between repeats. If omitted, or set to zero, the default repeat timing will be used.
transmit_rc6(Frequency,Command,Address,[Field],[Repeats],[Interval],[Command Bits],[Address Bits])
First appeared in App version 1.0Assigns a IR pattern based on the rc-6 protocol to the current button.
Frequency - An integer containing the Carrier Frequency in Hz.
Command - The command/data part of the protocol . If Command starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer.
Address - The address part of the protocol, used to identify a particular device. If Address starts with 0x, it is treated as hexadecimal, otherwise it is treated as an integer.
Field - Three bits which determine which mode of the protocol to use. Field is usually set to zero, which has an 8 bit address and 8 bit command.
Repeats - The number of repeats of the signal to combine into one send. It is an integer ranging from 1 to 10. If omitted, the signal will be set to send once.
Interval - Interval in microseconds between repeats. If omitted, or set to zero, the default repeat timing will be used.
Command Bits - The number of bits of command data to send. Integer in the range of 0-32. For Field mode 0, the command bits is set to 8. For other modes - unsure of the exact structure and number of bits, so recommend only using mode 0.
Address Bits - The number of bits of address data to send. Integer in the range of 0-32. For Field mode 0, the address bits is set to 8. For other modes - unsure of the exact structure and number of bits, so recommend only using mode 0.
transmit_raw([Frequency],Pattern)
First appeared in App version 1.0Assigns a IR pattern based on raw timing data.
Frequency - An integer containing the Carrier Frequency in Hz. If omitted, it is assumed to be 38000 Hz, unless frequency information is included in the Pattern.
Pattern - This is a string, typically comma separated times in microseconds for subsequent high, low times. The first number corresponds to the time the signal should be high.
An example: transmit_raw(40000,”1200,600,300,300”) would use a carrier frequency of 40 kHz to send a leader signal that is 1200 µs high followed by a 600 µs space before sending a 300 µs high and then finishing with a 300 µs space.
If the pattern consists of pronto code starting with “0000 “, then it will be converted into raw times and the frequency adjusted accordingly.