Os motores de busca de Datasheet de Componentes eletrônicos
  Portuguese  ▼
ALLDATASHEETPT.COM

X  

AN3209 Folha de dados(PDF) 17 Page - STMicroelectronics

Nome de Peças AN3209
Descrição Electrónicos  Developing your M24LR64-R datalogger application for temperature acquisition
PDF  42 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Fabricante Electrônico  STMICROELECTRONICS [STMicroelectronics]
Página de início  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN3209 Folha de dados(HTML) 17 Page - STMicroelectronics

Back Button AN3209 Datasheet HTML 13Page - STMicroelectronics AN3209 Datasheet HTML 14Page - STMicroelectronics AN3209 Datasheet HTML 15Page - STMicroelectronics AN3209 Datasheet HTML 16Page - STMicroelectronics AN3209 Datasheet HTML 17Page - STMicroelectronics AN3209 Datasheet HTML 18Page - STMicroelectronics AN3209 Datasheet HTML 19Page - STMicroelectronics AN3209 Datasheet HTML 20Page - STMicroelectronics AN3209 Datasheet HTML 21Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 17 / 42 page
background image
AN3209
Component overview
Doc ID 17419 Rev 2
17/42
2.2.3
STM8L101K3 configuration
Clock configuration
The STM8L101K3 microcontroller is configured as follows for the demonstration M24LR64-
R_Datalogger_application_firmware:
●
Master clock set to 2 MHz (minimum)
●
I2C, timer 2 (TIM2), Auto wakeup clocks enabled.
This is done by calling the following functions of the STM8L101 firmware library:
CLK_MasterPrescalerConfig(CLK_MasterPrescaler_HSIDiv8);
CLK_PeripheralClockConfig(CLK_Peripheral_I2C, ENABLE);
CLK_PeripheralClockConfig(CLK_Peripheral_TIM2, ENABLE);
CLK_PeripheralClockConfig(CLK_Peripheral_AWU, ENABLE);
I/O configuration
Three dedicated pins are set in output mode to power the Dual interface EEPROM, the
temperature sensor, and the I2C bus. This is done by using the following STM8L101
firmware library function:
GPIO_Init (GPIOD,GPIO_Pin_5 • GPIO_Pin_6 • GPIO_Pin_7,
GPIO_Mode_Out_PP_Low_Fast);
This example is illustrated in Figure 4.
Note:
It is recommended to set unused pins in input mode to minimize power consumption.
Auto wakeup configuration
The Auto wakeup (AWU) provides an internal wakeup timebase that can be used when the
microcontroller enters Active-halt power saving mode. This timebase is clocked by the low
speed internal (LSI) RC oscillator clock.
To ensure the best possible accuracy when using the LSI clock, its frequency can be
measured with TIM2 timer input capture 1, by calling the AWU_AutoLSICalibration
functions of the STM8L101 firmware library (see code example below):
AWU_AutoLSICalibration ();
AWU_Init (AWU_Timebase_1s);
AWU_Cmd (ENABLE);
/*The datalogger FW then issues the HALT instruction to switch the
microcontroller to Active-halt low power mode. In the following
function, command3 will automatically be executed 1second after
command2 according to the previous configuration */
void function (void)
{
command1 ;
command2 ;
halt ;
command3 ;
}



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 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42


Folha de dados Download

Go To PDF Page


Ligação URL



ALLDATASHEET é útil para você?  [ DONATE ] 

Sobre Alldatasheet   |   Publicidade   |   Contato conosco   |   Privacy Policy   |   Link para a ficha técnica    |   roca de Link   |   Lista de Fabricantes
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