-
Notifications
You must be signed in to change notification settings - Fork 8
385 DB AP Instructions
The default configuration for this device is available:
cd /opt/openwrt/marvell-openwrt-bb wget https://raw.githubusercontent.com/MarvellEmbeddedProcessors/openwrt-misc/openwrt-14.07-a38x-docs-15t1/marvell/38x/385_db_ap/config -O .config
If you decide not to use the default configuration and configure OpenWrt and kernel manually, follow the instructions bellow:
make menuconfig
Make sure the following options are selected:
Target System (Marvell Armada 37x/38x/XP) ---> Target Profile (Marvell Armada 385 DB AP (DB-88F6820-AP)) ---> [*] Advanced configuration options (for developers) ---> (/opt/kernel/marvell/linux-3.10.70-2015_T1.1/) Use external kernel tree
The following command will copy the kernel configuration and open the kernel menuconfig interface. Use it only if you need too modify kernel configuration.
If necessary environment can be reset to the factory defaults with the following commands:
resetenv reset
To flash the image we first need to set a few environment variables:
setenv bootargs_root_owrt 'ubi.mtd=2 root=ubi0:rootfs rootfstype=ubifs rw' setenv bootcmd 'setenv bootargs ${console} ${mtdparts} ${bootargs_root_owrt}; nboot kernel; bootm'
At this stage it will probably be necessary to set the IP of the server and the board.
setenv ipaddr <board IP addr> setenv serverip <server IP addr> saveenv
The board is now ready to be flashed. First we flash the kernel:
tftpboot ${loadaddr} openwrt-mvebu-uImage-armada-385-db-ap nand erase.part kernel nand write ${loadaddr} kernel ${filesize}
Tip! We can also do this in one line:
tftpboot ${loadaddr} openwrt-mvebu-uImage-armada-385-db-ap && nand erase.part kernel && nand write ${loadaddr} kernel ${filesize}
Next we need to flash the root filesystem:
tftpboot ${loadaddr} openwrt-mvebu-root.ubifs ubi part rootfs ; ubi remove rootfs ; ubi create rootfs ubi write ${loadaddr} rootfs ${filesize}
Tip! This can also be done in one line:
tftpboot ${loadaddr} openwrt-mvebu-root.ubifs && ubi part rootfs && ubi remove rootfs && ubi create rootfs && ubi write ${loadaddr} rootfs ${filesize} && reset
The board will now reset and then boot the new image.
We can also use ramdisk image to boot the board. Using the above instructions to set the environment we can now use the following to boot the board:
setenv ipaddr <board IP addr> setenv serverip <server IP addr> saveenv tftpboot ${loadaddr} openwrt-mvebu-armada-385-db-ap-initramfs setenv bootargs ${console} ${mtdparts} ${bootargs_root_owrt} bootm ${loadaddr}
Tip! Single line command:
tftpboot ${loadaddr} openwrt-mvebu-armada-385-db-ap-initramfs && setenv bootargs ${console} ${mtdparts} ${bootargs_root_owrt} && bootm ${loadaddr}