About Me Banner


 

This page describes installing Kernal and LUbuntu on a Micro

 

SD memory card for use with the pcDuino3.

 

 

What is the pcDuino3?

 

    

 

pcDuino3 is a high performance, cost effective single board computer. It runs operation systems such as Ubuntu Linux and Android. pcDuino3 has HDMI interface to output its graphic desktop screen. It could support multi-format 1080p 60fps video decoder and 1080p 30fps H.264 and MPEG4 video encoder with its built-in hardware video processing engine. It targets specially the fast growing demands from the open source community. pcDuino3 provides easy-to-use tool chains and is compatible with the popular Arduino ecosystem such as Arduino Shields.

 

When I received my pcDuino3, LUbuntu was already factory installed in the NAND storage. My pcDuino3 also has the 4GB of NAND storage. But I want to install LUbuntu, Softrock server software, and the ghpsdr3-alex software on a Micro SD Flash Card. The following instructions will guide you through the process I used to create a bootable Micro SD card with LUbuntu. Let's get started. These same steps are available at:

 

http://www.pcduino.com/chapter-1-hardware-and-software-introductions-of-pcduino/

 

In every pcDUino Ubuntu release, there is a file named SD bootable image. This file is intended to create a bootable microSD card, so we can put all of our application and data on the SD card instead of the space-limited NAND flash.

 

My pcDuino has an onboard NAND of 4GB. When we are doing heavy duty project development, we can easily eat up all the space. For my situation, I want to use the pcDuino3 for not just the Softrock server and dspserver for the SDR Softrock Ensemble, but for my RTLSDR that I just purchased to monitor aircraft and create a special virtual radar server. So I am likely to use more than the NAND flash memory available.

 

So we need a way to move all the program and data from NAND to a SD of larger capacity and make that SD bootable. The key function we are going to use is:

 

make_mmc_boot “Clone system from nand to mmc card”

 

This function will copy the entire content in NAND to a SD card. This is equivalent to flash an mmc-boot image. The benefit is that users still keep their own program/data. When the space of NAND is not enough, we can use the SD card to replace the system in NAND.

 

We need to do an update in board-config to make it available. There are two ways to run board-config. One is to run that after reset. The other is to run it in terminal. In the following steps, we are going to use a terminal.

 

1. Power up the pcDuino3 and let it boot up to the desktop

 

2. Open up an LXTerminal from the desktop

 

3. In the terminal, type at the prompt: $ sudo board-config.sh

 

board-config.sh

 

4. In the board configuration window, scroll down to update     upate board-config and related packages. Move cursor to <Ok> and hit enter. The system will now ask you what you want to update. I selected all and hit <Ok> to make sure my system was up to date. You might see this on your screen:

 

update all

 

Make sure you hit Y at any of the prompts. This entire process will ensure that you copy over the very latest software to the SD card. Be patient here as the updates may take some time. The downloads took over 8 minutes for my system, then installed the updates, which may also take a few minutes.

 

5. After the update is done, exit and then rerun $ sudo board-config.sh

 

board-config.sh

 

6. In the board configuration window, scroll down to make mmc boot     Clone system from nand to mmc card.

 

7. Insert the Micro SD Flash Card into the pcDuino3. You probably will get a screen that opens telling you that Removable medium in inserted. Go ahead and hit Cancel in this window.

 

8. In the board configuration window, move the cursor to <Ok> and hit enter. You should get another window that says:

 

Do you want to clone your system from nand flash to sd card?
Need to insert and empty sdcard ( >= 4000 MBytes )

 

Select <Yes>. Next should pop up another window asking:

 

Do you really want to format this card?

 

Select <Yes>. You should get a screen that might contain the following lines:

 

Formatting

 

Once the formating is completed, you should get a message indicating that the nand flash is being copied to the sdcard, similare to the following:

 

GSWPD_CH2_19

 

If you get this, so far so good. Once the copying is completed, you will get another pop up window that will say:

 

clone system from nand to mmc card succeed!

 

If you get this, you have succeeded in creating a bootable sd card with LUbuntu installed.

 

9. Reboot the pcDuino3 and check the storage space in a terminal window by typing at the prompt: $ df -h

 

You should get the following:

 

GSWPD_CH2_21

 

The indicator that the pcDuino3 booted up using the SD card is if you see under the word Filesystem: /dev/mmcblk0p2 .

In the above figure, we can see that although the SD card is of capacity 16GB, it only shows up as 2GB. In my system, it showed 4GB.

 

We are going to use a script to expand the file system to the whole SD card. At the prompt, type

 

wget https://s3.amazonaws.com/pcduino/SampleCode/System/expandFS/expand_sdcard_rootfs.sh

 

Once this is completed, then type: sudo bash ./expand_sdcard_rootfs.sh

 

You should see a screen that looks like the following:

 

GSWPD_CH2_22

 

10. After the expansion, we reboot the pcDuino3 by typing at the prompt: sudo reboot

 

11. After reboot in a terminal window, type: sudo resize2fs /dev/mmcblk0p2

 

GSWPD_CH2_23

 

This is going to take a bit of time. Good time to go get something to drink!

 

12. When the expansion is complete, you should see the following in your terminal window:

 

GSWPD_CH2_24

 

13. Check the storage space again by typing in your terminal window: df -h

 

You should now see that you have full access to your SD card. In my case, 16GB.

 

Your system is ready for use, bootable from the SD card.

 

Back to top of page

© 2017, Jonathan Tucker N8MDP. All Rights Reserved. Powered by cPanel.