Exiting from Over-drive mode
ขอแนะนำให้ออกจาก Over-drive mode เมื่อ the application ไม่ได้กำลังรัน critical tasks และเมื่อ the system clock source คือ HSI หรือ HSE อย่างใดอย่างหนึ่ง. มีสองลำดับที่ยอมให้ออกจาก over-drive mode:
• โดยการรีเซ็ต the ODEN and ODSW bits bit พร้อมกันใน the PWR_CR1 register (ลำดับที่ 1)
• โดยการรีเซ็ต the ODSW bit ก่อนเพื่อสลับ the voltage regulator ไปเป็น Normal mode และจากนั้นรีเซ็ต the ODEN bit เพื่อ
ปิดใช้งาน the Over-drive mode (ลำดับที่ 2).
ตัวอย่างของลำดับที่ 1:
1. เลือก HSI หรือ HSE เป็น system clock source.
2. ปิดใช้งาน the peripheral clocks ที่ไม่ถูกสร้างโดย the System PLL (I2S clock, LCD-TFT clock, SAI1 clock,
USB_48MHz clock,....)
3. รีเซ็ต the ODEN and ODSW bits bit พร้อมกันใน the PWR_CR1 register เพื่สลับ the voltage regulator กลับไปเป็น
Normal mode และปิดใช้งาน the Over-drive mode.
4. รอสำหรับ the ODWRDY flag of PWR_CSR1 ที่จะถูกรีเซ็ต.
ตัวอย่างของลำดับที่ 2:
1. เลือก HSI หรือ HSE เป็น system clock source.
2. ปิดใช้งาน the peripheral clocks ที่ไม่ถูกสร้างโดย the System PLL (I2S clock, LCD-TFT clock, SAI1 clock,
USB_48MHz clock,....)
3. รีเซ็ต the ODSW bits bit ใน the PWR_CR1 register เพื่สลับ the voltage regulator กลับไปเป็น Normal mode. The
system clock จะถูกทำให้หยุดในระหว่าง voltage switching.
4. รอสำหรับ the ODWRDY flag of PWR_CSR1 ที่จะถูกรีเซ็ต.
5. รีเซ็ต the ODEN bit ใน the PWR_CR1 register เพื่อปิดใช้งาน the Over-drive mode.
Note: ในระหว่าง step 3, the ODEN bit ยังคงเซ็ตและ the Over-drive mode ยังคงถูกเปิดใช้งานแต่จะไม่ทำงาน (ODSW bit ถูก
รีเซ็ต). ถ้า the ODEN bit ถูกรีเซ็ตแทน, the Over-drive mode จะถูกปิดใช้งานและ the voltage regulator จะถูกสลับกลับ
ไปยัง the initial voltage.