This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

DSPBIOS timer + edma + spi configuration

Other Parts Discussed in Thread: OMAP-L138, ADS8332

Hi all,

I've been working on ADC reading part of a project. My ADC is ADS8332 and DSP is L138. My environment is DSP/BIOS version 5.41.11.38, BIOS PSP v 1.30.00.05 and CCSv5.1. L138 SPI0 pins and CS pin are directly connected to ADC. Convst and EOC pins are connected to L138's GPIO pins.

The structure I need to implement is:

--------------------------------------             ----------------------
                          Timer  ->    CONVST Pin      ->  Conversion
                                                                                         |
     SPI   +   EDMA       <-        EOC Pin      <-  ---------

              OMAP-L138             |             |     ADS8332
--------------------------------------             ----------------------

I need to configure BIOS to drive a GPIO pin by timer and trigger EDMA to read via SPI by GPIO pin. I am currently using BIOSPSP SPI driver. Driver uses EDMA but I couldn't connect it to a GPIO.
I consider some ways to implement this.  
- Configuring BIOS if it is possible (the easiest way)
- Developing a new BIOS driver.
- Develop a configuration fxns with CSL. 

Please share your experience. Thanks
Serdar
 
  • It seems that it is not possible to control CONVST pin (GP5_6) by timer. I have checked the technical manual and I read that "The timer can generate an output pulse (Figure 31-11) or clock (Figure 31-12) signals on the TM64P_OUT12 pin.". CONVST is not connected to TM64Pn_OUT12.

    How can I control CONVST pin? Any idea, comment ?

    Serdar

  • Hi Serder,

    I guess I can help you with the BIOS PSP you are using. 

    Firstly, It is preferable to you use BIOS PSP version 01.30.01 which is a GA release. You can download it from here. Also refer the top level User guides and the Release notes of the BIOSPSP package before using it.

    For the Timer configuration and programming, you can use the csl placed in - pspdrivers_xx_xx_xx\packages\ti\pspiom\cslr

    For the GPIO, you can refer to the sample application for programming the pins and registering the interrupts(ISR). And in the ISR, you can simply read/write via SPI.

    A facility to activate/deactivate the chipselect using a GPIO pin is already provided in the SPI driver. Please refer to 'dataparam' structure in the "BIOSPSP_spi.chm" file. Or you can also refer to "Spi_localControlDataConfig" function in the spi driver. "Spi_GPIO_CS" macro is used to enable/disable use of GPIO pin as chipselect..

    serdar uludag said:
    trigger EDMA to read via SPI by GPIO pin

    Driver uses EDMA but I couldn't connect it to a GPIO.

    Somehow, I am unable to follow these statements. Could you please elaborate.

    Best Regards,

    Raghavendra

  • Raghavendra, thanks for your reply,

    I studied more on tools and capabilities. I decided to write code with CSL to control hardware (timers, spi etc.). I'll check EDMA_LLD's examples. I plan to use it for programming EDMA. I understand that BIOS PSP spi driver is not suitable for me.

    There are lots of tool to program C6000 and this may cause confusion. My short experience about C6000 programming is (probably you discovered this so long ago), use BIOS to task management, use BIOS PSP drivers if they suits your application, if not, use CSL. That is all.

    Regards,

    Serdar