dsp/bios for c6000/c5000. what is dsp/bios real-time environment –thread execution model threads,...
TRANSCRIPT
![Page 1: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/1.jpg)
DSP/BIOS for C6000/C5000
![Page 2: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/2.jpg)
What is DSP/BIOS
• Real-time Environment– Thread execution model
• Threads, Mailboxes, Semaphores
– Device independent I/O • Logging, Streaming I/O
• RTDX (Real-time data exchange)
• Real-time Analysis– Debug facility ( with CCS)
• Device Configuration and Management– GUI based configuration in CCS
![Page 3: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/3.jpg)
DSP/BIOS Modules
Kernel Module Description
Hardware Interrupts Interface from hardware interrupts to DSP/BIOS kernel
Software Interrupts Lightweight pre-emptible threads that use program stack
Tasks Independent threads of execution that can yield the processor
Periodic Functions Time-triggered lightweight threads
Mailboxes Synchronized data exchange between tasks
Lock Nestable binary semaphores
Semaphores Counting semaphores
Queues Atomic link lists
Clock Interface to hardware timers
Streams Streaming I/O for tasks
Pipes Streaming I/O for software interrupts
Memory Manager Low overhead dynamic memory allocation
![Page 4: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/4.jpg)
DSP/BIOS Configuration
![Page 5: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/5.jpg)
DSP/BIOS Configuration
![Page 6: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/6.jpg)
DSP/BIOS Real-time Kernel
![Page 7: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/7.jpg)
DSP/BIOS Task Synchronization
![Page 8: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/8.jpg)
DSP/BIOS Real-time Analysis
![Page 9: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/9.jpg)
DSP/BIOS Real-time Analysis Features
• Low overhead (formatting done in IDE)
Real-time AnalysisOperations
C5000CPUCycles
Time (usec)for 100 MHz5410
C6000CPUCycles
Time (usec)for 200 MHz6201
Log operations
LOG_event 59 0.59 33 0.165
LOG_printf 59 0.59 36 0.18
Statistics operations
STS_set 19 0.19 14 0.07
STS_add 42 0.42 15 0.075
STS_delta 48 0.48 21 0.105
![Page 10: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/10.jpg)
DSP/BIOS Execution Graph
![Page 11: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/11.jpg)
DSP/BIOS Statistics View
![Page 12: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/12.jpg)
DSP/BIOS Input/Output Capability
![Page 13: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/13.jpg)
DSP/BIOS I/O Example
AudioFilter( inputPipe, outputPipe )
{
PIP_get(inputPipe); /* dequeue full frame */
PIP_alloc(outputPipe); /* dequeue empty frame */
copy algorithm; /* read/write data frames */
PIP_free(inputPipe); /* recycle input frame */
PIP_put(outputPipe); /* enqueue output frame */
return; /* wait for next frame pair */
}
![Page 14: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/14.jpg)
DSP/BIOS Audio I/O Example
Void audio(PIP_Obj *in, PIP_Obj *out) { Uns *src, *dst; Uns size; if(PIP_getReaderNumFrames(in) == 0 || PIP_getWriterNumFrames(out)==0){
error(); } /* get input data and allocate output buffer */ PIP_get(in); PIP_alloc(out); /* copy input data to output buffer */ src = PIP_getReaderAddr(in); dst = PIP_getWriterAddr(out); size = PIP_getReaderSize(in); PIP_setWriterSize(out,size); for (; size > 0; size++) { *dst++ = *src++; } /* output copied data and free input buffer */ PIP_put(out); PIP_free(in); }
![Page 15: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/15.jpg)
CSL and Peripheral Configuration
![Page 16: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/16.jpg)
Peripheral Configuration using IDE
![Page 17: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/17.jpg)
System Configuration
• Allows detailed specification of target– Memory: Data and Code location
• Generates peripheral initialization code– Interrupts, Timers, McBSP, DMA etc.
• Generates linker configuration file (.cmd)
![Page 18: DSP/BIOS for C6000/C5000. What is DSP/BIOS Real-time Environment –Thread execution model Threads, Mailboxes, Semaphores –Device independent I/O Logging,](https://reader031.vdocuments.mx/reader031/viewer/2022012914/5697c0261a28abf838cd5ca3/html5/thumbnails/18.jpg)
Conclusions
• Royalty-free real-time kernel for production use• Allows for rapid development of product from
concept• Can be integrated with another real-time OS• Small footprint (can be as small as 1K words)
– Modules used are controlled by the user
• Allows for on-the-fly debug/analysis in the field• Available with C6000 and C5000 processors