Wire Command Reference
Learn button codes sent from IR remote controls. The codes are received via an Global Caché® iTach network device.
Command Line Options
Command Line Options
user@boxen:~/Wire$ ./wire -h Wagner IR Extractor, v2.0 Usage: wire [-a n] [-h] [-i ip] [-p port] [-r remote] [-s n] [-u] [-v] Where: -a n Set learn attempts (default: 10) -h Help (this screen) -i ip Set IP address (default: 192.168.1.70) -p port Set command port (default: 4998) -r remote Select IR remote (default: default) -s n Set learn strength (default: 3) -u Update config file -v Verbose mode Default values are stored in the file ~/wired/wire.conf
Option: Set Learn Attempts (
This option sets the maximum number of times that a remote button can be pressed in a learn attempt. The minimum number is set by the ‘
-s‘ option. This ‘
-a‘ option is merely to curtail a bad learn attempt sequence. See ‘
-s‘ option for further explanation.
Option: Help (
Display the command line options. Options with values will show the default values currently stored in the configuration file.
Option: Set IP Address (
The one option that you are most likely to need. Once you discover the IP address assigned to your iTach device you will need to supply it with this option.
Option: Set Command Port (
The IP port number used by the iTach device. There are very few reasons to alter this value from the default of 4998.
Option: Name of IR Remote (
This option sets the name of the remote. The name can be either an existing remote or a new one. Remote names containing spaces will need to be quoted. If you make a mistake entering the name of an existing remote, a new remote will be silently created. For this reason it is preferable to use the
Choose Remote option from the main menu.
Option: Set Learn Strength (
Each time you press a remote button, the IR signal is converted into a sequence of values. The environment you are working in can adversely affect the quality of the converted data. As such we need to capture the data several times for comparison. This option sets the number of IR captures that must match each other to assure correct data.
Option: Update Configuration File (
The options requiring a parameter (
-s) derive their default values from the Wire configuration file. Providing one of these options overrides the default configuration. You may write these command line values to the configuration file with the ‘
-u‘ option. The next invocation of Wire will therefore use the newly saved values, eliminating the need to provide them on the command line. For example, the default for the IP address in the ‘
-i‘ option shown above is
192.168.1.70, but the following Wire command:
user@boxen:~/Wire$ ./wire -i 172.16.1.100 -u
changes the configuration file to reflect
172.16.1.100 as the new default IP address.
Option: Verbose Mode (
Set this option to see the expanded results of a successful learn attempt
user@boxen:~/Wire$ ./wire -v ... Remote[My TV] Command (1-7)? 2 Press remote button 1: got it ... Press button again 2: good go ... Press button again 3: good go ... last one Button capture successful ------------------------------------------------------------------------ CARRIER: 38343 IR DATA: 8,34,8,66,8,29,8,109,8,50,8,50,8,45,8,103,8,498,8,34,8,109,8, 29,8,29,8,29,8,29,8,29,8,29,8 IR REPEAT: 8,34,8,66,8,29,8,109,8,50,8,50,8,45,8,103,8,498,8,34,8,66, 8,71,8,29,8,29,8,29,8,29,8,29,8 IR HALF STOP: 3136 IR FULL STOP: 4907 ------------------------------------------------------------------------
- CARRIER is the clock frequency of the IR signal.
- IR DATA is the actual sequence of IR data received.
- IR REPEAT is IR data for buttons with repeat sequences.
- IR HALF STOP is the gap between IR-DATA and IR_REPEAT.
- IR FULL STOP is the pause after the end of all IR data.
Select menu item: 1) Choose remote 2) Learn a button 3) Save a button 4) Delete a button 5) List saved buttons 6) Test button IR 7) Exit Remote[default] Command (1-7)?
The main menu prompt shows the name of the currently selected IR remote. This will display “default” if no remote has been selected. You change the remote by selecting Choose Remote from the menu. A list of available remotes will be displayed, plus the option to create a new remote.
Choose a remote: 1) NEW REMOTE 2) Comcast_3067BC2-R 3) Toshiba_SD-V296 Select remote (1-3)?
NEW REMOTE and a prompt will ask your for a name.
Select remote (1-3)? 1 Enter remote name: My Remote
At which point the prompt will change to reflect the newly created remote.
Remote[My Remote] Command (1-7)?
The remote you choose will remain persistent through successive runs of Wire. The next time you run Wire, the same remote will be selected.
Learn a button
This will initiate the process of capturing the IR codes for a remote button. You will be prompted to press the desired button on your remote.
Press remote button
Aim your remote at the sensor on the iTach device and hold the button down for at least a second. You have 15 seconds to respond before the program times-out. Wire will respond with:
1: got it ... Press button again
This indicates that the IR codes were received, and that you need to press the button again. After the second press you will see this message on a successful capture.
2: good go ... Press button again
If the capture was not successful then this message will be displayed:
2: nice try ... Press button again
In either case, you are requested to press the remote button yet again. Once you have successfully received IR data equal to the selected Learn Strength (default: 3), you will be done. A completed button learning sequence looks as follows:
Press remote button 1: got it ... Press button again 2: good go ... Press button again 3: good go ... last one Button capture successful
If you are seeing a lot of “nice try” messages you will have to adjust the way you are pointing the remote at the iTach device. It is best when the remote is no more than a few inches away and pointed directly into the hole. The remote should not be held at an angle to the device.
Save a button
Once you have finished learning a button, it can be saved to the remote file. You can give it any name you wish as long as it does not contain either of the square bracket ‘’ characters.
Enter button name: Power Button 'Power' saved
If the name you enter is already in the button file, you will be prompted as to whether the data should be overwritten:
Enter button name: 0 Overwrite button? [y/N] y Button '0' saved
Learned IR data that has not been saved can be overwritten by a subsequent button learning process.
Delete a button
Permanently remove a button from a remote file:
Enter button name to be deleted: 0 Button '0' deleted
When the requested button does not exist in the remote file:
Enter button name to be deleted: g Button 'g' not found
List saved buttons
Show a list of all buttons in the current remote file.
Button Carrier Pulses Burst Spacer ------------------------------------------------------------------------ 0 38343Hz 36 157ms 127ms 1 38343Hz 36 157ms 127ms 2 38343Hz 36 157ms 127ms 3 38343Hz 36 157ms 127ms 4 38343Hz 36 157ms 127ms 5 38343Hz 36 157ms 127ms 6 38343Hz 36 157ms 127ms 7 38343Hz 36 157ms 127ms 8 38343Hz 36 159ms 127ms 9 38343Hz 36 159ms 127ms +CH 38343Hz 36 159ms 127ms -CH 38343Hz 36 159ms 127ms ENTER 38343Hz 36 157ms 127ms POWER 38343Hz 36 159ms 127ms +VOL 38343Hz 36 159ms 127ms -VOL 38343Hz 36 159ms 127ms
|Button||– Name of the button|
|Carrier||– Clock frequency of the IR transmitter|
|Pulses||– Number of IR pulses in button code|
|Burst||– Length of IR stream in milliseconds|
|Spacer||– Gap at end of IR stream in milliseconds|
Test button IR
You can test any of the buttons you have saved. This will send your saved button data out the IR emitter of the iTach device. If all goes well then your IR receiver (i.e., TV set) should react as though you pressed the button on your remote control.
Select IR output connector: 1) Connector 1 [Mode: IR] 2) Connector 2 [Mode: IR] 3) Connector 3 [Mode: IR_BLASTER] Connector (1-3)? 1 Enter comma separated list of buttons: Power done
# ******************************************************** # Default values used by "wire", "wirch" and "wircmd" # Edit these for your specific needs # ******************************************************** # - IP address assigned to iTach device # Out of the box, an iTach device is assigned the ip address: 169.254.1.70 ip_address="192.168.1.70" # - Command port number of iTach device # This default value is unlikely to ever change. command_port="4998" # - Number of learn attempts that must match # A value of 1 shuts off the mechanism and # just accepts whatever the first attempt provides. # This parameter only used by wire utility learn_strength="3" # - Number of learn attempts before quiting # Otherwise the program may get caught in an infinite loop. # This parameter only used by wire utility learn_attempts="10" # - Name of chosen remote # Remotes are stored in your home directory # under wired/remotes. Each is a file with the 'txt' extension. ir_remote="default" # - IR Blaster connector port number (1-3) # This parameter only used by wirch and wircmd utilities. ir_connector="1" # - Delay in seconds between each IR character transmitted # This parameter only used by wirch and wircmd utilities. digit_delay="0.5" # - Name of button to be sent after channel number # This parameter only used by wirch utility. terminal_button=""