Option 1 ( Software Baud Rate selection )
This Blog post explains how to set Irdroid USB irDA module baud rates. The mcp2120 used in Irdroid USB irDA module allows for setting the Baud rate in software when the controller is in command mode. The is a small switch under the module that can switch the unit in command mode for changing the baud rate in Software. Below are the steps for accomplishing this.
Use a terminal program that can send HEX chars. In my case I am using RealTerm to do the job. Insert the Irdroid USB irDA module in a free USB port of your PC or MAC, then start realterm identify the com port number of the Irdroid USB Irda module and set the baud rate to 9600 then click “Open” and then click on the “Send” Tab
The available HEX commands for switching the Irdroid USB Irda module SIR baud rate are:
- – 0x87 9600bps (Default)
- – 0x8B 19200bps
- – 0x85 38400bps
- – 0x83 57600bps
- – 0x81 115200bps
0x11 a command that has to be sent after the command for baud rate selection. This command is for confirming the new baud rate.
Choose the command from the list above and write the respective HEX code in the “Send” field see the image below. Then click on “Numbers” . The command will be sent to the module and echoed back. To confirm the new Baud rate send the 0x11 HEX command in the same field. then flip back the switch of the module and reopen the com port with the new baud rate (The above should be done every time the module is plugged)
- When in command mode you can receive IR data at the newly selected baud rate, but if the switch is flipped you can not send IR data as you communicate with the controller and it expects commands for changing the baud rate
Option 2 ( Hardware Baud Rate Selection )
The Hardware Baud Rate selection requires opening the module enclosure and soldering skills. MCP2120 has three Baud Rate configuration pins that allow for Baud rate selection in Hardaware (The benefit of using hardware selection of baud rate is for systems with a fixed baud rate that rarely changes and also the baud rate is selected after power-on reset. In software selection mode the baud rate needs to be configured every time the module is powered ). The combination is show in the table below:
Below is example configuration for 115200 Baud rate selection made in Hardware: