版本 723003abd7ed2fdf99068052ec3b74e91234deb8
Changes from 723003abd7ed2fdf99068052ec3b74e91234deb8 to 209f25d68d02bf9a041266dc815d2c9e5a84c2a1
---
title: Lab28: Extend RTOS
toc: no
...
預期目標
-------
* 擴展 rtenv 的功能:引入 rtenv-plus,一個強化的 rtenv 版本,未來將逐步使其具備商用 RTOS 能力
* 擴展 ``rtenv`` 的功能:引入 ``rtenv-plus``,一個強化的 ``rtenv`` 版本,未來將逐步使其具備商用 RTOS 能力
* 分析 romfs,並實作基本檔案處理
* 整合之前的 unit test
rtenv-plus: 強化的 rtenv
-------------------------
* 成大資訊系 102 級林哲安同學的最新力作
- 基於 https://github.com/embedded2014/rtenv
* 修改項目
- ROM file system offers a read-only file system during compilation
- Various build system improvements
- Fix memcpy error
- Support of block devices
- Fix of memory configuration
- Introduce event monitor technique to handle interrupts
- Efficient I/O encapsulation
* 測試方式
- ``git clone git@github.com:embedded2014/rtenv-plus.git``
* 或者 ``git clone https://github.com:embedded2014/rtenv-plus.git``
- ``cd rtenv-plus``
- ``echo X > data/rom0/X`` # 我們試著在 romfs 放入一個檔名為 "X",內容也是 "X" 的檔案
- ``make``
- ``make qemu``
- 當出現 QEMU 畫面後,在 UART 中輸出 help,預期可見以下:
* xxd: Make a hexdump
- 在 UART 輸入 ``xxd /X``,可見到以下輸出:
* 00000000: 580a X.
- 由此可見,``rtenv-plus`` 提供了一份檔案系統實作,而且可在編譯時期加入到 ``main.bin`` 中。驗證方法:
* ``make clean``
* ``echo NCKU > data/rom0/X``
* ``make``
* 用 vim 打開 ``build/main.bin`` 檔案,或者用以下指令確認:
- ``strings build/main.bin | grep NCKU``