SINE8I PROGRAM. AICSEC.word 162Ch,1h,4892h,67h ;Fs = 8 kHz This instruction sets the sampling frequency, fs, at 8 kHz.

Slides:



Advertisements
Similar presentations
Parul Polytechnic Institute
Advertisements

Interrupts, Low Power Modes and Timer A (Chapters 6 & 8)
Chapter 6 Multi-channel Buffered Serial Port (McBSP)
The 8051 Microcontroller Chapter 5 SERIAL PORT OPERATION.
Interrupts Chapter 8 – pp Chapter 10 – pp Appendix A – pp 537 &
1/1/ / faculty of Electrical Engineering eindhoven university of technology Architectures of Digital Information Systems Part 1: Interrupts and DMA dr.ir.
Chapter 2 HARDWARE SUMMARY
8086.  The 8086 is Intel’s first 16-bit microprocessor  The 8086 can run at different clock speeds  Standard 8086 – 5 MHz  –10 MHz 
Microprocessor and Microcontroller
I/O Unit.
1/1/ / faculty of Electrical Engineering eindhoven university of technology Introduction Part 3: Input/output and co-processors dr.ir. A.C. Verschueren.
68HC11 Polling and Interrupts
Hierarchy of I/O Control Devices
CSC Timers Since this is a microcontroller it mainly finds itself in embedded devices Quite often embedded devices need to synchronize events The.
Interrupts What is an interrupt? What does an interrupt do to the “flow of control” Interrupts used to overlap computation & I/O – Examples would be console.
6-1 I/O Methods I/O – Transfer of data between memory of the system and the I/O device Most devices operate asynchronously from the CPU Most methods involve.
1 TK2633TK Microprocessor Architecture DR MASRI AYOB.
7-1 Digital Serial Input/Output Two basic approaches  Synchronous shared common clock signal all devices synchronised with the shared clock signal data.
The 8051 Microcontroller and Embedded Systems
MODES OF Details of Pins Pin 1 –Connected Ground Pins 2-16 –acts as both input/output. Outputs address at the first part of the cycle and outputs.
Interfacing ‘C542 DSP to Analog Interface Circuit EE113L Week 3 Rick Huang.
Embedded Systems 7763B Mt Druitt College of TAFE
SC200x Peripherals Broadband Entertainment Division DTV Source Applications July 2001.
DAT2343 Accessing Services Through Interrupts © Alan T. Pinck / Algonquin College; 2003.
MSP430 Mixed Signal Microcontroller – Parte 2 Afonso Ferreira Miguel Source: slau056d – Texas instruments.
Unit 10.2 Timer Examples. Example – Music Generation Channel 6 – Set up as a timer Output to Generate Square Waves Channel 4 – Set up as a timer Output.
EE 445S Real-Time Digital Signal Processing Lab Fall 2013 Lab #2 Generating a Sine Wave Using the Hardware & Software Tools for the TI TMS320C6748 DSP.
McBSP Copyright © 2012 Texas Instruments. All rights reserved. Technical Training Organization T TO C6657 Workshop.
I/O Interfacing A lot of handshaking is required between the CPU and most I/O devices. All I/O devices operate asynchronously with respect to the CPU.
Microprocessors 1 MCS-51 Interrupts.
MODES OF Details of Pins Pin 1GND –Connected Ground Pins 2-16 AD14-AD0–acts as both input/output. Outputs address at the first part of the cycle.
NS Training Hardware. Serial Controller - UART.
© 2008, Renesas Technology America, Inc., All Rights Reserved 1 Course Introduction Purpose  This training course provides an overview of the CPU architecture.
9-1 EE 319K Introduction to Microcontrollers Lecture 9:I/O Synchronization; LCD Interfacing; Implementing Local Variables using a Stack Frame; Parameter.
Fall EE 333 Lillevik 333f06-l21 University of Portland School of Engineering Computer Organization Lecture 21 Subroutines, stack Interrupts, service.
CSNB374: Microprocessor Systems Chapter 5: Procedures and Interrupts.
Microprocessor. Interrupts The processor has 5 interrupts. CALL instruction (3 byte instruction). The processor calls the subroutine, address of which.
Fall EE 333 Lillevik 333f06-l23 University of Portland School of Engineering Computer Organization Lecture 23 RAID Input/output design RS232 serial.
1 © Unitec New Zealand Interrupt Lecture 6 Date: - 20 Sept, 2011 Embedded Hardware ETEC 6416.
6-1 Infineon 167 Interrupts The C167CS provides 56 separate interrupt sources that may be assigned to 16 priority levels. The C167CS uses a vectored interrupt.
Serial Communications Interface Module Slide #1 of 19 MC68HC908GP20 Training PURPOSE -To explain how to configure and use the Serial Communications Interface.
Embedded Systems Design 1 Lecture Set 8 MCS-51 Interrupts.
EE/CS-352: Embedded Microcontroller Systems Part V The 8051 Assembly Language Interrupts.
EE 345S Real-Time Digital Signal Processing Lab Fall 2007 Lab #2 Generating a Sine Wave Using the Hardware & Software Tools for the TI TMS320C6713 DSP.
Page 62 in Chassaing. The.start directive links the section name to start at location address. For the section to have a valid starting address, the.start.
Interrupt-Driven I/O There are different types of interrupts –Hardware Generated by the 8259 PIC – signals the CPU to suspend execution of the current.
CS-280 Dr. Mark L. Hornick 1 Sequential Execution Normally, CPU sequentially executes instructions in a program Subroutine calls are synchronous to the.
8085 INTERNAL ARCHITECTURE.  Upon completing this topic, you should be able to: State all the register available in the 8085 microprocessor and explain.
Lecture – 8 Interrupt 1. Outline Introduction Handling interrupt Interrupt sources Switching interrupt Peripheral interrupts Using two interrupts Conclusions.
8 085Microprocessor Temp Reg (8) Accumulator (A reg) Flag flip flops(8) Instruction Register (8) Arithmetic Logic Unit ALU Instruction Decoder and Machine.
The 8085A is a general-purpose microprocessor with low hardware overhead requirements. Within the 8085A are contained the functions of clock generation,
Serial I/O Port.
Architectures of Digital Information Systems Part 1: Interrupts and DMA dr.ir. A.C. Verschueren Eindhoven University of Technology Section of Digital.
The 8085 Microprocessor Architecture
Interrupt Source: under
8086/8088 Hardware Specifications
8085 Microprocessor Architecture
Introduction to Micro Controllers & Embedded System Design I/O Processing and Serial Port Operation Department of Electrical & Computer Engineering Missouri.
An Introduction to Microprocessor Architecture using intel 8085 as a classic processor
Timer.
8085 Microprocessor Architecture
8085 MICROPROCESSOR 8085 CPU Registers and Status Flags S Z AC P C A B
COMP3221: Microprocessors and Embedded Systems
Accessing Services Through Interrupts
Interrupt Source: under
The 8085 Microprocessor Architecture
Professors: Eng. Diego Barral Eng. Mariano Llamedo Soria Julian Bruno
8085 Microprocessor Architecture
EE 345S Real-Time Digital Signal Processing Lab Fall 2007
Computer Operation 6/22/2019.
Presentation transcript:

SINE8I PROGRAM

AICSEC.word 162Ch,1h,4892h,67h ;Fs = 8 kHz This instruction sets the sampling frequency, fs, at 8 kHz.

SINE_ADDR.word SINE_VAL ;starting addr of sine values.brstart "SINE_BUFF",16 ;align sine table SINE_VAL.word 0,707,1000,707,0,-707,-1000,-707 ;sine values LENGTH.set 8 ;length of circular buffer These instructions initialize the starting address of the circular buffer. Note that the circular buffer must be of size 2 n. The length of circular buffer is 8 generating a frequency of 8 kHz/8 = 1 kHz.

BEGIN LDP AICSEC ;init to data page 128 This instruction establishes the data page register at 128. CALL AICSET_I ;init AIC This instruction calls the AICSET_I subroutine in the AICCOM31 program.

AIC Configuration (Chassaing P. 60)

AICSET_I Subroutine AICSET_I ;---CONFIG FOR INTERRUPT CALL AICSET ;call AICSET routine LDI 0h,IF ;clear IF register OR 10h,IE ;enable EXINT0 CPU interrupt OR 2000h,ST ;global interrupt enable RETS ;return from subroutine Call AICSET routine

Put of copy of these registers on the stack AICSET PUSH AR0 ;save AR0 PUSH AR1 ;save AR1 PUSH R0 ;save R0 PUSH R1 ;save R1 SP SP + 1 SP + 2 SP + 3 SP + 4

;AR0 -> h LDI 1,R0 ;timer CLK=H1/2*(AIC master CLK) STI R0,*+AR0(28h) ;timer period reg(TCLK0=6.25 MHZ) AR0

LDI 03C1h,R0 ;init timer global register STI R0,*+AR0(20h) ;reset timer AR0

03C1

AR0  xx INXF0OUTXF0I/OFX0I/OFX1INXF1OUTXF IOF (IO Flag Register) Configures XF0 as an output Put a 0 on XF0

62H Place the AIC in reset by bringing XFO pin low. This is done by writing an 02 to the CPU’s IOF register.

809c03 809c04 809c05 AR1  809c06 162c Contents of ATABLE = 809c03 This instruction establishes AR1 as a pointer to the table containing the information that sets the sampling frequency and the bandwidth of the antialiasing and reconstruction filters, as well as other constants used by the DSP.

D15D14D13D12D11D10D9D8D6D5D4D3D7D2D1D0 XXXX TA RA X X c Four values are defined in ATABLE. The first and third values define the sampling rate. TB RB 4892

D15D14D13D12D11D10D9D8D6D5D4D3D7D2D1D0 XXXX T’A R’A The second value in table ATABLE sets TA’ and RA’ to zero implying that the sampling frequency will be determined only by TA and TB.

D15D14D13D12D11D10D9D8D6D5D4D3D7D2D1D0 XXX01 1 XXXXX11001 The fourth value of the table is the contents of the control register. Inserts antialiasing filter Disables loop- back function. Disables auxiliary input. Synchronous transmit receive sections The signal varies between  3 volts.

AR0 

131

NOTE for this problem that the input A/D is not used. Only the D/A is used to generate the sine wave

AR0 

FSXOUT XRDY RRDY XCLK SRCE DRP DXP CLKRP CLKXP RFSM XFSM RVAREN XVAREN RCLK SRCE HS RSR FULL XSR EMPTY SERIAL PORT GLOBAL CONTROL REGISTER xx xx xx xx RRESET XRESET RINT RTINT XINT XTINT RLEN XLEN FSRP FSXP

0E970300

The FSX and FSR frame syncs act as active-low inputs from the AIC. The DX and DR data signals remain active high. Both transmitted and received words are 16 bits in length. This configuration sets the serial port mode for a standard mode (i.e. not continuous mode) with a variable data rate. A variable data rate mode works with AIC’s timing protocol, whereas a fixed data rate mode does not.

LDI 0,R0 ;R0 = 0 STI R0,*+AR0(48h) ;clear serial port XMIT register OR 06h,IOF ;bring AIC out of reset LDI 03h,RC ;RC=3 to transmit 4 values RPTB SECEND ;repeat 4 data transmit of sec com

CALL TWAIT ;wait for data transmit LDI 03h,R0 ;value for secondary XMIT request STI R0,*+AR0(48h) ;secondary XMIT request to AIC CALL TWAIT ;wait for data transmit LDI *AR1++(1),R0 ;AR1 -> next AIC init data SECEND STI R0,*+AR0(48h) ;DTR = current AIC data POP R1 ;restore R1 POP R0 ;restore R0 POP AR1 ;restore AR1 POP AR0 ;restore AR0 RETS ;return from subroutine