Assabet 8.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301
  1. The Intel Assabet (SA-1110 evaluation) board
  2. ============================================
  3. Please see:
  4. http://developer.intel.com
  5. Also some notes from John G Dorsey <jd5q@andrew.cmu.edu>:
  6. http://www.cs.cmu.edu/~wearable/software/assabet.html
  7. Building the kernel
  8. -------------------
  9. To build the kernel with current defaults:
  10. make assabet_config
  11. make oldconfig
  12. make zImage
  13. The resulting kernel image should be available in linux/arch/arm/boot/zImage.
  14. Installing a bootloader
  15. -----------------------
  16. A couple of bootloaders able to boot Linux on Assabet are available:
  17. BLOB (http://www.lartmaker.nl/lartware/blob/)
  18. BLOB is a bootloader used within the LART project. Some contributed
  19. patches were merged into BLOB to add support for Assabet.
  20. Compaq's Bootldr + John Dorsey's patch for Assabet support
  21. (http://www.handhelds.org/Compaq/bootldr.html)
  22. (http://www.wearablegroup.org/software/bootldr/)
  23. Bootldr is the bootloader developed by Compaq for the iPAQ Pocket PC.
  24. John Dorsey has produced add-on patches to add support for Assabet and
  25. the JFFS filesystem.
  26. RedBoot (http://sources.redhat.com/redboot/)
  27. RedBoot is a bootloader developed by Red Hat based on the eCos RTOS
  28. hardware abstraction layer. It supports Assabet amongst many other
  29. hardware platforms.
  30. RedBoot is currently the recommended choice since it's the only one to have
  31. networking support, and is the most actively maintained.
  32. Brief examples on how to boot Linux with RedBoot are shown below. But first
  33. you need to have RedBoot installed in your flash memory. A known to work
  34. precompiled RedBoot binary is available from the following location:
  35. ftp://ftp.netwinder.org/users/n/nico/
  36. ftp://ftp.arm.linux.org.uk/pub/linux/arm/people/nico/
  37. ftp://ftp.handhelds.org/pub/linux/arm/sa-1100-patches/
  38. Look for redboot-assabet*.tgz. Some installation infos are provided in
  39. redboot-assabet*.txt.
  40. Initial RedBoot configuration
  41. -----------------------------
  42. The commands used here are explained in The RedBoot User's Guide available
  43. on-line at http://sources.redhat.com/ecos/docs.html.
  44. Please refer to it for explanations.
  45. If you have a CF network card (my Assabet kit contained a CF+ LP-E from
  46. Socket Communications Inc.), you should strongly consider using it for TFTP
  47. file transfers. You must insert it before RedBoot runs since it can't detect
  48. it dynamically.
  49. To initialize the flash directory:
  50. fis init -f
  51. To initialize the non-volatile settings, like whether you want to use BOOTP or
  52. a static IP address, etc, use this command:
  53. fconfig -i
  54. Writing a kernel image into flash
  55. ---------------------------------
  56. First, the kernel image must be loaded into RAM. If you have the zImage file
  57. available on a TFTP server:
  58. load zImage -r -b 0x100000
  59. If you rather want to use Y-Modem upload over the serial port:
  60. load -m ymodem -r -b 0x100000
  61. To write it to flash:
  62. fis create "Linux kernel" -b 0x100000 -l 0xc0000
  63. Booting the kernel
  64. ------------------
  65. The kernel still requires a filesystem to boot. A ramdisk image can be loaded
  66. as follows:
  67. load ramdisk_image.gz -r -b 0x800000
  68. Again, Y-Modem upload can be used instead of TFTP by replacing the file name
  69. by '-y ymodem'.
  70. Now the kernel can be retrieved from flash like this:
  71. fis load "Linux kernel"
  72. or loaded as described previously. To boot the kernel:
  73. exec -b 0x100000 -l 0xc0000
  74. The ramdisk image could be stored into flash as well, but there are better
  75. solutions for on-flash filesystems as mentioned below.
  76. Using JFFS2
  77. -----------
  78. Using JFFS2 (the Second Journalling Flash File System) is probably the most
  79. convenient way to store a writable filesystem into flash. JFFS2 is used in
  80. conjunction with the MTD layer which is responsible for low-level flash
  81. management. More information on the Linux MTD can be found on-line at:
  82. http://www.linux-mtd.infradead.org/. A JFFS howto with some infos about
  83. creating JFFS/JFFS2 images is available from the same site.
  84. For instance, a sample JFFS2 image can be retrieved from the same FTP sites
  85. mentioned below for the precompiled RedBoot image.
  86. To load this file:
  87. load sample_img.jffs2 -r -b 0x100000
  88. The result should look like:
  89. RedBoot> load sample_img.jffs2 -r -b 0x100000
  90. Raw file loaded 0x00100000-0x00377424
  91. Now we must know the size of the unallocated flash:
  92. fis free
  93. Result:
  94. RedBoot> fis free
  95. 0x500E0000 .. 0x503C0000
  96. The values above may be different depending on the size of the filesystem and
  97. the type of flash. See their usage below as an example and take care of
  98. substituting yours appropriately.
  99. We must determine some values:
  100. size of unallocated flash: 0x503c0000 - 0x500e0000 = 0x2e0000
  101. size of the filesystem image: 0x00377424 - 0x00100000 = 0x277424
  102. We want to fit the filesystem image of course, but we also want to give it all
  103. the remaining flash space as well. To write it:
  104. fis unlock -f 0x500E0000 -l 0x2e0000
  105. fis erase -f 0x500E0000 -l 0x2e0000
  106. fis write -b 0x100000 -l 0x277424 -f 0x500E0000
  107. fis create "JFFS2" -n -f 0x500E0000 -l 0x2e0000
  108. Now the filesystem is associated to a MTD "partition" once Linux has discovered
  109. what they are in the boot process. From Redboot, the 'fis list' command
  110. displays them:
  111. RedBoot> fis list
  112. Name FLASH addr Mem addr Length Entry point
  113. RedBoot 0x50000000 0x50000000 0x00020000 0x00000000
  114. RedBoot config 0x503C0000 0x503C0000 0x00020000 0x00000000
  115. FIS directory 0x503E0000 0x503E0000 0x00020000 0x00000000
  116. Linux kernel 0x50020000 0x00100000 0x000C0000 0x00000000
  117. JFFS2 0x500E0000 0x500E0000 0x002E0000 0x00000000
  118. However Linux should display something like:
  119. SA1100 flash: probing 32-bit flash bus
  120. SA1100 flash: Found 2 x16 devices at 0x0 in 32-bit mode
  121. Using RedBoot partition definition
  122. Creating 5 MTD partitions on "SA1100 flash":
  123. 0x00000000-0x00020000 : "RedBoot"
  124. 0x00020000-0x000e0000 : "Linux kernel"
  125. 0x000e0000-0x003c0000 : "JFFS2"
  126. 0x003c0000-0x003e0000 : "RedBoot config"
  127. 0x003e0000-0x00400000 : "FIS directory"
  128. What's important here is the position of the partition we are interested in,
  129. which is the third one. Within Linux, this correspond to /dev/mtdblock2.
  130. Therefore to boot Linux with the kernel and its root filesystem in flash, we
  131. need this RedBoot command:
  132. fis load "Linux kernel"
  133. exec -b 0x100000 -l 0xc0000 -c "root=/dev/mtdblock2"
  134. Of course other filesystems than JFFS might be used, like cramfs for example.
  135. You might want to boot with a root filesystem over NFS, etc. It is also
  136. possible, and sometimes more convenient, to flash a filesystem directly from
  137. within Linux while booted from a ramdisk or NFS. The Linux MTD repository has
  138. many tools to deal with flash memory as well, to erase it for example. JFFS2
  139. can then be mounted directly on a freshly erased partition and files can be
  140. copied over directly. Etc...
  141. RedBoot scripting
  142. -----------------
  143. All the commands above aren't so useful if they have to be typed in every
  144. time the Assabet is rebooted. Therefore it's possible to automate the boot
  145. process using RedBoot's scripting capability.
  146. For example, I use this to boot Linux with both the kernel and the ramdisk
  147. images retrieved from a TFTP server on the network:
  148. RedBoot> fconfig
  149. Run script at boot: false true
  150. Boot script:
  151. Enter script, terminate with empty line
  152. >> load zImage -r -b 0x100000
  153. >> load ramdisk_ks.gz -r -b 0x800000
  154. >> exec -b 0x100000 -l 0xc0000
  155. >>
  156. Boot script timeout (1000ms resolution): 3
  157. Use BOOTP for network configuration: true
  158. GDB connection port: 9000
  159. Network debug at boot time: false
  160. Update RedBoot non-volatile configuration - are you sure (y/n)? y
  161. Then, rebooting the Assabet is just a matter of waiting for the login prompt.
  162. Nicolas Pitre
  163. nico@fluxnic.net
  164. June 12, 2001
  165. Status of peripherals in -rmk tree (updated 14/10/2001)
  166. -------------------------------------------------------
  167. Assabet:
  168. Serial ports:
  169. Radio: TX, RX, CTS, DSR, DCD, RI
  170. PM: Not tested.
  171. COM: TX, RX, CTS, DSR, DCD, RTS, DTR, PM
  172. PM: Not tested.
  173. I2C: Implemented, not fully tested.
  174. L3: Fully tested, pass.
  175. PM: Not tested.
  176. Video:
  177. LCD: Fully tested. PM
  178. (LCD doesn't like being blanked with
  179. neponset connected)
  180. Video out: Not fully
  181. Audio:
  182. UDA1341:
  183. Playback: Fully tested, pass.
  184. Record: Implemented, not tested.
  185. PM: Not tested.
  186. UCB1200:
  187. Audio play: Implemented, not heavily tested.
  188. Audio rec: Implemented, not heavily tested.
  189. Telco audio play: Implemented, not heavily tested.
  190. Telco audio rec: Implemented, not heavily tested.
  191. POTS control: No
  192. Touchscreen: Yes
  193. PM: Not tested.
  194. Other:
  195. PCMCIA:
  196. LPE: Fully tested, pass.
  197. USB: No
  198. IRDA:
  199. SIR: Fully tested, pass.
  200. FIR: Fully tested, pass.
  201. PM: Not tested.
  202. Neponset:
  203. Serial ports:
  204. COM1,2: TX, RX, CTS, DSR, DCD, RTS, DTR
  205. PM: Not tested.
  206. USB: Implemented, not heavily tested.
  207. PCMCIA: Implemented, not heavily tested.
  208. PM: Not tested.
  209. CF: Implemented, not heavily tested.
  210. PM: Not tested.
  211. More stuff can be found in the -np (Nicolas Pitre's) tree.