beautypg.com

3 pcm module notes, 7 watchdog timer, 1 watchdog timer messaging – Cirrus Logic AN333 User Manual

Page 27

background image

AN333

27

6.3 PCM Module Notes

6.3 PCM Module Notes

The following are the possible PCM input modes:

Stereo Mode: Stereo PCM into DAI_D4. 2 Channel Mode set in IO_CONFIG in the OS Manager.

Multichannel Mode: PCM into DAI_D0–DAI_D3. Multichannel Mode set in IO_CONFIG in the OS Manager.

Stereo and Multichannel input modes above are mutually exclusive and must be configured prior to runtime
(pre-kick-start). At runtime, switching between modes is not allowed.

7 Watchdog Timer

The CS470xx has an integrated hardware watchdog timer that acts as a monitor for the DSP. The watchdog timer must
be reset by the DSP before the counter expires, or the entire chip is reset. This peripheral ensures that the CS470xx resets
itself in the event of a temporary system failure. In standalone mode (that is, no host MCU), the DSP reboots from external
FLASH. In slave mode (with host MCU present), all GPIOs are pulled high to signal the host that the watchdog has expired
and the DSP should be rebooted and reconfigured. The watchdog timer is disabled on reset. There are three important
registers that the host uses for configuring the watchdog timer: KICKSTART, WDG_RELOAD, and WDG_COUNT.

The enabling of the watchdog timer happens post-kick-start.

7.1 Watchdog Timer Messaging

The KICKSTART message that enables the watchdog is set by bit 8 (a = 1). To enable no watchdog re-kicking, set bit 9
as well (a = 3). No watching with re-kicking is only used as a test hook to verify that the reset occurs when the
timer expires.

The WDG_COUNT message reflects the watchdog state at last-timer ISR. The default is abcdefgh = FFFFFFFF.

The WDG_RELOAD message is used to set the watchdog reload time. The default is abcdefgh = 00BB800, which is a
1-second reload time at 12.288 MHz.

The equation to calculate the watchdog reload time is as follows:

Watchdog reload time = MCLK / WDG_RELOAD

Mnemonic

Value

KICKSTART

0x81000000
0x00000a00

Mnemonic

Value

WDG_COUNT

0x81000018

0xabcdefgh

Mnemonic

Value

WDG_RELOAD

0x81000019

0xabcdefgh