Docsity

Shared Network - Components and Techniques for Digital Systems - Lecture Slides, Slides of Computer Science

Partial preview of the text

Download Shared Network - Components and Techniques for Digital Systems - Lecture Slides and more Slides Computer Science in PDF only on Docsity!

Voice Over a Shared Network

Project 1

Project 2

Project 3

Project 4

Hello World!

Hello World!

Board Level Block Diagram

Xilinx FPGA

XC4010XL

PC84 Package

Bus

DAC

SRAM

64KB

DATA[7:0]

ADDR[15:0]

A/D

Mic Converter

Speaker

Where all your designs go

Discrete parts on Prototype Board

Wire Wrap

Line Transmit/Receiver

Inside the FPGA

FIFO

FIFO

SRAM

UART

IN

UART

OUT

Main Control

FSM

Collision

Audio In interface

Audio Out interface

Packet Logic

Project Break Down

• Complete project in pieces/checkpoints

• Check Point 1

– SRAM Interface

– FIFO

• Check Point 2

– UART Transmitter Receiver

• Check Point 3

– Audio Interfaces

• Check Point 4

– Preliminary Global Data-path and Control

• Finished Project

Check Point 2

• UART Transmitter

– Takes Parallel Data Input

– Converts to Serial

– Outputs Serial Data to Bus

– Look for Collision and Abort

Transmission When Appropriate

• UART Receiver

– Reads Serial Data from Bus

– Converts from Serial to Parallel

– Sends Data to Rest of the Design

– * Must Super Sample Data From

Asynchronous Bus

UART

IN

UART

OUT

Check Point 3

• Audio In from A/D

– Expand Data Path to Take Data From A/D

– Write Data in FIFO Buffer in SRAM

– Shares Data line with SRAM

• Audio Out to D/A

– Take Data from FIFO Buffer

– Convert Data to Serial Form

– Output to D/A chip

Audio In interface

Audio Out interface

Check Point 4

• Packet Logic

– Receive Logic

• Take Data From UART

• Reconstruct Packet

• Interpret Packet and Take Appropriate Action

– Send Logic

• Take Data from SRAM

• Construct Packet

• Send to UART

• You are expected to show successful transmission

of a packet for this checkpoint.

What is a Packet?

  • 5 bytes of UART transmission
  • 1 header, and 4 data samples
  • Header has 2 bit control, 3bit destination, 3bit source.

Header, comes from Dipswitch

Time

Network Protocol

  • Always listen on the shared bus. (everyone picks up everything on the line)
  • Filter out packets that does not have you as a source in the packet logic.
  • Transmission policy (greatly reduces collision frequency)
    • Before you transmit first check Packet Logic and UART to see if bus is being used.
    • If bus is not used then wait a random amount of time before you start transmission
    • If 2 stations happens to decide to start at the same time, they collide, the station with

the first 1 in the transmission loses and backs off.

  • To tell collision check to see if output is same as input on the shared bus.

Network Protocol

Busy Busy

Idle Idle

When bus is busy no one else

can start a new transmission

Collision can only occur when more than one station wants to

transmit when the bus is idle. Even then it only happens

when they both decide to start at the same time

Trace of data flow in Final project

1. Analog input voltage is converted to 8bit

unsigned

2. This 8bit DATA is written directly into the SRAM

through the shared data line of A/D and SRAM

 this is done by asserting the WE of SRAM during the

time when RD is asserted for the A/D chip

 The Address for the write is provided by the FIFO for

the out going data.

3. Data is read out of the SRAM 4 bytes at a time

and put into the packet logic. A header byte is

also added by taking input from the DIP SWITCH

Trace of data flow in Final project

4. The packet is sent to the UART out one byte at a

time. If the bus is idle and there is no collision

5. DATA travels bit serially to another station and

gets picked up by UART in.

6. The UART in then sends the data to the Packet

Logic one byte at a time

7. Packet Logic decodes the packet

 If the destination matches the station then send the

4 data bytes to the SRAM one at a time.

 The OUTPUT FIFO generates the address

Miscellaneous info

• Max bus bit rate, 250Kbps

• Super sampled clock rate 2MHz

• Voice sampling, 8bit, 2KHz

– 8 x 2K = 16Kbps pure data rate

• Network Bandwidth taken per voice stream

– Pure data rate plus…

– UART overhead 2bits per 8 data bits

– Packet 1 header byte per 4 data bytes

– Idle time overhead for random wait time after bus idle

• Many shared resources! Think hard about how to share

them.