Audio Engine - Newhaven Display International NHD-7.0-800480FT-CTXL-CTP Manual

7.0” eve2 tft module (spi) – supports: display / touch / audio
Table of Contents

Advertisement

Touch-Screen Engine
The Capacitive Touch Screen Engine (CTSE) of the FT813 communicates with the external Capacitive Touch Panel Module
(CTPM) through an I2C interface. The CTPM will assert its interrupt line when there is a touch detected. Upon detecting
CTP_INT_N line active, the FT813 will read the touch data through I2C. Up to 5 touches can be reported and stored in
FT813 registers.
For more details on the FT813 Touch-Screen Engine, please refer to pages 32-35 of the official FT81x Datasheet:
http://www.ftdichip.com/Support/Documents/DataSheets/ICs/DS_FT81x.pdf

Audio Engine

The FT81x provides mono audio output through a PWM output pin, AUDIO_L. It outputs two audio sources, the sound
synthesizer and audio file playback.
This pin is designed to be passed into a simple filter circuit and then passed to an amplifier for best results. Please refer
to the example schematic in the Audio Filter and Amplifier Reference Circuit section on the next page.
Sound Synthesizer
A sound processor, AUDIO ENGINE, generates the sound effects from a small ROM library of waves table. To play a
sound effect listed in Table 4.3, load the REG_SOUND register with a code value and write 1 to the REG_PLAY register.
The REG_PLAY register reads 1 while the effect is playing and returns a '0' when the effect ends. Some sound effects
play continuously until interrupted or instructed to play the next sound effect. To interrupt an effect, write a new value
to REG_SOUND and REG_PLAY registers; e.g. write 0 (Silence) to REG_SOUND and 1 to PEG_PLAY to stop the sound
effect.
The sound volume is controlled by register REG_VOL_SOUND. The 16-bit REG_SOUND register takes an 8-bit sound in
the low byte. For some sounds, marked "pitch adjust" in the table below, the high 8 bits contain a MIDI note value. For
these sounds, a note value of zero indicates middle C. For other sounds the high byte of REG_SOUND is ignored.
Audio Playback
The FT81x can play back recorded sound through its audio output. To do this, load the original sound data into the
FT81x's RAM, and set registers to start the playback. The registers controlling audio playback are:
REG_PLAYBACK_START:
REG_PLAYBACK_LENGTH:
REG_PLAYBACK_FREQ:
REG_PLAYBACK_FORMAT:
REG_PLAYBACK_LOOP:
REG_PLAYBACK_PLAY:
REG_VOL_PB:
The mono audio formats supported are 8-bits PCM, 8-bits uLAW and 4-bits IMA-ADPCM. For ADPCM_SAMPLES, each
sample is 4 bits, so two samples are packed per byte, the first sample is in bits 0-3 and the second is in bits 4-7.
The current audio playback read pointer can be queried by reading the REG_PLAYBACK_READPTR. Using a large sample
buffer, looping, and this read pointer, the host MPU/MCU can supply a continuous stream of audio.
For more details on the FT81x Audio Engine, please refer to pages 30-32 of the official FT81x Datasheet:
http://www.ftdichip.com/Support/Documents/DataSheets/ICs/DS_FT81x.pdf
The start address of the audio data.
The length of the audio data, in bytes.
The playback sampling frequency, in Hz.
The playback format, one of LINEAR SAMPLES, uLAW SAMPLES, or
ADPCM SAMPLES.
If '0', the sample is played once. If '1', the sample is repeated indefinitely.
A write to this location triggers the start of audio playback, regardless of
writing '0' or '1'. Read back '1' when playback is ongoing, and '0' when
playback finishes.
Playback volume, 0-255.
[9]

Advertisement

Table of Contents
loading

Table of Contents