usb training - silicon labs -
DESCRIPTION
Slideshow the Silicon Labs Meeting on USB BridgeTRANSCRIPT
������������� ���������� � ��
�
��� ���������� ��
♦ Mixed-signal semiconductor company� Headquartered in Austin, TX� Fabless manufacturing model
♦ Proven, established partner� $425M annual revenue� More than 600 employees
♦ World-class mixed-signal talent� Engineering focused� Broad IP portfolio
�
������������������
♦ Workhorse technology for semiconductor industry� Low cost, abundant, portable� Consistently two generations ahead of other technologies
♦ New architectures for high-performance mixed-signal ICs� Breakthrough integration possibilities� Opportunity to leverage mixed-signal design expertise
����!�"�������#�������� ���
First Globally Compliant
Silicon DAA
First Globally Compliant
Silicon DAA
$%%&
First Single Chip GSM RF
Synthesizer
First Single Chip GSM RF
Synthesizer
First CMOS GSM/GPRS Transceiver
First CMOS GSM/GPRS Transceiver
First Embedded Modem with Silicon DAA
First Embedded Modem with Silicon DAA
First Integrated CMOS SLIC
First Integrated CMOS SLIC
First CMOS GSM Power
Amplifier
First CMOS GSM Power
Amplifier
First CMOS 8051 MCU with
24-bit ADC
First CMOS 8051 MCU with
24-bit ADC
First Single-Chip CMOS GSM/GPRS
Transceiver
First Single-Chip CMOS GSM/GPRS
Transceiver
First CMOS Digital
FM Tuner
First CMOS Digital
FM Tuner
First Fully Digital Power
Controller
First Fully Digital Power
Controller
�''(
First Single-Chip GSM/GPRS
Phone
First Single-Chip GSM/GPRS
Phone
(
������) ##����� ����
High level of integration
Easy implementation
Few external components
Rapid time-to-market
Low power consumption
Small footprint
Customer Requirements
Customer Benefits
*
+������+���#�� �
SiRX™ Satellite ReceiversFM Radio TunersSatellite Radio Tuners
Precision Mixed-SignalSmall Form FactorCANUSBUSB to UART Bridge
Digital Power Controllers
Frequency Control Solutions Precision Clock ICs
ISOmodem®
ProSLIC®
DSL AFESilicon DAASiPHY® High-Speed ICs
AeroFONE™ Single-Chip PhoneAero® Transceiver FamilyGSM/GPRS Power AmplifierRF Synthesizers
,
� ���+�����
Precision Mixed-Signal
Small Form Factor
CAN
USB
USB to UART Bridge Applications:
IndustrialConsumerAutomotiveMedical Power Management
&
� � ����-�.�� /��0� ��������
♦ Smallest� 3x3 mm, 4x4 mm, 5x5 mm packages� Very flexible I/O system to maximize pin functions� Highest integration in class
♦ Fastest � Fastest 8-Bit CPU available–100 MHz� 70% of instructions 1 or 2 cycles� On-chip debugging hardware� 8051 compatible
♦ Best analog� ADCs� DACs� Precision oscillator� Comparators� On-chip temperature sensor
$''$''$''$''
Silicon Labs
''''
$'$'$'$'
�'�'�'�'
�'�'�'�'
' ' ' '
('('('('
*'*'*'*'
,',',','
&'&'&'&'
%'%'%'%'
A B C
Pea
k M
IPS
Silicon Labs
%
��� ����������� 0��0�0�� ������ ��
Advance analog integration enables the following:� Complete system-on-a-chip� Simpler designs and shorter design cycle� Faster time to market� Higher reliability and less quality issues� Better cost structure
Typical 8-bit MCUMulti-Chip Discrete Solution
C
C
C
R
XTA
L
DA
C12
PG
A
uC
ON
TR
OL
LE
R
AD
C24
CM
P
CRR
R R
RE
F
R
C
19.4 x 16.5 mm = 320 mm²
Silicon Labs Solution
5 x 5 mm = 25 mm²
$'
1 ��0+��#��� �����2������������������
Flash Memory:On-chip charge pumpSmall segmentsSecurityEmulates byte EEPROM
Cross Bar:Custom select I/O
8051 CPU:Up to 100 MHz70% Instr. in 1 or 2 cyclesPipelined object code compatibility
Debug:On-chip JTAG-based
Serial Communications:UARTSPISMBusUSB 2.0CAN 2.0B
Timers:Capture & CompareAccumulatePWMRTC
I/O:Dynamically reconfigurable
Analog-to-Digital:Up to 16-Bit SARUp to 24-Bit Sigma-DeltaUp to 1 MspsDual ADC optionUp to 32-ChannelsSelectable VREF
Digital-to-Analog:Up to 12-Bit
Analog:Temperature sensorProgrammable comparatorsPrecision Oscillator
$$
3��� ����������������#�������"�4 ��� ���
♦ Many embedded systems are distributed networks and mustmust be connected in order to share information
♦ Different embedded networks require different modes of connectivity� High-speed� Wireless
� RF� IR
� TCP/IP based� Fault tolerant� Cost effective
♦ Silicon Laboratories has embedded connectivity solutions for each one of these areas
$�
� � ����-�.�������������� � ������������
♦ USB Connectivity� Wide range of MCU and fixed function solutions with software
drivers and reference designs
♦ RF wireless networking� 802.15.4 and ZigBee solutions
♦ Ethernet and TCP/IP networks� Hardware reference designs� Full CMX TCP/IP protocol stack
♦ Fault-tolerant distributed networking� CAN enabled MCU products with 32 message buffers
♦ Cost sensitive networks� UART, IIC, and SPI enabled MCUs
RSRS--485 multi485 multi--drop networkdrop network
Ethernet Development KitEthernet Development Kit
CP2201 Evaluation KitCP2201 Evaluation Kit
$�
��� ������ ���� /��0� ���������2 /��02��� ���
�������� ��
♦ CP210x family of devices� Fixed function USB to UART
bridges provide the easiest method for upgrading legacy RS-232 systems with USB
♦ Mixed-Signal USB MCUs� High-speed 8051 core operating
up to 48 MIPS� Up to 64 kB on-board Flash and
5376 bytes of RAM� 17 ch. 10-bit, 200 ksps ADC� External memory interface� In-system non-intrusive debug
engine eliminates the need for emulators
� Integrated on-chip regulator, oscillator, and USB transceiver
� Effective operating range from 2.7 to 5.25 V
C8051F340C8051F340--GQGQ
UART1
64 kB FLASH
256 Byte SRAM
POR
SFR Bus
8051
Core
ResetRST/C2CK
External Oscillator
Circuit
Debug HW
Brown-Out
P0
Drv
4 kB XRAM
XTAL1 XTAL2
P0.0P0.1P0.2/XTAL1P0.3/XTAL2P0.4P0.5P0.6/CNVSTRP0.7/VREF
SPI
REGIN
CROSSBAR
P1
Drv
P1.0P1.1P1.2P1.3P1.4P1.5/ALEP1.6/RDP1.7/WR
Port 0 Latch
SMBus
Timer 0,1,2,3 /
RTC
UART0
System Clock
P2
Drv
P3
Drv
P2.0/A0P2.1/A1P2.2/A2P2.3/A3P2.4/A4P2.5/A5P2.6/A6P2.7/A7
C2D
P1 Latch
PCA/WDT
USBController
USBTransceiver
Analog/Digital Power
VoltageRegulator
5.0V
1 kB USB SRAM
VBUS
D+
D-
12 MHzInternal
Oscillator
GND
VDD
IN
OUT
Enable
x4 ÷ 2
USB Clock÷ 2
÷ 1,2,3,4Clock
Recovery
P3.0/A8/C2DP3.1/A9P3.2/A10P3.3/A11P3.4/A12P3.5/A13P3.6/A14P3.7/A15
External DataMemory Bus
10-bit200 ksps ADC
AMUX
AIN0-AIN16
VREF
VDD
CP1 +-
Temp
VDD
CP0 +-
VREF
VREF
P4
Drv
P4.0/D0P4.1/D1P4.2/D2P4.3/D3P4.4/D4P4.5/D5P4.6/D6P4.7/D7
CTL
P2 LatchAddr P3 Latch
P4 LatchData
$
5������������ ��
♦ CP220x single-chip Ethernet controller� Industry’s smallest, highest performance
10Base-T Ethernet controller� 10/100Base-T compatible
♦ Ethernet evaluation kit� The CP2201EK demonstrates the
simplicity of adding Ethernet connectivity to a product
� Demo applications included
♦ Ethernet development kit� Provides everything needed to develop
an embedded Ethernet solution with the CP220x
� CMX TCP/IP stack included free of cost or royalty fees
$(
&'�6$(6 �7�8 ��������� ��
♦ Microcontrollers� Low current consumption� High throughput 8051 CPU (up to
100 MIPS)
♦ Development Kits� 2.4 GHz ISM band operation� IEEE 802.15.4 PHY/MAC evaluation� Helicomm ZigBee protocol stack and
tools
♦ Modules� Silicon Labs/Helicomm co-developed
8051-based modules� Full drop-in wireless solution to ensure
fastest time-to-market
$*
�������#�������)��
♦ Detailed inspection of USB solutions� Demonstration of Mass Storage Reference Design
♦ Review Ethernet development platform� Demonstration of Ethernet evaluation kit
♦ Describe 802.15.4 and ZigBee solutions
♦♦ Let’s get started…Let’s get started…
�������������� ��
$&
������ �
♦ Benefits of USB
Easy to UsePlug & Play
Low PowerConsumption
Low Cost
RS232 Ports Disappearing
Reliable
Fast
$%
����# ���#����
♦ Ease of Use� One interface for many devices� Hot pluggable� Automatic configuration� No power supply required
� Devices can pull up to 500mA from the bus
♦ Reliability� Lossless data transfers
�'
����# ���#����
♦ Speed� Three transfer speeds
� Low Speed – 1.5 Mbps (USB 1.1 and 2.0)� Full Speed – 12 Mbps (USB 1.1 and 2.0)� High Speed – 480 Mbps (USB 2.0 only)� Silicon Labs devices support Low and Full Speed. (USB 2.0 Compliant)
♦ Low Power Consumption� Suspend mode
� Devices consume 500 �A or less
♦ Availability� Microsoft and Intel’s PC 2001 System Design Guide requires that all
new PC’s have two user-accessible USB ports.
�$
)�# � � ��
♦ USB – Universal Serial Bus
♦ Host – System which initiates all transfers over the bus
♦ Device – Peripheral which communicates with and receives information from the host
♦ Hub – Provides connecting points and power
♦ Pipe – Logical abstraction which creates an association between an endpoint on a device and the host software
♦ Endpoint – Memory buffer on a device which serves as a sink or source of data� IN Endpoint – Endpoint from which host reads data� OUT Endpoint – Endpoint to which host writes data
� Endpoints on Silicon Labs MCUs are implemented as FIFO’s in on-chip XRAM
��
������������
��
)�# � � ��
� Transfer – The process of making and carrying out a communication request
� Transaction – The delivery of service to an endpoint� Packet – Block of information� Frame – A 1 ms time base established on low- and full-speed buses
♦ Transfers are divided into transactions. ♦ Transactions are made up of packets. ♦ The host controls transfers by allocating transactions to a
frame.♦ Transfers may span multiple frames.
�
����2��� ��) �����
�(
)�# � � ��
♦ Enumeration� Enumeration is the activity that identifies and assigns unique
addresses to devices attached to a bus� Makes USB devices hot-pluggable
� The host is always checking the bus for new devices� The host cannot communicate with a USB device until that device
has been properly enumerated� Invisible to user
�*
����+��������0 2��� ����#�������1��
♦ Enumerate Devices
♦ Transfer Data with Peripherals
♦ Provide Power� A full-power USB Host can provide up to 500 mA for each peripheral� Some low-power USB hosts support only low-power devices which
are limited to 100 mA� USB peripherals can be self-powered as well
♦ Manage the USB Bus
�,
����+��������0 2��� ����#�������+�� ������
♦ Transfer Data with the USB Host
♦ Manage power� The supply current that can be drawn from the bus depends on the
state of the bus� A bus-powered device in normal mode may draw up to 500 mA� When the bus is suspended, the device must draw less than 500 uA� If the device supports remote wakeup, it may draw up to 2.5 mA
when in suspend mode
♦ Respond to Standard Requests from the Host
�&
����+��������9 5���� ���7 �+ ��
♦ All data is transferred to or from a device endpoint
♦ An Endpoint is memory on the USB peripheral that stores the data it receives from the host or it stores the data it intends to send
♦ Endpoints transfer data in one direction and labeled either IN or OUT, except for control endpoints which are bidirectional
♦ A Pipe is a logical connection between an endpoint on the device and the host controller’s software
�%
����#�������
♦ Four types of transfers:�Control Transfers�Bulk Transfers� Interrupt Transfers� Isochronous Transfers
�'
����#�������
♦ Control Transfers�Two uses:
� Carry mandatory requests which enable the host to recognize and enumerate devices
� Carry user-defined requests for any other purpose
�Mandatory: Every device must support control transfers�Top Speeds:
� Full Speed – 832 Kbytes/sec
�$
����#�������
♦ Bulk Transfers�Fastest transfer type�No guaranteed data rate or latency�Supported only by High and Full
Speed devices�Top Speeds:
� Full Speed – 1.2 Mbytes/sec
�Common Applications:� Printers� Scanners� Disk Drives (USB thumb drive)
��
����#�������
♦ Interrupt Transfers�Guaranteed latency�Top Speeds:
� Full Speed – 64 Kbytes/sec
�Common Applications:� Keyboards� Mice� Joysticks
��
����#�������
♦ Isochronous Transfers�Streaming real-time transfers
� Guaranteed delivery rate and latency
� No error correction – Not lossless!
�Supported only by High and Full Speed devices
�Top Speeds:� Full Speed - 1.0 Mbytes/sec
�Common Applications:� Music� Video
�
����)�� �������
♦ USB defines a set of standard device classes to enable interoperability across multiple platforms
� HID – Human Interface Device� Keyboards, mice, controls, thermometers, voltmeters
� Mass Storage� Removable and non-removable storage: floppy, hard, optical, and Flash drives
� Audio� Speaker, microphone, audio processor
� Communications Device Class� Analog and digital modems, analog and digital telephones, ADSL and cable
modems, ethernet adapters and hubs
� IrDA, Power, Printer, Smartcard, Imaging, etc.
�(
)�� �������� # ��
♦ The Host machine distinguishes between devices by looking at their unique identifiers� VID – Vendor ID
� Assigned by the USB Implementer’s Forum� PID – Product ID
� Assigned by the vendor� Serial Number
� Assigned by the developer/manufacturer� Unique for every USB device
♦ Silicon Labs Allotment System� Silicon Labs has a unique VID (0x10C4)� All in-house items are assigned a PID under our VID� Customers may receive PID’s under our VID for bridge and MCU products� Contact [email protected] to receive a PID
�*
����+������"��� :�� ���2����
Silicon Labs Silicon Labs h/w, s/w, h/w, s/w,
drivers, and drivers, and examplesexamples
Application requirements
CertificationCertification
ProductionProduction
Device Class
Bandw
idth Driv
ers
Custom
RequirementsRequirements
�,
�������� �����.��
Longest development time -- requires custom firmware and driver development
Optimized for applicationUse existing Control, Interrupt, and Bulk firmware and driver examples as starting point
Does not fit existing class
No host driver installUse USB Audio application note and example code
App fits Audio class definition
Limited to 64 K bytes/sec max data rate
No host driver installUse HID application note and example code
App fits HID class definition
Requires ~11 kB code space
No host driver install –intuitive “drag-and-drop” interface
Use MSD reference design
App fits MSD class definition
Requires host driver installation
2nd Shortest time to market -- Easy to use high-speed data pipe (up to 1 M bytes/sec)
Use USBXpress®Don’t have time to master USB – need high bandwidth
Requires host driver installation
Shortest time to market -- No change to host application or firmware
Use fixed-function USB/UART bridge device (CP210x) + VCP driver
Legacy RS-232 upgrade
Potential DownsideBenefitsUSB OptionCondition
�&
���� # ��� ���������� �� �������� ��
♦ USB Implementer’s Forum (USB-IF)� www.usb.org� Assigns Vendor IDs (VIDs)� Oversees Compliance Testing
� USB products must pass compliance testing in order to display the USB logo and to be listed on the USB-IF Integrators List
� Contact [email protected] for help with compliance testing
�%
��������+������-�������
QFN28 (5X5) LQFP32 (9X9) TQFP48 (9X9)EMIF, 2 UARTs
64K, 5376 bytes RAM
Mixed-Signal USB
MCU
48
25
MIPS
32K, 3328 bytes RAM
Mixed-Signal USB
MCU
48
25
MIPS
16K, 1536 bytes RAM
Mixed-Signal USB
MCU MIPS
16K, 1536 bytes RAM
USB
MCU
Internal OSC, VREG,
EEPROM
USB-Serial Interface
Yes
No
Host I/O
25
MIPS
25
CP2101
CP2102 CP2103
F340-GQ
F341-GQ
F342-GQ
F343-GQ
F344-GQ
F345-GQ
F346-GQ
F347-GQ
F321-GM
F326-GM
F327-GM
F320-GQ
��������
� �� ��� � ��
��������
� �� ��� � ��
��������
� �� ��� � ��
��������
� �� ��� � ��♦ Pin-for-pin compatibility for
effortless migration� 16 to 64kB� 25 to 48 MIPS� Price sensitive to high
performance
♦ Highly integrated solutions in small form factors
♦ Larger packages include external memory interface for additional expansion
Product Offerings and Packages
'
� ���+����#��� /��0� ������������
♦ High-speed 8051 core operating up to 48 MIPS
♦ 64 kB on-board Flash and 5376 bytes of RAM
♦ 17 ch. 10-bit, 200 ksps ADC♦ External memory interface♦ In-system non-intrusive debug
engine eliminates the need for emulators
♦ Integrated on-chip regulator♦ Effective operating range from
2.7 to 5.25 V
C8051F340C8051F340--GQGQ
UART1
64 kB FLASH
256 Byte SRAM
POR
SFR Bus
8051
Core
ResetRST/C2CK
External Oscillator
Circuit
Debug HW
Brown-Out
P0
Drv
4 kB XRAM
XTAL1 XTAL2
P0.0P0.1P0.2/XTAL1P0.3/XTAL2P0.4P0.5P0.6/CNVSTRP0.7/VREF
SPI
REGIN
CROSSBAR
P1
Drv
P1.0P1.1P1.2P1.3P1.4P1.5/ALEP1.6/RDP1.7/WR
Port 0 Latch
SMBus
Timer 0,1,2,3 /
RTC
UART0
System Clock
P2
Drv
P3
Drv
P2.0/A0P2.1/A1P2.2/A2P2.3/A3P2.4/A4P2.5/A5P2.6/A6P2.7/A7
C2D
P1 Latch
PCA/WDT
USBController
USBTransceiver
Analog/Digital Power
VoltageRegulator
5.0V
1 kB USB SRAM
VBUS
D+
D-
12 MHzInternal
Oscillator
GND
VDD
IN
OUT
Enable
x4 ÷ 2
USB Clock÷ 2
÷ 1,2,3,4Clock
Recovery
P3.0/A8/C2DP3.1/A9P3.2/A10P3.3/A11P3.4/A12P3.5/A13P3.6/A14P3.7/A15
External DataMemory Bus
10-bit200 ksps ADC
AMUX
AIN0-AIN16
VREF
VDD
CP1 +-
Temp
VDD
CP0 +-
VREF
VREF
P4
Drv
P4.0/D0P4.1/D1P4.2/D2P4.3/D3P4.4/D4P4.5/D5P4.6/D6P4.7/D7
CTL
P2 LatchAddr P3 Latch
P4 LatchData
$
����)������� �������� ��
♦ Evaluation kits for USB/UART Bridge Devices� CP2102EK, CP2103EK� VCP Driver CD included
♦ Full development kits for Flash-based USB MCUs� C8051F320DK
C8051F326DK C8051F340DK
� Integrated IDE, assembler, compiler, linker, debugger
� On-chip debug hardware (breakpoints, watchpoints, single-step)
CP2103 Evaluation Board
USB MCU Development Kit
�
��#������������
♦ Silicon Labs USB support software is broad-based, from easiest to use to greatest flexibility and highest performance
USBXpress®
Support Software
VCPDrivers
Software Examples
3rd Party Tools
No Firmware Required
Firmware Library
Windows DLL
Boot Loader Example
Drivers and FirmwareBulk Interrupt
HID Audio / Isochronous
HIDBoot LoaderMSD
File Transfer Example
�
�������������� ��
+ =
5
15
Products
CP2101CP2102CP2103
C8051F320C8051F321
C8051F326C8051F327
C8051F340C8051F341C8051F342C8051F343C8051F344C8051F345C8051F346C8051F347
F340-DK
F326-DK
F320-DK
CP2103-EK
CP2102-EK
Support Hardware
USB FM Tuner(‘F321+Si4701)
Innovative Applications
Human Interface Device (HID) Best Practices Application Note
Mass Storage Device (MSD) Best Practices w / Data Logger
Example
+ USBXpress®
Support Software
VCPDrivers
Software Examples
3rd Party Tools
No Firmware Required
Firmware Library
Windows DLL
Boot Loader Example
Drivers and FirmwareBulk Interrupt
HID Audio / Isochronous
HIDBoot LoaderMSD
File Transfer Example
����2� �"�� ��"�#�������)� ��
Accelerating Embedded Radio Applications
(
1�� � ��; ��!<����� ��
Buffered 32.768 kHz
(MCU)
C8051F321
Low Cost Watch Crystal
������������ ������� �������������� ������� ��
���� ����������������������� �������������������
����� ������������������ �������������
������ ���! ������������! ���������
"����!������� ��� �"����!������� ��� �
���#$"% �&�����#$"% �&��
*
������#���������2� �"�� �
����������� �� ����� �� �� �� � ���� �� �� � ���� � � ��� �� � ���� �� �� � ���� � � ��� ��
� ��� �� �� �� �� ���� �� �� � �� ���� �� � � � ��� ��� �� �� �� �� ���� �� �� � �� ���� �� � � � ��
� ��� ��� �� ���� � ��� � �� � ���� ��� ��� �� ���� � ��� � �� � ���
� �� ��� ��� �� ��� ��� �� �� ��� ��� �� ��� ��� �� �� �� �� ����� ��� �� �� �� ����� ��
� ����� �� � �� ���� �� � �� �� ����� �� � �� ���� �� � �� �
� ��� �� �� ���� � � ��� � �� ��� �� �� ���� � � ��� � �
! " � �� � � �� # ������! " � �� � � �� # ������
,
���0���� ���������
♦♦ USB FM Radio HardwareUSB FM Radio Hardware
♦♦ User’s GuideUser’s Guide: Explains easy set-up to use radio
♦♦ AN264AN264: Provides systems overview, interface specifications, USB device classes, firmware overview
♦ AN283: Provides in-depth tutorial on USB Audio class implementation
♦♦ AN264SWAN264SW: “Unzips” to provide all design documentation in native formats
♦♦ Radio PlayerRadio Player: Launch executable file directly from your PC (no installation required)
&
2���� ������#��� �� ��
www.silabs.com/usbradiowww.silabs.com/usbradio
Complete technical Complete technical information including: information including: user’s guide, applications user’s guide, applications note, Gerber files, note, Gerber files, schematics, BOM, schematics, BOM, firmware source, and firmware source, and Radio Player sourceRadio Player source
���������������- .����
('
5/�� ����)����-��� ��������
♦ Fleet shipping container monitoring system
� Record temperature once per second (8 bits per sample)
� Record time and magnitude of disturbances (load shifts, dropped packages, etc.) using an accelerometer (16 bits per sample)
� Data logging for 3 months requires a lot of storage space:� 3600 secs/hr * 24 hrs/day * 30 days/month * 3 months * 3 bytes per
sample = over 21 million bytes
($
� ����������1������������!�) �����
(�
� ����������2 �� ���������!�) �����
(�
)�� ������ ���9 ���� ��� ��������#���
1. Connect RS-232 cable between PC and Demo Board2. Connect DC Power Adapter to Demo Board3. Set up HyperTerminal to use COM port at 115200 Baud, 8
Data bits, No Parity, 1 Stop Bit, No flow control, and “Append line feeds to incoming line ends”
(
)�� ������ ���9 ���� ��� ��������#���
4. Use the Command Interpreter shell presented by the device in HyperTerminal to log temperature data to a file:
a) Type “calibrate 25” to calibrate the device to room temp (25 C)
b) Type “templog temp.txt” to initiate a temperature data log
c) Wait a few seconds to collect some temperature data
d) Type “templog” to stop logging temperature data
e) Type “type temp.txt” to view the stored file
((
)�� ������ ���9 ���� ��� ��������#���
5. Use the Command Interpreter shell presented by the device in HyperTerminal to log button press/release events to a file:
a) Type “log button.txt” to begin logging button events
b) Press buttons “P2.0” and “P2.1”repeatedly
c) Type “log” again to end button event logging
d) Type “type button.txt” to view the stored file
(*
)�� ������ ���9 ���� ��� ��������#���
♦ In addition to the commands used in the previous walk-through, the demo application implements the following commands:� cls: Clear Screen� del <filename>: Delete a file� dir: List directory contents� chkdsk: Print media size information� s <#####>: Print raw sector information
(,
)�� ������ ���9 ���������#���
1. Connect a USB cable to the PC and the USB connector on the Demo Board.
2. The OS should recognize the new hardware, and display it as a new USB Mass Storage Device on the system.
(&
)�� ������ ���9 ���������#���
3. Open Windows Explorer (Right-click Start, and then click Explore).
4. Find the new drive in the list of folders.5. View the contents of the drive and
open the saved text files in a text editor.
(%
)�� ������ ���9 ���������#���
7. Files can also be copied to/from the drive, deleted, and modified from within the OS.8. To disconnect the drive, click on the icon in the system tray, and select “Safely Remove
USB Mass Storage Device”
*'
)�� �����������������
Available Free Space (45.1kB)
72%
Used Space(17.9 kB)28%
File System / Sector Server (4.5kB)7%
Example Application (4.0kB)6%USB / MSD / SCSI (3.8kB)6%
Compiler Library Calls / Misc (3.1kB)5%
CompactFlash Media Access (0.7kB)1%
SD / MMC Media Access (1.8kB)3%
*$
����� ����)��� ��00 ���������#���
♦ Mass Storage Device (MSD) Class Implementation� Uses native OS drivers – no special driver is necessary
� Works on all Windows, MAC, and Linux platforms that support MSD
� Device appears to PC as a removable storage device
♦ SCSI Command Set� Specified by the USB Mass Storage Device Class specification
*�
����� ����)��� ��00 � �� ������
♦ Sector Server handles file system management� FAT16 File Structure� Supports up to 4 GB storage
♦ SD / MMC Interface� Communicates via hardware SPI bus� Accessed as 512-byte sectors to reduce RAM requirements and
increase speed
♦ Compact Flash Interface Also Supported
*�
���� ���2 �������� �2��� �2 �� ����
♦ Uses ANSI ‘C’ “Stream I/O” interface to access media file system
♦ File Access Functions:� fopen(): Open a file for access� fclose(): Close an open file� fwrite(): Write information into an open file� fread(): Read information from an open file� feof(): Look for End-of-File Indicator
♦ File System Maintenance Functions:� findfirst(): Returns first available file name� findnext(): Returns next available file name� fdelete(): Delete a file
*
5/�� ����=1����6�/�>
♦ The following code excerpt creates a file called “hello.txt” and stores it to the MMC/SD card� FILE *fp;
� unsigned char error;� unsigned char mystr[] = “Hello world!”;
� error = fopen (&fp, “hello.txt”, “w”);
� fwrite (fp, mystr, sizeof (mystr));
� fclose (&fp);
♦ It is very easy to add MSD functionality to your own system!
(Next module)(Next module)
5��������������+?�+�������� � ��
**
����� ��
♦ OSI Model
♦ TCP/IP Protocol Family
♦ Embedded EthernetDevelopment Kit
♦ AB4 Ethernet Development Board
♦ TCP/IP Configuration Wizard
♦ Demo
*,
����� ����
♦ Open Systems Interconnection Model
♦ Layered abstract description for communications and computer network protocol design.
♦ Divided into layers� Each layer can use functions only from the layer below.� Each layer can export functionality only to the layer above.� Layers can be implemented in hardware, software, or a mixture of
both.� Generally, the lower levels are implemented in hardware and the
upper layers in software.
*&
����� ����
ApplicationNetwork Process to Application
PresentationData Representation
SessionInterhost Communication
PhysicalMedia, Signal, and Binary Transmission
Data LinkMAC and LLC (Physical Addresing)
NetworkPath Determination and IP (Logical Addressing )
TransportEnd-to-End Connections and Reliablity
Data
Data
Data
Bits
Frames
Packets
Segments
*%
����� ������� ���� ����� ��
Hardware (Ethernet, Modem, etc.)
Hardware Device Drivers
IP
TCP UDP
HTTP FTP SMTP TFTP BOOTP DHCP
Physical
Data Link
Network
Transport
Application
,'
��+?�+�+��������
♦ TCP/IP is a set of standard communication protocols which fit within the OSI model.
♦ Benefits of TCP/IP:� Interoperability – The protocols operate at a layer of abstraction above the hardware
layer.� Ubiquity – Nearly all network devices implement standard TCP/IP protocols.� Ease of Development – Code implementations are already written and can be
reused.� Reliability – Protocols have been proven by over 20 years of widespread use.
♦ Silicon Laboratories provides a library providing TCP/IP functionality in the Embedded Ethernet Development Kit.
,$
��+?�+�+�������
♦ Network Layer
� IP (Internet Protocol) – Manages logical addressing of network devices (i.e. IP addressing).
� ARP (Address Resolution Protocol) – Converts an IP address (logical address) to a MAC address (physical address).
� PING – Program which sends a packet to a network device and waits for a response. Returns the round trip time of the request.
NetworkPath Determination and IP (Logical Addressing )
,�
��+?�+�+�������
♦ Transport Layer
� UDP (User Datagram Protocol)� Advantages
• Fast• Requires less protocol overhead• Implementations consume less code space
� Disadvantages• Connectionless• Unreliable• Best Effort (Data may arrive of order and packets may be lost!)
TransportEnd-to-End Connections and Reliablity
,�
��+?�+�+�������
♦ Transport Layer (cont’d)
� TCP (Transmission Control Protocol)
� Advantages• Connection-oriented• Reliable• Data Stream (data arrives in order)
� Disadvantages• Slower• Requires more protocol overhead• Implementations consume more code space
TransportEnd-to-End Connections and Reliablity
,
��+?�+�+�������
♦ Application Protocols
� HTTP (HyperText Transfer Protocol) – Transfers HTML files across the World Wide Web.
� FTP (File Transfer Protocol) – Exchanges files over a network.
� SMTP (Simple Mail Transfer Protocol) – Sends email.
� TFTP (Trivial File Transfer Protocol) – A simpler but unreliable version of FTP.
ApplicationNetwork Process to Application
,(
��+?�+�+�������
♦ Application Protocols (cont’d)
� BOOTP (Boot Protocol) – Assigns a static IP address to a network device.
� DHCP (Dynamic Host Configuration Protocol) – Assigns a dynamic IP address to a network device.
ApplicationNetwork Process to Application
,*
��+?�+�+��������)�������� �
Hardware (Ethernet, Modem, etc.)
Hardware Device Drivers
IP
TCP UDP
HTTP FTP SMTP TFTP BOOTP DHCP
Physical
Data Link
Network
Transport
Application
,,
������� ����+��'/�5������������������
♦ Industry’s smallest, low power Ethernet controller� 5 x 5 mm package reduces board
space up to 95% compared to competing devices
♦ Highest performance 10Base-T Ethernet controller� 10/100Base-T compatible� Implements a high-performance
parallel external memory interface
♦ Embedded Ethernet made easy with the CP220x� CP220x Development Kit simplifies
design process
,&
� � �� #� ���5� .������5�������<�+��'/
♦ Parallel host interface with up to a 30 Mbps transfer rate� Reduces the amount of time the MCU spends communicating with the Ethernet controller
♦ 8 kB of on-chip Flash memory factory pre-programmed with a unique 48-bit MAC address� Eliminates the necessary serialization step from the product manufacturing process� Can be used for non-volatile storage requirements and offload host MCU
♦ Low power consumption (70 mA typ) suitable for high-density applications where self-heating is a key concern
♦ Supports auto-negotiation (for maximum bandwidth utilization)♦ Extended temperature range (-40 to +85 °C operation)
,%
�+��'/�@���2�����
♦ Auto-Negotiation Support
10 Base-T Half Duplex
10 Base-T Full Duplex
100 Base-T Half Duplex
100 Base-T Full Duplex
10 Base-T Half Duplex
10 Base-T Full Duplex
♦ Low Operating Current: 75mA @ 3.3V, 150mA peak (typ)� Average current depends on packet size and data rate.� Typical average current ranges from 60 to 90 mA.
♦ Extended Temperature Range: -40 to +85°C
&'
5��������)������� ����@ �
♦ Provides all of the hardware and software necessary to develop an embedded Ethernet solution using the CP220x
♦ The CMX Micronet TCP/IP protocol stack is included in an easy-to-use library format.
♦ A TCP/IP configuration wizard is provided to generate a highly customized library optimized for user-selected protocols
♦ Kit Contents� CP2200-based Ethernet Development Board� C8051F120 Target Board� Universal Power Supply� USB Debug Adapter� 1 m Cat5e Cable, USB Cable, Serial Cable� CD containing:
� Silicon Labs IDE� TCP/IP configuration wizard� Evaluation version of the Keil C51 Tool Chain� Source code examples and register definition
files� Documentation
Part #: EthernetDK
The Ethernet Development Kit is available for $119 at
www.silabs.com/ethernet.
&$
�� �5��������)������� ���������
♦ CP2200 and RJ-45connector provide Ethernet connectivity.
♦ 96-pin connector interfaces to ‘F120,‘F020, and ‘F340Target Boards.
♦ Prototyping area,switches, and LED’sfacilitate development.
&�
��+?�+����# ���� ���; :���
♦ Included in the Ethernet Development Kit� Generates a highly customized library
optimized for user-selected protocols� Generates both the framework code and
a project file that can be managed within the Silicon Labs IDE
♦ Host processor Flash memory requirements for Ethernet implementations range from 16.2 kB to 49.5 kB� These are minimum memory requirement
and do not include additional user code� 16.2 kB implementation includes ARP,
PING, UDP, & IP protocols� 49.5 kB implementation includes DHCP,
HTTP, FTP, TFTP, ARP, PING, TCP, UDP, & IP protocols
5� .������5��������)�� �
&
�+��'$�5����� ���@ ���������
♦ CP2201EB Evaluation Board♦ Universal 9V Power Supply♦ Standard Ethernet Cable (Blue)♦ Crossover Ethernet Cable (Yellow)♦ Evaluation Kit CD♦ Quick Start Guide
&(
�+��'$�5����� ��������
♦ Demonstrates Small Size – Entire board is 1.25” x 1.50”.♦ Uses the C8051F340 and the CP2201.♦ Demonstrates Embedded Ethernet Connectivity.
&*
�+��'$�5����� ���@ ��)�� �
♦ Automatic Network Configuration using Netfinder♦ Remote Monitoring and Control from a Web Browser♦ Remote Monitoring and Control from HyperTerminal♦ Sending E-mail from the Embedded System♦ Updating Firmware over the Network
&,
����� ��
♦ This demonstration will implement a simple “Hello World” web server using the AB4 Ethernet Development Board and C8051F340 Target Board.
♦ The steps of the demonstration are:1. Hardware Setup2. Network Configuration3. Software Generation
&&
1������������
1. Connect the C8051F120 Target Board to the AB4 using their 96-pin connectors.
2. Connect an Ethernet cable to the RJ-45 connector on the AB4 and to a network jack (hub, switch, NIC, router, etc.).
3. Connect the 10-pin ribbon cable of the USB Debug Adapter to J4 on the ‘F120 Target Board.
4. Connect the USB cable to the USB Debug Adapter and to the PC.5. Plug the power supply into P1 on the ‘F120 Target Board.
USB
JTAG
Ethernet
&%
3�����!����# ���� ��
♦ To determine a valid IP address for the Embedded Web Server:1. Launch the TCP/IP Configuration Wizard.2. Select the IP Addresses field under System Settings.3. Go to Start ���� Run then type cmd /K ipconfig.4. Enter IP Address + 1 and Subnet Mask into the Source IP Address and
Subnet Mask IP Address fields.
Note: 169.254.236.193 + 1 = 169.254.236.194
%'
���# ���������� ���+������
♦ My Network Places� Right Click “Properties”
♦ Network and Dialup Connections� Right Click “Local Area Connection”� Select “Properties”
♦ Select Internet Protocol (TCP/IP)� Click Properties� Use the Following IP Address radio button� Assign 10.10.10.80� Click OK (click OK on warning to use default subnet mask)
♦ Click OK…..PC IP address is now 10.10.10.80
%$
��#������A������ ��
1) Select the following checkboxes:a) CP220xb) C8051F34xc) Ethernetd) TCPe) HTTPf) Click IP Addressesg) Assign source IP address as
10.10.10.168
%�
��#������A������ ��
2) Generate Project Files:a) Select “File ->Generate Project.”b) Browse to destination folder.c) Press OK.
3) Open the output project (TCPIP_Project.wsp) in the Silicon Laboratories IDE.
4) Build the project and download to the C8051F340 target board.
%�
��#������A������ ��
5) Press “Go.” After a few seconds, the link LED on the connector will turn on.
6) Launch a web browser and enter the IP address configured during Network Configuration.
7) The web browser will display the “Hello World” HTML document.
�555�&'�6$(6 �7�8 ����B
Comprehensive Solutions with ZigBee
%(
����8 �����"���� �������555�&'�6$(6
�������� �������� ���� ������
� ��
�������������� ������������ !���
��"��#�$% ��� �� � &#���'"�$(�#�'
�((�#"��#�'
��)
*#+,�����#�'"�
)---��. �����
�����/��
�#�#"�' � ���
�((*#+,������"�
♦ Low power operation → longer battery life♦ Flexible & dynamic network topologies
� Star, Cluster-Tree & Mesh ♦ Security & reliability
A B
A
♦ Limited to point-to-point or point-to-multipoint (star) configurations
♦ Longer distance → more power →shorter battery life
B
A B
%*
����"�����8 ����� ��� �������
Star orPoint-to-Point
802.15.4 or ZigBee
ZigBee Only
Coordinator (FFD)Routing Node (FFD)End Node (RFD)
Range
Cluster-Tree
Mesh
%,
&'�6$(6 ?8 �����2��4��� ��7�)����"���
2.4 GHz
915 MHz
868 MHz
ISM
ISM
ISM
Worldwide
Europe
Americas
250 kbps
20 kbps
40 kbps
16
1
10
BAND COVERAGE DATA RATE # OF CHANNEL(S)
*Current market offerings support either the 2.4 GHz or the 868/915 MHz ISM bands.
%&
������"������#����� ��
Development Kits♦ 2.4 GHz ISM band operation♦ Helicomm ZigBee protocol
stack and tools♦ IEEE 802.15.4 PHY/MAC
evaluation♦ USB interface♦ 100 MIPs 8051 core♦ 128 kB Flash/8 kB RAM♦ JTAG connection for in-circuit
debug♦ Power supply or 9 V battery
operation
Modules♦ Silicon Labs/Helicomm
co-developed 8051-based modules
♦ Full drop-in wireless solution to ensure the fastest time-to-market.
♦ Chip antenna or connector options available
MCUs♦ Low current consumption♦ High throughput 8051
CPU (up to 100 MIPS)♦ Up to 128 kB Flash/8 kB
RAM♦ Highest performance
integrated analog: up to 24-bit ADCs; up to 1 Msps ADCs
♦ Small footprint (3x3 mm)
%%
5��0��0���A�������)������� ��������
Silicon Laboratories IDE♦ Windows-based IDE
� Full-featured editor� Full macro-assembler with evaluation C-compiler� Full debugger support� Support for 3rd party tools
♦ Configuration Wizard� Automatically generate configuration code� Full peripheral support for C8051 families� Generates both C and assembly
ZigBee Demonstration GUI
♦ Graphical representation of various ZigBee topologies
♦ 13 different topology examples included
♦ Interactive GUI supports 3 demo applications which can monitor data from any networked devices� Temperature� Received Signal Strength
Indicator (RSSI)� Thumbwheel (analog)
802.15.4 Demonstration GUI♦ Graphical representation of
the association and disassociation of a star network
♦ GUI can support additional boards to create a larger star network
♦ Interactive GUI allows the user to:� Monitor the temperature
and thumbwheel operation of each development board
� Control the update rate and LED state of each development board
$'
'
��� ������ ������� ���#���8 �����7�&'�6$(6
♦ Hardware platforms� Microcontrollers� Development kits/reference designs� Drop-in modules
♦ Firmware & Software� IEEE 802.15.4 MAC� Full ZigBee protocol stack� 802.15.4 demonstration GUI � ZigBee demonstration GUI
♦ Development Tools� Silicon Labs Integrated Development Environment
���6 ��.6���