SlideShare ist ein Scribd-Unternehmen logo
1 von 3
Downloaden Sie, um offline zu lesen
EE5381/7381

Lab 3 Fun With Real Audio

Introduction:
Analog to digital converters (ADCs) make it possible to digitize an analog voltage. By sampling an analog
voltage at a constant rate a digital representation of an analog signal can be created. In this lab we will
use an ADC to sample an analog signal from an audio source and send the digitized signal to a PC for
playback. This will take the next two lab sessions to complete.
Some Quick Sampling Theory:
To digitize an analog signal you must sample at least twice as fast as the highest frequency you’re trying
to capture (Nyquest) or there will be aliasing. For this lab a suitable sampling frequency would be 16k
samples per second. Sampling at 16k times per second with an 8 bit wide sample produces PCM quality
audio, which sounds pretty good.
Since you can’t guarantee that the input to the ADC will be in the range of frequencies that prevent
aliasing (0 Hz – 8,000 Hz) there must be an anti‐aliasing filter in series with the ADC. The anti‐aliasing
filter for our lab will be a simple low pass filter, frequencies from 0 Hz – 8,000 Hz will pass through filter
relatively unaffected and frequencies greater than 8,000 Hz will be attenuated.
Procedure:
1. Hook up the ADC and sample some voltages to make sure it’s working, and send samples out of
the Coldfire’s serial port using the “printf” command. Use HyperTerminal to monitor the
Coldfire’s serial port output.
2. Use a periodic interrupt timer to sample the ADC 16,000 times per second and test it out by
connecting a signal generator to the ADC’s input. Try sending samples from the ADC to MATLAB
over the Coldfire’s serial port and plot the results.
3. Build the anti‐aliasing filter circuit, sample some music, and play it back using MATLAB
Details:
Connecting the ADC
We’re using a Microchip MCP3001 ADC. The MCP3001 is a 10 bit, 200ksps ADC. This means that the
MCP3001 can convert an input voltage into a 10 bit number 200k times per second. The MCP3001 uses
SPI communications to transmit and receive data. What is SPI you ask? SPI stands for Serial Peripheral
Interface and is an easy to use method for communicating between electronic devices.
SPI is all about shifting bits. Here’s how SPI works in general: A master device, the Coldfire board, will be
connected to a slave device, the ADC. The master device controls all of the communications transactions
and slave does as it’s told. Four signals connect the master and slave: a chip select, data input, data
output, and a clock. As data is clocked out of the master’s SPI shift register to the slave device’s SPI shift
register, the slave device clocks data from its SPI shift register back to master’s SPI shift register.
EE5381/7381

Lab 3 Fun With Real Audio

The MCP3001 is a simple SPI device in that it only outputs data (this means it has no inputs). In order to
initiate a SPI transfer on the Coldfire data must be sent though. The solution is simple; the Coldfire just
sends some junk data out of its unconnected data output to initiate a SPI transfer
Figure 1, MCP3001 timing diagram

The ADC will be connected to the Coldfire with 3 pins, the clock (QSPICLK), data input (QSPIDIN), and
chip select pins (QSPICS0). When a transfer is initiated on the Coldfire the Chip select will be brought
low. Then the Coldfire will output 13 clock transitions. During the last 10 clock transitions the ADC will
output its 10 bits of data back to the Coldfire.
The SPI hardware on the Coldfire is called the QSPI module, the ‘Q’ stands for queued, and here’s how it
needs to be setup to work with the ADC:
1. The QSPI_PAR register needs to be configured so that the QSPI pins aren’t GPIO
2. The QMR register needs the following set: Master mode, the length of the transfer (13 bits), and
baud rate (0x0032 will work), and the CPHA bit needs clearing
3. In the QWR register the CSIV bit needs setting
4. Set the QAR register to point to Command RAM
5. Write a 0x7E00 to the QDR register
6. Set the SPE bit in the ODLYR register to initiate a transfer
7. Wait until the SPIF bit in the QIR register is set
8. Set the QAR register to point to the Receive RAM
9. Read the QDR register to retrieve the reading from the ADC
10. Repeat steps 5 to 9 to get more readings
Periodic Interrupt Timers
The mcf5235 has 4 periodic interrupt timers (PITs). These timers allow the user to create interrupts at
specific rates. These interrupts cause the processor to halt what it’s doing and execute a specific chunk
of code at a constant rate. Setting up the PITs isn’t hard, but due to time constraints code will be
provided to setup and use the PITs.
Anti‐aliasing filter and scaling circuit ???????
Appendix A
EE5381/7381

Schematic for connecting MCP3001 to Coldfire board

Lab 3 Fun With Real Audio

Weitere ähnliche Inhalte

Was ist angesagt?

The IoT Academy IoT training Arduino Part 5 Arduino peripherals
The IoT Academy IoT training Arduino Part 5 Arduino peripheralsThe IoT Academy IoT training Arduino Part 5 Arduino peripherals
The IoT Academy IoT training Arduino Part 5 Arduino peripherals
The IOT Academy
 
Nrf24l01 tutorial 0
Nrf24l01 tutorial 0Nrf24l01 tutorial 0
Nrf24l01 tutorial 0
Khanh Le
 
Interfacing technique with 8085- ADC[0808]
Interfacing technique with 8085- ADC[0808]Interfacing technique with 8085- ADC[0808]
Interfacing technique with 8085- ADC[0808]
Guhan k
 
Digital Alarm Clock 446 project report
Digital Alarm Clock 446 project reportDigital Alarm Clock 446 project report
Digital Alarm Clock 446 project report
Akash Mhankale
 

Was ist angesagt? (20)

Bayas
BayasBayas
Bayas
 
Analog to Digital Converters
Analog to Digital ConvertersAnalog to Digital Converters
Analog to Digital Converters
 
ADC Interfacing with pic Microcontrollert
ADC Interfacing with pic MicrocontrollertADC Interfacing with pic Microcontrollert
ADC Interfacing with pic Microcontrollert
 
The IoT Academy IoT training Arduino Part 5 Arduino peripherals
The IoT Academy IoT training Arduino Part 5 Arduino peripheralsThe IoT Academy IoT training Arduino Part 5 Arduino peripherals
The IoT Academy IoT training Arduino Part 5 Arduino peripherals
 
Physical prototyping lab1-input_output (2)
Physical prototyping lab1-input_output (2)Physical prototyping lab1-input_output (2)
Physical prototyping lab1-input_output (2)
 
Temperature sensor with raspberry pi
Temperature sensor with raspberry piTemperature sensor with raspberry pi
Temperature sensor with raspberry pi
 
Physical prototyping lab2-analog_digital
Physical prototyping lab2-analog_digitalPhysical prototyping lab2-analog_digital
Physical prototyping lab2-analog_digital
 
Amvdd Data Converter Fundamentals
Amvdd Data Converter FundamentalsAmvdd Data Converter Fundamentals
Amvdd Data Converter Fundamentals
 
Digital to Analog conversion
Digital to Analog conversionDigital to Analog conversion
Digital to Analog conversion
 
Nrf24l01 tutorial 0
Nrf24l01 tutorial 0Nrf24l01 tutorial 0
Nrf24l01 tutorial 0
 
07 Analogue to Digital Converter(ADC).2016
07 Analogue to Digital Converter(ADC).201607 Analogue to Digital Converter(ADC).2016
07 Analogue to Digital Converter(ADC).2016
 
Digital clock
Digital clockDigital clock
Digital clock
 
ADC and DAC Best Ever Pers
ADC and DAC Best Ever PersADC and DAC Best Ever Pers
ADC and DAC Best Ever Pers
 
Physical prototyping lab6-motors
Physical prototyping lab6-motorsPhysical prototyping lab6-motors
Physical prototyping lab6-motors
 
(D/A) and (A/D)conversion
(D/A) and (A/D)conversion(D/A) and (A/D)conversion
(D/A) and (A/D)conversion
 
Interfacing technique with 8085- ADC[0808]
Interfacing technique with 8085- ADC[0808]Interfacing technique with 8085- ADC[0808]
Interfacing technique with 8085- ADC[0808]
 
Ditial to Analog Converter
Ditial to Analog ConverterDitial to Analog Converter
Ditial to Analog Converter
 
Digital Alarm Clock 446 project report
Digital Alarm Clock 446 project reportDigital Alarm Clock 446 project report
Digital Alarm Clock 446 project report
 
Digital To Analog Conversion
Digital To Analog ConversionDigital To Analog Conversion
Digital To Analog Conversion
 
Mc module5 lcd_interface_ppt_msj
Mc module5 lcd_interface_ppt_msjMc module5 lcd_interface_ppt_msj
Mc module5 lcd_interface_ppt_msj
 

Andere mochten auch

AfED_1-08-abkhazia_book_eng
AfED_1-08-abkhazia_book_engAfED_1-08-abkhazia_book_eng
AfED_1-08-abkhazia_book_eng
Natalya Luneva
 
Musical instruments
Musical instrumentsMusical instruments
Musical instruments
tinkerbell_3
 
Dr. Abhin Chandra Homoeopathy Medical College & Hospital (Bhubaneswar, India)...
Dr. Abhin Chandra Homoeopathy Medical College & Hospital (Bhubaneswar, India)...Dr. Abhin Chandra Homoeopathy Medical College & Hospital (Bhubaneswar, India)...
Dr. Abhin Chandra Homoeopathy Medical College & Hospital (Bhubaneswar, India)...
Dr. Kabita Mishra
 

Andere mochten auch (14)

AfED
AfEDAfED
AfED
 
Happening at the wall
Happening at the wallHappening at the wall
Happening at the wall
 
5 Rules to Follow While Growing your Startup’s Brand
5 Rules to Follow While Growing your Startup’s Brand5 Rules to Follow While Growing your Startup’s Brand
5 Rules to Follow While Growing your Startup’s Brand
 
B'Ramping Family
B'Ramping FamilyB'Ramping Family
B'Ramping Family
 
Elektrolisis dan electroplating 2
Elektrolisis dan electroplating 2Elektrolisis dan electroplating 2
Elektrolisis dan electroplating 2
 
Bootstrapping your brand
Bootstrapping your brandBootstrapping your brand
Bootstrapping your brand
 
Police appreciation
Police appreciationPolice appreciation
Police appreciation
 
AfED_1-08-abkhazia_book_eng
AfED_1-08-abkhazia_book_engAfED_1-08-abkhazia_book_eng
AfED_1-08-abkhazia_book_eng
 
Musical instruments
Musical instrumentsMusical instruments
Musical instruments
 
Pravda analytics technical monthly review for december 2016
Pravda analytics technical monthly review for december 2016Pravda analytics technical monthly review for december 2016
Pravda analytics technical monthly review for december 2016
 
Chemistry : Deret Volta (Laporan Praktikum Kimia)
Chemistry : Deret Volta (Laporan Praktikum Kimia)Chemistry : Deret Volta (Laporan Praktikum Kimia)
Chemistry : Deret Volta (Laporan Praktikum Kimia)
 
Restaurants & Mobile Apps
Restaurants & Mobile AppsRestaurants & Mobile Apps
Restaurants & Mobile Apps
 
Dr. Abhin Chandra Homoeopathy Medical College & Hospital (Bhubaneswar, India)...
Dr. Abhin Chandra Homoeopathy Medical College & Hospital (Bhubaneswar, India)...Dr. Abhin Chandra Homoeopathy Medical College & Hospital (Bhubaneswar, India)...
Dr. Abhin Chandra Homoeopathy Medical College & Hospital (Bhubaneswar, India)...
 
28 states:discrimination against the girl child
28 states:discrimination against the girl child28 states:discrimination against the girl child
28 states:discrimination against the girl child
 

Ähnlich wie Lab3

Using Ready-for-PIC and SDR Libraries
Using Ready-for-PIC and SDR LibrariesUsing Ready-for-PIC and SDR Libraries
Using Ready-for-PIC and SDR Libraries
Corrado Santoro
 
ATmegaMicrocontrollerArchitecturenotes.pptx
ATmegaMicrocontrollerArchitecturenotes.pptxATmegaMicrocontrollerArchitecturenotes.pptx
ATmegaMicrocontrollerArchitecturenotes.pptx
aartis110
 

Ähnlich wie Lab3 (20)

Assembler4
Assembler4Assembler4
Assembler4
 
Using Ready-for-PIC and SDR Libraries
Using Ready-for-PIC and SDR LibrariesUsing Ready-for-PIC and SDR Libraries
Using Ready-for-PIC and SDR Libraries
 
Embedded systems and robotics by scmandota
Embedded systems and robotics by scmandotaEmbedded systems and robotics by scmandota
Embedded systems and robotics by scmandota
 
Welcome to International Journal of Engineering Research and Development (IJERD)
Welcome to International Journal of Engineering Research and Development (IJERD)Welcome to International Journal of Engineering Research and Development (IJERD)
Welcome to International Journal of Engineering Research and Development (IJERD)
 
Industrial training report of embedded system and robotics
Industrial training report of embedded system and roboticsIndustrial training report of embedded system and robotics
Industrial training report of embedded system and robotics
 
Gas sensor
Gas sensorGas sensor
Gas sensor
 
Training Report on embedded Systems and Robotics
Training Report on embedded  Systems and RoboticsTraining Report on embedded  Systems and Robotics
Training Report on embedded Systems and Robotics
 
digital clock atmega16
digital clock atmega16digital clock atmega16
digital clock atmega16
 
Peripherals and interfacing
Peripherals  and interfacingPeripherals  and interfacing
Peripherals and interfacing
 
JamesEndl
JamesEndlJamesEndl
JamesEndl
 
A 1.2V 10-bit 165MSPS Video ADC
A 1.2V 10-bit 165MSPS Video ADCA 1.2V 10-bit 165MSPS Video ADC
A 1.2V 10-bit 165MSPS Video ADC
 
Part-2: Mastering microcontroller with embedded driver development
Part-2: Mastering microcontroller with embedded driver developmentPart-2: Mastering microcontroller with embedded driver development
Part-2: Mastering microcontroller with embedded driver development
 
PC based oscilloscope
PC based oscilloscopePC based oscilloscope
PC based oscilloscope
 
Wds
WdsWds
Wds
 
Introduction to PIC.pptx
Introduction to PIC.pptxIntroduction to PIC.pptx
Introduction to PIC.pptx
 
Scaling Down Instrumentation Deploying Analog Mixed Signal Technology
Scaling Down Instrumentation Deploying Analog Mixed Signal TechnologyScaling Down Instrumentation Deploying Analog Mixed Signal Technology
Scaling Down Instrumentation Deploying Analog Mixed Signal Technology
 
ATmegaMicrocontrollerArchitecturenotes.pptx
ATmegaMicrocontrollerArchitecturenotes.pptxATmegaMicrocontrollerArchitecturenotes.pptx
ATmegaMicrocontrollerArchitecturenotes.pptx
 
ELECTRICAL ENGINEERING PROJECT
ELECTRICAL ENGINEERING PROJECTELECTRICAL ENGINEERING PROJECT
ELECTRICAL ENGINEERING PROJECT
 
electrical engineering project
electrical engineering projectelectrical engineering project
electrical engineering project
 
ARDUINO AND ITS PIN CONFIGURATION
 ARDUINO AND ITS PIN  CONFIGURATION ARDUINO AND ITS PIN  CONFIGURATION
ARDUINO AND ITS PIN CONFIGURATION
 

Kürzlich hochgeladen

Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
ciinovamais
 
The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptx
heathfieldcps1
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
QucHHunhnh
 
Seal of Good Local Governance (SGLG) 2024Final.pptx
Seal of Good Local Governance (SGLG) 2024Final.pptxSeal of Good Local Governance (SGLG) 2024Final.pptx
Seal of Good Local Governance (SGLG) 2024Final.pptx
negromaestrong
 

Kürzlich hochgeladen (20)

Z Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot GraphZ Score,T Score, Percential Rank and Box Plot Graph
Z Score,T Score, Percential Rank and Box Plot Graph
 
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
Food Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-II
Food Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-IIFood Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-II
Food Chain and Food Web (Ecosystem) EVS, B. Pharmacy 1st Year, Sem-II
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptx
 
The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptx
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docx
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Micro-Scholarship, What it is, How can it help me.pdf
Micro-Scholarship, What it is, How can it help me.pdfMicro-Scholarship, What it is, How can it help me.pdf
Micro-Scholarship, What it is, How can it help me.pdf
 
Energy Resources. ( B. Pharmacy, 1st Year, Sem-II) Natural Resources
Energy Resources. ( B. Pharmacy, 1st Year, Sem-II) Natural ResourcesEnergy Resources. ( B. Pharmacy, 1st Year, Sem-II) Natural Resources
Energy Resources. ( B. Pharmacy, 1st Year, Sem-II) Natural Resources
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Class 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdfClass 11th Physics NEET formula sheet pdf
Class 11th Physics NEET formula sheet pdf
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
PROCESS RECORDING FORMAT.docx
PROCESS      RECORDING        FORMAT.docxPROCESS      RECORDING        FORMAT.docx
PROCESS RECORDING FORMAT.docx
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...
 
Seal of Good Local Governance (SGLG) 2024Final.pptx
Seal of Good Local Governance (SGLG) 2024Final.pptxSeal of Good Local Governance (SGLG) 2024Final.pptx
Seal of Good Local Governance (SGLG) 2024Final.pptx
 

Lab3

  • 1. EE5381/7381 Lab 3 Fun With Real Audio Introduction: Analog to digital converters (ADCs) make it possible to digitize an analog voltage. By sampling an analog voltage at a constant rate a digital representation of an analog signal can be created. In this lab we will use an ADC to sample an analog signal from an audio source and send the digitized signal to a PC for playback. This will take the next two lab sessions to complete. Some Quick Sampling Theory: To digitize an analog signal you must sample at least twice as fast as the highest frequency you’re trying to capture (Nyquest) or there will be aliasing. For this lab a suitable sampling frequency would be 16k samples per second. Sampling at 16k times per second with an 8 bit wide sample produces PCM quality audio, which sounds pretty good. Since you can’t guarantee that the input to the ADC will be in the range of frequencies that prevent aliasing (0 Hz – 8,000 Hz) there must be an anti‐aliasing filter in series with the ADC. The anti‐aliasing filter for our lab will be a simple low pass filter, frequencies from 0 Hz – 8,000 Hz will pass through filter relatively unaffected and frequencies greater than 8,000 Hz will be attenuated. Procedure: 1. Hook up the ADC and sample some voltages to make sure it’s working, and send samples out of the Coldfire’s serial port using the “printf” command. Use HyperTerminal to monitor the Coldfire’s serial port output. 2. Use a periodic interrupt timer to sample the ADC 16,000 times per second and test it out by connecting a signal generator to the ADC’s input. Try sending samples from the ADC to MATLAB over the Coldfire’s serial port and plot the results. 3. Build the anti‐aliasing filter circuit, sample some music, and play it back using MATLAB Details: Connecting the ADC We’re using a Microchip MCP3001 ADC. The MCP3001 is a 10 bit, 200ksps ADC. This means that the MCP3001 can convert an input voltage into a 10 bit number 200k times per second. The MCP3001 uses SPI communications to transmit and receive data. What is SPI you ask? SPI stands for Serial Peripheral Interface and is an easy to use method for communicating between electronic devices. SPI is all about shifting bits. Here’s how SPI works in general: A master device, the Coldfire board, will be connected to a slave device, the ADC. The master device controls all of the communications transactions and slave does as it’s told. Four signals connect the master and slave: a chip select, data input, data output, and a clock. As data is clocked out of the master’s SPI shift register to the slave device’s SPI shift register, the slave device clocks data from its SPI shift register back to master’s SPI shift register.
  • 2. EE5381/7381 Lab 3 Fun With Real Audio The MCP3001 is a simple SPI device in that it only outputs data (this means it has no inputs). In order to initiate a SPI transfer on the Coldfire data must be sent though. The solution is simple; the Coldfire just sends some junk data out of its unconnected data output to initiate a SPI transfer Figure 1, MCP3001 timing diagram The ADC will be connected to the Coldfire with 3 pins, the clock (QSPICLK), data input (QSPIDIN), and chip select pins (QSPICS0). When a transfer is initiated on the Coldfire the Chip select will be brought low. Then the Coldfire will output 13 clock transitions. During the last 10 clock transitions the ADC will output its 10 bits of data back to the Coldfire. The SPI hardware on the Coldfire is called the QSPI module, the ‘Q’ stands for queued, and here’s how it needs to be setup to work with the ADC: 1. The QSPI_PAR register needs to be configured so that the QSPI pins aren’t GPIO 2. The QMR register needs the following set: Master mode, the length of the transfer (13 bits), and baud rate (0x0032 will work), and the CPHA bit needs clearing 3. In the QWR register the CSIV bit needs setting 4. Set the QAR register to point to Command RAM 5. Write a 0x7E00 to the QDR register 6. Set the SPE bit in the ODLYR register to initiate a transfer 7. Wait until the SPIF bit in the QIR register is set 8. Set the QAR register to point to the Receive RAM 9. Read the QDR register to retrieve the reading from the ADC 10. Repeat steps 5 to 9 to get more readings Periodic Interrupt Timers The mcf5235 has 4 periodic interrupt timers (PITs). These timers allow the user to create interrupts at specific rates. These interrupts cause the processor to halt what it’s doing and execute a specific chunk of code at a constant rate. Setting up the PITs isn’t hard, but due to time constraints code will be provided to setup and use the PITs. Anti‐aliasing filter and scaling circuit ??????? Appendix A
  • 3. EE5381/7381 Schematic for connecting MCP3001 to Coldfire board Lab 3 Fun With Real Audio