Please note as of Wednesday, August 15th, 2018 this wiki has been set to read only. If you are a TI Employee and require Edit ability please contact x0211426 from the company directory.

Configuring DSPLink Dynamically

From Texas Instruments Wiki
Jump to: navigation, search


DSP Link is still available for download, but no further releases or updates are planned. Please see IPC Software Options for details and alternatives.

This page provides information about how dynamic configuration can be used to customize DSPLink to the final system.


DSP/BIOS Link provides a feature of dynamic configuration to enable system integrators to modify configuration information required by DSPLink without having to rebuild DSPLink. This feature is available in DSPLink from version 1.40.03 onwards (including 1.50 and subsequent releases).

The dynamic configuration is provided to DSPLink through a file in the format as present in /dsplink/config/all/CFG_<PLATFORM>.c. OS-specific dynamic configuration is present in file /dsplink/config/all/CFG_<GPPOS>.c. The configuration present in these files are the default configurations available, which are pre-built into DSPLink. All the fields in these files are available to be modified by the user.


If the users wish to change any dynamic configuration items, there are two methods:

Directly modify DSPLink default configuration

The system integrator may directly modify DSPLink default configuration present in the location /dsplink/config/all. After modifying the configuration, the GPP user-side DSPLink library needs to be rebuilt:

$ cd $(DSPLINK)/gpp/src/api
$ make -s

The GPP-side kernel module and DSP-side library do not need to be rebuilt.
PROC_setup can be called with NULL parameter.

Use application specific configuration

If the system integrator does not wish to rebuild DSPLink at all, the dynamic configuration can be provided to DSPLink as a parameter to PROC_setup.
PROC_setup () optionally takes a pointer to a configuration structure in the same format as the provided configuration source file. If a valid pointer is provided, the configuration values provided by the application are used. If none is provided, the default configuration is used. This ensures backward compatibility of existing applications.

There are two possible scenarios here. In one scenario, major changes are required - for example, changing the memory map. In the second scenario, only minor changes are required in the configuration - for example, changing the handshake poll count.
The message_multi sample application in DSPLink demonstrates usage of dynamic configuration.

Major changes

Here, the application retains its own copy of the dynamic configuration and passes that to PROC_setup.
Refer to /dsplink/gpp/inc/linkcfgdefs.h for definitions of the structures. The easy way to implement this is to make a copy of an existing default configuration file in your application. Change only the top-level structure name from LINKCFG_config to your own, say LINKCFG_myConfig.
Make all required changes in this application copy of the configuration file. Include this file in the application build.
Pass the new configuration to PROC_setup.

/* Initialize and configure the DSPLink driver */
status = PROC_setup (&LINKCFG_myConfig) ;

Minor changes

From DSPLink 1.60 onwards, this is very simple to do:

For making configuration changes, it is very simple to update existing default configuration, instead of keeping the application’s own copy of the configuration. This can be done by updating existing configuration prior to PROC_setup call. Using this method allows the application to remain independent of changes in configuration, and makes it easier to have platform-independent application code. Example of runtime change of existing configuration:

/* Extern declaration to default configuration object in  (CFG_<PLATFORM>.c) */
extern LINKCFG_Object  LINKCFG_config ;
/* Increase maximum Message Queues to 32. */
LINKCFG_config.gppObject->maxMsgqs = 32 ;
/* Make handshake poll count infinite to enable DSP-side debugging. */
LINKCFG_config.dspConfigs [0]->linkDrvObjects [0].hshkPollCount = -1 ;
/* Initialize and configure the DSPLink driver */
status = PROC_setup (&LINKCFG_config) ;