版本 c346aa2ef3e046ff028eb61a9bc52b13ec48b37c
Changes from c346aa2ef3e046ff028eb61a9bc52b13ec48b37c to current
---
title: Week #4 (Mar 17) :: ARM Exceptions/Interrupts
toc: no
...
重大事項宣達
-------------------
* [贊助學生參加 jjhou 課程](https://www.facebook.com/groups/ncku.embedded2015/permalink/662675613878927/) (Mar 20 前登記)
- C++ Under the Hood (C++ 底層揭密)
- Memory Management (記憶體管理)
- C++11/14 (C++新特性)
- Heap Management in CRT and in Windows (CRT 及 Windows系統中的Heap管理機制)
* 受理一對一面試申請 (修課和旁聽學生都可申請,前者優先處理),作為考試成績
- 請在 2015 年 7 月 5 日前,用 email 約定面談時段 (暑期 intern 應該在 5 月 15 日之前),注意以下:
* 寄送到 Jim Huang (黃敬群) <jserv.tw@gmail.com>
* 標題以 [NCKU/embedded] 開頭,後面加註姓名,依據 [資訊科技產業面試模擬和工作咨詢](/embedded/rehearsal) 的說明提供相關資訊
- 比照資訊科技產業面試的出題方式,本學期上課提及的概念、術語,甚至作業都在涵蓋範圍
* 題目會累積,所以,務必注意時間
* 會有紙上寫程式的要求
* 第 6 周 (3 月 31 日) 確認分組名單與題目志願表,請開始物色隊友
- 3 到 5 人一組,建議不要都是同一個實驗室的成員
- GitHub 和 Hackpad 是你的好朋友,知己知彼
- 期中報告 + 期末專題
面試經驗分享
-------------------
* [資訊科技產業面試模擬和工作咨詢](/embedded/rehearsal)
* 郭俊儀
[Lab-38](/embedded/Lab38) 心得分享
----------------------------------------------------------
* [Fibonacci fast doubling : ARM assembly 實作](http://www.slideshare.net/erickitten/fibonacci-fast-doubling)
- 實做程式碼: https://github.com/erickitten/arm-lecture-1/commits/master
- 程式碼使用到的 ARM 指令 (完整可見 [Quick Reference](http://users.ece.utexas.edu/~valvano/Volume1/QuickReferenceCard.pdf)):
+-------------------+--------------------------+
| ARM instruction | Action |
+===================+==========================+
| CLZ Rd,Rm | Rd = leading zero of Rm |
+-------------------+--------------------------+
| RSB Rd,Rn,<op2> | Rd = <op2> - Rn |
+-------------------+--------------------------+
| MLA Rd,Rm,Rs,Rn | Rd = (Rn+(Rm*Rs)) |
+-------------------+--------------------------+
| CBZ Rn,<label> | if(Rn==0) goto <label> |
+-------------------+--------------------------+
| <op2>:= Rs,LSL,#N | logical shift left N |
+-------------------+--------------------------+
教材
-------
* `ARM Cortex-M3 Introduction<http://www.arm.com/files/pdf/CortexM3_Uni_Intro.pdf>`_ (概念)
- `ARM Cortex-M3<http://www.slideshare.net/GauravVerma3/arm-cortex-processor-compatibility-mode>`_ (詳細解說)
- `Assembly language programming: ARM Cortex-M3<http://www.slideshare.net/GonzaloSantiago/assembly-language-programming-arm-cortexm3-vincent-mahout>`_
* [ARM Cortex-M3 Introduction](http://www.arm.com/files/pdf/CortexM3_Uni_Intro.pdf) (概念)
- [ARM Cortex-M3](http://www.slideshare.net/GauravVerma3/arm-cortex-processor-compatibility-mode) (詳細解說)
- [Assembly language programming: ARM Cortex-M3](http://www.slideshare.net/GonzaloSantiago/assembly-language-programming-arm-cortexm3-vincent-mahout)
* `淺談優先權,從 ARM Cortex-M 到 FreeRTOS 設定<http://enginechang.logdown.com/posts/248297-talking-about-the-priority-from-the-arm-set-cortex-m-to-freertos>`_
* 共筆: [FreeRTOS](http://wiki.csie.ncku.edu.tw/embedded/freertos)
* [淺談優先權,從 ARM Cortex-M 到 FreeRTOS 設定](http://enginechang.logdown.com/posts/248297-talking-about-the-priority-from-the-arm-set-cortex-m-to-freertos)
- 什麼是 Interrupt?
- NVIC (Nested vectored interrupt controller)
- ARM Cortex-M 每個 Exception 都有自己的優先權
- 不同架構有不同數量的優先權
- FreeRTOS 的優先權
- FreeRTOS 的 Tick/Timer
* `Introduction: the ARM Cortex-M3 Exception / Interrupt</embedded/arm-exceptions.pdf>`_
- `Interrupt-Driven Input/Output<http://www.eng.auburn.edu/~nelson/courses/elec2220/Interrupt_IO%20part2.pdf>`_
* [Introduction: the ARM Cortex-M3 Exception / Interrupt](/embedded/arm-exceptions.pdf)
- [Interrupt-Driven Input/Output](/embedded/2015q1w4/interrupt_part2.pdf)
* Interrupt vectors and vector table
* Interrupt masks and priorities
* NVIC
* STM32F4 external interrupt signals
- 延伸閱讀: 共筆 [GPIO](/embedded/GPIO) + [ADC](/embedded/ADC) (找 NVIC)
作業須知 (Lab-40)
----------------
* 作業描述: Lab 40
* 作業描述: [Lab 40](/embedded/Lab40)
* 截止日期: Mar 28, 2015 (含) 之前