paul@36 | 1 | Introduction
|
paul@36 | 2 | ------------
|
paul@36 | 3 |
|
paul@36 | 4 | The ben-arduino-usb distribution provides a test program that runs on the Ben
|
paul@36 | 5 | NanoNote and controls USB Host shields designed for the Arduino that employ
|
paul@36 | 6 | the MAX3421E USB Peripheral/Host Controller. To connect a suitable Arduino
|
paul@36 | 7 | shield to the Ben, the 8:10 port which is typically employed to access microSD
|
paul@36 | 8 | cards is instead used to hold a suitable breakout board that exposes the 8:10
|
paul@36 | 9 | port's connectors to other circuits. These connectors are in turn connected to
|
paul@36 | 10 | specific connectors on the Arduino USB Host shield as follows:
|
paul@36 | 11 |
|
paul@36 | 12 | Sniffer UBB Shield
|
paul@36 | 13 | ------- ---- ------
|
paul@36 | 14 | |----------------------------------- DAT2 DAT2 9 (INT)
|
paul@36 | 15 | | |------------------------------ CD DAT3 10 (SS)
|
paul@36 | 16 | |-------------+----+------------------------------ CMD CMD 7 (RESET)
|
paul@36 | 17 | | | | VCC VDD VIN
|
paul@36 | 18 | | | | |-------------- CLK CLK 13 (SCLK)
|
paul@36 | 19 | | | | | GND GND GND
|
paul@36 | 20 | | | | |---------+-------------- DAT0 DAT0 11 (MOSI)
|
paul@36 | 21 | | | | | |----+-------------- DAT1 DAT1 12 (MISO)
|
paul@36 | 22 | | | | | | |
|
paul@36 | 23 |
|
paul@36 | 24 | RX ... 7 8 9 10 11 12 13 GND AREF (shield labelling)
|
paul@36 | 25 | RESET GPX INT SS MOSI MISO SCLK (shield connections)
|
paul@36 | 26 |
|
paul@36 | 27 | Unlike Arduino-based usage of the shield, the GPX pin is not used purely
|
paul@36 | 28 | because the 8:10 port does not expose enough connections.
|
paul@36 | 29 |
|
paul@36 | 30 | To power the shield, a 5V supply needs to be supplied to the shield's VIN
|
paul@36 | 31 | connector and when used in conjunction with an Arduino Duemilanove or other
|
paul@36 | 32 | 5V-capable Arduino, the Vin connector in the POWER block of pins will provide
|
paul@36 | 33 | this power. The GND connector on the shield can be connected to the Gnd
|
paul@36 | 34 | connector next to the Vin connector on the Arduino board.
|
paul@36 | 35 |
|
paul@36 | 36 | If an Arduino is to be used to provide power, it is important that it receive
|
paul@36 | 37 | power from a sufficient power source itself. It is not sufficient for the
|
paul@36 | 38 | Arduino to rely on USB bus power from a host computer in order to pass it on
|
paul@36 | 39 | to the shield, especially where a Sparkfun shield is concerned. However, a
|
paul@36 | 40 | suitable power source can be plugged into the "power jack" on the Arduino
|
paul@36 | 41 | board instead of using USB bus power, and the hardware specifications for the
|
paul@36 | 42 | specific shield in question should be consulted so that the correct voltage is
|
paul@36 | 43 | chosen.
|
paul@36 | 44 |
|
paul@36 | 45 | For an Arduino Duemilanove, a power supply of 7V-12V is apparently acceptable
|
paul@36 | 46 | for input into the "power jack", and this solution has been tested with a
|
paul@36 | 47 | power adaptor supplying 9V, with the tip of the adapter's "male" connector
|
paul@36 | 48 | being the positive terminal.
|
paul@36 | 49 |
|
paul@36 | 50 | Warning!
|
paul@36 | 51 | --------
|
paul@36 | 52 |
|
paul@36 | 53 | Do not supply 5V power to any of the connectors used by the Ben. Check that
|
paul@36 | 54 | the shield you are using employs 3.3V power in the controller-related
|
paul@36 | 55 | functions of the board. Connecting the Ben to a peripheral is done at your own
|
paul@36 | 56 | risk.
|
paul@36 | 57 |
|
paul@36 | 58 | Hardware: USB Host Shield
|
paul@36 | 59 | -------------------------
|
paul@36 | 60 |
|
paul@36 | 61 | This software has been developed using the Sparkfun USB Host shield which is
|
paul@36 | 62 | available as product DEV-09947 from various retailers and from Sparkfun:
|
paul@36 | 63 |
|
paul@36 | 64 | https://www.sparkfun.com/products/9947
|
paul@36 | 65 |
|
paul@36 | 66 | Various revisions of this board have been made, but only those labelled with
|
paul@36 | 67 | "5-28-10" on the rear of the board can be assumed to function with the
|
paul@36 | 68 | configuration described above.
|
paul@36 | 69 |
|
paul@36 | 70 | Although the Sparkfun board functions in the above configuration, it may not
|
paul@36 | 71 | be reliable in use with a power supply based on USB bus power coming through
|
paul@36 | 72 | an Arduino board. In addition to this apparent defect, in order for the
|
paul@36 | 73 | Sparkfun board to be usable in Arduino-based solutions (where the software
|
paul@36 | 74 | runs on the Arduino, not the Ben), Sparkfun have relied upon software provided
|
paul@36 | 75 | by Oleg Mazurov who has designed his own USB Host shield based on the
|
paul@36 | 76 | MAX3421E.
|
paul@36 | 77 |
|
paul@36 | 78 | Although Oleg's shield and Sparkfun's shield may be distinct designs, Sparkfun
|
paul@36 | 79 | clearly benefit substantially from Oleg's work and yet compete with him
|
paul@36 | 80 | directly in sales of hardware. Thus, for apparently better reliability under
|
paul@36 | 81 | certain usage conditions and to support Oleg's work, I suggest purchasing a
|
paul@36 | 82 | USB Host Shield product from Circuits At Home:
|
paul@36 | 83 |
|
paul@36 | 84 | http://www.circuitsathome.com/arduino_usb_host_shield_projects
|
paul@36 | 85 |
|
paul@36 | 86 | Hardware: 8:10 Port Breakout Board
|
paul@36 | 87 | ----------------------------------
|
paul@36 | 88 |
|
paul@36 | 89 | To connect the Ben NanoNote to the USB Host shield, a suitable breakout board
|
paul@36 | 90 | is required to expose the connections inside the 8:10 slot. To achieve this,
|
paul@36 | 91 | the Sparkfun microSD Sniffer has been used:
|
paul@36 | 92 |
|
paul@36 | 93 | https://www.sparkfun.com/products/9419
|
paul@36 | 94 |
|
paul@36 | 95 | This board is apparently intended for eavesdropping on communications between
|
paul@36 | 96 | a "host" device with a microSD slot and a microSD-based device that can be
|
paul@36 | 97 | inserted into a slot mounted on the board (instead of being inserted directly
|
paul@36 | 98 | into the host device). However, the board-mounted slot can be ignored and the
|
paul@36 | 99 | exposed connections routed to the USB Host shield instead.
|
paul@36 | 100 |
|
paul@36 | 101 | Another board that achieves the same purpose is the Universal Breakout Board
|
paul@36 | 102 | (UBB):
|
paul@36 | 103 |
|
paul@36 | 104 | http://en.qi-hardware.com/wiki/UBB
|
paul@36 | 105 |
|
paul@36 | 106 | The UBB is somewhat more difficult to work with as its connectors are very
|
paul@36 | 107 | small and, compared to the microSD Sniffer, awkward to attach things to. The
|
paul@36 | 108 | microSD Sniffer employs connectors situated around holes with 0.1 inch
|
paul@36 | 109 | spacing, meaning that commonly available connection headers can be soldered
|
paul@36 | 110 | onto the board.
|
paul@36 | 111 |
|
paul@36 | 112 | Although the labelling of the connections is different between the microSD
|
paul@36 | 113 | Sniffer and UBB (see above), the layout appears to be identical.
|
paul@36 | 114 |
|
paul@36 | 115 | Contact, Copyright and Licence Information
|
paul@36 | 116 | ------------------------------------------
|
paul@36 | 117 |
|
paul@36 | 118 | The author can be contacted at the following e-mail address:
|
paul@36 | 119 |
|
paul@36 | 120 | paul@boddie.org.uk
|
paul@36 | 121 |
|
paul@36 | 122 | Copyright and licence information can be found in the docs directory - see
|
paul@36 | 123 | docs/COPYING.txt and docs/LICENCE.txt for more information.
|
paul@36 | 124 |
|
paul@36 | 125 | The software being distributed has been developed using the MAX3421E
|
paul@36 | 126 | documentation. Although the author has occasionally consulted Oleg Mazurov's
|
paul@36 | 127 | Arduino libraries for clarification when unexpected behaviour has occurred
|
paul@36 | 128 | when testing this software, this software does not use any code from those
|
paul@36 | 129 | libraries. Nevertheless, the author would like to give credit to Oleg for
|
paul@36 | 130 | demonstrating the feasibility of the MAX3421E solution and thus providing the
|
paul@36 | 131 | motivation to get the hardware working with the Ben NanoNote.
|