Wednesday, 25 February 2015 12:07

USB Host Relay board

Written by




KMtronic USB Host  Arduino compatible relay board


KMtronic USB Host  Arduino compatible relay board




Multifunctional 8 Relay board with USB Host interface. USB Host allo to connect to board and control relays using any ready USB Device like Bluetooth, Joystick, Keyboard, Remote control, Mouse, RFID Reader, HID devices or custom developed modules.

What is idea?
Build open source universal relay board with possibilities control using any ready or custom made USB device.



Technical Details

  • Arduino MEGA ADK compatible
  • ATmega2560 microcontroller
  • Flash Memory: 256 KB of which 8 KB used by bootloader
  • SRAM: 8 KB
  • EEPROM: 4 KB
  • Clock Speed: 16 MHz
  • USB Host Chip: MAX3421E
  • Required power: 12VDC/1500 mA
  • Outputs: 8 relays each capable of switching 12VDC/10A or 240VAC/7A. Each relay has an LED to indicate when it is operated.
  • Two collors functional LED (Green + Red)


Relays specifications:
Relays has Normally Open (NO) and Normally Closed (NC) Contacts rated for voltages:
- 12VDC/10A
- 24VDC/10A
- 125VAC/10A
- 250VAC/7A


After test examples "USB Host Library for Arduino" Lauszus (TKJElectronics) and Oleg Mazurov we just successfully control relays using:

USB Keyboard

USB Mouse

USB Joystick

USB Bluetooth

USB Remote control


Now try to expand examples with many more USB devices like:

USB WIFI module

USB 3G Module

Android USB Control

USB DS1820 Temperature reader

Custom USB Modules






USB > RF433MHz > 8 Channel Relay Board










are available to work with the following operating systems :
All Windows versions, Linux, Mac OS X, Mac OS 9, Mac OS 8,
Windows CE.NET (Version 4.2 and greater), Arduino, Raspberry Pi ...


Required power:
12VDC / minimum 600 mA.


Wireless Data Transmittion Module:
CC1101 Low-Power RF Transceiver
(Texas Instruments)


USB Converter:
CDC USB to Serial Converter


Communication Parameters:
8 Data, 1 Stop, No Parity
Baud rate : 9600



Commands (ID01):
FIRST channel commands:
OFF command : FF 01 00 (HEX) or 255 1 0 (DEC)
ON command : FF 01 01 (HEX) or 255 1 1 (DEC)
EIGHT channel commands:
OFF command : FF 08 00 (HEX) or 255 8 0 (DEC)
ON command : FF 08 01 (HEX) or 255 8 1 (DEC)

 Status read (ID01):
Command - FF A1 00 
Reply - FF A1 xx xx xx xx xx xx xx xx
where xx is: 00 if relay is OFF, 01 if relay is ON


Relay board have an option to change the ID (from ID 01 to ID 15) manually
through a DIP Switch placed near power connector.




In open area max 350 meters










KMTronic RF433MHz Relay Boards Installation Guide





















Thursday, 08 January 2015 07:43

Windows startup control KMtronic USB Relays

Written by



Execute a script a startup



Download KMtronic command line application, configure and test that work:



Download "start.bat" and change COM port and path to KMtronic command line application:


"start.bat" file:

timeout /t 10
D:/usbrelay.exe -c:20 -r:1#1



Start the policy editor of the local group: Start Menu > Run > Type gpedit.msc




  • Go to Computer Configuration > Windows Settings > Scripts (Startup/Shutdown)
  • Double click on Startup>Show files ...
  • Copy "start.bat" in folder


















Tuesday, 09 December 2014 11:22


Written by







Friday, 07 November 2014 08:57

PLC 8 relay remote control for iPhone and iPad

Written by



PLC 8 relay remote control net

Vincenzo Scozzaro


8 channels WEB Relay board




















Wednesday, 17 September 2014 10:36

Raspberry Pi LCD 16x2 Display

Written by


1. Raspberry Pi
2. 16x2 LCD display 202A-D REV.A
3. Cables
4. Recommend install Raspbian






Pictures on Display









Upgrade distribute (required for RPi.GPIO 0.3.1a) 
$ sudo apt-get install python-dev
$ sudo apt-get install python-setuptools
$ sudo apt-get install unzip
Download and test display
$ unzip
$ chmod +x
$ sudo
You can test the wiring from the previous step by simply running the
python code, as it has a little code it in that will simply display a test message when wired
If you're using a Version 2 Raspberry Pi, pin #21 has been replaced with pin #27 so edit and change:
def __init__(self, pin_rs=25, pin_e=24, pins_db=[23, 17, 21, 22], GPIO = None):
def __init__(self, pin_rs=25, pin_e=24, pins_db=[23, 17, 27, 22], GPIO = None):


Wednesday, 17 September 2014 07:33

Server Control

Written by





MySql Table




MAC Address

MAC address (ID) relay board



Status relays after power lost



Status relays when connection to server lost



Curent status



Time between two connections in secconds



Relay board with MAC address 70-B3-D5-6D-60-1C:

- when lost power and be powered will turn all relays OFF

- when lost connection to server will turn relays 1,2,3,4,5 OFF, relays 6,7,8 ON

- will turn relays 1,3,5,7 ON, relays 2,4,6,8 OFF










Monday, 15 September 2014 08:11

Raspberry Pi How to install Web Server

Written by

  1. 1
    Because you are running a fresh version of Raspberry PI (Raspbian) , you will need to do some housecleaning, updating, and installing. First, we are going to update the clock, update our sources, then upgrade any pre-installed packages. Type the following at the command line (press return/enter after each line):
    sudo dpkg-reconfigure tzdata
    sudo apt-get update
    sudo apt-get upgrade
  1. 2
    Set the date and time. From the command line type (replace parts as necessary):
    sudo date --set="15 September 2014 11:13:00"
  1. 3
    To install Apache and PHP, execute the following commands:
    sudo apt-get install apache2 php5 libapache2-mod-php5
  1. 4
    Now restart the service:
    sudo service apache2 restart

    sudo /etc/init.d/apache2 restart
  1. 5
    To install MySQL, install a few packages with the following command:
    sudo apt-get install mysql-server mysql-client php5-mysql
  1. 6
    We will now install FTP to allow transferring files to and from your Raspberry Pi.
  2. 7
    Take ownership of the web root:
    sudo chown -R pi /var/www
  3. 8
    Next, install vsftpd:
    sudo apt-get install vsftpd
  4. 9
    Edit your vsftpd.conf file:
    sudo nano /etc/vsftpd.conf
  5. 10
    Make the following changes:
    • anonymous_enable=YES to anonymous_enable=NO
    • Uncomment local_enable=YES and write_enable=YES by deleting the #symbol in front of each line
    • then go to the bottom of the file and add force_dot_files=YES.
  6. 11
    Now save and exit the file by pressing CTRL-O, CTRL-X.
  7. 12
    Now restart vsftpd:
    sudo service vsftpd restart
  8. 13
    Create a shortcut from the Pi user's home folder to /var/www:
    ln -s /var/www/ ~/www
  9. 14
    You can now FTP using the Pi user and access the /var/www folder via a shortcut that should appear on login.
Monday, 15 September 2014 08:10

Raspberry Pi Web Control Relay

Written by
1 RaspberryPI
1 USB 485 Relay (for test)
USB cable
Web Server
recommend install Raspbian
Install KMTronic Web Interface 
 $ wget
$ cd /var/www/
$ unzip
$ chmod +x
$ chmod +x
Set Permissions on usbtty0
$chmod -R 777 /dev/ttyUSB0
Web interface
Mobile Interface
Friday, 12 September 2014 07:57

Raspberry Pi RS232 8 Relay Board

Written by


Now I'll show you a very easy way how to control RS232 8 relays

with the help of Raspberry PI 


1 RaspberryPI 

1 RS232 KMTronic 8 Relay Board

1 USB cable 

1 FTDI KMTronic
1 RS232 to TTL converter with MAX232
2 DB9 RS232 Male
12-volt power
recommend install Raspbian
DB9 RS232 Male to Male
FTDI to RS232 to TTL converter with MAX232


Sets baud rate of the USB relay
stty -F /dev/ttyUSB0 9600
How to switch on or off the relays
Shell code
# sends on signal to the USB relay
echo -e "\xFF\x01\x01" > /dev/ttyUSB0   -----> ON 
echo -e "\xFF\x01\x00" > /dev/ttyUSB0   -----> OFF
Page 7 of 33