Total IR Control for Linux
Home arrow Support arrow CommandIR Utils arrow Windows BETA
 
Install CommandIR Windows Utils Beta
The Windows utilities are very simple command-line programs to record and send IR commands. 
 

ImageWindows Installation

Prerequisite: Download CommandIR LibUSB driver and Install CommandIR Windows LibUSB driver (Windows 7 Instructions).  This driver installation is only required once, and is compatible with all CommandIR Util versions.
 
Then to install the utilities:
1. Download the latest CommandIR Utils for Windows Beta.
2. Unzip the files.  There is no installation program. 
 
These are Command-Line utilities.  To use them:
1. Open a 'Command Prompt' from the Start Menu->All Programs->Accessories->Command Prompt
2. use the 'cd' command to move to the folder containing the unzipped utilities.  If you unzipped the utilities in your 'Downloads' directory, type the commands in italic:
Microsoft Windows [Version 6.1.7600]
Copyright (c) 2009 Microsoft Corporation. All rights reserved.
 
C:\Users\Matthew> cd Downloads\CommandIR_Utils_0.61_win32
C:\Users\Matthew\Downloads\CommandIR_Utils_0.61_win32>
 
The utils are commandir_record, commandir_send, commandir_set, and the commandird daemon.  Type them and press enter to see the help screens:
 
C:\Users\Matthew\Downloads\CommandIR_Utils_0.61_win32> commandir_record 
 commandir_record 0.61 Beta

Record IR codes from a CommandIR III

Usage: commandir_record [-n] [-sCOMMANDIR_NAME] [-gGAP_SIZE] BUTTON_NAME [BUTTON_NAME] ...
commandir_record [-n] [-sCOMMANDIR_NAME] [-gGAP_SIZE] -d

-gGAP_SIZE - in microseconds (us): calibrate the recorder to distinguish between repeat signals. Default: 50000
- If -g is not specified, commandir_record will try to determine it.
-d - Display Hex String only, do not save to file.
-sCOMMANDIR_NAME - Record from a specific CommandIR (Firmware >=3.42 required)
-n[HostName] - Record from a CommandIR via the 'commandird' daemon.
Defaults to localhost daemon if no host is specified.
C:\Users\Matthew\Downloads\CommandIR_Utils_0.61_win32> commandir_send
commandir_send 0.61 Beta

Send IR codes to CommandIR (or commandird) for transmitting

commandir_send [-n] [-dDELAY] [[-bEMITTER_BITMASK_HEX] | [-eEMITTERNUM] -sCOMMANDIR_NAME] FILENAME [FILENAME]...
commandir_send [-n] [-dDELAY] [[-bEMITTER_BITMASK_HEX] | [-eEMITTERNUM] -sCOMMANDIR_NAME] -r [RAW CODE STRING]

-n[HostName] - Use a network connection to send the command to a commandird
server. Defaults to localhost if no host specified.
-s used in conjunction with commandir_set and CommandIR Firmware 3.42+
Examples:
Send two commands to emitter 3 with a 500ms delay in between:
commandir_send -d500 -e3 amp_volup amp_volup
Send one command to emitters 1, 2, 3 and 4:
commandir_send -b0F sa_power
Send two commands to emitter 2 on a specific CommandIR named 'COMMANDIR_0':
commandir_send -sCOMMANDIR_0 -e2 amp_volup amp_volup
Send two commands to emitter 2 on a remote CommandIR using commandird:
commandir_send -n192.168.1.15 -e2 amp_volup amp_volup
Send command Hex Code directly:
commandir_send -bff -r 0000 0074 0017 0000 0020 0021 0020 0020 0020 0021 0020 0020 0020 0021 0020 \
0020 0020 0021 0020 0020 0040 0020 0020 0041 003F 0041 0020

C:\Users\Matthew\Downloads\CommandIR_Utils_0.61_win32> commandir_set
commandir_set 0.61 Beta (For CommandIR III Firmware >= 3.42)
Set CommandIR orders, groups, device names, and mini/expansion mode

commandir_set -l
commandir_set -p
commandir_set -n NEW_NAME [BUS_NUM] [DEV_NUM]
commandir_set -r OLD_NAME NEW_NAME
commandir_set -s COMMANDIR_NAME_1 [COMMANDIR_NAME_2] [COMMANDIR_NAME_3] ...
commandir_set -e [-s COMMANDIR_NAME_1 [COMMANDIR_NAME_2] ...]
commandir_set -m [-s COMMANDIR_NAME_1 [COMMANDIR_NAME_2] ...]
commandir_set -d [-s COMMANDIR_NAME_1 [COMMANDIR_NAME_2] ...]

-l List the order and mode of attached CommandIRs
-p Persist the CommandIR order by USB connection order (LIRC's default)
-n Name/rename a CommandIR by USB bus and device numbers
-r Rename a CommandIR
-s Set the order by specifying CommandIR names
-e Set the CommandIR(s) to operate in 'Expanded' mode (expansion required)
-m Set the CommandIR(s) to operate in 'Mini' mode
-d Delete order overrides. CommandIRs will order automatically by USB ids
 
 C:\Users\Matthew\Downloads\CommandIR_Utils_0.61_win32> commandird
 commandird 0.61 Beta

Daemon for programs to send and receive from CommandIR III's via Pipes and TCP/IP

Usage: commandird [-d] [-v] [-sCOMMANDIR_NAME] [-sCOMMANDIR_NAME2] ...

Run with -d or -v to setup network and pipe servers.
-d - run as a daemon
-v - Verbose - do not daemonize; display all activity
-sCOMMANDIR_NAME - Use only specific CommandIRs (Firmware >=3.42 required)

TCP/IP Networking: commandird accepts TCP connections on port 65123
Simply use commandir_record and commandir_send in network mode (with the -n switch)
to use commandird remotely

Pipes: commandird uses two pipes by default:
/tmp/commandir_tx: Create with 'mkfifo /tmp/commandir_tx'
To use this tx pipe, send a commandir_send command line to the pipe.
Example:
echo "commandir_send -b5 -r 0000 0074 0017 0000 0020 0020 0040 0040 0020 0021 0020 0020 0020 \
0021 0020 0020 0020 0021 003F 0021 0020 001F 0020 0021 0020 0020 0020" > /tmp/commandir_tx
commandir_rx: Create with 'mkfifo /tmp/commandir_rx'
To use this rx pipe, simply read the pipe to see the hex code data.
Example:
cat /tmp/commandir_rx
 

If you see these help screens, then you are ready to use your CommandIR. For more details, see commandir_record and commandir_send over on the Linux CommandIR Utils page.

 

Sample Usage and using Batch Files

After recording your remote commands with commandir_record, it is easy to write bat file scripts of commandir_send commands.  You do remember bat files from the 90's, right?  Here's a sample:

 

turn_everything_on.bat:

@echo off
commandir_send -e1 tv_power
commandir_send -e2 dvd_power
commandir_send -e3 receiver_power
commandir_send -e4 wii_power

 

The utilities plus scripts form the basic functionality that other higher layers can tap into.  For example:

  • Configure buttons on your Windows Remote to run CommandIR_Send scripts and control device from your Windows remote
  • Use 'Task Scheduler' to automate turning devices on and off
  • Anywhere you can specify a command to run, you can control your external device with CommandIR!
Last Updated: Thursday, 17 November 2011
 
 
  



CommandIR Control Technologies is a division of InnovationOne Applied Technology.

(C) 2006-2012, All Rights Reserved. 

Last update: Mon Oct 29 22:23:04 EDT 2012

 

Privacy   Terms of Use