Electronic Components Datasheet Search
  English  ▼

X  

AN4157 Datasheet(PDF) 21 Page - STMicroelectronics

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

AN4157 Datasheet(HTML) 21 Page - STMicroelectronics

Back Button AN4157 Datasheet HTML 16Page - STMicroelectronics AN4157 Datasheet HTML 17Page - STMicroelectronics AN4157 Datasheet HTML 18Page - STMicroelectronics AN4157 Datasheet HTML 19Page - STMicroelectronics AN4157 Datasheet HTML 20Page - STMicroelectronics AN4157 Datasheet HTML 21Page - STMicroelectronics AN4157 Datasheet HTML 22Page - STMicroelectronics AN4157 Datasheet HTML 23Page - STMicroelectronics AN4157 Datasheet HTML 24Page - STMicroelectronics  
Zoom Inzoom in Zoom Outzoom out
 21 / 24 page
background image
AN4157
Peripheral firmware examples description
Doc ID 023629 Rev 1
21/24
TIM2 is configured as follows:
The Retrigerrable One Pulse mode is used, the external signal is connected to TIM2
CH2 pin (PA1), the rising edge is used as active edge, and the One Pulse signal is
output on TIM2_CH1 (PA0).
The TIM_Pulse defines the One Pulse value. The pulse value is fixed to:
Retrigerrable One Pulse value = TIM_Period/TIM2 counter clock
Retrigerrable One Pulse value = 65535 / 36000000 = 1.8 ms.
Note:
Connect the external signal to the TIM2_CH2 pin (PA01)
Connect the TIM2_CH1 (PA00) pin to an oscilloscope to monitor the waveform.
3.25
USB example
3.25.1
Purpose
This example provides a description of how to use the USB-FS-Device on the STM32F30x
/STM32F31x devices. It is enumerated as an USB-FS-Device mouse, that uses the native
PC Host USB-FS-Device HID driver.
3.25.2
Description
This example shows how the board is recognized as a standard mouse and how its motion
will also control the PC cursor.
The LSM303DLHC MEMS accelerometer device mounted on the STM32F3DISCOVERY
board is used to emulate the mouse directions.
3.26
WWDG example
3.26.1
Purpose
This example shows how to periodically update the WWDG counter, and how to simulate a
software fault which generates an MCU WWDG reset when the programmed time period
has expired.
3.26.2
Description
The WWDG timeout is set to 58.2 ms and the refresh window is set to 80 ms. The WWDG
counter is refreshed each 43ms in the main program infinite loop to prevent a WWDG reset.
LED4 is also toggled each 43 ms indicating that the program is running. An EXTI Line is
connected to a GPIO pin and configured to generate an interrupt on the rising edge of the
signal.
The EXTI Line is used to simulate a software failure: once the EXTI Line event occurs by
pressing the user push-button, the corresponding interrupt is served. In the ISR, a write to
invalid address generates a Hardfault exception containing an infinite loop and preventing to
return to main program (the WWDG counter is not refreshed).



Html Pages

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24


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