Yepkit YKUSH 3 User manual

YKUSH 3 Yepkit USB 3.1 Switchable Hub
User Manual
Version 1.0.0

INDEX
YKUSH 3 Yepkit USB 3.1 Swit hable Hub
CONNECTING AND SETUP
2.
PRODUCT OVERVIEW
1.
USING IT
3.
CONTROL PROTOCOL
4.
1
APPENDIX: REVISION HISTORY
A.

PRODUCT OVERVIEW
YKUSH 3 Yepkit USB 3.1 Swit hable Hub
CONTROL YOUR
USB DEVICES
Yepkit USB 3.1 Switchable Hub
Being able to onne t/dis onne t USB devi es without
having to physi ally plug/unplug is quite helpful for
re urrent pro esses. Bellow are some example of use
ases where this apability is quite advantageous:
The ontrol is a hieved by sending UP/ON and DOWN/OFF ommands to the on-board mi ro ontroller, visible to the
host system as an HID USB devi e. The ommands are based in a very simple proto ol detailed in Control Proto ol
se tion of this manual.
Key Features:
●Three USB 3.1 Gen1 downstream ports
●Sele table USB bus powered or Self/Externally powered
●Full downstream ports swit hing (both VBUS power and data lines)
●ICSP programming interfa e for loading new firmwares
●Loaded with a Bootloader for firmware updates/programming through USB
2
Key Benefits:
●Full ontrol over your USB devi e ON/OFF
●Remote swit hing of USB devi es
●Bus powered for ease of use
●Self/Externally powered for higher urrent devi es
●High flexibility of use and integration brought by a user appli ation layer ontrol software
●Open sour e ontrol software allowing ustomization
●High speed of USB 3.1 Gen1
●Data ba kup systems using USB HDDs
●Data a ess ontrol by emulating the physi al plug/unplug by onne ting/dis onne ting the USB devi e (Both
power and data lines) ontaining or relaying the data
●Power saving s hemes for solutions with USB powered systems or devi es

CONNECTING AND SETUP
YKUSH 3 Yepkit USB 3.1 Swit hable Hub
CONNECTING AND
SETUP
YKUSH 3 board terminals
1MCU additional interfa es breakouts
2ICSP programming interfa e
3External power input terminal
4External / Bus Power Mode sele t jumper
5Upstream Port ( onne t to the host)
6Downstream Port 3
7Downstream Port 2
8Downstream Port 1
95V swit hable power output
10 GPIOs
The hardware setup to start using YKUSH 3 is quite simple, it's onne ted exa tly as any other USB Hub, just
onne t the upstream port to the host system (eg., a PC USB port).
At this point YKUSH 3 is working as Bus Powered Hub (takes the power input from the host USB port). This
powering mode should only be used when just low power USB devi es are to be onne ted. If higher power USB
devi es (e.g., external USB HDD) are to be onne ted then the Self/External Powered mode (external power supply)
is re ommended.
To use the advan ed board fun tionalities a software omponent must be installed in the host system (or ustom
developed by the user). We make available for download our ontrol software, the kushcmd. This software
omponent implements the ommuni ation proto ol with the YKUSH 3 in-board mi ro ontroller that ontrols the
board fun tionalities.
The ontrol appli ation is provided as Open Sour e software and an be downloaded from the YKUSH 3 produ t
page at www.yepkit. om.
The software provided sends ommands from the host system to YKUSH 3 to perform the following a tions:
●Swit h ON (bring UP) a downstream port
●Swit h OFF (bring DOWN) a downstream port
●Get downstream port status
●List the serial numbers of the YKUSH 3 boards onne ted
To make these ommands available in the host system follow the instru tions in the setup guide by following the link
for your system in the produ t page.
3
1
8
10
3
4
5
9
7
6
2

CONNECTING AND SETUP
YKUSH 3 Yepkit USB 3.1 Swit hable Hub
For most use ases the External Powered mode is preferable to avoid instabilities due to insuffi ient power due to
upstream port power onstrains on the host side. Use Bus Powered mode when only low onsumption USB devi es
are to be onne ted to the downstream ports of the YKUSH 3.
4
Selecting power input mode (Bus/Externall Powered)
Power Input Mode
Sele t Jumper
The power input mode is sele ted through
the on-board jumper indi ated in this
pi ture.
The boards are set at fa tory with the
jumper in the Bus Powered position
(VBUS). If the board is intended to be
powered by an external 5V power supply
the user should move the jumper to the
Externally Powered position (VEXT).
Bus Powered (VBUS)
Self/Externall Powered (VEXT)
In Bus Powered mode (jumper at VBUS position), all power ne essary to sour e the
YKUSH 3 internal ir uitry and the power demands from the USB devi es onne ted to
to YKUSH 3 downstreams is sour ed from the Upstream VBUS. This has obvious
limitations imposed by the urrent sour ing apability of the Host port to whi h the
YKUSH 3 upstream is onne ted, and should only be used when just low powered
devi es are to be onne ted to the YKUSH 3.
In Externally Powered mode (jumper at VEXT position), all power is sour ed from an
external 5V power supply. This external power supply must have enough urrent
apa ity to sour e the internal YKUSH 3 ir uitry and all USB devi es atta h to the
downstream ports.
Ensure the external power supply output voltage does not exceed 5.4VDC.

USING IT
YKUSH 3 Yepkit USB 3.1 Swit hable Hub
USING YOUR YKUSH 3
The command structure
[ ] → Optional
< > → Variable
option:
u Turns up/on the downstream port with number port_number
d Turns down/off the downstream port number port_number
g Gets the status of the downstream port number port_number
l List the serial number of the onne ted boards
on Turns ON the 5V power output
off Turns OFF the 5V power output
w Write GPIO
r Read GPIO
Configure port default state
reset Reset devi e
port_number:
1 Downstream port 1
2 Downstream port 2
3 Downstream port 3
a All downstream ports
e Additional 5V swit hable power output
value Value to be written/used
The [-s serial_number] parameter is optional and only relevant when more than one YKUSH 3 board is onne ted
to the same host. This option addresses a spe ifi board with the unique serial number serial_number.
Note that in Windows operating system the ommand is kushcmd.exe instead of kushcmd.
5
Now that everything is set up you an start using the full apabilities of YKUSH 3. If you are using our software
(ykush md), the ommands have the following stru ture and options.
kushcmd kush3 [-s serial_number] -<option> <port_number> [value]

USING IT
YKUSH 3 Yepkit USB 3.1 Swit hable Hub
6
Some examples
Swit h OFF/DOWN the downstream port 1.
kushcmd kush3 -d 1
Swit h ON/UP the downstream port 1.
kushcmd kush3 -u 1
Get status of downstream port 2.
kushcmd kush3 -g 2
List the serial numbers of the onne ted boards.
kushcmd kush3 -l
Swit h OFF/DOWN the downstream port 2 of the board with serial number YK00001.
kushcmd kush3 -s YK00001 -d 2

CONTROL PROTOCOL
YKUSH 3 Yepkit USB 3.1 Swit hable Hub
UNDERSTANDING THE PROTOCOL
The communication protocol
7
YKUSH 3 board has an in-board mi ro ontroller that handles the ontrol ommuni ation with the host system and
performs the swit hing of the downstream USB ports.
This in-board mi ro ontroller is visible to the host system as an HID USB devi e with the following details:
Vendor ID (VID): 0x04D8
Product ID (PID): 0xF11B
The ommuni ation proto ol between the host system and YKUSH 3 in-board mi ro ontroller is a 64 byte pa ket
(HID report) based ommand/a knowledge intera tion.
HOST YKUSH 3
Time
command
ack. response
For detailed proto ol listing refer to the ykush3_protocol_tables.pdf do ument.

APPENDIX: REVISION HISTORY
YKUSH 3 Yepkit USB 3.1 Swit hable Hub
8
Initial release.
Revision 1.0.0 (10/2017)
Table of contents