Cubieboard power usage with SATA

I have installed lubuntu to my Cubieboard2 and I have also connected a 2.5” SATA HDD. I wanted to know if my power supply is providing enough power so I tried to measure current output from 5V power supply.

I used cheap small USB power meter (find also some on eBay for less then 5€).

charger doctor - USB volat and amper meter

My results varies according to HDD usage:

DLNA media server on Cubieboard with Lubuntu

I have installed Lubuntu on my new Cubieboard 2. I have also attached HDD to SATA so I have more space to store my media. This posts describes the steps needed to install and configure media server to share my media to other devices (media players). I spent some time to select the right one and chose minidlna tool (also known as ReadyMedia, lightweight DLNA/UPnP-AV server targeted at embedded systems).

According to Ubuntu documentation the MiniDNLA daemon serves media files (music, pictures, and video) to clients on a network. Example clients include applications such as totem and xbmc, and devices such as portable media players, smartphones, and televisions.
MiniDLNA is a simple, lightweight alternative to MediaTomb, but has fewer features. It does not have a web interface for administration and must be configured by editing a text file.

Mount SATA drive in Cubieboard with Lubuntu

The main advantage of cubieboard is it’s SATA connector. I have old HDD from notebook, so I wanted to use it as a media server.

This post has 3 parts related to HDD connected to Cubieboard2 with lubuntu:

  • Mounting HDD
  • Backup NAND
  • Spin down HDD


There are many ways to see all disks and partitions but my favorite command is lsblk:

sudo lsblk -o NAME,FSTYPE,SIZE,MOUNTPOINT,LABEL
NAME        FSTYPE   SIZE MOUNTPOINT LABEL
sda                149.1G
nand                 3.7G
|-nanda     vfat      64M            Volumn
`-nandb     ext4     3.6G /
mmcblk0              241M
`-mmcblk0p1 vfat     241M            SSD

or also fdisk:

I2C on Cubieboard with Lubuntu

I2C bus is used by many integrated circuits and is simple to implement. Any microcontroller can communicate with I2C devices even if it has no special I2C interface so I wanted to enable I2C also in my Cubieboard2 to get direct access to sensors.

Apache+PHP on Cubieboard with Lubuntu

I executed the following steps to install apache with PHP on my cubieboard2 with lubuntu.

Lets start with installation that will take about 25MB:

sudo apt-get install apache2
sudo apt-get install php5
sudo /etc/init.d/apache2 restart

Cubieboard2 – Lubuntu – Enabling Print Screen

When I installed Lubuntu on my new Cubieboard2, the print screen was not working. When I hit the “Print Screen” button I got this message:

I’ve fixed it by installing the scrot application:

sudo apt-get install scrot

If you hit “Print Screen” or “Alt+Print Screen” you will see a new file *_scrot.png in you home directory.

 

Cubieboard2 – Lubundu – Extending NAND from 2GB to 4GB

When I install new Lubuntu NAND image to my new Cubieboard2 I had only 2GB of space out of 4GB available.

I followed this forum to expand the filesystem to 4GB.

sudo nand-part

In my case I used this nand-part command:

sudo nand-part -f a20 /dev/nand 32768 'bootloader 131072' 'rootfs 7569408'

the number in bootloader is the same as previous partition size.
The number in rootfs is the sum of previous partition size of partition 2 and partition 3 that we wanted to merge.