System Software Design Engineer: Mac Gainor Western Washington University.
-
Upload
melina-malone -
Category
Documents
-
view
215 -
download
0
description
Transcript of System Software Design Engineer: Mac Gainor Western Washington University.
![Page 1: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/1.jpg)
Programmable Drum MachineSystem Software DesignEngineer: Mac GainorWestern Washington University
![Page 2: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/2.jpg)
MCU Specifications Memory Requirements Kernel Choice Kernel Design Overall System Design
Introduction
![Page 3: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/3.jpg)
TMS320C6713 DSP◦ Dual Fixed/Floating Point Multipliers◦ Two Multichannel Audio Serial Ports (McASP)◦ Two General-Purpose Timers◦ 15 General-Purpose I/O Pins
Bus Frequency: 225MHz
MCU
![Page 4: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/4.jpg)
262k Internal RAM Available◦ Estimated Program Requirement: 10kBytes
256k Flash ROM Available◦ Estimated Program Requirement: 25kBytes
Memory
![Page 5: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/5.jpg)
DSP/BIOS◦ Scalable Real-Time Multi-Tasking Kernel◦ Designed for C6000 Series DSP◦ Real-Time Analysis Tools◦ Semaphore and Mutual Exclusion Implementation
Kernel Choice
![Page 6: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/6.jpg)
Prioritized Kernel Events1. HWI2. SWI3. Tasks4. Idle
Kernel Tick Time: 32uS
Kernel Design
![Page 7: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/7.jpg)
McBSP Rec Interrupt (Generate Semaphore)◦ Frequency: 44kHz◦ Period: 22.7uS◦ Execution Time: 0.1uS(max)
ADC Receive Interrupt (Generate Semaphore)◦ Frequency: ~1.6kHz◦ Period: ~625uS◦ Execution Time: 0.1uS(max)
Hardware Interrupts
![Page 8: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/8.jpg)
Clock Interrupts◦ ADC Receive (Generate Semaphore)
Period: 32uS Execution Time: .1uS(max)
◦ LCD Transmit (Generate Semaphore) Period: 32uS Execution Time: .1uS(max)
◦ UI Task Frequency (Generate Semaphore) Period: 9.98ms Execution Time: .1uS(max)
Software Interrupts
![Page 9: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/9.jpg)
Task Name PriorityStartTask() 1ClockTask() 2CodecTask() 3ADCRecTask() 4UITask() 5LCDTask() 6
Tasks - Overview
![Page 10: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/10.jpg)
Description: The purpose of the start task is to run initialization code for different hardware and software modules. The start task must initialize interrupts, LCD, and DSK peripherals.
Period: One Shot Execution Time: ~600mS
StartTask()
![Page 11: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/11.jpg)
Description: The clock task provides software interrupts at 32uS intervals. The clock task must count up to 312 to reach approximately 10mS. The 10mS SWI is used to post a UITask().
Period: ~9.98ms(Periodic) Execution Time: 10uS(max)
ClockTask()
![Page 12: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/12.jpg)
Description: The periodic codec task pends on a codec semaphore and an output buffer mutex. The output buffer is sent to the codec and the next output is calculated.
Period: 2.27uS(Periodic) Execution Time: 0.45uS(max)
CodecTask()
![Page 13: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/13.jpg)
Description: The ADC Receive Task checks to see if a new analog input has been received into an input buffer. If so, it pends on the output buffer mutex and copies the input data to the output array.
Period: 32uS(Periodic) Execution Time: 0.5uS(max)
ADCRecTask()
![Page 14: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/14.jpg)
Description: The user interface task runs every 10mS and polls the GPIO pins looking for a button press. If a button press is found, the LCD display task semaphore is posted for changes to be displayed.
Period: 10mS(Periodic) Execution Time: 10us(max)
UITask()
![Page 15: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/15.jpg)
Description: The LCD task runs when the user interface task posts a semaphore. This task looks for changes in the effects selection and sends appropriate messages to the LCD.
Period: 10mS(Periodic) Execution Time: 1uS(max)
LCDTask()
![Page 16: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/16.jpg)
Max Load: 44.70%
CPU Load
HWI SWI TASKS
![Page 17: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/17.jpg)
Module Tasks Public Functionsmain.c Start Task
Codec TaskADC Receive TaskUser Interface Task
DSK_init()comm_intr()Effects StructureInput BufferOutput Buffer
LCD.c LCD Task LCD_init()LCD_clear()LCD_clearline()LCD_putchar()LCD_putstr()
drum_machinecfg_c.c Clock Task All kernel functionseffects.c filter()
delay()lfo()phase_shift()
Library Description
![Page 18: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/18.jpg)
System Data Flow
![Page 19: System Software Design Engineer: Mac Gainor Western Washington University.](https://reader036.fdocuments.us/reader036/viewer/2022082621/5a4d1b6d7f8b9ab0599b3e23/html5/thumbnails/19.jpg)
System Data Flow (cont)