Digital Circuits Part 2 - Communication

Similar documents
The I2C Bus. NXP Semiconductors: UM10204 I2C-bus specification and user manual HAW - Arduino 1

Elettronica dei Sistemi Digitali Costantino Giaconia SERIAL I/O COMMON PROTOCOLS

User s Manual of Board Microcontroller ET-MEGA2560-ADK ET-MEGA2560-ADK

Using Xbee in Serial Communication

AND8336. Design Examples of On Board Dual Supply Voltage Logic Translators. Prepared by: Jim Lepkowski ON Semiconductor.

UM I 2 C-bus specification and user manual. Document information

HARDWARE MANUAL. BrightSign HD120, HD220, HD1020. BrightSign, LLC Lark Ave., Suite 200 Los Gatos, CA

SPI I2C LIN Ethernet. u Today: Wired embedded networks. u Next lecture: CAN bus u Then: wireless embedded network

Introduction the Serial Communications Huang Sections 9.2, 10.2 SCI Block User Guide SPI Block User Guide

Chapter 13. PIC Family Microcontroller

A DIY Hardware Packet Sniffer

2.0 Command and Data Handling Subsystem

Raspberry Pi. Hans- Petter Halvorsen, M.Sc.

Note monitors controlled by analog signals CRT monitors are controlled by analog voltage. i. e. the level of analog signal delivered through the

Figure 1.Block diagram of inventory management system using Proximity sensors.

Application Note 83 Fundamentals of RS 232 Serial Communications

The I 2 C-bus and how to use it (including specifications)

Data Acquisition Module with I2C interface «I2C-FLEXEL» User s Guide

Serial Communications

THE I 2 C-BUS SPECIFICATION VERSION 2.1 JANUARY document order number:

Adding WiFi to Your Embedded System. WPG Americas & Gainspan Titus Wandinger (WPG) & Su Li (Gainspan) April 23, 2013

POCKET SCOPE 2. The idea 2. Design criteria 3

Real-time Operating Systems Lecture 27.1

RS-422/485 Multiport Serial PCI Card. RS-422/485 Multiport Serial PCI Card Installation Guide

Embedded Systems on ARM Cortex-M3 (4weeks/45hrs)

USB2.0 <=> I2C V4.4. Konverter Kabel und Box mit Galvanischetrennung

Arduino Due Back. Warning: Unlike other Arduino boards, the Arduino Due board runs at 3.3V. The maximum. Overview

8051 MICROCONTROLLER COURSE

Serial port interface for microcontroller embedded into integrated power meter

USB / Data-Acquisition Module NOW LEAD-FREE

The Programming Interface

Implementation of Wireless Gateway for Smart Home

Atmel Norway XMEGA Introduction

TTL-232R-3V3 USB to TTL Serial Converter Cable

Arduino ADK Back. For information on using the board with the Android OS, see Google's ADK documentation.

Location-Aware and Safer Cards: Enhancing RFID Security and Privacy

Guangzhou HC Information Technology Co., Ltd. Product Data Sheet

Patient Health Monitoring Using Wireless Body Area Network

Designing VM2 Application Boards

ESP 8266: A BREAKTHROUGH IN WIRELESS SENSOR NETWORKS AND INTERNET OF THINGS

Demystifying Wireless for Real-World Measurement Applications

SBC6245 Single Board Computer

7a. System-on-chip design and prototyping platforms

Chapter 1 Lesson 3 Hardware Elements in the Embedded Systems Chapter-1L03: "Embedded Systems - ", Raj Kamal, Publs.: McGraw-Hill Education

FLYPORT Wi-Fi G

Guangzhou HC Information Technology Co., Ltd. Product Data Sheet

Guangzhou HC Information Technology Co., Ltd. Product Data Sheet

Design and Verification of Nine port Network Router

Open Flow Controller and Switch Datasheet

ARM Cortex -A8 SBC with MIPI CSI Camera and Spartan -6 FPGA SBC1654

PHYS 2P32 Project: MIDI for Arduino/ 8 Note Keyboard

PROGRAMMABLE WIRELESS STAMP (PWS) USER MANUAL

DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING Question Bank Subject Name: EC Microprocessor & Microcontroller Year/Sem : II/IV

HARDWARE MANUAL HD222, HD1022. BrightSign, LLC Lark Ave., Suite B Los Gatos, CA

A+ Guide to Managing and Maintaining Your PC, 7e. Chapter 1 Introducing Hardware

Freescale Semiconductor, Inc. Product Brief Integrated Portable System Processor DragonBall ΤΜ

Design And Implementation Of Bank Locker Security System Based On Fingerprint Sensing Circuit And RFID Reader

Process Control and Automation using Modbus Protocol

Bluetooth Stereo Network

KTA-223 Arduino Compatible Relay Controller

8 Gbps CMOS interface for parallel fiber-optic interconnects

WUA Mbps Wireless USB Network Adapter

Pmod peripheral modules are powered by the host via the interface s power and ground pins.

Web Site: Forums: forums.parallax.com Sales: Technical:

Universal EXTension connector (UEXT)

Part 1. MAX BIT DAC with an Arduino Board. MIDI to Voltage Converter Part1

Memory Basics. SRAM/DRAM Basics

Ways to Use USB in Embedded Systems

Data Sheet. Adaptive Design ltd. Arduino Dual L6470 Stepper Motor Shield V th November L6470 Stepper Motor Shield

1. Memory technology & Hierarchy

Microcontrollers and Sensors. Scott Gilliland - zeroping@gmail

Implementing a Digital Answering Machine with a High-Speed 8-Bit Microcontroller

Design of a Wireless Medical Monitoring System * Chavabathina Lavanya 1 G.Manikumar 2

Internet of things (IOT) applications covering industrial domain. Dev Bhattacharya

VDIP1. Vinculum VNC1L Module. Datasheet

ALL-AIO-2321P ZERO CLIENT

Pre-tested System-on-Chip Design. Accelerates PLD Development

Wireless Microcontrollers for Environment Management, Asset Tracking and Consumer. October 2009

USER GUIDE EDBG. Description

HARDWARE MANUAL. BrightSign XD230, XD1030, XD1230. BrightSign, LLC Lark Ave., Suite B Los Gatos, CA

Manual Serial PCI Cards

Single channel data transceiver module WIZ2-434

Wireless Personal Area Networks (WPANs)

Part Number Description Packages available

DesignWare IP for IoT SoC Designs

RAM & ROM Based Digital Design. ECE 152A Winter 2012

Wireless LAN g USB Adapter

USB - FPGA MODULE (PRELIMINARY)

MFRD52x. Mifare Contactless Smart Card Reader Reference Design. Document information

WISE-4000 Series. WISE IoT Wireless I/O Modules

Networking 101 (Networking Basics) Presentation to UCHUG - 1/03/07 G. Skalka

Discovering Computers Living in a Digital World

Eliminate Risk of Contention and Data Corruption in RS-485 Communications

Chapter 4 System Unit Components. Discovering Computers Your Interactive Guide to the Digital World

Welcome to the tutorial for the MPLAB Starter Kit for dspic DSCs

Intelligent Fleet Management System Using Active RFID

All Programmable Logic. Hans-Joachim Gelke Institute of Embedded Systems. Zürcher Fachhochschule

Develop a Dallas 1-Wire Master Using the Z8F1680 Series of MCUs

Block 3 Size 0 KB 0 KB 16KB 32KB. Start Address N/A N/A F4000H F0000H. Start Address FA000H F8000H F8000H F8000H. Block 2 Size 8KB 16KB 16KB 16KB

ZigBee Technology Overview

Transcription:

Introductory Medical Device Prototyping Digital Circuits Part 2 - Communication, www.tc.umn.edu/~drsteve Department of Biomedical Engineering, University of Minnesota

Topics UART Memory RAM and ROM. Digital/Analog Converters - DAC and ADC. Current Communication protocols: Low speed I 2 C (preferred) and SPI. High speed USB and Ethernet. Wireless networks WLAN Bluetooth

Relevance Arduino WiFi Shield Absolute Orientation Sensor LCD Display Many prototypes you build will be based on microcontrollers, and peripheral devices, including user interfaces, sensors and actuators; that typically communicate with one or more of these protocols. Images courtesy of Adafruit and DIY Mall

Components of a Microcontroller Scherz, P.& S. Monk. Practical Electronics for Inventors, McGraw Hill, New York, NY (2016).

The UART Universal Asynchronous Receiver/Transmitter - A device that converts data from serial to parallel, and from parallel to serial, using shift registers. Historically the bases for the RS232 interface. Has an on-chip bit rate (baud rate) generator to control transmit and receive data rate; and handshake lines. They have an interrupt function to the host microprocessor. There are on-chip FIFO buffers for incoming and outgoing data.

General Description of a Shift Register Serial or parallel incoming data can be retransmitted in either a serial or parallel manner. Remember this concept for later discussion of bit manipulation when programming in C. Lancaster, D. and Berlin, H.M. CMOS Cookbook. H.W. Sams, Indianapolis, IN (1988)

Serial Data Stream Serial in Serial out or Parallel in Lancaster, D. and Berlin, H.M. CMOS Cookbook. H.W. Sams, Indianapolis, IN (1988) Scherz, P.& S. Monk. Practical Electronics for Inventors, McGraw Hill, New York, NY (2016).

Simplified Explanation of a UART Sparkfun, https://learn.sparkfun.com/tutorials/serial-communication/uarts

UART Block Diagram Courtesy of the Exar ST16C550 datasheet

Random Access Memory (RAM) Static RAM (SRAM) Six transistor memory cell that does not need refreshing. Holds its state while power is applied. Dynamic RAM (DRAM) Using only a single transistor and capacitor, it holds its state only momentarily, and must be refreshed regularly. Less expensive, and commonly used for computer memory today. SRAM Cell (6 Transistors) DRAM Cell (1 Transistor and one capacitor) Wikipedia, https://en.wikipedia.org/wiki/random-access_memory

Read Only Memory (ROM) ROM State remains after power is removed. EPROM UV light erasable programmable ROM. EEPROM Electronically erasable programmable ROM. Flash Memory Based on NAND or NOR gates. Can be reprogrammed fewer times. Used in memory cards, USB drives and solid state drives.

Analog to Digital Converters Analog to Digital Converters (ADC) Convert an analog signal such as voltage, into a digital signal. Resolution is the number of discrete values the converter can produce over the range of the analog signal. For example, an 8-bit encoder can decode an analog value to 2 8, or 256 different values. Sampling rate is subject to the Nyquist-Shannon sampling theorem. In simple terms, you must sample minimally at a rate twice that of the frequency in order to reproduce the original analog signal.

Digital to Analog Converters Digital to Analog Converters (DAC) Convert digital data into an analog signal, such as voltage or current. Commonly used to reproduce music from CD to amplifiers, speakers and headphones. The Arduino pins can be configured for ADC and DAC. Dedicated ADC/DAC chips are available from a number of manufacturers.

I 2 C or Inter-Integrated Circuit Only two bus lines are required; a serial data line (SDA) and a serial clock line (SCL). Each device connected to the bus is software addressable by a unique address and simple master/slave relationships exist at all times; masters can operate as master-transmitters or as master-receivers. It is a true multi-master bus including collision detection and arbitration to prevent data corruption if two or more masters simultaneously initiate data transfer. Serial, 8-bit oriented, bidirectional data transfers can be made at up to 100 kbit/s in the Standard-mode, up to 400 kbit/s in the Fast-mode, up to 1 Mbit/s in Fast-mode Plus, or up to 3.4 Mbit/s in the High-speed mode. UM10204 I2C-bus specification and user manual (2014)

I 2 C Features Continued Serial, 8-bit oriented, unidirectional data transfers up to 5 Mbit/s in Ultra Fast-mode On-chip filtering rejects spikes on the bus data line to preserve data integrity. The number of ICs that can be connected to the same bus is limited only by a maximum bus capacitance. More capacitance may be allowed under some conditions. Video 2:46 UM10204 I2C-bus specification and user manual (2014)

Example I 2 C Applications UM10204 I2C-bus specification and user manual (2014)

Example of I 2 C Benefits The 2-wire serial I 2 C-bus minimizes interconnections so ICs have fewer pins and there are not so many PCB tracks; result smaller and less expensive PCBs. The completely integrated I 2 C-bus protocol eliminates the need for address decoders and other glue logic. The multi-master capability of the I 2 C-bus allows rapid testing and alignment of end-user equipment via external connections to an assembly line. The availability of I 2 C-bus compatible ICs in various leadless packages reduces space requirements. UM10204 I2C-bus specification and user manual (2014)

I 2 C Bus UM10204 I2C-bus specification and user manual (2014)

Master Slave Addressing UM10204 I2C-bus specification and user manual (2014)

I 2 C Communication Lines The I 2 C bus drivers are open drain, meaning that they can pull the corresponding signal line low, but cannot drive it high. The result is there can be no bus contention where one device is trying to drive the line high while another tries to pull it low, eliminating the potential for damage to the drivers or excessive power dissipation in the system. Each signal line has a pull-up resistor on it, to restore the signal to high when no device is asserting it low. Sparkfun / https://learn.sparkfun.com/tutorials/i2c

SDA and SCL are Bidirectional Lines UM10204 I2C-bus specification and user manual (2014)

Data Valid and Start/Stop Conditions UM10204 I2C-bus specification and user manual (2014)

Data Transfer on the I 2 C Line UM10204 I2C-bus specification and user manual (2014)

I 2 C Communication Lines Sparkfun / https://learn.sparkfun.com/tutorials/i2c

I 2 C and Arduino SDA SCL

SPI Serial Peripheral Interface A Motorola protocol implemented on 4 signal lines: A clock signal named SCLK, sent from the bus master to all slaves; all the SPI signals are synchronous to this clock signal; A slave select signal for each slave, SSn, used to select the slave the master communicates with; A data line from the master to the slaves, named MOSI (Master Out-Slave In) A data line from the slaves to the master, named MISO (Master In-Slave Out). Byte Paradigm, http://www.byteparadigm.com/applications/introduction-to-i2c-and-spi-protocols/

Master-Slave Transfer Diagram Motorola SPI Block Guide V03.06/ (2003)

SPI Signals Sparkfun / https://learn.sparkfun.com/tutorials/i2c

USB Universal Serial Bus Standardized interface to computer peripherals. Has largely replaced RS232 and parallel ports. Standard, mini and micro sizes. Downstream facing devices supply power.

USB Speeds Wikipedia, USB

USB Hubs in a Desktop Environment Universal Serial Bus Specifications, Revision 2 (2000)

USB A and B Connectors Universal Serial Bus Specifications, Revision 2 (2000)

USB Cable Universal Serial Bus Specifications, Revision 2 (2000)

Packet Voltage Levels Universal Serial Bus Specifications, Revision 2 (2000)

USB Transceiver Circuit Example Universal Serial Bus Specifications, Revision 2 (2000)

USB Implementation Areas Universal Serial Bus Specifications, Revision 2 (2000)

FTDI Chips and Software Future Technology Devices International, Ltd. (FTDI) They specialize in USB connectivity and display interfaces. Their software drivers are commonly used with USB peripheral devices. They have a number of USB based converter cables - e.g. for USB-TTL, USB-RS232, USB- RS422, USB-RS484 and others. Future Technology Devices International, Ltd.

Adding FTDI to Arduino This is a USB to TTL serial cable, with a FTDI FT232RL USB/serial chip embedded in the head. It has a 6-pin socket at the end with 5V power and ground, as well as RX, TX, RTS and CTS at 3V logic level Adafruit, https://www.adafruit.com/products/70

Ethernet Networking method for home, business and communities. Speed ups to 100 Gbit/s; with 400 Gbit/s coming. Data streams are divided into frames. Each frame contains source and destination addresses and error checking. Communication via twisted pair copper wire, fiber optics or wireless.

Adding Ethernet to Arduino Although available, Arduino is no longer supporting this Ver. 3 board. Consider instead a wireless interface discussed next. Arduino

Wireless Network Wireless data connection between nodes, using radio frequencies. Includes internet, cell phones, sensor networks, stellite and terrestrial communication. WLAN (wireless local area network) links two or more devices over a short distance usually through an internet access. Wi-Fi. Bluetooth is a licensed spread spectrum based communication protocol for short range.

Adding Wi-Fi to Arduino Arduino Wi-Fi Shield 101 connects the Arduino to the internet. Open source documentation, software and even board files. Operating voltage both 3.3V and 5V (supplied from the host board) Connection via: IEEE 802.11 b/g/n for up to 72 Mbps networks Encryption types: WEP and WPA2 Personal Support TLS 1.1 (SHA256) Connection with Arduino on SPI port Onboard Crypto Authentication by ATMEL Arduino, https://www.arduino.cc/en/main/arduinowifishield101

Bluetooth Bluetooth operates at frequencies between 2402 and 2480 MHz, or 2400 and 2483.5 MHz including guard bands 2 MHz wide at the bottom end and 3.5 MHz wide at the top. Uses the Industrial, Scientific and Medical (ISM) 2.4 GHz shortrange radio frequency band. Bluetooth uses a radio technology called frequency-hopping spread spectrum. Bluetooth divides transmitted data into packets, and transmits each packet on one of 79 designated Bluetooth channels. Each channel has a bandwidth of 1 MHz It usually performs 800 hops per second, with Adaptive Frequency- Hopping (AFH) enabled. Bluetooth low energy uses 2 MHz spacing, which accommodates 40 channels.

Adding Bluetooth to Arduino The Bluefruit EZ-Link - Bluetooth Serial Link & Arduino Programmer - v1.3 The Bluefruit LE UART Friend adds Bluetooth Low Energy connectivity Adafruit, https://www.adafruit.com/products/1588 https://learn.adafruit.com/introducing-the-adafruit-bluefruit-le-uart-friend Image courtesy of Kevin Townsend

Single Chip Microcontroller and Wi-Fi IoT (For future Internet of Things applications) Cloud Connectivity Home Automation Home Appliances Access Control Security Systems Smart Energy Internet Gateway Industrial Control Smart Plug and Metering Wireless Audio IP Network Sensor Nodes TI CC3200 SimpleLink Wi-Fi

Summary UART Memory RAM and ROM. Digital/Analog Converters - DAC and ADC. Current Communication protocols: Low speed I 2 C (preferred) and SPI. High speed USB and Ethernet. Wireless network WLAN Bluetooth