Professional Documents
Culture Documents
ECEN321 - Quiz No5 PDF
ECEN321 - Quiz No5 PDF
Class: …………………………………………………………...
ECEN321
Microcomputer principles and applications
Midterm exam #5
Problem. Write a program in order to make a single sample on A2 with reference to AVcc. If A2 >
0.5*AVcc, P1.6 is set, else reset.
MSP430G2553
-----------------
/|\| XIN|-
| | |
--|RST XOUT|-
| |
>---|P1.2/A2 P1.6|--> LED
Solution: ………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………
……………………………………………………………………………………………………………………………………