DSPRelated.com
Forums

How to continuously use RTDX without disturbing DSP program?

Started by paulmauricedsp August 13, 2007
Hello everybody,

Working with C6711DSK and Code Composer 2, I need to send data (float)
from Target to Host with RTDX.

However, having read the Code Composer's tutorials, there is still
something that I do not understan.

Classical code to communicate with RTDX is:

/*****************************************/
//send data
status = RTDX_write( &ochan, &message, sizeof(message) );

//check errors
if (status==0) {exit(-1);}

//wait for data to be sent
while ( (RTDX_writing != NULL) )
{
#if RTDX_POLLING_IMPLEMENTATION
RTDX_Poll();
#endif
}
/*****************************************/

See the line "while ( (RTDX_writing != NULL) )" ?
This one causes problems with me, because it keeps the CPU busy during
a microsecond, so that it stops other activities, such as McBSP reading.
Therefore, when RTDX happens, the real-time operations are break down.

How to not occupy CPU?

Regards,
Paul Maurice
Paul-

> Working with C6711DSK and Code Composer 2, I need to send data (float)
> from Target to Host with RTDX.
>
> However, having read the Code Composer's tutorials, there is still
> something that I do not understan.
>
> Classical code to communicate with RTDX is:
>
> /*****************************************/
> //send data
> status = RTDX_write( &ochan, &message, sizeof(message) );
>
> //check errors
> if (status==0) {exit(-1);}
>
> //wait for data to be sent
> while ( (RTDX_writing != NULL) )
> {
> #if RTDX_POLLING_IMPLEMENTATION
> RTDX_Poll();
> #endif
> }
> /*****************************************/
>
> See the line "while ( (RTDX_writing != NULL) )" ?
> This one causes problems with me, because it keeps the CPU busy during
> a microsecond, so that it stops other activities, such as McBSP reading.
> Therefore, when RTDX happens, the real-time operations are break down.
>
> How to not occupy CPU?

I think with 6711, RTDX operates in "stop mode"; i.e. the CPU has to stop to allow
JTAG circuitry to take over and move data. I'm not sure with 6713. I know that
newer TI devices support "run mode" RTDX.

Another option with 6711 DSK is to use the HPI interface to move data to/from the
host PC (over parallel port interface). TI provides a DLL that supports that,
although it has a reputation as a bit buggy. There is also a free download at:

ftp://ftp.signalogic.com/software/DirectDSP_DSK

that uses DirectDSP software and a WinXP driver to provide DSK 6711-to-PC
communication (includes a Dig Scope example and source code).

-Jeff
Paul,
--- Jeff Brower wrote:

> Paul-
>
> > Working with C6711DSK and Code Composer 2, I need
> to send data (float)
> > from Target to Host with RTDX.
> >
> > However, having read the Code Composer's
> tutorials, there is still
> > something that I do not understan.
> >
> > Classical code to communicate with RTDX is:
> >
> > /*****************************************/
> > //send data
> > status = RTDX_write( &ochan, &message,
> sizeof(message) );
> >
> > //check errors
> > if (status==0) {exit(-1);}
> >
> > //wait for data to be sent
> > while ( (RTDX_writing != NULL) )
> > {
> > #if RTDX_POLLING_IMPLEMENTATION
> > RTDX_Poll();
> > #endif
> > }
> > /*****************************************/
> >
> > See the line "while ( (RTDX_writing != NULL) )" ?
> > This one causes problems with me, because it keeps
> the CPU busy during
> > a microsecond, so that it stops other activities,
> such as McBSP reading.
> > Therefore, when RTDX happens, the real-time
> operations are break down.
> >
> > How to not occupy CPU?
>
> I think with 6711, RTDX operates in "stop mode";
> i.e. the CPU has to stop to allow
> JTAG circuitry to take over and move data. I'm not
> sure with 6713. I know that
> newer TI devices support "run mode" RTDX.
FYI-
All c62xx and c67xx devices use 'stop mode'.
c64 and c64+ devices are accessed via JTAG while the
device is running.

mikedunn
>
> Another option with 6711 DSK is to use the HPI
> interface to move data to/from the
> host PC (over parallel port interface). TI provides
> a DLL that supports that,
> although it has a reputation as a bit buggy. There
> is also a free download at:
>
> ftp://ftp.signalogic.com/software/DirectDSP_DSK
>
> that uses DirectDSP software and a WinXP driver to
> provide DSK 6711-to-PC
> communication (includes a Dig Scope example and
> source code).
>
> -Jeff
>