Archive for category Embedded Linux

CVJI-E212, one more cheap Allwinner A10 media player

I started looking into a number of devices based on Allwinner A10 SoC — this appears to be a very popular chip in China, and there are endless varieties of cheap tablets and HDMI media players. Among the most known are Mele A1000/A2000, MK802, MK802+, MiniX media players — they all provide HDMI interface, one or two USB ports, and some of them come with a built-in WiFi adapter.  The chip also supports OTG USB interface, and some of those devices also provide it. Also MK802 can be powered from the USB port.

Those devices come usually with pre-installed Android 4.0. Typically the OS supports only a limited range of screen resolutions and frequencies (I couldn’t get a decent picture on my Sony Bravia TV and on a computer monitor via a HDMI-to-DVI adapter).

Anyway, I’m a server guy, and my primary interest is in “server” applications, even on such small appliances. So, I don’t really care about graphics.

Read the rest of this entry »


, ,


Cloning a Voyage Linux host

After you made all your customizations to a Voyage Linux installation, you may want to replicate it to other boards. The procedure is tested with PC Engines’ ALIX2 boards.

The dump can also be easily piped through SSH to/from your backup server. This way it’s easy to organize snapshots for your lab testing and backups. Do not use any compression inside ALIX — the CPU is quite slow, and it’s faster to transfer uncompressed data over SSH and compress it on the target host if needed (assuming the target host is a usual modern machine).

# get dump and restore
apt-get install dump

# make sure your source filesystem is read-only

# The target CF card is attached as /dev/sdb in a USB card reader

/usr/local/sbin/ -t $CF -b 1 -y
mkdir /tmp/cf
mount $CF1 /tmp/cf
cd /tmp/cf
dump -0 -f - /dev/hda1 | restore -r -f -

# let the new system re-generate SSH keys
rm /tmp/cf/etc/ssh/ssh_host_*
touch /tmp/cf/voyage.1st

# Populate a new hostname
vi /tmp/cf/etc/hostname
vi /tmp/cf/etc/hosts

# Install the boot loader (assuming Partition 1 is used for boot filesystem)
echo "(hd0) $CF" > /tmp/cf/boot/grub/
mount -o bind /dev /tmp/cf/dev
chroot /tmp/cf /usr/sbin/grub --device-map=/boot/grub/ <<EOM
setup (hd0) (hd0,0)
umount /tmp/cf/dev

# finished preparing the filesystem
cd /
umount $CF1

, ,


Tweaking Voyage Linux on PC engines’ ALIX

ALIX is a small-factor, low-power x86 platform designed and sold by PC Engines. I’ve set up one such system with my call-home scripts, and I plan to use it instead of (or alongside) those netbooks: it’s more compact, and it’s cheaper (around $150 for a box).

Voyage Linux is a Debian OS distribution adapted for such small-factor platforms. It mounts the flash drive in read-only mode by default, and also the kernel loads all necessary modules to support the ALIX board.

After setting up Voyage as described in their README, I do the following steps to optimize the setup (after issuing remountrw command):

0. Edit /etc/apt/sources.list and select a nearer mirror, e.g.

deb squeeze main contrib non-free

1. Adapt the DHCP client configuration so that it re-tries faster if DHCP service is unavailable:

# /etc/dhcp/dhclient.conf
# <other options skipped>
timeout 10;
retry 20;

2. Install NTP service. This is important because the board does not have a battery-powered RTC clock.

apt-get update
apt-get install ntp

3. Add a user for myself, add it to sudoers with NOPASSWD: option, and then remove the root password completely.

4. If I want to use X11 forwarding through SSH, there’s one problem: my home directory is by default on a read-only filesystem, and xauth tries to create .Xauthority in my home directory. To avoid that, I do the following:

sudo apt-get install xauth
sudo cat >> /etc/ssh/sshd_config <<EOT
PermitUserEnvironment yes
sudo service ssh restart
cat >.ssh/environment <<EOT

5. Install additional stuff as needed:

sudo apt-get install dump git wireshark

6. Reboot, test, and backup the filesystem by using dump command (don’t use dump compression, as the CPU is rather slow).

, , ,

Leave a comment

Big Endian for i.MX27: bug test code

a piece of assembler code which proves the bug in big-endian mode:

 Read the rest of this entry »

, ,

Leave a comment

Big Endian for i.MX27: found the problem

Found the big endian problem: it looks like the memory controller bug.

Read the rest of this entry »

, , ,


Two-in-One embedded linux box

Posted a new idea at

Read the rest of this entry »

Leave a comment

Big Endian for i.MX27: looks like it’s not working

I managed to launch the CPU in big endian mode, and it even executes
some part of u-boot code. But the serial is silent, and MTD driver can’t find
any NAND chips.

The UART control registers receive correct values, I verified this.
So, most probably the UART hardware fails to get those values from a big-endian CPU.

, , ,

Leave a comment

Moving to big endian: first steps

Here’s my message at Armadeus mailing list

Here’s the link to the u-boot patch to be studied.

UPD: Currently the nand_spl loader is compiled in LE, and then it prepares the u-boot image in the memory and switches to BE mode. Then u-boot starts quite normally, but then it hangs up without printing anything to the serial console. Looks like some initialization code breaks internal memory. Need to solder a JTAG connector for further debugging…

, ,

Leave a comment

Mounting the LCD touchscreen on top of Armadeus devboard

img_0878Assembled all the Armadeus parts together. Now it’s much easier to move them around the table 🙂

The Armadeus devboard comes without any cables. The LCD and touchscreen are equipped with two cables for connecting to the devboard. The devboard needs a 2.5/5.5 power jack, and the power supply should support at least 12W power draw.

Read the rest of this entry »



Armadeus apf27 hardware ordered

Ordered the following hardware from

  • APF27-M128F256-EUF200 (i.MX27,  128 Mb RAM, 256MB NAND Flash, FPGA spartan3A (200Kgates))
  • APF27_Dev_Light
    • DAC+ADC
    • CAN
    • backuped RTC
  • LQ043_adapt kit
    • Touch screen FJT N010-0554-T241

, ,

Leave a comment