Electronic Components Datasheet Search
  English  ▼
ALLDATASHEET.NET

X  

AN4062 Datasheet(PDF) 6 Page - STMicroelectronics

Part # AN4062
Description  STM32F0DISCOVERY peripheral firmware examples
PDF  17 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  STMICROELECTRONICS [STMicroelectronics]
Direct Link  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN4062 Datasheet(HTML) 6 Page - STMicroelectronics

Back Button AN4062 Datasheet HTML 2Page - STMicroelectronics AN4062 Datasheet HTML 3Page - STMicroelectronics AN4062 Datasheet HTML 4Page - STMicroelectronics AN4062 Datasheet HTML 5Page - STMicroelectronics AN4062 Datasheet HTML 6Page - STMicroelectronics AN4062 Datasheet HTML 7Page - STMicroelectronics AN4062 Datasheet HTML 8Page - STMicroelectronics AN4062 Datasheet HTML 9Page - STMicroelectronics AN4062 Datasheet HTML 10Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 6 / 17 page
background image
Peripheral firmware examples description
AN4062
6/17
DocID022897 Rev 3
Description
In this example:
•
The system tick timer is initialized.
•
The system tick timer interrupt is enabled in the NVIC.
•
The system tick timer/counter starts in free running mode to generate periodical
interrupts.
•
The system tick timer interrupt is triggered every 1 ms.
•
A Delay function is implemented, based on the system tick timer end-of-count event.
The two LEDs, LED3 and LED4, are toggled with a timing defined by the Delay function.
3.4
Standby mode example
Purpose
This example shows how to put the system in Standby mode and wake it up from this mode
using the external reset, RTC Alarm A.
Description
In this example:
•
The system tick timer is initialized.
•
The system tick timer interrupt is enabled in the NVIC.
•
The system tick timer/counter starts in free running mode to generate periodical
interrupts. The system tick timer interrupt is triggered every 250 ms. In the SysTick
interrupt handler, LED3 is toggled; this is used to indicate whether the MCU is in
STANDBY or RUN mode.
•
The EXTI line 0 is configured to generate an interrupt on each rising/falling edge
detected on the PA0 pin. The external interrupt is generated every time the PA0
changes levels (GND or VDD).
–
When a falling or rising edge is detected on the EXTI line, an interrupt is
generated. In the EXTI handler routine, the RTC is configured to generate an
Alarm event in 3 seconds, after which the system enters the Standby mode and
LED3 is Off.
After wake-up from Standby mode, the program execution restarts in the same way as after
a reset; the RTC configuration (clock source, prescaler) is kept and LED3 is toggling again.
As a result, there is no need to configure the RTC.
LED3 is used to monitor the system state as following:
•
LED3 toggling: system in RUN mode
•
LED3 off: system in STANDBY mode
•
LED3 toggling: system resumed from STANDBY mode
These steps are repeated in an infinite loop.



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17


Datasheet Download

Go To PDF Page


Link URL



Does ALLDATASHEET help your business so far?  [ DONATE ] 

About Alldatasheet   |   Advertisement   |   Contact us   |   Privacy Policy   |   Link to Datasheet    |   Link Exchange   |   Manufacturer List
All Rights Reserved©Alldatasheet.com


Mirror Sites
English : Alldatasheet.com  |   English : Alldatasheet.net  |   Chinese : Alldatasheetcn.com  |   German : Alldatasheetde.com  |   Japanese : Alldatasheet.jp
Russian : Alldatasheetru.com  |   Korean : Alldatasheet.co.kr  |   Spanish : Alldatasheet.es  |   French : Alldatasheet.fr  |   Italian : Alldatasheetit.com
Portuguese : Alldatasheetpt.com  |   Polish : Alldatasheet.pl  |   Vietnamese : Alldatasheet.vn
Indian : Alldatasheet.in  |   Mexican : Alldatasheet.com.mx  |   British : Alldatasheet.co.uk  |   New Zealand : Alldatasheet.co.nz
Family Site : ic2ic.com  |   icmetro.com