Toshiba H1 SERIES TLCS-900 Manuel d'utilisateur Page 118

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 260
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs
Vue de la page 117
TMP92CM22
2007-02-16
92CM22-116
Example: To generate 1/4 duty 62.5 kHz pulses (at f
C
= 40 MHz):
Calculate the value that should be set in the timer register.
To obtain a frequency of 62.5 kHz, the pulse cycle t should be: t = 1/62.5 kHz = 16 μs
φT1 (= (16/fc)s (at f
C
= 40MHz);
16 μs/(16/fc)s = 40
Therefore set TA1REG to 40 (28H)
The duty is to be set to 1/4: t × 1/4 = 16 μs × 1/4 = 4 μs
4 μs/(16/fc)s = 10
Therefore, set TA0REG = 10 = 0AH
7 6 5 4 3210
TA01RUN
0 X X X
0 0 0 Stop TMRA0 and TMRA1 and clear it to “0”.
TA01MOD 1 0 X X X X 0 1 Set the 8-bit PPG mode, and select φT1 as input clock.
TA0REG 0 0 0 0 1010 Write 0AH.
TA1REG 0 0 1 0 1000 Write 28H.
TA1FFCR X X X X 011X Set TA1FF and set inversion to enable.
Writing “10” provides negative logic pulse.
PCCR
X
X
X1
PCFC
X
X
X1
Set PC1 to TA1OUT pin.
TA01RUN
1 X X X
1 1 1 Start TMRA0 and TMRA1 counting.
X : Don’t care, : No change
16
μ
s
Vue de la page 117
1 2 ... 113 114 115 116 117 118 119 120 121 122 123 ... 259 260

Commentaires sur ces manuels

Pas de commentaire