Changes between Version 4 and Version 5 of howto/SD_Config
- Timestamp:
- Aug 25, 2012, 9:16:06 PM (12 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
howto/SD_Config
v4 v5 72 72 The default WARP v3 CPLD design loads configuration files from the SD card starting at an offset of 64MB. Up to 8 configuration files can be stored per card, with each file separated by 16MB. The active configuration file is selected by the config DIP switch on the WARP v3 board. You must choose which "slot" when copying the .bin file to the SD card. 73 73 74 We use the open-source dd tool to write configuration files to SD cards. dd is available for OS X, Linux and Windows (and probably other OSs). Each call to dd copies one configuration file. There are four arguments:74 We use the open-source dd tool to write configuration files to SD cards. dd is available for OS X, Linux and Windows (and probably other OSs). Each call to dd copies one configuration file. There are four required arguments: 75 75 {{{ 76 dd bs=512 seek= BaseAddr if=someFile.bin of=sdCardDevice76 dd bs=512 seek=<base_block_addr> if=<config_file.bin> of=<sd_device_descriptor> 77 77 }}} 78 78 * bs: Block size, always 512 for SD cards 79 * if: input file (your .bin file)80 * of: device descriptor for SD card (OS specific; see below)79 * if: Input file (your .bin file) 80 * of: Device descriptor for SD card (OS specific; see below) 81 81 * seek: Staring address for the output file, in units of block size. Use (131072 + slotNum*32768) for standard WARP v3 config design: 82 82 * Slot 0: 131072 … … 89 89 * Slot 7: 360448 90 90 91 === OS X === 92 Apple provides a copy of dd with recent releases of OS X (at least since 10.7, probably earlier). 91 The specific calls to dd depend on your operating system. 92 * [wiki:./OSX OS X] 93 * [wiki:./Linux Linux] 94 * [wiki:./Windows Windows] 93 95 94 '''Finding the SD card descriptor:'''[[BR]]95 1. Insert the SD card96 1. In a terminal run {{{diskutil list}}} to find device descriptor for SD card. Look for the SD card in the list of disks. On a MBP, the shows:97 {{{98 #: TYPE NAME SIZE IDENTIFIER99 0: GUID_partition_scheme *500.1 GB disk0100 1: EFI 209.7 MB disk0s1101 2: Apple_HFS Macintosh HD 499.2 GB disk0s2102 3: Apple_Boot Recovery HD 650.0 MB disk0s3103 /dev/disk1104 #: TYPE NAME SIZE IDENTIFIER105 0: FDisk_partition_scheme *2.0 GB disk1106 1: DOS_FAT_32 WARP SD 32.0 MB disk1s1107 }}}108 2. In this example, the SD card device descriptor is /dev/disk1. The actual descriptor will differ on other machines with different disk configurations.109 110 '''Copying the .bin file:'''[[BR]]111 1. Unmount ('''not''' eject) the drive using this command:112 {{{113 diskutil unmountDisk /dev/diskX114 }}}115 1. Run this command, replacing the last three arguments with the correct values:116 {{{117 dd bs=512 seek=<N> if=<yourFile.bin> of=</dev/diskX>118 }}}119 1. ''<N>'': depends on the target slot number; see the list above120 1. ''<yourFile.bin>'': the binary FPGA configuration file121 1. ''</dev/diskX>'': device descriptor for the SD card122 1. If successful, dd should report the following (the time/throughput values will differ):123 {{{124 18032+1 records in125 18032+1 records out126 9232444 bytes transferred in 8.503631 secs (1085706 bytes/sec)127 }}}128 1. Repeat for additional .bin config files if needed.129 1. Eject the SD card in the Finder (if it's mounted).130 96 131 97 ----