Host Port Interface Expansion Bus Chapter 16 C6000 Integration Workshop Copyright © 2005 Texas Instruments. All rights reserved. T TO Technical Training.

Slides:



Advertisements
Similar presentations
Chapter 9 Bootloader.
Advertisements

Chapter 7: System Buses Dr Mohamed Menacer Taibah University
8086 [2] Ahad. Internal! External? 8086 vs _bit Data Bus 20_bit Address 8_bit Data Bus 20_bit Address Only external bus of 8088 is.
PROGRAMMABLE PERIPHERAL INTERFACE -8255
MC68HC11 System Overview. System block diagram (A8 version)
8086.  The 8086 is Intel’s first 16-bit microprocessor  The 8086 can run at different clock speeds  Standard 8086 – 5 MHz  –10 MHz 
Chapter 2 Microprocessor Bus Transfers. Big- and Little-Endian Ordering Bit-endian processor architecture –High-order-byte-first (H-O-B-F) map the highest-order.
Direct Memory Access Introduction to 8237
Processor System Architecture
CS-334: Computer Architecture
1 TK2633TK Microprocessor Architecture DR MASRI AYOB.
Chapter 9 Bootloader. Dr. Naim Dahnoun, Bristol University, (c) Texas Instruments 2002 Chapter 9, Slide 2 Learning Objectives  Need for a bootloader.
Introduction An interrupt is an event which informs the CPU that its service (action) is needed. Sources of interrupts: internal fault (e.g.. divide by.
University College Cork IRELAND Hardware Concepts An understanding of computer hardware is a vital prerequisite for the study of operating systems.
TECH CH03 System Buses Computer Components Computer Function
680XX Hardware Interface Outline Goal Reading
9/20/6Lecture 3 - Instruction Set - Al Hardware interface (part 2)
NS Training Hardware. System Controller Module.
CS-334: Computer Architecture
Computer Architecture Lecture 08 Fasih ur Rehman.
The 6713 DSP Starter Kit (DSK) is a low-cost platform which lets customers evaluate and develop applications for the Texas Instruments C67X DSP family.
Input/Output. Input/Output Problems Wide variety of peripherals —Delivering different amounts of data —At different speeds —In different formats All slower.
Chapter 7 Input/Output Luisa Botero Santiago Del Portillo Ivan Vega.
Khaled A. Al-Utaibi  Intel Peripheral Controller Chips  Basic Description of the 8255  Pin Configuration of the 8255  Block Diagram.
Chapter 10: Input / Output Devices Dr Mohamed Menacer Taibah University
NS Training Hardware.
CHAPTER 3 TOP LEVEL VIEW OF COMPUTER FUNCTION AND INTERCONNECTION
1-1 Embedded Network Interface (ENI) API Concepts Shared RAM vs. FIFO modes ENI API’s.
Top Level View of Computer Function and Interconnection.
Direct Memory Access (DMA) Microprocessors I -1. Topics to be discussed  Basic DMA Concept Basic DMA Concept  DMA pins and timing DMA pins and timing.
EEE440 Computer Architecture
Input-Output Organization
ECEG-3202 Computer Architecture and Organization Chapter 3 Top Level View of Computer Function and Interconnection.
L/O/G/O Input Output Chapter 4 CS.216 Computer Architecture and Organization.
Embedded Network Interface (ENI). What is ENI? Embedded Network Interface Originally called DPO (Digital Product Option) card Printer without network.
Dr Mohamed Menacer College of Computer Science and Engineering, Taibah University CE-321: Computer.
Input/Output Problems Wide variety of peripherals —Delivering different amounts of data —At different speeds —In different formats All slower than CPU.
Basic Memory Management Chapter 3 C6000 Integration Workshop Copyright © 2005 Texas Instruments. All rights reserved. Technical Training Organization T.
DSP C5000 Chapter 10 Understanding and Programming the Host Port Interface (EHPI) Copyright © 2003 Texas Instruments. All rights reserved.
بسم الله الرحمن الرحيم MEMORY AND I/O.
Chapter Microcontroller
Chapter 3 System Buses.  Hardwired systems are inflexible  General purpose hardware can do different tasks, given correct control signals  Instead.
Multiplex of Data and Address Lines in 8088 Address lines A0-A7 and Data lines D0-D7 are multiplexed in These lines are labelled as AD0-AD7. –By.
PCI 9052 소개 권 동혁. Contents 1.Introduction 2.Major features 3.PCI 9052RDK-LITE.
Computer Architecture. Top level of Computer A top level of computer consists of CPU, memory, an I/O components, with one or more modules of each type.
ATLAS Pre-Production ROD Status SCT Version
Department of Computer Science and Engineering
DMA CONTROLLER 8257 Features: It is a 4-channel DMA.
Chapter 3 Top Level View of Computer Function and Interconnection
COMP2121: Microprocessors and Interfacing
EE 445S Real-Time Digital Signal Processing Lab Spring 2017
This chapter provides a series of applications.
8237 DMA CONTROLLER.
8237 DMA CONTROLLER.
Chapter 4 Introduction to Computer Organization
Chapter 9 Bootloader.
William Stallings Computer Organization and Architecture 7th Edition
William Stallings Computer Organization and Architecture
Presentation transcript:

Host Port Interface Expansion Bus Chapter 16 C6000 Integration Workshop Copyright © 2005 Texas Instruments. All rights reserved. T TO Technical Training Organization

Objectives  HPI Overview  HPI on the DSK  Host Software Example  HPI Hardware Description  Optional Discussions T TO Technical Training Organization

Why HPI? CC CC ‘C6x Ser. Port 32 || Bus Ded. Bus Dedicated to memory accessDedicated to Codecs and A/D’s T TO Technical Training Organization

Why HPI for Communication?  Give host control of the transfer  Allow host to access the entire C6000 memory map  Additional parallel bus for data exchange between a host and the C6000  Provide glueless interface to many different types of hosts T TO Technical Training Organization

What are the requirements of the dedicated bus? Why HPI? CC CC ‘C6x Ser. Port 32 || Bus Ded. Bus Dedicated to memory accessDedicated to Codecs and A/D’s T TO Technical Training Organization

What are the requirements for the dedicated bus? 1. Address 2. Data 3. Control What are the requirements for the dedicated bus? 1. Address 2. Data 3. Control HPI Bus HPI Overview CC CC ‘C6x HPI HPIC HPIA HPID DMA Aux. Ch. Addr. Data Memory T TO Technical Training Organization

HPI Bus HPI Overview Since the HPI bus (HD) is only 16 bits wide, each read/write requires two operations. Since the HPI bus (HD) is only 16 bits wide, each read/write requires two operations. CC CC ‘C6x HPI HPIC HPIA HPID DMA Aux. Ch. Addr. Data Memory T TO Technical Training Organization

Objectives HPI Overview  HPI on the DSK  Host Software Example  HPI Hardware Description  Optional Discussions T TO Technical Training Organization

Host  DSK Communications  The C6713 DSK has a HPI connector which brings out the pins of the Host Port Interface  On the C6416 DSK, this connector contains the muxed HPI/PCI pins  Also shown, the JTAG emulation connections DSP JTAG Emulation Port HPI connector USBUSB JTAG T TO Technical Training Organization

Objectives HPI Overview HPI on the DSK  Host Software Example  HPI Hardware Description  Optional Discussions T TO Technical Training Organization

Some Ideas for Host Interface API C6X_open( ) Open a connection to the C6000 C6X_close( ) Close a connection to the C6000 C6X_resetBoard( ) Reset the entire board C6X_resetDsp( ) Reset only the DSP on the board C6X_dspImageLoad( ) Load a DSP image (COFF) to DSP memory C6X_memRead( ) Read DSP memory via the HPI C6X_memWrite( ) Write to DSP memory via the HPI C6X_ctrlRead( ) Read HPI control register C6X_ctrlWrite( ) Write to HPI control register C6X_generateInt( ) Generate a DSP interrupt C6X_isr( ) Respond to host interrupt (HINT) from DSP  Here are some ideas for the host software (and hardware) functionality you might want to build into your system  These routines could be combined to create more advanced host functions (like routines for setting up the EDMA and such)  Unfortunately, we cannot provide these functions for you, as they must be written specific to the hardware of your host T TO Technical Training Organization

Objectives HPI Overview HPI on the DSK Host Software Example  HPI Hardware Description  Setup Control and Address  Writing 32-bits  Reading 32-bits  Sequential Accesses  Optional Discussions T TO Technical Training Organization

HPI Control Register 32-bit transfer = Minimum of 8 CPU cycles CC CC ‘C6x HPI HPIC HPIA HPID DMA Aux. Ch. Addr. Data Memory HD 16 T TO Technical Training Organization

Setup HPI Control Register HWOB 0 - Big Endian 1 - Little Endian HWOB 0 - Big Endian 1 - Little Endian HWOB reserved HWOB reserved  Setup the HPI Control register ( HWOB-bit ) to specify which 16-bits (upper or lower) are transferred first.  Similar to little/big endian.  Order doesn’t matter when writing to HPIC as the fields are aliased to both halves. T TO Technical Training Organization

Setup HPIC 1. Use HCNTL[1:0] = 00 b to enable access to HPIC CC CC ‘C6x HPI DMA Aux. Ch. Addr. Data 2 HCNTL HPID HPIA Memory HD 16 HPIC HCNTL Values HCNTL1 HCNTL0Description 00HPIC 01HPIA 10HPID (HPIA++) 11HPID T TO Technical Training Organization

Setup HPIC CC CC ‘C6x HPI DMA Aux. Ch. Addr. Data 2 HCNTL HPID HPIA Memory HD 16 HPIC HR/ W 1. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB= xxx1) 1. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB= xxx1) T TO Technical Training Organization

Setup HPIC - 1 CC CC ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HD 16 HPIC HR/ W HHWIL 1. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0), HD = ctrl bits (HWOB = xxx1) HHWIL = 0 indicates first halfword transfer 1. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0), HD = ctrl bits (HWOB = xxx1) HHWIL = 0 indicates first halfword transfer 2 HCNTL T TO Technical Training Organization

HSTRB - 2 CC CC ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HPIC HSTRB 1. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB = xxx1) HHWIL = 0 indicates first halfword transfer 2. HSTRB to indicate active 1. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB = xxx1) HHWIL = 0 indicates first halfword transfer 2. HSTRB to indicate active HD 16 HR/ W HHWIL 2 HCNTL xxx1 T TO Technical Training Organization

Setup HPIC - 3 CC CC ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HPIC 3. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB = xxx1) HHWIL = 1 indicates second halfword transfer 3. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB = xxx1) HHWIL = 1 indicates second halfword transfer HD 16 HR/ W HHWIL 2 HCNTL xxx1 T TO Technical Training Organization

Setup HPIC - 4 CC CC ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HPIC HSTRB 3. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB = xxx1) HHWIL = 1 indicates second halfword transfer 4. HSTRB to indicate active 3. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB = xxx1) HHWIL = 1 indicates second halfword transfer 4. HSTRB to indicate active HD 16 HR/ W HHWIL 2 HCNTL xxx1 T TO Technical Training Organization

Setup HPIA - 1  C Write 8000_0000 to HPIA  C Write 8000_0000 to HPIA ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HPIC 1. Use HCNTL[1:0] = 01 b to enable access to HPIA HR/ W to write (0), HD = 0000 HHWIL = 0 indicates first halfword transfer 1. Use HCNTL[1:0] = 01 b to enable access to HPIA HR/ W to write (0), HD = 0000 HHWIL = 0 indicates first halfword transfer HR/ W HHWIL HD 16 2 HCNTL xxx1 T TO Technical Training Organization

Setup HPIA - 2  C Write 8000_0000 to HPIA  C Write 8000_0000 to HPIA ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HPIC HSTRB 1. Use HCNTL[1:0] = 01 b to enable access to HPIA HR/ W to write (0). HD = 0000 HHWIL = 0 indicates first halfword transfer 2. HSTRB to indicate active 1. Use HCNTL[1:0] = 01 b to enable access to HPIA HR/ W to write (0). HD = 0000 HHWIL = 0 indicates first halfword transfer 2. HSTRB to indicate active HD 16 HR/ W HHWIL 2 HCNTL xxx T TO Technical Training Organization

Setup HPIA - 3  C Write 8000_0000 to HPIA  C Write 8000_0000 to HPIA ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HPIC 3. Use HCNTL[1:0] = 01 b to enable access to HPIA HR/ W to write (0). HD = 8000 HHWIL = 1 indicates second halfword transfer 3. Use HCNTL[1:0] = 01 b to enable access to HPIA HR/ W to write (0). HD = 8000 HHWIL = 1 indicates second halfword transfer HD 16 HR/ W HHWIL 2 HCNTL xxx T TO Technical Training Organization

Setup HPIA - 4  C Write 8000_0000 to HPIA  C Write 8000_0000 to HPIA ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HPIC HSTRB 3. Use HCNTL[1:0] = 01 b to enable access to HPIA HR/ W to write (0). HD = 8000 HHWIL = 1 indicates second halfword transfer 4. HSTRB to indicate active 3. Use HCNTL[1:0] = 01 b to enable access to HPIA HR/ W to write (0). HD = 8000 HHWIL = 1 indicates second halfword transfer 4. HSTRB to indicate active HD 16 HR/ W HHWIL 2 HCNTL xxx T TO Technical Training Organization

Objectives HPI Overview HPI on the DSK Host Software Example HPI Hardware Description Setup Control and Address  Writing 32-bits  Reading 32-bits  Sequential Accesses  Optional Discussions T TO Technical Training Organization

Example 1: Writing a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 0, HD = 5678 HHWIL = 0 1. HCNTL[1:0] = 11 b (HPID) HR/ W = 0, HD = 5678 HHWIL = 0  C Write 1234_5678 to 8000_0000  C Write 1234_5678 to 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HD 16 HR/ W HPIC xxx1 T TO Technical Training Organization

Example 1: Writing a 32-bit Value - 2  C Write 1234_5678 to 8000_0000  C Write 1234_5678 to 8000_0000 ‘C6x HPI HPID 5678 DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HD 16 HSTRB HR/ W HPIC xxx1 1. HCNTL[1:0] = 11 b (HPID) HR/ W = 0, HD = 5678 HHWIL = 0 2. HSTRB 1. HCNTL[1:0] = 11 b (HPID) HR/ W = 0, HD = 5678 HHWIL = 0 2. HSTRB T TO Technical Training Organization

Example 1: Writing a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 0 Write value: HHWIL = 1, HD = HCNTL[1:0] = 11 b (HPID) HR/ W = 0 Write value: HHWIL = 1, HD = 1234  C Write 1234_5678 to 8000_0000  C Write 1234_5678 to 8000_0000 ‘C6x HPI HPID 5678 DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HD 16 HR/ W HPIC xxx1 T TO Technical Training Organization

Example 1: Writing a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 0 Write value: HHWIL = 1, HD = HSTRB 3. HCNTL[1:0] = 11 b (HPID) HR/ W = 0 Write value: HHWIL = 1, HD = HSTRB  C Write 1234_5678 to 8000_0000  C Write 1234_5678 to 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HD 16 HR/ W HPIC xxx1 HSTRB T TO Technical Training Organization

Example 1: Writing a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 0 Write value: HHWIL = 1, HD = HSTRB 5. HRDY high (not-ready) until DMA is finished 3. HCNTL[1:0] = 11 b (HPID) HR/ W = 0 Write value: HHWIL = 1, HD = HSTRB 5. HRDY high (not-ready) until DMA is finished  C Write 1234_5678 to 8000_0000  C Write 1234_5678 to 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HD 16 HSTRB HRDY  HPIC xxx1 HR/ W T TO Technical Training Organization

Example 1: Writing a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 0 Write value: HHWIL = 1, HD = HSTRB 5. HRDY high (not-ready) until DMA is finished 3. HCNTL[1:0] = 11 b (HPID) HR/ W = 0 Write value: HHWIL = 1, HD = HSTRB 5. HRDY high (not-ready) until DMA is finished  C Write 1234_5678 to 8000_0000  C Write 1234_5678 to 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HD 16 HSTRB HPIC xxx1 HR/ W T TO Technical Training Organization

Objectives HPI Overview HPI on the DSK Host Software Example HPI Hardware Description Setup Control and Address Writing 32-bits  Reading 32-bits  Sequential Accesses  Optional Discussions T TO Technical Training Organization

Example 2: Reading a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 1. HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0  C Read 8000_0000  C Read 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HR/ W HPIC xxx1 T TO Technical Training Organization

Example 2: Reading a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB, HPIA is copied to DMA address 1. HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB, HPIA is copied to DMA address  C Read 8000_0000  C Read 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HSTRB HPIC xxx1 HR/ W T TO Technical Training Organization

Example 2: Reading a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB, HPIA is copied to DMA address 3. HRDY is asserted until HD = HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB, HPIA is copied to DMA address 3. HRDY is asserted until HD = 5678  C Read 8000_0000  C Read 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HPIC xxx1 HD HR/ W HSTRB HRDY  Host Data T TO Technical Training Organization

Example 2: Reading a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB, HPIA is copied to DMA address 3. HRDY is asserted until HD = HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB, HPIA is copied to DMA address 3. HRDY is asserted until HD = 5678  C Read 8000_0000  C Read 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HPIC xxx1 HD HR/ W HSTRB Host Data T TO Technical Training Organization

Example 2: Reading a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 1 4. HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 1  C Read 8000_0000  C Read 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HPIC xxx1 HD HR/ W 5678 Host Data T TO Technical Training Organization

Example 2: Reading a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 1 5. HSTRB 4. HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 1 5. HSTRB  C Read 8000_0000  C Read 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HPIC xxx HD 16 HR/ W HSTRB 5678 Host Data T TO Technical Training Organization

Example 2: Reading a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 5. HSTRB 6. HD = HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 5. HSTRB 6. HD = 1234  C Read 8000_0000  C Read 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HPIC xxx1 HD HR/ W HSTRB 1234_5678 Host Data T TO Technical Training Organization

HRDY Example 2: Reading a 32-bit Value HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 5. HSTRB 6. HD = HCNTL[1:0] = 11 b (HPID) HR/ W = 1 Read value: HHWIL = 0 5. HSTRB 6. HD = 1234  C Read 8000_0000  C Read 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HPIC xxx1 HD HR/ W HSTRB 1234_5678 Host Data T TO Technical Training Organization

Objectives HPI Overview HPI on the DSK Host Software Example HPI Hardware Description Setup Control and Address Writing 32-bits Reading 32-bits  Sequential Accesses  Optional Discussions T TO Technical Training Organization

Example 3: Sequential Accesses HCNTL[1:0] = 10 b (HPID w/HPIA++) HR/ W = 1 Read value: HHWIL = 0 1. HCNTL[1:0] = 10 b (HPID w/HPIA++) HR/ W = 1 Read value: HHWIL = 0  C Read 16 values starting at 8000_0000  C Read 16 values starting at 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HPIC xxx1 HR/ W T TO Technical Training Organization

Example 3: Sequential Accesses HCNTL[1:0] = 10 b (HPID w/HPIA++) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB 1. HCNTL[1:0] = 10 b (HPID w/HPIA++) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB  C Read 16 values starting at 8000_0000  C Read 16 values starting at 8000_0000 ‘C6x HPI HPID DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL HPIA Memory HPIC xxx1 HR/ W HSTRB T TO Technical Training Organization

Example 3: Sequential Accesses HCNTL[1:0] = 10 b (HPID w/HPIA++) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB 3. HRDY is high until HD = 5678, HPIA is incremented 1. HCNTL[1:0] = 10 b (HPID w/HPIA++) HR/ W = 1 Read value: HHWIL = 0 2. HSTRB 3. HRDY is high until HD = 5678, HPIA is incremented  C Read 16 values starting at 8000_0000  C Read 16 values starting at 8000_0000 ‘C6x HPI HPID DMA Aux. Ch Addr. Data HHWIL 2 HCNTL HPIA 8000 Memory HD 16 HPIC xxx1 HR/ W HSTRB HRDY  5678 Host Data T TO Technical Training Organization

Example 3: Sequential Accesses HCNTL[1:0] = 10 b (HPID w/HPIA++) HR/ W = 1 Read value: HHWIL = 0 5. HSTRB 6. HD = HCNTL[1:0] = 10 b (HPID w/HPIA++) HR/ W = 1 Read value: HHWIL = 0 5. HSTRB 6. HD = 1234  C Read 16 values starting at 8000_0000  C Read 16 values starting at 8000_0000 ‘C6x DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL Memory HD HPI HPID HPIA HPIC 0004 xxx1 HR/ W HSTRB 1234_5678 Host Data T TO Technical Training Organization

Example 3: Sequential Accesses The new address in HPIA is copied to the DMA. The DMA begins to pre-fetch this address. HRDY is high until the DMA finishes. 7. The new address in HPIA is copied to the DMA. The DMA begins to pre-fetch this address. HRDY is high until the DMA finishes.  C Read 16 values starting at 8000_0000  C Read 16 values starting at 8000_0000 ‘C6x DMA Aux. Ch. Addr. Data HHWIL 2 HCNTL Memory HD HPI HPID HPIA HPIC 0004 xxx1 HR/ W HSTRB 1234_5678 Host Data HRDY  0008 T TO Technical Training Organization

HPI Pin Summary ‘C6x Host HCNTRL [1:0] HHWIL Address HR/ W R/ W HDS1 HDS2 HCS DATASTROBES HAS ALE HBE [1:0] BE HRDY Ready HINTINTERRUPT HDData [15:0] HSTRB T TO Technical Training Organization

HPI Pin Summary ‘C6x Host HCNTRL [1:0] HHWIL Address HR/ W R/ W HDS1 HDS2 HCS DATASTROBES HAS ALE HBE [1:0] BE HRDY Ready HINTINTERRUPT HDData [15:0] HSTRB T TO Technical Training Organization

HR/ W HSTRB CC CC ‘C62xx HPI DMA Aux. Ch. Addr. Data 2 HCNTL HPID HPIA Memory HD 16 HPIC HHWIL HSTRB HDS1 HDS2 HCS HSTRB internal signal 1. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB = x) Write first halfword, then second with HHWIL = 0, then HSTRB to indicate active. 1. Use HCNTL[1:0] = 00 b to enable access to HPIC HR/ W to write (0). HD = ctrl bits (HWOB = x) Write first halfword, then second with HHWIL = 0, then HSTRB to indicate active. HSTRB T TO Technical Training Organization

HAS  Facilitates interface to multiplexed address and data buses by allowing more time to switch bus states from address to data information  Allows HCNTL[1:0], HR/W, and HHWIL to be removed earlier in the access cycle  Often connected to ALE from µC T TO Technical Training Organization

Interface Example ‘C6x MC68360 HCNTRL [1:0] HHWIL HR/ W R/ W HDS1 HDS2 HCS DSACK1 HAS HBE [1:0] HRDY HINTIRQx HD [15:0] Data [31:16] A [3:2] A [1] DSACK0 VccGND CSx GND Vcc T TO Technical Training Organization

HPI Hardware Overview Setup Control and Address Writing 32-bits Reading 32-bits Sequential Accesses  Optional Discussions Objectives Control Register (and CSL for HPI) Expansion Bus (XBUS) Next Chapter 17. Wrap Up T TO Technical Training Organization

HPI Control Register Interrupts DSPINThost interrupt to ‘6x HINT ‘6x can interrupt Host, determines the state of HINT output HWOB 0 - Big Endian 1 - Little Endian Software Handshaking FETCH requests a read at the address pointed to by HPIA HRDY Ready signal to host. Host can poll this bit to determine the state of the HPI. HWOBDSPINTHINTHRDYFETCH reserved HWOBDSPINTHINTHRDYFETCH reserved T TO Technical Training Organization

CSL HPI Support Syntax HPI_getDspint HPI_getEventId HPI_getFetch HPI_getHint HPI_getHrdy HPI_getHwob HPI_setDspint HPI_setHint HPI_SUPPORT Type F C Description Reads the DSPINT bit from the HPIC register Obtain the IRQ event associated with the HPI device Reads the FETCH flag from the HPIC register and returns its value. Returns the value of the HINT bit of the HPIC Returns the value of the HRDY bit of the HPIC Returns the value of the HWOB bit of the HPIC Writes the value to the DSPINT field of the HPIC Writes the value to the HINT field of the HPIC A compile time constant whose value is 1 if the device supports the HPI module Note: F = Function; C = Constant; S = Structure; T = Typedef T TO Technical Training Organization

HPI Hardware Overview Setup Control and Address Writing 32-bits Reading 32-bits Sequential Accesses  Optional Discussions Objectives Control Register (and CSL for HPI) Expansion Bus (XBUS) Next Chapter 17. Wrap Up T TO Technical Training Organization

Expansion Bus (XBUS)  Overview  HPI  32-bit Slave  Sync/Master  I/O Ports  Async  Sync  XBUS Summary T TO Technical Training Organization

‘C6xxx XBUS Introduction 16-bit wide EPROM SDRAM EMIF Data[31:0] T TO Technical Training Organization

‘C6xxx Who gets the bus? Read FIFO Write FIFO Host 16-bit wide EPROM SDRAM EMIF Data[31:0] T TO Technical Training Organization

‘C6xxx Who gets the bus? Read FIFO Write FIFO Host 16-bit wide EPROM SDRAM EMIF Data[31:0] Are there any problems with this many devices on one bus? Are there any problems with this many devices on one bus? T TO Technical Training Organization

C6000 Solution Sync Read FIFO Sync Write FIFO Host 16-bit wide EPROM SDRAM EMIF Data[31:0] XBUS HPI I/O Ports XD[31:0] T TO Technical Training Organization

Expansion Bus (XBUS)  Overview  HPI  32-bit Slave  Sync/Master  I/O Ports  Async  Sync  XBUS Summary T TO Technical Training Organization

Expansion Bus (XBUS) CC CC ‘C6201 HPI HPID HHWIL 2 HCNTL HPIA HD 16 HR/ W HPIC HSTRB HRDY  2 HBE CC CC C6000 XBUS C6000 XBUS XD 32 The C6000 XBUS provides a 32-bit async interface to the host. XCNTL XR/W XCS XRDY 4 XBE The ‘C6201 HPI provides a 16-bit async interface to the host. In both interfaces, the ‘C6x is slave only. XBD XBISA T TO Technical Training Organization

C6000 XBUS Sync Mode - Slave CC CC C6000 XBUS XCLKIN XD [31:0] XW/R XBE [3:0] XBLAST XRDY XCNTL XCS XAS SLAVE XBISA XBD T TO Technical Training Organization

C6000 XBUS Synch Mode - Master PCI C6000 XBUS XCLKIN XD [31:0] XW/R XBE [3:0] XBLAST XWAIT XAS XRDY SLAVE XBISA MASTER XBIMA XBEA XBD T TO Technical Training Organization

XBUS Synch Mode - Arbitration PCI C6000 XBUS XHOLD XHOLDA XBOFF SLAVE XBISA XBD MASTER XBIMA XBEA XBD XCLKI N XD [31:0] XW/R XBE [3:0] XBLAST XRDY XCNTL XCS XAS XWAIT ARBITER Shared signals T TO Technical Training Organization

Expansion Bus (XBUS)  Overview  HPI  32-bit Slave  Sync/Master  I/O Ports  Async  Sync  XBUS Summary T TO Technical Training Organization

XBUS I/O Ports HPI Sync or Async XCE0 XCE1 XCE2 XCE3 mem map 4000_ _ _ _ _0000 Internal Data T TO Technical Training Organization

XBUS HPI I/O Ports Sync or Async XCE0 XCE1 XCE2 XCE3 mem map 4000_ _ _ _ _0000 Internal Data What types of devices can go here? T TO Technical Training Organization

I/O Ports 4000_ _ _ _0000 Write Sync FIFO Read Sync FIFO Async Bit I/O XCE0 XCE1 XCE2 XCE3 XCE Control Regs xxx Async Sync MTYPE Data (XD31:0) T TO Technical Training Organization

Expansion Bus (XBUS)  Overview  HPI Block  32-bit Slave  Sync/Master  I/O Ports  Async  Sync  XBUS Summary T TO Technical Training Organization

HPI PortAsyncSync XCE0 XCE1 XCE2 XCE3 XBUS Summary 16 word addresses 16 read/16 write Master/SlaveSlave only Async Glue Write16 R/W Write16 R/W Write16 R/W Read16 R/W No GlueGlue No GlueGlue No GlueGlue No Glue T TO Technical Training Organization

ti Technical Training Organization T TO Technical Training Organization

Byte Enable  C Write by byte  C Write by byte ‘C6x HPI DMA Aux. Ch. Addr. Data 2 HCNTL HPID HPIA Memory HD 16 HPIC HHWIL 2 HBE ABCD xxx1 HRDY HR/ W HSTRB  HPIA is a 30-bit word address, lower 2-bits always read as 0  On Host write accesses, these bits are provided by HBE [1:0]  HPIA, HHWIL and HBE [1:0] form a byte address from host  HBE [1:0] are used for writes only  HPIA is a 30-bit word address, lower 2-bits always read as 0  On Host write accesses, these bits are provided by HBE [1:0]  HPIA, HHWIL and HBE [1:0] form a byte address from host  HBE [1:0] are used for writes only T TO Technical Training Organization

Writing a Byte HPI 16 HD HBE1 HBE0 HPID BE Write 0xFF to byte 0 of HPID FF?? 01 T TO Technical Training Organization

Writing a Byte HPI 16 HD HBE1 HBE0 FF HPID BE Write 0xFF to byte 0 of HPID ?? T TO Technical Training Organization

Writing a Halfword HPI 16 HD HBE1 HBE0 FF 00 HPID BE Write 0xFFFF to the HPID FF T TO Technical Training Organization

Writing a Halfword HPI 16 HD FF HPID Write 0xFFFF to the HPID FF?? HBE1 HBE0 BE T TO Technical Training Organization

C6000 XBUS Summary 16-bit wide EPROM SDRAM EMIF Data[31:0] CE2 CE1 T TO Technical Training Organization

C6000 XBUS Summary Sync Read FIFO Sync Write FIFO 16-bit wide EPROM SDRAM Sync Host EMIF Data[31:0] CE2 CE1 XD[31:0] XCS/XAS XCE0 XCE3 XBUS HPI I/O Ports T TO Technical Training Organization

Synch or Asynch - XCE Control Reg MTYPE RW, b = 32-bit wide Asynch 101b = 32-bit wide FIFO Note: all others reserved 010b = 32-bit wide Asynch 101b = 32-bit wide FIFO Note: all others reserved T TO Technical Training Organization

Asynchronous Interface Read Setup Write Hold Write Strobe Write Setup Read Hold rsv MTYPE rsv Read Strobe RW, R, +xRW, +11 RW, +1111RW, RW, +11RW,  What does this remind you of?  An async XCE space is identical to the async EMIF  If FIFO interface is selected, only MTYPE is used T TO Technical Training Organization

Synchronous Write Interface EB XFCLK XD[31:0] XRE XOE XWE XCE3 XCE2 XCE1 XCE0 EXT_INTx WF WEN WCLK EF / FF / HF D[31:0] T TO Technical Training Organization

Synchronous Read Interface EB XFCLK XD[31:0] XRE XOE XWE XCE3 XCE2 XCE1 XCE0 EXT_INTx RF REN RCLK OE EF / FF / HF Q[31:0] Note: XOE is only enabled in XCE3 for a glueless read interface. T TO Technical Training Organization

Synchronous Interface EB XFCLK XD[31:0] XRE XOE XWE XCE3 XCE2 XCE1 XCE0 EXT_INTx WF WEN WCLK EF / FF / HF D[31:0] RF REN RCLK OE EF / FF / HF Q[31:0] Note: XOE is only enabled in XCE3 for a glueless read interface. T TO Technical Training Organization

C6000 HPI Expansion Bus I/O Ports XCE0 XCE1 XCE2 XCE3 Sync or Async HPI Sync or Async? T TO Technical Training Organization

C6000 Expansion Bus Block Diagram XCLKIN XFCLK XD[31:0] Shared Signals XCE[3:0] XBE[3:0] /XA[5:2] XOE I/O Ports XRE XWE XCS XAS XCNTL Host Port InterfaceXW/R XRDY XBLAST XBOFF XHOLD XHOLDA Bus Arbitration Signals T TO Technical Training Organization

C6000 DMA Aux. Channel C6000 XBUS SLAVE XBISA XBD MASTER XBIMA XBEA XBD DMA Aux Ch addr ‘6202 Mem Host data addr data The XBUS as the master writes to the host. The DMA Aux Ch is used to service the request of the XBUS to the ‘C6x mem map. T TO Technical Training Organization

C6000 DMA Aux. Channel C6000 XBUS SLAVE XBISA XBD MASTER XBIMA XBEA XBD DMA Aux Ch addr count C6000 Mem Host data addr data Where does the DMA’s count come from??? T TO Technical Training Organization

XBUS HPI Control Register (XBHC) XFRCT 3116 rsv R, RW, +0RW, +11RW, +0 RW, rsv START 01 - starts a write burst *XBIMA to *XBEA 10 - starts a read burst *XBEA to *XBIMA XFRCT Transfer counter when XBUS is master XFRCT Transfer counter when XBUS is master INTSRC 10 - interrupt is caused when XFRCT= DSPINT is the interrupt source DSPINT External master to DSP interrupt DSPINT External master to DSP interrupt T TO Technical Training Organization

The ‘6202 Expansion Bus  32-bits wide  2 co-existing interfaces  I/O Port  Host Port Interface  Support for PCI interface chips  Support for clocked FIFOs T TO Technical Training Organization

C6000 I/O Port  2 modes selected by XCE space  Asynchronous  Similar to EMIF Async. Interface  4 address lines for glueless access to 16 devices  Synchronous FIFOs  Glueless to 3 write/1 read, or 4 write FIFOs  Read in XCE3 only  Minimal glue allows up to 16 write and 16 read FIFOs per XCE space T TO Technical Training Organization

Summary HCNTL HCNTL1 HCNTL0Description 00HPIC 01HPIA 10HPID (HPIA++) 11HPID HWOBDSPINTHINT HRDY FETCH reserved HWOBDSPINTHINT HRDY FETCH reserved HSTRB HDS1 HDS2 HCS HSTRB internal signal T TO Technical Training Organization

C6000 HPI  Either synchronous or asynchronous  Asynchronous  Slave only operation  Used with hosts which have an async. bus  Very similar to ‘6201 HPI operation  Synchronous  Master and Slave operation  Internal Arbiter for bus arbitration  Connectivity of HPI to DSP mem. map provided by DMA aux. ch. T TO Technical Training Organization

Lab 16 (Optional) T TO Technical Training Organization

Writing a Byte  C Write by byte  C Write by byte ‘C6x HPI DMA Aux. Ch. Addr. Data 2 HCNTL HPID HPIA Memory HD 16 HPIC HHWIL 2 HBE ABCD ByteHHWIL = 0HHWIL = 1LE addr.BE addr. D D CBA C B A xxx1 HRDY HR/ W HSTRB T TO Technical Training Organization

Writing a Halfword  C Write by halfword  C Write by halfword ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HPIC H-wordHHWIL = 0HHWIL = 1LE addr.BE addr. B A BA AB xxx1 2 HCNTL HD 16 HHWIL 2 HBE HRDY HR/ W HSTRB T TO Technical Training Organization

Writing a Word  C Write by word  C Write by word ‘C6x HPI DMA Aux. Ch. Addr. Data HPID HPIA Memory HPIC WordHHWIL = 0HHWIL = 1LE addr.BE addr. A00 A A xxx1 2 HCNTL HD 16 HHWIL 2 HBE HRDY HR/ W HSTRB T TO Technical Training Organization

Timing 1. Use HCNTL[1:0] = 00 b to setup HPIC HR/W- to write (0). Write first halfword, then second. HHWIL = 0, then HSTRB to indicate active. 3. HRDY from HPI to host, “got it” 1. Use HCNTL[1:0] = 00 b to setup HPIC HR/W- to write (0). Write first halfword, then second. HHWIL = 0, then HSTRB to indicate active. 3. HRDY from HPI to host, “got it”