⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 readme.txt

📁 摩托罗拉MMC2107在ucosII的移植代码
💻 TXT
字号:
This bundle contains porting of MicroC Operating System (uCOS-II) to M-Core processor (MMC2107).
**************************************************************************************************

To work with the project, unzip the bundle into directory "C:\SOFTWARE" and open the "C:\SOFTWARE\app\standalone.mcp" file with Code Warrior 4.1. Don't forget to add uCOS-II source files and change file paths indicated in "uCOS_II.c" to absolute (just add the drive name), otherwise Code Warrior fails to locate them during preprocessing.



I. File structure
=================
C:SOFTWARE         General Info
	|
	|
	|---uCOS-II      Operation System.
	|     |
	|     |---SOURCE   OS sources (not included; should be purchased separately).
	|     |---MMC2107  OS CPU specific files (actual port).
	|     `---APP      Application specific configuration files (APP could be any name).
	|
	|---MMC2107      MMC2107 drivers*.
	|     |
	|     |---LIB      Motorola General Market CMF Driver for MMC2107 (MMC2107_GMD **).
    |     |---INC      Headers for MMC2107_GMD.
    |     `---CFG      Header containing a number of MMC2107 definitions.
    |
    `----APP         Project files (AD - name of the project; could be any name).
          |
          |---EVB2107  Board Support Package files for Motorola EVB2107 (Rev C) evaluation board.
          |---TASKS    Application tasks (Pulse Width Modulation, Console etc.).
          `---standalone_Data (Code Warrior project configuration directory).

* includes my API's handling MMC2107 Timers that is missing in the General Market Driver. I also added a PWM module (c:\SOFTWARE\AD\TASKS\pwm.c & pwm.h) that uses Timer driver.

** more information about driver is on Motorola MMC2107 site:
   http://e-www.motorola.com/webapp/sps/site/prod_summary.jsp?code=MMC2107&nodeId=01M0ylsb8yr



II. Application components
==========================
The project was built using CodeWarrior 4.1 and tested on Motorola EVB2107 evaluation board, which has 1MB of external SRAM and 2MB of external FLASH. The program is loading into the external SRAM. Vector table stays there. Variables, stacks, heap etc. are initialized in MMC2107 internal SRAM (8 KB !).

Application was assembled from several sources:
- Kerby Suhre's uC/OS-II v2.00 for MMC2001 port.
- Code Warrior Lessons "The Hitchhiker's Guide to Programming M-Core Microcontrollers" on the site:
  http://www.codewarrioru.com/CodeWarriorU.
- Motorola General Market CMF Driver Applications.



III. Program flow
=================
1) Startup
- Vector address initialization (VBR register).
- Stack initialization (including alternative stack for fast interrupts).
- Zero-vars initialization (BSS region).
- Copying of writable initialized data from ROM to RAM.
2) Main
- BSP initialization (System clock 32MHz, Watchdog disabled, Serial 2 on 19200 for console).
- OS initialization.
- Several tasks created (one of them - "Start" - initializes hardware for OS).
- OS started.
3) Tasks
- "Start" task initializes hardware ( Routine "OSTickISR" is assigned to PIT 1 interrupt source, PIT 1 ticks with intervals of 1 ms ) and deletes itself (not necessary, just for test).
- "Monitor" task constantly outputs to console dot characters (".") to indicate time intervals of 1 ms.
- "Pulse" task outputs "|" each time it changes pulse width. Those outputs are only for some visual indication. Real width changes can be detected with oscilloscope on Timer 1 pins (ICOC 10-13 on J53 connector of EVB2107). Task is repeatedly changing the width from 0x0 to 0xF (itterating 0x1 each 2 ms).



IV. Notes
=========
- I understand that the file and code structures are still far from perfect. I will appreciate any suggestions.
- The port does not include a new ISR algorithm. Later on, I will learn this issue and make all necessary changes.
- Makefile support, internal EEPROM load, ADC module are a subjects of future updates.
- In "uCOS_II.c", I changed pathes of included files to absolute paths, otherwise Code Warrior fails to locate them.



V. Contacts
===========
Dmitry Shvarts
+972(2)5411-256
dimash@satec.co.il
Satec, Israel

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -