How does SATA-USB converter work ? - Page 1
Forum section: electronics / beginners

author: houkensjtu
author_rank: Contributor
timestamp: May 12, 2015, 02:24:20 pm
content: I teared down my WD portable harddisk and find out this little board. I googled the chipset name "inicio inic-1807P" is a sata-usb converter(controller) produced by a company called inicio.I want to understand the operating principle but Unfortunately the datasheet is not available on net.Any suggestion or material?

author: free_electron
author_rank: Super Contributor
timestamp: May 12, 2015, 03:20:56 pm
content: all this thing does is create a mass storage class transport over USB. this is a standard class of USB.on the other side it creates a sata port.that's it. the USB class driver wraps the drive commands in a header and payload package, the inico chip unwraps the payload and sends it as sata commands to the drive. the inicio chip has no intelligence.

author: photon
author_rank: Frequent Contributor
timestamp: May 12, 2015, 05:52:01 pm
content: I think the company you want is called Initio. Here is their website.http://www.initio.com/They are a small fabless company in San Jose, CA. Some of the engineers there used to work at Adaptec. The web site will allow you to get a data sheet.

author: houkensjtu
author_rank: Contributor
timestamp: May 13, 2015, 05:13:22 am
content: Quote from: free_electron on May 12, 2015, 03:20:56 pmThanks you for quick reply!Please forgive me if my questions are just too newbie...:1. I use linux and I found this converter board is just "right out of the box" and need no more driver to be installed. HOW can my computer indentify and utilize this chip without new driver(well I know there is some driver doing the job but I just want to know WHICH)2. I also saw a quartz crystal unit like component on the board. What's this little guy's job during converting?3. Finally I know it maybe really stupid to ask but, why there are bunch of capacitors and resistors on the board or, why can't one directly connect the io ports of USB and SATA into the chip?Where can I find useful tutorial or HOWTO's about design principle of such converter circuits?ThX!

author: houkensjtu
author_rank: Contributor
timestamp: May 13, 2015, 05:15:29 am
content: Quote from: photon on May 12, 2015, 05:52:01 pmThank u! Actually I found the same webpage but the datasheet requesting page is out of date..

author: rs20
author_rank: Super Contributor
timestamp: May 13, 2015, 05:18:53 am
content: 1. You could ask the same question about your USB keyboard and mouse: they just work, without linux having specific Dell drivers or whatever. USB defines some standard device classes, including keyboard and, more relevantly mass storage class devices. Linux has generic mass storage class drivers; the chip speakers the mass storage class protocol, everything works.2. USB requires the bitrates to be reasonably well regulated, so that quartz crystal is all about that. Making sure the bits it sends are the right length, and making sure it can understand the incoming bits by having a reference clock to measuring incoming bits with.3. I'm sure the datasheet you've already been pointed to will talking about power supply decoupling caps and termination resistors. If you want some further reading, there are your google terms: "decoupling caps" and "termination resistors". Disclaimer: not all of the caps and resistors there are necessarily all decoupling and termination.

author: houkensjtu
author_rank: Contributor
timestamp: May 13, 2015, 05:51:50 am
content: Quote from: rs20 on May 13, 2015, 05:18:53 amThx for those useful information! And I will further study for decoupling capcitor and termination resistor. Just a quick question again:Generally speaking how is USB device indentified by OS ? Do all usb devices store their basic manufacture information inside themselves? Is this kind communication defined within the USB standard?

author: helius
author_rank: Super Contributor
timestamp: May 13, 2015, 05:57:10 am
content: The USB device is identified by its Device Descriptor and/or Endpoint Descriptors, which contain VID/PID pairs that are supposed to be unique to the device. This is all defined by the USB standard, but it also defines "vendor-specific" communication modes that can be used for arbitrary protocols with specific drivers.

author: Mechatrommer
author_rank: Super Contributor
timestamp: May 13, 2015, 05:57:58 am
content: Quote from: houkensjtu on May 13, 2015, 05:13:22 ammy best guess is... mass storage class is pretty ancient standard along the way with USB standardization during the early day, most OSes already included some form of generic class/driver for this. if the manufacturer adhere to this standard, they can use existing generic driver without needing to develop specialized driver for their chip only. similarly to those elcheapo keyboard and mouse, they come bundled without any software or driver, they adhered to hid/keyboard/mouse class or whatever the name is.

author: marinedalek
author_rank: Contributor
timestamp: May 13, 2015, 01:14:31 pm
content: If I recall correctly, Windows 98 SE still required a driver for USB mass storage. I think some early flash drives even came with one of those 8cm CDs containing the driver for older systems! I think 2000/Me and onwards provided a standard driver.

author: bitwelder
author_rank: Super Contributor
timestamp: May 14, 2015, 08:30:44 am
content: As for the detection on Linux, as example I have just plugged a SATA-to-USB dock on my Linux computer, and in 'dmesg' log I can see the following:[ 7390.296667] usb 3-1: new high-speed USB device number 2 using ehci-pci[ 7390.429976] usb 3-1: New USB device found, idVendor=152d, idProduct=2329[ 7390.429989] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=5[ 7390.429996] usb 3-1: Product: USB to ATA/ATAPI bridge[ 7390.430001] usb 3-1: Manufacturer: JMicron[ 7390.430006] usb 3-1: SerialNumber: 20910BA83FFF[ 7390.467713] usb-storage 3-1:1.0: USB Mass Storage device detected[ 7390.467764] usb-storage 3-1:1.0: Quirks match for vid 152d pid 2329: 8020[ 7390.467788] scsi6 : usb-storage 3-1:1.0[ 7390.467845] usbcore: registered new interface driver usb-storage(continues with ids about the hard disk that is plugged to the dock)also, with 'lsmod' command I can see a usb-storage kernel module has been effectively loaded.If I check the linux sources (v3.13), the file drivers/usb/storage/unusual_devs.h lists among others this JMicron device:UNUSUAL_DEV( 0x152d, 0x2329, 0x0100, 0x0100,"JMicron","USB to ATA/ATAPI Bridge",USB_SC_DEVICE, USB_PR_DEVICE, NULL,US_FL_IGNORE_RESIDUE | US_FL_SANE_SENSE ),So the chain is: udevd (or in older systems hotplugd) process detects a new device has been plugged to USB port, it collects the VID-PID for the device, and as it is a 'well-known' device it knows what do do with it and it triggers the usb-storage functionality for that device.Basically as far as you use a recent kernel, the list of VID-PID should be updated with any device that has been reported been working with Linux, without the need to install additional drivers.

author: houkensjtu
author_rank: Contributor
timestamp: May 14, 2015, 01:23:51 pm
content: Quote from: bitwelder on May 14, 2015, 08:30:44 amThank you for your example session!Still a minor question: you used the word "well-known", does it mean that the kernel is keeping a well-know device list and corresponding module list it should load? (I thought it's quite unrealistic to keep ALL device's driver information in the world).So my guess is the devices provided this kind of driver information themselves. After plugged into the PC, they are like saying "I am XXX and from XXX, please load XXX module for me". Is that right?

author: Monkeh
author_rank: Super Contributor
timestamp: May 14, 2015, 01:35:53 pm
content: Quote from: bitwelder on May 14, 2015, 08:30:44 amudev doesn't need to be involved at all, and with this type of device, nor are the VID or PID, at least as far as basic detection goes.

author: houkensjtu
author_rank: Contributor
timestamp: May 15, 2015, 11:36:02 am
content: A quick update:I googled for "decoupling capacitor" and most of the references said it's usually necessary to add a decoupling capacitor to IC's power supply in order to cut off the high frequency noise. According to this explanation, it seems only one or two capacitor is necessary for one IC, but in my picture apparently there are tens of capacitors around the converter IC, so I suppose there are still other functionality they are doing?

author: amyk
author_rank: Super Contributor
timestamp: May 15, 2015, 03:35:05 pm
content: Quote from: houkensjtu on May 15, 2015, 11:36:02 amYou might want to watch this video from Dave. It's not the same type of capacitor but still relevant:

author: John_ITIC
author_rank: Frequent Contributor
timestamp: May 15, 2015, 11:20:45 pm
content: Quote from: houkensjtu on May 15, 2015, 11:36:02 amGoogle "Power Distribution Network Design":https://www.google.com/?gws_rd=ssl#q=power+distribution+network+designThere are many books written on the subject. The purpose of "decoupling capacitors" is to provide charge to ICs with sufficiently low loop inductance. This in turn is needed to support quickly switching waveforms. By using small capacitor packages, the inductance is minimized. By using parallel capacitors, the effect of the internal resistance (ESR) of the capacitors will be minimized.Note that most IC vendors are telling customers to "put three sizes of capacitors per device power pin". This is nonsense and lazy design. What should be done is to properly calculate the inductance of the power plane and capacitor leads, analyze the impedance requirements for the PCB and finally simulate (hyperlynx or similar software) to ensure that the PCB design is correct. The result of proper analysis is proper functionality and most often a BOM with 25% of the needed capacitors.

author: helius
author_rank: Super Contributor
timestamp: May 16, 2015, 01:17:34 am
content: Quote from: houkensjtu on May 14, 2015, 01:23:51 pmJust looking at dmesg output doesn't tell you what is happening at the hardware level. It's a collection of printfs, not a logic analyzer.If you had looked up the USB standard, you would see the descriptor definitions.http://www.beyondlogic.org/usbnutshell/usb5.shtmlThey are sent by the device in response to a configuration request command from the host. The data in the descriptor tells the host what drivers to use to service the device: in addition to VID/PID, there is also a device class (and subclass, etc...) and a description of all of the device's endpoints and their classes. So if a device has the Mass Storage class and two bulk endpoints, code on the host can decide to treat it as a disk and try to mount it. But of course, devices can have many functions, and disk functionality may be only one part of the USB device.http://www.beyondlogic.org/usbnutshell/usb4.shtml