background image

HT66FV1x0  Integrated Audio Amplifier Application Guideline 

 

AN0486EN  V1.10 

13 / 16 

June 8, 2021 

 

  CALL DELAY_10US   

 

  MOV  A,1 

 ; increase PLADH/PLADL from 0000H to 8000H  

 

  ADDM A,PLADL  

 

  MOV  A,0  

 

  ADCM A,PLADH  

 

  SNZ  PLADH.7  

 

  JMP  LOOP1  

 

  MOV  A,00H 

 ; v

olume = 

target value, MU

TEB=0

 to disable speaker 

 

  MOV   USVC, A 

 

  SET  PAEN  

; enable power amplifier 

 

  CALL DELAY_200MS 

; wait before power amplifier is stable 

 

  SET  MUTEB 

 ; 

MUTEB=1

 to enable speaker 

 

  RET 

(4)

 

Power On Sequence settings using V3 C language 

 

SPI_ON(); 

 

  RAMP_UP(); 

(5)

 

SPI On settings using V3 C language 

 

void SPI_ON(void) 

 

 

 

_pbs0 = _pbs0 | 0x03;

 

// enable VDDIO 

 

 

_pcs1 = 0x55;

 

// enable SPI pins 

 

   

 

 // set SAMLS, SACSEN 

 

 

_spiac0 = 0x00; 

 

 

 

_spiac1 = 0x0C; 

 

 

 

_spiaen = 1;

 

// set SPIAEN 

 

(6)

 

Ramp Up settings using V3 C language 

 

void RAMP_UP(void) 

 

 

  unsigned int j; 

 

 

_pladl = 0x00; 

 

 // initialise DAC 16-bit data 

 

 

_pladh = 0x00;

 

  

 

 

_daen    = 1;

 

 // enable 16-bit D/A converter 

 

 

_paen    = 0; 

 

 // disable power amplifier 

 

 

_usvc = 0x80; 

 

 // 

MUTEB=1 to enable speaker; volume=000_0000

 

 

 

PLAD = 0x0000;

 

 

 

while(PLAD != 0x8000) 

 

// increase PLADH/PLADL from 0000H to 8000H 

 

  { 

     

GCC_CLRWDT(); 

 

 

GCC_DELAY(10); 

 

 

PLAD+=1;

 

 

 

_pladl = PLAD;

 

 

 

_pladh = PLAD >>8;

 

 

  } 

     

_usvc = 0x00; 

 

 // v

olume = 

target 

value, MUTEB=0 to disable speaker

 

     

_plac = 0x03; 

 

 // enable power amplifier 

 

 

for(j= 0;j<300;j++)

 

// wait before power amplifier is stable 

      { 

     

GCC_CLRWDT(); 

 

 

GCC_DELAY(4000); 

 

  } 

 

   

_usvc = 0x80; 

 

 

// MUTEB=1

 to enable speaker 

 

(7)

 

Ramp Down settings using ASM language 

 

RAMPDOWN:  

 

  CLR  PAEN 

; disable power amplifier 

 

COMPARE_EQUAL: 

; increase PLADH/PLADL gradually to 8000H 

 

  MOV   A,PLADH 

 

  XOR   A,80h 

Summary of Contents for HT66FV1 0 Series

Page 1: ...principles features and usage of the MCU integrated audio power amplifier Functional Description A power amplifier is the most basic device in an audio system Power amplifiers can amplify a weak input...

Page 2: ...om the on to off state of the two transistors the distortion of Class B is higher IC IC IC t t Output Waveform Load Line Quiescent Point Quiescet Point Vi Input Waveform Crossover Distortion VBE VCE C...

Page 3: ...A MOSFET driver is used for high power voltage and current amplification after which the amplified digital signal is filtered by a low pass filter to restore the analog audio signal Class D Modulator...

Page 4: ...is input to the power amplifier harmonics based on input frequency multiples are generated due to factors such as the amplifier internal circuit or external component non linear distortion The ratio b...

Page 5: ...r will play the corresponding sound The HT66FV1x0 voice playing function block diagram is shown as follows DAEN and PAEN are the DAC and amplifier enable bits respectively which can be cleared to zero...

Page 6: ...2 1 0 Name P_D7 P_D6 P_D5 P_D4 P_D3 P_D2 P_D1 P_D0 R W R W R W R W R W R W R W R W R W POR 0 0 0 0 0 0 0 0 Bit7 0 P_D7 P_D0 Paly data low byte register bit7 bit0 This register is used to store the 16...

Page 7: ...resistor to AUD AUD_IN is optional according to the desired volume control method A 10 F capacitor is connected to the BIAS pin for bias reference voltage stabilisation and filtering Pin Description...

Page 8: ...ribed below 1 When the PAEN PLAC 1 bit is set high the power amplifier is enabled When the DAEN PLAC 0 bit is set high the 16 bit D A converter is enabled 2 When the MUTEB USVC 7 bit is set high the s...

Page 9: ...which will affect VCC resulting in unstable output To solve this problem set the PC7 SCSAB pin from 1 to 0 and then initiate the ramp up process This will ensure a stable power supply when playing voi...

Page 10: ...s time varies with different speakers Ramp up software flow as shown below Ramp Up Voice Playing Register Initialisation PLADL 0 PLADH 0 DAEN 1 PAEN 0 MUTEB 1 USVC6 USVC0 000_0000 16 bit Play Data PLA...

Page 11: ...ble Power Amplifier PAEN 0 PLADH PLADL 8000H PLADH PLADL 8000H 16 bit Play Data PLADH PLADL 1 16 bit Play Data PLADH PLADL 1 Volume Setup USVC6 USVC0 000_0000 16 bit Play Data PLADH PLADL 1 PLADH PLAD...

Page 12: ...d audio power amplifier Demo code settings are as follows fSYS 8MHz 1 Power On Sequence settings using ASM language MAIN_START CALL SPI_ON CALL RAMP_UP 2 SPI On settings using ASM language SPI_ON enab...

Page 13: ...SACSEN _spiac0 0x00 _spiac1 0x0C _spiaen 1 set SPIAEN 6 Ramp Up settings using V3 C language void RAMP_UP void unsigned int j _pladl 0x00 initialise DAC 16 bit data _pladh 0x00 _daen 1 enable 16 bit D...

Page 14: ...A LOOP2 CALL DELAY_10US MOV A 0FFH decrease PLADH PLADL from 8000H to 0000H ADDMA PLADL MOV A 0FFH ADCMA PLADH SZ PLADL JMP LOOP2 SZ PLADH JMP LOOP2 CLR MUTEB disable speaker output CLR DAEN disable 1...

Page 15: ...f Sequence settings using V3 C language RAMP_DOWN SPI_OFF 12 SPI Off settings using V3 C language void SPI_OFF void _spiaen 0x00 clear SPIAEN _spiac1 0x00 clear SAMLS SACSEN _pcs1 0x00 disable SPI pin...

Page 16: ...iable for any damages including but not limited to computer virus system problems or data loss whatsoever arising in using or in connection with the use of this website by any party There may be links...

Reviews: