AM64x MCU+ SDK  08.06.00

The ICSS SDFM driver provides a well defined set of APIs to expose sigma delta interface.

The ICSS SDFM example invokes these APIs to

  • Set SDFM channels
  • Set ACC source, NC OSR, OC OSR, Clock source & Clock inversion
  • Enable & disable threshold comparators
  • Set high, low & zero cross threshold values
  • configure sample trigger time (time for read sample)
  • Inform firmware to enable SDFM mode
  • Configure GPIO pins for high, low & zero cross thresholds

Once these steps are executed

  • ICSS SDFM example waits for a interrupt (trigger by SDFM firmware) to read sample data
  • when interrupt occurs, example reads sample data from DMEM and again comes back to waiting loop

ICSS SDFM Example Implementation

Following section describes the Example implementation of ICSS SDFM on ARM(R5F).

ICSS SDFM Example

Important files and directory structure

Folder/Files Description
${SDK_INSTALL_PATH}/examples/motor_control/icss_sdfm
app_sddf.c & sddf.c ICSS SDFM application
${SDK_INSTALL_PATH}/source/motor_control/current_sense/sdfm
firmware/ Folder containing SDFM firmware sources.
driver/ ICSS SDFM driver.

Supported Combinations

Parameter Value
CPU + OS r5fss0-0 freertos
ICSSG ICSSG0
PRU PRU0
Toolchain ti-arm-clang
Board am64x-evm
Example folder examples/motorcontrol/sddf

Steps to Run the Example

Hardware Prerequisites

Other than the basic EVM setup mentioned in EVM Setup, below additional HW is required to run this demo

  • TIDEP-01015 3 Axis board
  • Interface card connecting EVM and TIDEP-01015 3 Axis board
  • Signal generator

Hardware Setup

Hardware Setup SDFM

Build, load and run

  • When using CCS projects to build, import the CCS project and build it using the CCS project menu (see Using SDK with CCS Projects).
  • When using makefiles to build, note the required combination and build using make command (see Using SDK with Makefiles)
  • Launch a CCS debug session and run the executable, see CCS Launch, Load and Run
  • Refer to UART terminal for user interface menu options.

Test Case Description

Test detail Steps Pass/fail crieteria
To check raw data for 64 NC OSR 1. Set NC OSR to 64 Resolution of sampled data should be 13.9 bits
2. Set data read time half of epwm cycle
3. Set epwm output frequency 20Khz
4. Draw graph for Raw data
NC sample data
To check raw data for 32 NC OSR 1. Set NC OSR to 32 Resolution of sampled data should be 11.4 bits
2. Set data read time half of epwm cycle
3. Set epwm output frequency 20Khz
To check Threshold comparator 1. Set High Threshold to 3500 and low threshold to 2500 Logic analyzer capture for High & Low Thresholds
2. Set Over current OSR to 32
Logic analyzer Capture
3. Probe Ch0 high, low threshold GPIO pins & input signal
4. Capture signal in Logic analyzer