Sign in

username:

password:



Not a member?

Search code-comp



Search tips

Subscribe to code-comp



code-comp by Keywords

ARM7 | BIOS | Bug | EVM | JTAG | Linker | LOG_printf | McBSP | Profiling | Relocation | RTDX | Simulator | Target | Watch

Sponsor

Evaluate multicore with Texas Instruments:
Low-cost evaluation module & free software development kit available NOW.

Discussion Groups

See Also

Embedded SystemsFPGAElectronics

Discussion Groups | Code-Composer | input_sample and output_sample not working

Technical discussions about Code Composer Studio.

  

Post a new Thread

input_sample and output_sample not working - m_st...@hotmail.com - Mar 11 11:42:23 2010

Hi,

I've got Rulph Chassaing's book "Applications Using C and the TMS320C6x
DSK" and I'm trying to use some of the examples - specifically fft256 and
loop_intr, but they don't appear to do anything! Examples such as the tone
project in CCS work fine, it seems to be anything using the functions
input_sample and output_sample that doesn't work. (Everything builds and runs
fine for fft256 and loop_intr, but with no output).

Has anybody ever experienced any problems with these functions? Using the
function DSK6713_AIC23_write in some of the other examples works fine. I haven't
edited the code from the examples at all, I've just tried loading it onto the
DSP from the CD. I'm sure I must have to change some settings in CSS but I have
no idea what to do - I'm new to this.

Cheers,

Mike

_____________________________________

______________________________
New Code Sharing Section now Live on DSPRelated.com. Learn about the Reward Program for Contributors here.



(You need to be a member of code-comp -- send a blank email to code-comp-subscribe@yahoogroups.com )

Re: input_sample and output_sample not working - Jeff Brower - Mar 11 13:25:17 2010

Mike-

> I've got Rulph Chassaing's book "Applications Using C and the
> TMS320C6x DSK" and I'm trying to use some of the
> examples - specifically fft256 and loop_intr, but they don't
> appear to do anything! Examples such as the tone project
> in CCS work fine, it seems to be anything using the functions
> input_sample and output_sample that doesn't work.
> (Everything builds and runs fine for fft256 and loop_intr,
> but with no output).
>
> Has anybody ever experienced any problems with these
> functions? Using the function DSK6713_AIC23_write in some of
> the other examples works fine. I haven't edited the code
> from the examples at all, I've just tried loading it onto
> the DSP from the CD. I'm sure I must have to change some
> settings in CSS but I have no idea what to do - I'm new to
> this.

I recall that the DSKC6713_AIC23_write() and _read() functions use polling.  So
they burn a lot of CPU time waiting
for each audio sample to move in/out over the McBSP (serial port) connected to
the AIC23.

If so then functions that take more processing time (fft256 for instance) would
not enough CPU time to complete and
you would hear artifacts resulting from non-real-time operation (buzz, spikes,
static, cyborg sounds, you name it).

Basically, you can think of it this way:  if you use polling for audio sample
I/O, then *any* processing you do must
get done in one sample period.  For example with 8 kHz sampling rate, that would
be 125 usec -- which is a tiny sliver
of time in the world of real-time DSP.

Instead, you would want to use interrupt based processing, where you act on an
interrupt after a buffer is filled with
samples.  Then you would have a chunk of time (say for instance 128 samples, or
16 msec) in which to get real-time
work done on each buffer.

I don't know Chassaing's book well, but hopefully it talks about interrupt and
buffer based processing mechanisms.  If
not then there should be lots of relevant discussion on group archives and also
tutorials and app notes on TI's
website.

-Jeff

PS. Suggest to post on C6x as opposed to code-comp.  Your issues are more about
DSP processing and less about how to
use CCS.

_____________________________________





(You need to be a member of code-comp -- send a blank email to code-comp-subscribe@yahoogroups.com )