STM32F7 5 Reset and clock control (RCC)

Started by tha, September 16, 2022, 01:43:08 PM

Previous topic - Next topic

tha

Bits 14:6 PLLI2SN[8:0]: PLLI2S multiplication factor for VCO
     บิตเหล่านี้ถูกเซ็ตและเคลียร์โดย software เพื่อควบคุม the multiplication factor of the VCO.
     บิตเหล่านี้ควรถูกเขียนเฉพาะถ้า the PLLI2S ถูกปิดใช้งาน. เฉพาะ half-word and word accesses ถูกอนุญาติให้เพื่อเขียนบิตเหล่านี้.

     Caution: The software ต้องเซ็ตบิตเหล่านี้อย่างถูกต้องเพื่อให้แน่ใจว่า the VCO output frequency อยู่ระหว่าง 100 and 432
                       MHz.
     VCO output frequency = VCO input frequency × PLLI2SN with 50 ≤ PLLI2SN ≤ 432
     000000000: PLLI2SN = 0, wrong configuration
     000000001: PLLI2SN = 1, wrong configuration
     ...
     001100010: PLLI2SN = 50
     ...
     001100011: PLLI2SN = 99
     001100100: PLLI2SN = 100
     001100101: PLLI2SN = 101
     001100110: PLLI2SN = 102
     ...
     110110000: PLLI2SN = 432
     110110000: PLLI2SN = 433, wrong configuration
     ...
     111111111: PLLI2SN = 511, wrong configuration
Note: ระหว่าง 50 and 99, multiplication factors สามารถเป็นได้สำหรับ VCO input frequency ที่สูงกว่า 1 MHz. อย่างไรก็ตาม
          ต้องใช้ความระมัดระวังเพื่อให้ได้ the minimum VCO output frequency ตามที่ระบุไว้ข้างบน


Bits 5:0 Reserved, must be kept at reset value.

tha

5.3.24 RCC PLLSAI configuration register (RCC_PLLSAICFGR)

Address offset: 0x88
Reset value: 0x2400 3000
Access: no wait state, word, half-word and byte access.
รีจีสเตอร์นี้ถูกใช้เพื่อกำหนดค่า the PLLSAI clock outputs สอดคล้องกับ the formulas:
•   f(VCO clock) = f(PLLSAI clock input) × (PLLSAIN / PLLM)
•   f(PLLISAI_P) = f(VCO clock) / PLLSAIP
•   f(PLLISAI_Q) = f(VCO clock) / PLLSAIQ
•   f(PLLISAI_R) = f(VCO clock) / PLLSAIR



Bit 31 Reserved, must be kept at reset value.

Bits 30:28 PLLSAIR[2:0]: PLLSAI division factor for LCD clock
     เซ็ตและเคลียร์โดย software เพื่อควบคุม the LCD clock frequency.
     บิตเหล่านี้ควรถูกเขียนเมื่อ the PLLSAI ถูกปิดใช้งาน.
     LCD clock frequency = VCO frequency / PLLSAIR with 2 ≤ PLLSAIR ≤ 7
     000: PLLSAIR = 0, wrong configuration
     001: PLLSAIR = 1, wrong configuration
     010: PLLSAIR = 2
     ...
     111: PLLSAIR = 7

Bits 27:24 PLLSAIQ[3:0]: PLLSAI division factor for SAI clock
     เซ็ตและเคลียร์โดย software เพื่อควบคุม the frequency of SAI clock.
     บิตเหล่านี้ควรถูกเขียนเมื่อ the PLLSAI ถูกปิดใช้งาน.
     SAI1 clock frequency = VCO frequency / PLLSAIQ with 2 ≤ PLLSAIQ ≤ 15
     0000: PLLSAIQ = 0, wrong configuration
     0001: PLLSAIQ = 1, wrong configuration
     ...
     0010: PLLSAIQ = 2
     0011: PLLSAIQ = 3
     0100: PLLSAIQ = 4
     0101: PLLSAIQ = 5
     ...
     1111: PLLSAIQ = 15

Bits 23:18 Reserved, must be kept at reset value.

Bits 17:16 PLLSAIP[1:0]: PLLSAI division factor for 48MHz clock
     เซ็ตและเคลียร์โดย software เพื่อควบคุม the frequency of the PLLSAI output clock (PLLSAI48CLK). เอาพุทนี้สามารถถูก
     เลือกสำหรับ USB, RNG, SDMMC (48 MHz clock). บิตเหล่านี้ควรถูกเขียนเฉพาะถ้า the PLLSAI ถูกปิดใช้งาน. เฉพาะ half-word
     and word accesses ถูกอนุญาติให้เขียนบิตเหล่านี้.

     PLLSAI48 output clock frequency = VCO frequency / PLLSAIP with PLLSAI P = 2, 4, 6, or 8
     00: PLLSAIP = 2
     01: PLLSAIP = 4
     10: PLLSAIP = 6
     11: PLLSAIP = 8

Bit 15 Reserved, must be kept at reset value.

Bits 14:6 PLLSAIN[8:0]: PLLSAI division factor for VCO
     เซ็ตและเคลียร์โดย software เพื่อควบคุม the multiplication factor of the VCO.
     บิตเหล่านี้ควรถูกเขียนเมื่อ the PLLSAI ถูกปิดใช้งาน.
     เฉพาะ half-word and word accesses ถูกอนุญาติให้เขียนบิตเหล่านี้.

     Caution: The software ต้องเซ็ตบิตเหล่านี้อย่างถูกต้องเพื่อให้แน่ใจว่า the VCO output frequency อยู่ระหว่าง 100 and 432
                       MHz.

     VCO output frequency = VCO input frequency x PLLSAIN with 50 ≤ PLLSAIN ≤ 432
     000000000: PLLSAIN = 0, wrong configuration
     000000001: PLLSAIN = 1, wrong configuration
     ......
     001100010: PLLISAIN = 50
     ...
     001100011: PLLISAIN = 99
     001100100: PLLISAIN = 100
     001100101: PLLISAIN = 101
     001100110: PLLISAIN = 102
     ...
     110110000: PLLSAIN = 432
     110110000: PLLSAIN = 433, wrong configuration
     ...
     111111111: PLLSAIN = 511, wrong configuration
Note: ระหว่าง 50 and 99, multiplication factors สามารถเป็นได้สำหรับ VCO input frequency ที่สูงกว่า 1 MHz. อย่างไรก็ตาม
          ต้องใช้ความระมัดระวังเพื่อให้ได้ the minimum VCO output frequency ตามที่ระบุไว้ข้างบน


Bits 5:0 Reserved, must be kept at reset value

tha

5.3.25 RCC dedicated clocks configuration register (RCC_DCKCFGR1)

Address offset: 0x8C
Reset value: 0x0000 0000
Access: no wait state, word, half-word and byte access.
รีจีสเตอร์นี้ยอมให้กำหนดค่า the timer clock prescalers และ the PLLSAI and PLLI2S output clock dividers สำหรับ SAIs and LTDC peripherals สอดคล้องกับสูตรต่อไปนี้:
     f(PLLSAIDIVQ clock output) = f(PLLSAI_Q) / PLLSAIDIVQ
     f(PLLSAIDIVR clock output) = f(PLLSAI_R) / PLLSAIDIVR
     f(PLLI2SDIVQ clock output) = f(PLLI2S_Q) / PLLI2SDIVQ



Bits 31:25 Reserved, must be kept at reset value.

Bit 24 TIMPRE: Timers clocks prescalers selection
     บิตนี้ถูกเซ็ตและรีเซ็ตโดย software เพื่อควบคุม the clock frequency ของทุก the timers ที่ต่อถึง APB1 and APB2 domain.
     0: ถ้า the APB prescaler (PPRE1, PPRE2 in the RCC_CFGR register) ถูกกำหนดค่าแฟคเตอร์ตัวหารเท่ากับ 1, TIMxCLK =
         PCLKx. ถ้าเป็นอย่างอื่น, the timer clock frequencies จะถูกเซ็ตเป็นสองเท่าของ the frequency of the APB domain ซึ่ง
         the timers นั้นถูกต่อถึง: TIMxCLK = 2xPCLKx.
     1: ถ้า the APB prescaler (PPRE1, PPRE2 in the RCC_CFGR register) ถูกกำหนดค่าแฟคเตอร์ตัวหารเท่ากับ 1, 2 หรือ 4,
         TIMxCLK = HCLK. ถ้าเป็นอย่างอื่น, the timer clock frequencies จะถูกเซ็ตเป็นสี่เท่าของ the frequency of the APB
         domain ซึ่ง the timers นั้นถูกต่อถึง: TIMxCLK = 4xPCLKx.


tha

Bits 23:22 SAI2SEL[1:0]: SAI2 clock source selection:
     บิตเหล่านี้ถูกเซ็ตและเคลียร์โดย software เพื่อควบคุม the SAI2 clock frequency.
     บิตเหล่านี้ควรถูกเขียนเมื่อ the PLLSAI and PLLI2S ถูกปิดใช้งาน.
     00: SAI2 clock frequency = f(PLLSAI_Q) / PLLSAIDIVQ
     01: SAI2 clock frequency = f(PLLI2S_Q) / PLLI2SDIVQ
     10: SAI2 clock frequency = Alternate function input frequency
     11: wrong configuration

Bits 21:20 SAI1SEL[1:0]: SAI1 clock source selection
     บิตเหล่านี้ถูกเซ็ตและเคลียร์โดย software เพื่อควบคุม the SAI1 clock frequency.
     บิตเหล่านี้ควรถูกเขียนเมื่อ the PLLSAI and PLLI2S ถูกปิดใช้งาน.
     00: SAI1 clock frequency = f(PLLSAI_Q) / PLLSAIDIVQ
     01: SAI1 clock frequency = f(PLLI2S_Q) / PLLI2SDIVQ
     10: SAI1 clock frequency = Alternate function input frequency
     11: wrong configuration

Bits 19: 18 Reserved, must be kept at reset value.

tha

Bits 17:16 PLLSAIDIVR[1:0]: division factor for LCD_CLK
     บิตเหล่านี้ถูกเซ็ตและเคลียร์โดย software เพื่อควบคุม the frequency of LCD_CLK.
     บิตเหล่านี้ควรถูกเขียนเฉพาะถ้า the PLLSAI ถูกปิดใช้งาน.
     LCD_CLK frequency = f(PLLSAI_R) / PLLSAIDIVR with 2 ≤ PLLSAIDIVR ≤ 16
     00: PLLSAIDIVR = /2
     01: PLLSAIDIVR = /4
     10: PLLSAIDIVR = /8
     11: PLLSAIDIVR = /16

Bits 15: 13 Reserved, must be kept at reset value.

Bits 12:8 PLLSAIDIVQ[4:0]: PLLSAI division factor for SAI1 clock
     บิตเหล่านี้ถูกเซ็ตและรีเซ็ตโดย software เพื่อควบคุม the SAI1 clock frequency.
     บิตเหล่านี้ควรถูกเขียนเฉพาะถ้า the PLLSAI ถูกปิดใช้งาน.
     SAI1 clock frequency = f(PLLSAI_Q) / PLLSAIDIVQ with 1 ≤ PLLSAIDIVQ ≤ 31
     00000: PLLSAIDIVQ = /1
     00001: PLLSAIDIVQ = /2
     00010: PLLSAIDIVQ = /3
     00011: PLLSAIDIVQ = /4
     00100: PLLSAIDIVQ = /5
     ...
     11111: PLLSAIDIVQ = /32

Bits 7:5 Reserved, must be kept at reset value.

Bits 4:0 PLLI2SDIV[4:0]: PLLI2S division factor for SAI1 clock
     บิตเหล่านี้ถูกเซ็ตและรีเซ็ตโดย software เพื่อควบคุม the SAI1 clock frequency.
     บิตเหล่านี้ควรถูกเขียนเฉพาะถ้า PLLI2S ถูกปิดใช้งาน.
     SAI1 clock frequency = f(PLLI2S_Q) / PLLI2SDIVQ with 1 <= PLLI2SDIVQ <= 31
     00000: PLLI2SDIVQ = /1
     00001: PLLI2SDIVQ = /2
     00010: PLLI2SDIVQ = /3
     00011: PLLI2SDIVQ = /4
     00100: PLLI2SDIVQ = /5
     ...
     11111: PLLI2SDIVQ = /32

tha


tha