Electronic Components Datasheet Search
  English  ▼
ALLDATASHEET.NET

X  

AN413 Datasheet(PDF) 15 Page - STMicroelectronics

Part # AN413
Description  Initialization of the ST9
PDF  45 Pages
Scroll/Zoom Zoom In 100%  Zoom Out
Manufacturer  STMICROELECTRONICS [STMicroelectronics]
Direct Link  http://www.st.com
Logo STMICROELECTRONICS - STMicroelectronics

AN413 Datasheet(HTML) 15 Page - STMicroelectronics

Back Button AN413 Datasheet HTML 11Page - STMicroelectronics AN413 Datasheet HTML 12Page - STMicroelectronics AN413 Datasheet HTML 13Page - STMicroelectronics AN413 Datasheet HTML 14Page - STMicroelectronics AN413 Datasheet HTML 15Page - STMicroelectronics AN413 Datasheet HTML 16Page - STMicroelectronics AN413 Datasheet HTML 17Page - STMicroelectronics AN413 Datasheet HTML 18Page - STMicroelectronics AN413 Datasheet HTML 19Page - STMicroelectronics Next Button
Zoom Inzoom in Zoom Outzoom out
 15 / 45 page
background image
AN413
ST9 basic system configuration
Doc ID 1875 Rev 2
15/45
The specified count value leads to a count period of about 1 millisecond, (3003 x 333ns).
3.9
Timer/watchdog unit initialization
The External Interrupt Priority Level Register, EIPLR, specifies the priority level of four pairs
of external interrupts, a), A1,...D0, D1. It is thus used to set the priority of the
Timer/Watchdog EOC interrupt routine, called via channel A0.
Example:
5C FE ld eiplr,#0FEh
In this example priority levels of 4 and 5 are specified for the pair INTA0, INTA1.
The External Interrupts Pending Bit Register, EIPR, holds the eight interrupt pending bits for
the external interrupts, including, in the present context, the Watchdog/Timer EOC interrupt.
These bits are set by hardware action and reset by software during the service routine.
Example:
90 D3 clr eipr
In this example all the external interrupt pending bits are cleared.
The External Interrupts Mask-Bit Register, EIMR, holds the eight interrupt mask bits for the
external interrupts, including, in the present context, the Timer/Watchdog EOC interrupt.
Example:
4C 01 ld eimr,#ia0
In this example the Timer/Watchdog End of Count on Channel A0 is unmasked.
3.10
Interrupt service routine organization
When an enabled interrupt is acknowledged the Interrupt machine cycle performs the
following actions:
1.
All maskable interrupts are disabled by clearing the EI bit of register CICR.
2.
The PC (two bytes) and the FLAGS register are saved on the System stack.
3.
The PC is loaded with the 16-bit vector stored in the Vector Table.
On exit from the Interrupt service, using an IRET instruction the following operations are
carried out:
4.
The FLAGR register is restored from the System stack.
5.
The PC is restored from the System stack.
6.
The unmasked interrupts are enabled by setting the CICR.EI bit.
In general additional resources must be saved and restored apart from those handled
automatically by the system as listed above. In a typical case these additional resources will
include the two Register pointer registers, the Page-pointer register, and any working
registers used in the Interrupt routine.
An outline for a suitable Interrupt service routine is hence as follows:
Label_int:
work_reg_page0 = (0Dh*2)



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 43 44 45


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