libdragon
Data Fields
AI_regs_s Struct Reference

Register definition for the AI interface. More...

#include <regsinternal.h>

Data Fields

volatile void * address
 Pointer to uncached memory buffer of samples to play.
uint32_t length
 Size in bytes of the buffer to be played. Should be number of stereo samples * 2 * sizeof( uint16_t )
uint32_t control
 DMA start register. Write a 1 to this register to start playing back an audio sample.
uint32_t status
 AI status register. Bit 31 is the full bit, bit 30 is the busy bit.
uint32_t dacrate
 Rate at which the buffer should be played.
uint32_t samplesize
 The size of a single sample in bits.

Detailed Description

Register definition for the AI interface.


Field Documentation

Rate at which the buffer should be played.

Use the following formula to calculate the value: ((2 * clockrate / frequency) + 1) / 2 - 1


The documentation for this struct was generated from the following file:
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines