QUESTION 1 (100 Points):
In this assignment, you are expected to write a timer interrupt program which include milliseconds delay function. In order to calculate accurate delay function, you can use the timer interrupt and specify it call each millisecond. Structure of program and constraints for each approach are given below.
- Complete structure of code giving as a pseudo code manner. Syntax of program is not important.
Only approach of you will be grade. (20 Points)
- Implement your pseudo code. The program must be implemented with Arm Cortex M0+ assembly language. (80 Points)
- You must implement all functions in the program using same function name, parameters and return value type.
- Your main function name or label must be “__main”.
- You mustn’t change main function. Your program must do it.
- Your code should include a comment for each line. Otherwise, points will be deducted.
- If you need to use any value or address, please specify it in comments line.
- If you need to calculate any value, please write your formula and explain it step by step as a comment.
- Assume the clock frequency of microcontroller is 72Mhz.
- Your assembly source file is expected to work with Keil µVision IDE v5.
- Default configuration must be sufficient to run your programs. If your program expects any different configuration parameter, please write this at the top of the code in comment lines.
Submission: Please submit a C file for pseudo code and an assembly file for the implementation of the program. Type your name and student ID at the top of the file as comments. You are expected to submit your homework through the Ninova system before the due date. Late submissions will not be accepted.
Any solution must be your own work. If any plagiarism is detected, disciplinary regulations of the university will be followed.
Note: If you have any question regarding the homework, you may contact to teaching assistant of the course ( [email protected] ). All questions and answers related to this homework will be shared in a Word file on ninova system. Please check this file regularly.
Q&A Document URL: https://www.dropbox.com/s/e2mua7to683pink/Homework2-Q%26A.docx?dl=0