DatasheetQ Logo
Electronic component search and free download site. Transistors,MosFET ,Diode,Integrated circuits

AN726 Просмотр технического описания (PDF) - Silicon Laboratories

Номер в каталоге
Компоненты Описание
производитель
AN726
Silabs
Silicon Laboratories Silabs
AN726 Datasheet PDF : 28 Pages
1 2 3 4 5 6 7 8 9 10 Next Last
AN726
5. Class-D ToolStick Firmware Overview
5.1. System Overview
The system is configured for 48 MHz AHB and APB to maximize the output resolution of the EPCA.
In all modes, the EPCA0 operates continuously and outputs the PWM signal to the speaker. This waveform
generation is never interrupted. The SARADC modules operate in 12-bit mode at the maximum SAR clock
frequency in order to complete conversions as quickly as possible. The USB internal oscillator provides the
48 MHz system clock, which in conjunction with the PLL0 module, provides the precise timing required in the
different modes to recreate the audio waveforms.
5.1.1. SiM3U164 Module Usage
The modules used by the Class-D ToolStick firmware are:
SARADC0: Measures the right stereo jack channel and the microphone input
SARADC1: Measures the left stereo jack channel
VREF0: Provides the 2.4 V reference for the ADCs
FLASHCTRL0: Writes recorded microphone data to flash
EPCA0: Generates Class-D PWM waveforms (four channels)
CAPSENSE0: Provides button and slider user interface
TIMER0: Generates ~20 ms capacitive sensing scan timer
TIMER1: Generates mode timing (e.g. 48 kHz in USB) and handles LED PWM updates
PCA0 and Crossbar: Generates LED PWM waveforms for the six blue LEDs (one channel)
USB0: Provides the USB Audio input/output interface
PLL0: Provides the precise timing for the system and spectrum spreading to reduce emissions
AppBuilder generates the initialization code for all modules except for the USB0 module. This AppBuilder project is
included in the Utility Class-D ToolStick software package.
Note: Exporting code from version 1.1.1 of AppBuilder will overwrite the project file associated with the Class-D ToolStick firm-
ware. This project file includes manual changes to include the si32Library that will be removed when AppBuilder exports
the code. A saved version of the project file (save.project) is available in the Class-D ToolStick firmware package in
case this project file is overwritten. To restore the project file, simply copy the contents of save.project to the .project
file.
5.1.2. Firmware Organization
The Class-D ToolStick code follows the AppBuilder code organization scheme. The application-specific code for
each peripheral is in the src folder in the my- files, and the generated files from AppBuilder are in a generated
folder below the src folder. Additional application-specific files are in the src folder with names associated with the
functions in the file, like mulaw or LED_control.
class_d: includes the main Class-D loop and any control not handled by the TIMER1L interrupt handler.
LED_control: blue and red LED update functions; handles the shifting of the PCA channel on the crossbar.
mulaw: implements the µLaw companding algorithms.
myApplication: implements the system initialization code before passing control to class_d.
myBuildOptions: required for si32Library.
myDataPlaneIn: si32Library callback functions for the USB IN transactions (recording).
myDataPlaneOut: si32Library callback functions for the USB OUT transactions (playing).
myUsbAudioDevice: USB Audio descriptors and audio-specific si32Library function calls.
myUSB0: non-audio USB si32Library functions calls for the application.
pre_recorded_array: µLaw compressed prerecorded flash data.
volume: handles the volume decoding and control from either the USB interface or the Capacitive Sensing
slider.
my- files: implement application code associated with the particular peripheral.
g- files: AppBuilder generated initialization code associated with the particular peripheral.
8
Rev. 0.1

Share Link: 

datasheetq.com  [ Privacy Policy ]Request Datasheet ] [ Contact Us ]