12.07.2015 Views

RealView - ARM Information Center

RealView - ARM Information Center

RealView - ARM Information Center

SHOW MORE
SHOW LESS
  • No tags were found...

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

使 用 分 散 加 载 描 述 文 件• 加 载 区 至 少 满 足 以 下 条 件 之 一 :— 它 包 含 一 个 按 标 准 分 散 加 载 规 则 与 __at 节 相 匹 配 的 选 择 器— 它 至 少 具 有 一 个 类 型 与 __at 节 相 同 的 节 (RO、RW 或 ZI)— 它 没 有 EMPTY 属 性 。注 意链 接 器 将 类 型 为 RW 的 __at 节 视 为 与 RO 兼 容 。第 5-38 页 的 示 例 5-14 说 明 了 具 有 如 下 类 型 的 节 :.<strong>ARM</strong>.__at_0x0 RO、.<strong>ARM</strong>.__at_0x2000 RW、.<strong>ARM</strong>.__at_0x4000 ZI 和 .<strong>ARM</strong>.__at_0x8000 ZI。示 例 5-14 自 动 放 置 __at 节LR1 0x0{ER_RO 0x0 0x2000{*(+RO) ; .<strong>ARM</strong>.__at_0x0 lies within the bounds of ER_RO}ER_RW 0x2000 0x2000{*(+RW) ; .<strong>ARM</strong>.__at_0x2000 lies within the bounds of ER_RW}ER_ZI 0x4000 0x2000{*(+ZI) ; .<strong>ARM</strong>.__at_0x4000 lies within the bounds of ER_ZI}}; the linker creates a load and execution region for the __at section; .<strong>ARM</strong>.__at_0x8000 because it lies outside all candidate regions.将 键 放 在 闪 存 中某 些 闪 存 设 备 需 要 将 键 写 入 到 地 址 中 以 激 活 某 些 功 能 。 __at 节 提 供 了 一 种 简 单方 法 , 将 值 写 入 到 特 定 地 址 中 。假 定 设 备 的 闪 存 范 围 从 0x8000 到 0x10000, 并 且 需 要 将 键 放 在 地 址 0x9000 中 。 要使 用 __at 节 执 行 此 操 作 , 您 必 须 定 义 一 个 包 含 键 值 的 .<strong>ARM</strong>.__at_0x9000 节 。 例如 :int key __attribute__((__at(0x9000))) = 10;5-38 版 权 所 有 © 2007 <strong>ARM</strong> 公 司 。 保 留 所 有 权 利 。 <strong>ARM</strong> DUI 0349AC

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!