{
 "嵌入式 Linux 是什麼?與桌面 Linux 的差異#5": {
  "type": "table",
  "reveal": [
   0,
   1,
   2,
   2
  ],
  "head": [
   "項目",
   "桌面/伺服器",
   "嵌入式"
  ],
  "rows": [
   [
    "CPU 架構",
    "x86_64",
    "ARM、ARM64、RISC-V、MIPS"
   ],
   [
    "安裝方式",
    "下載映像、安裝精靈",
    "自己建置、燒錄"
   ]
  ]
 },
 "嵌入式 Linux 是什麼?與桌面 Linux 的差異#6": {
  "type": "table",
  "reveal": [
   0,
   1,
   2,
   3
  ],
  "head": [
   "項目",
   "桌面/伺服器",
   "嵌入式"
  ],
  "rows": [
   [
    "套件管理",
    "APT、DNF",
    "常常沒有"
   ],
   [
    "開機程式",
    "GRUB + UEFI",
    "U-Boot"
   ],
   [
    "硬體描述",
    "ACPI、PCI 探測",
    "裝置樹"
   ]
  ]
 },
 "嵌入式 Linux 是什麼?與桌面 Linux 的差異#7": {
  "type": "table",
  "reveal": [
   0,
   1,
   2
  ],
  "head": [
   "項目",
   "桌面/伺服器",
   "嵌入式"
  ],
  "rows": [
   [
    "編譯方式",
    "本機直接編譯",
    "PC 上交叉編譯"
   ],
   [
    "更新方式",
    "apt upgrade",
    "OTA + A/B 雙分區"
   ]
  ]
 },
 "硬體平台:SoC、記憶體、儲存與周邊#2": {
  "type": "table",
  "reveal": [
   0,
   1,
   2,
   3,
   4
  ],
  "head": [
   "儲存媒介",
   "特性"
  ],
  "rows": [
   [
    "RAM",
    "執行時的工作空間"
   ],
   [
    "SD 卡",
    "便宜方便,寫入次數有限"
   ],
   [
    "eMMC",
    "焊在板上,可靠度較高"
   ],
   [
    "NOR / NAND",
    "容量小、成本低,要磨損均衡"
   ]
  ],
  "widths": [
   2,
   4
  ]
 },
 "硬體平台:SoC、記憶體、儲存與周邊#3": {
  "type": "cards",
  "reveal": [
   0,
   1,
   2,
   3
  ],
  "cards": [
   {
    "title": "UART",
    "points": [
     "序列埠",
     "TX、RX、GND 三條線",
     "除錯主控台首選"
    ]
   },
   {
    "title": "GPIO",
    "points": [
     "通用輸入輸出",
     "控制 LED",
     "讀取按鈕"
    ]
   },
   {
    "title": "I2C",
    "points": [
     "兩條線:資料、時脈",
     "連接感測器",
     "每個裝置有位址"
    ]
   }
  ]
 },
 "硬體平台:SoC、記憶體、儲存與周邊#5": {
  "type": "table",
  "reveal": [
   0,
   1,
   2,
   3
  ],
  "head": [
   "項目",
   "注意事項"
  ],
  "rows": [
   [
    "GPIO 電壓",
    "3.3 V 邏輯,不可直接接 5 V"
   ],
   [
    "LED",
    "串聯限流電阻 220 Ω~1 kΩ"
   ],
   [
    "USB 轉 TTL",
    "3.3 V 準位,TX/RX 交叉接"
   ]
  ],
  "widths": [
   2,
   4
  ]
 },
 "硬體平台:SoC、記憶體、儲存與周邊#7": {
  "type": "table",
  "reveal": [
   0,
   1,
   2,
   3,
   4
  ],
  "head": [
   "指令",
   "用途"
  ],
  "rows": [
   [
    "cat /proc/cpuinfo",
    "處理器資訊"
   ],
   [
    "cat /proc/meminfo | head -3",
    "記憶體大小"
   ],
   [
    "lsblk",
    "儲存裝置與分割區"
   ],
   [
    "uname -m",
    "機器架構"
   ]
  ],
  "widths": [
   4,
   3
  ]
 },
 "開機流程:從上電到 shell#1": {
  "type": "flow",
  "layout": "snake",
  "reveal": [
   0,
   0,
   6,
   6
  ],
  "nodes": [
   {
    "label": "Boot ROM",
    "color": 0
   },
   {
    "label": "第一階段",
    "sub": "bootloader",
    "color": 1
   },
   {
    "label": "U-Boot",
    "color": 2
   },
   {
    "label": "Linux kernel",
    "color": 0
   },
   {
    "label": "init",
    "sub": "PID 1",
    "color": 1
   },
   {
    "label": "使用者空間",
    "color": 2,
    "kind": "end"
   }
  ]
 },
 "開機流程:從上電到 shell#2": {
  "type": "flow",
  "layout": "row",
  "reveal": [
   0,
   1,
   2,
   3,
   4
  ],
  "nodes": [
   {
    "label": "Boot ROM",
    "sub": "固化在晶片",
    "color": 0
   },
   {
    "label": "SPL",
    "sub": "初始化記憶體",
    "color": 1
   },
   {
    "label": "U-Boot",
    "sub": "載入 kernel、DTB",
    "color": 2
   },
   {
    "label": "kernel",
    "sub": "掛載根檔案系統",
    "color": 0,
    "kind": "end"
   }
  ]
 },
 "開機流程:從上電到 shell#4": {
  "type": "flow",
  "layout": "row",
  "reveal": [
   0,
   2,
   3
  ],
  "nodes": [
   {
    "label": "GPU 韌體",
    "sub": "存在 EEPROM",
    "color": 0
   },
   {
    "label": "讀 boot 分區",
    "sub": "config.txt、kernel、DTB",
    "color": 1
   },
   {
    "label": "啟動 CPU",
    "sub": "不一定經過 U-Boot",
    "color": 2,
    "kind": "end"
   }
  ]
 },
 "開機流程:從上電到 shell#5": {
  "type": "table",
  "reveal": [
   0,
   1,
   2,
   3,
   4,
   5
  ],
  "head": [
   "參數",
   "作用"
  ],
  "rows": [
   [
    "console",
    "主控台輸出的序列裝置"
   ],
   [
    "root",
    "根檔案系統所在裝置"
   ],
   [
    "rootwait",
    "等儲存裝置出現再掛載"
   ],
   [
    "ro / rw",
    "唯讀或可讀寫掛載"
   ],
   [
    "init",
    "指定第一個行程"
   ]
  ],
  "widths": [
   2,
   4
  ]
 },
 "嵌入式 Linux 系統的四大元件#1": {
  "type": "cards",
  "reveal": [
   0,
   1,
   2,
   3,
   4
  ],
  "cards": [
   {
    "title": "工具鏈",
    "points": [
     "在 PC 上產生",
     "目標板的程式"
    ]
   },
   {
    "title": "Bootloader",
    "points": [
     "如 U-Boot",
     "啟動 kernel"
    ]
   },
   {
    "title": "Kernel",
    "points": [
     "驅動程式",
     "裝置樹"
    ]
   },
   {
    "title": "根檔案系統",
    "points": [
     "C 函式庫、BusyBox",
     "init、設定檔、應用程式"
    ]
   }
  ]
 },
 "嵌入式 Linux 系統的四大元件#2": {
  "type": "table",
  "reveal": [
   1,
   2,
   3,
   4,
   4
  ],
  "head": [
   "做法",
   "特色"
  ],
  "rows": [
   [
    "手工打造",
    "全部自己來"
   ],
   [
    "Buildroot",
    "學習曲線平緩,建置快"
   ],
   [
    "Yocto",
    "功能最完整,適合長期維護"
   ],
   [
    "現成發行版",
    "做原型最快"
   ]
  ],
  "widths": [
   2,
   4
  ]
 },
 "嵌入式 Linux 系統的四大元件#7": {
  "type": "flow",
  "layout": "cycle",
  "reveal": [
   0,
   1,
   2,
   4
  ],
  "nodes": [
   {
    "label": "PC 建置",
    "sub": "Buildroot / Yocto",
    "color": 0
   },
   {
    "label": "送到板子",
    "sub": "SD 卡或網路",
    "color": 1
   },
   {
    "label": "板上執行",
    "color": 2
   },
   {
    "label": "看回結果",
    "sub": "序列、SSH、GDB",
    "color": 0,
    "kind": "end"
   }
  ]
 }
}