README.hardware 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436
  1. Poky Hardware Reference Guide
  2. =============================
  3. This file gives details about using Poky with different hardware reference
  4. boards and consumer devices. A full list of target machines can be found by
  5. looking in the meta/conf/machine/ directory. If in doubt about using Poky with
  6. your hardware, consult the documentation for your board/device. To discuss
  7. support for further hardware reference boards/devices please contact OpenedHand.
  8. QEMU Emulation Images (qemuarm and qemux86)
  9. ===========================================
  10. To simplify development Poky supports building images to work with the QEMU
  11. emulator in system emulation mode. Two architectures are currently supported,
  12. ARM (via qemuarm) and x86 (via qemux86). Use of the QEMU images is covered
  13. in the Poky Handbook.
  14. Hardware Reference Boards
  15. =========================
  16. The following boards are supported by Poky:
  17. * Compulab CM-X270 (cm-x270)
  18. * Compulab EM-X270 (em-x270)
  19. * FreeScale iMX31ADS (mx31ads)
  20. * Marvell PXA3xx Zylonite (zylonite)
  21. * Logic iMX31 Lite Kit (mx31litekit)
  22. * Phytec phyCORE-iMX31 (mx31phy)
  23. For more information see board's section below. The Poky MACHINE setting
  24. corresponding to the board is given in brackets.
  25. Consumer Devices
  26. ================
  27. The following consumer devices are supported by Poky:
  28. * FIC Neo1973 GTA01 smartphone (fic-gta01)
  29. * HTC Universal (htcuniversal)
  30. * Nokia 770/N800/N810 Internet Tablets (nokia770 and nokia800)
  31. * Sharp Zaurus SL-C7x0 series (c7x0)
  32. * Sharp Zaurus SL-C1000 (akita)
  33. * Sharp Zaurus SL-C3x00 series (spitz)
  34. For more information see board's section below. The Poky MACHINE setting
  35. corresponding to the board is given in brackets.
  36. Poky Boot CD (bootcdx86)
  37. ========================
  38. The Poky boot CD iso images are designed as a demonstration of the Poky
  39. environment and to show the versatile image formats Poky can generate. It will
  40. run on Pentium2 or greater PC style computers. The iso image can be
  41. burnt to CD and then booted from.
  42. Hardware Reference Boards
  43. =========================
  44. Compulab CM-X270 (cm-x270)
  45. ==========================
  46. The bootloader on this board doesn't support writing jffs2 images directly to
  47. NAND and normally uses a proprietary kernel flash driver. To allow the use of
  48. jffs2 images, a two stage updating procedure is needed. Firstly, an initramfs
  49. is booted which contains mtd utilities and this is then used to write the main
  50. filesystem.
  51. It is assumed the board is connected to a network where a TFTP server is
  52. available and that a serial terminal is available to communicate with the
  53. bootloader (38400, 8N1). If a DHCP server is available the device will use it
  54. to obtain an IP address. If not, run:
  55. ARMmon > setip dhcp off
  56. ARMmon > setip ip 192.168.1.203
  57. ARMmon > setip mask 255.255.255.0
  58. To reflash the kernel:
  59. ARMmon > download kernel tftp zimage 192.168.1.202
  60. ARMmon > flash kernel
  61. where zimage is the name of the kernel on the TFTP server and its IP address is
  62. 192.168.1.202. The names of the files must be all lowercase.
  63. To reflash the initrd/initramfs:
  64. ARMmon > download ramdisk tftp diskimage 192.168.1.202
  65. ARMmon > flash ramdisk
  66. where diskimage is the name of the initramfs image (a cpio.gz file).
  67. To boot the initramfs:
  68. ARMmon > ramdisk on
  69. ARMmon > bootos "console=ttyS0,38400 rdinit=/sbin/init"
  70. To reflash the main image login to the system as user "root", then run:
  71. # ifconfig eth0 192.168.1.203
  72. # tftp -g -r mainimage 192.168.1.202
  73. # flash_eraseall /dev/mtd1
  74. # nandwrite /dev/mtd1 mainimage
  75. which configures the network interface with the IP address 192.168.1.203,
  76. downloads the "mainimage" file from the TFTP server at 192.168.1.202, erases
  77. the flash and then writes the new image to the flash.
  78. The main image can then be booted with:
  79. ARMmon > bootos "console=ttyS0,38400 root=/dev/mtdblock1 rootfstype=jffs2"
  80. Note that the initramfs image is built by poky in a slightly different mode to
  81. normal since it uses uclibc. To generate this use a command like:
  82. IMAGE_FSTYPES=cpio.gz MACHINE=cm-x270 POKYLIBC=uclibc bitbake poky-image-minimal-mtdutils
  83. Compulab EM-X270 (em-x270)
  84. ==========================
  85. Fetch the "Linux - kernel and run-time image (Angstrom)" ZIP file from the
  86. Compulab website. Inside the images directory of this ZIP file is another ZIP
  87. file called 'LiveDisk.zip'. Extract this over a cleanly formatted vfat USB flash
  88. drive. Replace the 'em_x270.img' file with the 'updater-em-x270.ext2' file.
  89. Insert this USB disk into the supplied adapter and connect this to the
  90. board. Whilst holding down the the suspend button press the reset button. The
  91. board will now boot off the USB key and into a version of Angstrom. On the
  92. desktop is an icon labelled "Updater". Run this program to launch the updater
  93. that will flash the Poky kernel and rootfs to the board.
  94. FreeScale iMX31ADS (mx31ads)
  95. ===========================
  96. The correct serial port is the top-most female connector to the right of the
  97. ethernet socket.
  98. For uploading data to RedBoot we are going to use tftp. In this example we
  99. assume that the tftpserver is on 192.168.9.1 and the board is on192.168.9.2.
  100. To set the IP address, run:
  101. ip_address -l 192.168.9.2/24 -h 192.168.9.1
  102. To download a kernel called "zimage" from the TFTP server, run:
  103. load -r -b 0x100000 zimage
  104. To write the kernel to flash run:
  105. fis create kernel
  106. To download a rootfs jffs2 image "rootfs" from the TFTP server, run:
  107. load -r -b 0x100000 rootfs
  108. To write the root filesystem to flash run:
  109. fis create root
  110. To load and boot a kernel and rootfs from flash:
  111. fis load kernel
  112. exec -b 0x100000 -l 0x200000 -c "noinitrd console=ttymxc0,115200 root=/dev/mtdblock2 rootfstype=jffs2 init=linuxrc ip=none"
  113. To load and boot a kernel from a TFTP server with the rootfs over NFS:
  114. load -r -b 0x100000 zimage
  115. exec -b 0x100000 -l 0x200000 -c "noinitrd console=ttymxc0,115200 root=/dev/nfs nfsroot=192.168.9.1:/mnt/nfsmx31 rw ip=192.168.9.2::192.168.9.1:255.255.255.0"
  116. The instructions above are for using the (default) NOR flash on the board,
  117. there is also 128M of NAND flash. It is possible to install Poky to the NAND
  118. flash which gives more space for the rootfs and instructions for using this are
  119. given below. To switch to the NAND flash:
  120. factive NAND
  121. This will then restart RedBoot using the NAND rather than the NOR. If you
  122. have not used the NAND before then it is unlikely that there will be a
  123. partition table yet. You can get the list of partitions with 'fis list'.
  124. If this shows no partitions then you can create them with:
  125. fis init
  126. The output of 'fis list' should now show:
  127. Name FLASH addr Mem addr Length Entry point
  128. RedBoot 0xE0000000 0xE0000000 0x00040000 0x00000000
  129. FIS directory 0xE7FF4000 0xE7FF4000 0x00003000 0x00000000
  130. RedBoot config 0xE7FF7000 0xE7FF7000 0x00001000 0x00000000
  131. Partitions for the kernel and rootfs need to be created:
  132. fis create -l 0x1A0000 -e 0x00100000 kernel
  133. fis create -l 0x5000000 -e 0x00100000 root
  134. You may now use the instructions above for flashing. However it is important
  135. to note that the erase block size for the NAND is different to the NOR so the
  136. JFFS erase size will need to be changed to 0x4000. Stardard images are built
  137. for NOR and you will need to build custom images for NAND.
  138. You will also need to update the kernel command line to use the correct root
  139. filesystem. This should be '/dev/mtdblock7' if you adhere to the partitioning
  140. scheme shown above. If this fails then you can doublecheck against the output
  141. from the kernel when it evaluates the available mtd partitions.
  142. Marvell PXA3xx Zylonite (zylonite)
  143. ==================================
  144. These instructions assume the Zylonite is connected to a machine running a TFTP
  145. server at address 192.168.123.5 and that a serial link (38400 8N1) is available
  146. to access the blob bootloader. The kernel is on the TFTP server as
  147. "zylonite-kernel" and the root filesystem jffs2 file is "zylonite-rootfs" and
  148. the images are to be saved in NAND flash.
  149. The following commands setup blob:
  150. blob> setip client 192.168.123.4
  151. blob> setip server 192.168.123.5
  152. To flash the kernel:
  153. blob> tftp zylonite-kernel
  154. blob> nandwrite -j 0x80800000 0x60000 0x200000
  155. To flash the rootfs:
  156. blob> tftp zylonite-rootfs
  157. blob> nanderase -j 0x260000 0x5000000
  158. blob> nandwrite -j 0x80800000 0x260000 <length>
  159. (where <length> is the rootfs size which will be printed by the tftp step)
  160. To boot the board:
  161. blob> nkernel
  162. blob> boot
  163. Logic iMX31 Lite Kit (mx31litekit)
  164. ===============================
  165. The easiest method to boot this board is to take an MMC/SD card and format
  166. the first partition as ext2, then extract the poky image onto this as root.
  167. Assuming the board is network connected, a TFTP server is available at
  168. 192.168.1.33 and a serial terminal is available (115200 8N1), the following
  169. commands will boot a kernel called "mx31kern" from the TFTP server:
  170. losh> ifconfig sm0 192.168.1.203 255.255.255.0 192.168.1.33
  171. losh> load raw 0x80100000 0x200000 /tftp/192.168.1.33:mx31kern
  172. losh> exec 0x80100000 -
  173. Phytec phyCORE-iMX31 (mx31phy)
  174. ==============================
  175. Support for this board is currently being developed. Experimental jffs2
  176. images and a suitable kernel are available and are known to work with the
  177. board.
  178. Consumer Devices
  179. ================
  180. FIC Neo1973 GTA01 smartphone (fic-gta01)
  181. ========================================
  182. To install Poky on a GTA01 smartphone you will need "dfu-util" tool
  183. which you can build with "bitbake dfu-util-native" command.
  184. Flashing requires these steps:
  185. 1. Power down the device.
  186. 2. Connect the device to the host machine via USB.
  187. 3. Hold AUX key and press Power key. There should be a bootmenu
  188. on screen.
  189. 4. Run "dfu-util -l" to check if the phone is visible on the USB bus.
  190. The output should look like this:
  191. dfu-util - (C) 2007 by OpenMoko Inc.
  192. This program is Free Software and has ABSOLUTELY NO WARRANTY
  193. Found Runtime: [0x1457:0x5119] devnum=19, cfg=0, intf=2, alt=0, name="USB Device Firmware Upgrade"
  194. 5. Flash the kernel with "dfu-util -a kernel -D uImage-2.6.21.6-moko11-r2-fic-gta01.bin"
  195. 6. Flash rootfs with "dfu-util -a rootfs -D <image>", where <image> is the
  196. jffs2 image file to use as the root filesystem
  197. (e.g. ./tmp/deploy/images/poky-image-sato-fic-gta01.jffs2)
  198. HTC Universal (htcuniversal)
  199. ============================
  200. Note: HTC Universal support is highly experimental.
  201. On the HTC Universal, entirely replacing the Windows installation is not
  202. supported, instead Poky is booted from an MMC/SD card from Windows. Once Poky
  203. has booted, Windows is no longer in memory or active but when power is removed,
  204. the user will be returned to windows and will need to return to Linux from
  205. there.
  206. Once an MMC/SD card is available it is suggested its split into two partitions,
  207. one for a program called HaRET which lets you boot Linux from within Windows
  208. and the second for the rootfs. The HaRET partition should be the first partition
  209. on the card and be vfat formatted. It doesn't need to be large, just enough for
  210. HaRET and a kernel (say 5MB max). The rootfs should be ext2 and is usually the
  211. second partition. The first partition should be vfat so Windows recognises it
  212. as if it doesn't, it has been known to reformat cards.
  213. On the first partition you need three files:
  214. * a HaRET binary (version 0.5.1 works well and a working version
  215. should be part of the last Poky release)
  216. * a kernel renamed to "zImage"
  217. * a default.txt which contains:
  218. set kernel "zImage"
  219. set mtype "855"
  220. set cmdline "root=/dev/mmcblk0p2 rw console=ttyS0,115200n8 console=tty0 rootdelay=5 fbcon=rotate:1"
  221. boot2
  222. On the second parition the root file system is extracted as root. A different
  223. partition layout or other kernel options can be changed in the default.txt file.
  224. When inserted into the device, Windows should see the card and let you browse
  225. its contents using File Explorer. Running the HaRET binary will present a dialog
  226. box (maybe after messages warning about running unsigned binaries) where you
  227. select OK and you should then see Poky boot. Kernel messages can be seen by
  228. adding psplash=false to the kernel commandline.
  229. Nokia 770/N800/N810 Internet Tablets (nokia770 and nokia800)
  230. ============================================================
  231. Note: Nokia tablet support is highly experimental.
  232. The Nokia internet tablet devices are OMAP based tablet formfactor devices
  233. with large screens (800x480), wifi and touchscreen.
  234. To flash images to these devices you need the "flasher" utility which can be
  235. downloaded from the http://tablets-dev.nokia.com/d3.php?f=flasher-3.0. This
  236. utility needs to be run as root and the usb filesystem needs to be mounted
  237. although most distributions will have done this for you. Once you have this
  238. follow these steps:
  239. 1. Power down the device.
  240. 2. Connect the device to the host machine via USB
  241. (connecting power to the device doesn't hurt either).
  242. 3. Run "flasher -i"
  243. 4. Power on the device.
  244. 5. The program should give an indication it's found
  245. a tablet device. If not, recheck the cables, make sure you're
  246. root and usbfs/usbdevfs is mounted.
  247. 6. Run "flasher -r <image> -k <kernel> -f", where <image> is the
  248. jffs2 image file to use as the root filesystem
  249. (e.g. ./tmp/deploy/images/poky-image-sato-nokia800.jffs2)
  250. and <kernel> is the kernel to use
  251. (e.g. ./tmp/deploy/images/zImage-nokia800.bin).
  252. 7. Run "flasher -R" to reboot the device.
  253. 8. The device should boot into Poky.
  254. The nokia800 images and kernel will run on both the N800 and N810.
  255. Sharp Zaurus SL-C7x0 series (c7x0)
  256. ==================================
  257. The Sharp Zaurus c7x0 series (SL-C700, SL-C750, SL-C760, SL-C860, SL-7500)
  258. are PXA25x based handheld PDAs with VGA screens. To install Poky images on
  259. these devices follow these steps:
  260. 1. Obtain an SD/MMC or CF card with a vfat or ext2 filesystem.
  261. 2. Copy a jffs2 image file (e.g. poky-image-sato-c7x0.jffs2) onto the
  262. card as "initrd.bin":
  263. $ cp ./tmp/deploy/images/poky-image-sato-c7x0.jffs2 /path/to/my-cf-card/initrd.bin
  264. 3. Copy an Linux kernel file (zImage-c7x0.bin) onto the card as
  265. "zImage.bin":
  266. $ cp ./tmp/deploy/images/zImage-c7x0.bin /path/to/my-cf-card/zImage.bin
  267. 4. Copy an updater script (updater.sh.c7x0) onto the card
  268. as "updater.sh":
  269. $ cp ./tmp/deploy/images/updater.sh.c7x0 /path/to/my-cf-card/updater.sh
  270. 5. Power down the Zaurus.
  271. 6. Hold "OK" key and power on the device. An update menu should appear
  272. (in Japanese).
  273. 7. Choose "Update" (item 4).
  274. 8. The next screen will ask for the source, choose the appropriate
  275. card (CF or SD).
  276. 9. Make sure AC power is connected.
  277. 10. The next screen asks for confirmation, choose "Yes" (the left button).
  278. 11. The update process will start, flash the files on the card onto
  279. the device and the device will then reboot into Poky.
  280. Sharp Zaurus SL-C1000 (akita)
  281. =============================
  282. The Sharp Zaurus SL-C1000 is a PXA270 based device otherwise similar to the
  283. c7x0. To install Poky images on this device follow the instructions for
  284. the c7x0 but replace "c7x0" with "akita" where appropriate.
  285. Sharp Zaurus SL-C3x00 series (spitz)
  286. ====================================
  287. The Sharp Zaurus SL-C3x00 devices are PXA270 based devices similar
  288. to akita but with an internal microdrive. The installation procedure
  289. assumes a standard microdrive based device where the root (first)
  290. partition has been enlarged to fit the image (at least 100MB,
  291. 400MB for the SDK).
  292. The procedure is the same as for the c7x0 and akita models with the
  293. following differences:
  294. 1. Instead of a jffs2 image you need to copy a compressed tarball of the
  295. root fileystem (e.g. poky-image-sato-spitz.tar.gz) onto the
  296. card as "hdimage1.tgz":
  297. $ cp ./tmp/deploy/images/poky-image-sato-spitz.tar.gz /path/to/my-cf-card/hdimage1.tgz
  298. 2. You additionally need to copy a special tar utility (gnu-tar) onto
  299. the card as "gnu-tar":
  300. $ cp ./tmp/deploy/images/gnu-tar /path/to/my-cf-card/gnu-tar