41081 Chapter Notes - Chapter 4: Global Variable, Interrupt

43 views2 pages
5 Jun 2018
School
Department
Course
Professor
Chapter 4 Time intervals
Time-Interval Behaviour
Time-interval behaviour is system functionality where events must be separated by
specified intervals of real time.
A tie iterval a e related to a eedded sste’s iput i additio to its
output.
Synchronous SMs
The tick rate of an SM can be set to a specific time interval, known as the period.
SMs with a specific period are known as synchronous SMs.
In between ticks, the system is inactive. During this time, variables maintain their
values.
Choosing a Period for Different Time Intervals
Choose the period as the greatest common divisor and then use multiple states to
obtain the actual desired interval. A count function can also be used where a
variable is incremented with each state transition.
Microcontrollers with Timers
A timer is a hardware component that can be programmed to tick at a user-specified
rate.
When the timer ticks, the hardware interrupts the program execution with an ISR
(Interrupt Service Routine) which will execute the TimerISR function before
resuming the main program.
TimerSet(period) is used to set the timer duration in milliseconds, and TimerOn()
activates the timer.
A flag is a global variable used by the program to communicate basic status info.
find more resources at oneclass.com
find more resources at oneclass.com
Unlock document

This preview shows half of the first page of the document.
Unlock all 2 pages and 3 million more documents.

Already have an account? Log in

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents