Reply by Jeff Brower June 28, 20092009-06-28
Kamran-

> With a very simple configuration in which ADC is connected
> directly with DAC in simulink model with sampling frequency
> of 32 Khz, the code generated by Matlab is working properly
> and giving output... Dont know why in the other case it is
> not giving output despite the fact that other than this alert
> message " overrun-rate for base rate task too fast"in
> the stdout window in CCS there is no error or warning.

Well what's the difference in the block diagrams? What blocks do you have in the error case?

It's not like real-time processing comes free. Any block you add requires processing resources (MIPS) -- add enough
Simulink blocks and you exceed the DSP's capacity. C6713 is not fast, max 300 MHz. Also, the JTAG / RTDX interface
between Simulink and DSP code takes a share of the capacity.

Once real-time is exceeded, output is undefined, which is a good guess as to why you don't hear anything.

-Jeff

> --- In c..., "Jeff Brower" wrote:
>>
>> Kamran-
>>
>> > i am using a very simple simulink model to generate code for
>> > CCS. Configuration consist of a sin wave of 1 Khz
>> > frequency directly connected with DAC with sampling frequency
>> > 32 Khz. The program is successfully downloaded to
>> > TMS320C6713 kit and there are no errors in building of program
>> > but upon execution it gives a message in the stdout
>> > window (window tab is pres" overrun-rate for base rate task
>> > too fast"ent
>> > next to error tab) saying and after this DSK stops working and there is no
>> > output.
>> >
>> > Simulink model attached.
>>
>> 32 kHz is a relatively slow sampling rate. But Simulink does not generate optimized, efficient TI DSP code (that's
>> not its purpose) so it's possible you are asking the DSP code to do too much -- or Simulink to access the DSP code
>> too
>> often or read too much data while it's running -- and the overall result is your DSP code can't stay in real-time.
>>
>> Suggest that you reduce the Simulink block diagram to something very simple, for example A/D, invert the data (or
>> add
>> a small constant to it, etc), then D/A. Verify this works and you can hear the output data with no noise (buzz,
>> static, glitches etc), and then post again and let us know.
>>
>> -Jeff
>>
>> PS. Please post to the group, not to me. My job permits me to answer only group posts.

_____________________________________
Reply by kamrankhan757 June 27, 20092009-06-27
With a very simple configuration in which ADC is connected directly with DAC in simulink model with sampling frequency of 32 Khz, the code generated by Matlab is working properly and giving output... Dont know why in the other case it is not giving output despite the fact that other than this alert message " overrun-rate for base rate task too fast"in the stdout window in CCS there is no error or warning.

--- In c..., "Jeff Brower" wrote:
>
> Kamran-
>
> > i am using a very simple simulink model to generate code for
> > CCS. Configuration consist of a sin wave of 1 Khz
> > frequency directly connected with DAC with sampling frequency
> > 32 Khz. The program is successfully downloaded to
> > TMS320C6713 kit and there are no errors in building of program
> > but upon execution it gives a message in the stdout
> > window (window tab is pres" overrun-rate for base rate task
> > too fast"ent
> > next to error tab) saying and after this DSK stops working and there is no
> > output.
> >
> > Simulink model attached.
>
> 32 kHz is a relatively slow sampling rate. But Simulink does not generate optimized, efficient TI DSP code (that's
> not its purpose) so it's possible you are asking the DSP code to do too much -- or Simulink to access the DSP code too
> often or read too much data while it's running -- and the overall result is your DSP code can't stay in real-time.
>
> Suggest that you reduce the Simulink block diagram to something very simple, for example A/D, invert the data (or add
> a small constant to it, etc), then D/A. Verify this works and you can hear the output data with no noise (buzz,
> static, glitches etc), and then post again and let us know.
>
> -Jeff
>
> PS. Please post to the group, not to me. My job permits me to answer only group posts.

_____________________________________
Reply by Jeff Brower June 26, 20092009-06-26
Kamran-

> i am using a very simple simulink model to generate code for
> CCS. Configuration consist of a sin wave of 1 Khz
> frequency directly connected with DAC with sampling frequency
> 32 Khz. The program is successfully downloaded to
> TMS320C6713 kit and there are no errors in building of program
> but upon execution it gives a message in the stdout
> window (window tab is present
> next to error tab) saying " overrun-rate for base rate task
> too fast" and after this DSK stops working and there is no
> output.
>
> Simulink model attached.

32 kHz is a relatively slow sampling rate. But Simulink does not generate optimized, efficient TI DSP code (that's
not its purpose) so it's possible you are asking the DSP code to do too much -- or Simulink to access the DSP code too
often or read too much data while it's running -- and the overall result is your DSP code can't stay in real-time.

Suggest that you reduce the Simulink block diagram to something very simple, for example A/D, invert the data (or add
a small constant to it, etc), then D/A. Verify this works and you can hear the output data with no noise (buzz,
static, glitches etc), and then post again and let us know.

-Jeff

PS. Please post to the group, not to me. My job permits me to answer only group posts.

> ________________________________
> From: Jeff Brower
> To: Kamran Khan ; Pramod Mishra
> Cc: c...
> Sent: Friday, June 26, 2009 12:56:34 AM
> Subject: Re: [c6x] Re: ISR Overrun
>
> Guys-
>
>> i am having exactly the same error with C6713 DSK and Matlab
>> interfacing. have you figured it out how to remove this
>> error ???
>
> Is the ISR responding to the A/D converter on the DSK board? If so, what is your sampling rate?
>
> -Jeff
>
>> Hi All,
>>>
>>>�I have made a model in Simulink ...for which I have generated
>>>code using 'Embedded Target using TI c6000'. My code runs on DSK6713.
>>>However as soon as the code starts running ...i get a error 'ISR
>>>Overrun - base sample time too fast' . and execution stops. Why is it
>>>so ? What is the remedy?
>>>
>>>Plz reply soon. Thanx in advance
>>>
>>>Pramod Mishra

_____________________________________