PengPod1000 Debian Wheezy LXDE armhf Bootable Image!

The PengPod is an entry level Linux/Android tablet with an Allwinner A10 processor. Since I like Debian very much. I am releasing here my PengPod1000 Debian Wheezy LXDE armhf Bootable Image. I think it's the very first one on the Internet. The Debian image features:

  • HD playback via CedarX GPU driver, Mali DRI for X acceleration 
  • Touchscreen
  • Rotation
  • Iptables
  • Audio
  • USB webcam support
  • Backlight on/off with xscreensaver


Steps to create the bootable SD-card (4GB or more SD-card)
The image is not compatible with Pengpod700.

Autologin: debian, password: debian. root password: toor. When your screen is locked, you must type your password blind to unlock (turn on the display backlight).



Tips and tricks

  • Use Thunar file manager and right click media files to use CedarX graphics acceleration. (Unlock your GPU!)
  • Control VLC via ncurses:

  • To prevent the screensaver to blank the screen in VLC, go to Thunar, click Edit -> Configure custom actions, then edit the Command for Play with VLC to:
    xfce4-terminal -x ~/.thunarscripts/cvlc-cedar.sh %F and paste the contents of
    http://pastebin.com/LBf7GK5d to
    ~/.thunarscripts/cvlc-cedar.sh (chmod +rx)
  • If for some reason you loose focus of cvlc ncurses, you may not be able to stop video playback. Add a panic stop under the power button:
    in file ~/.config/openbox/lxde-rc.xml add in keyboard section:
        <keybind key="XF86PowerOff">
          <action name="Execute">
            <execute>~/.thunarscripts/cvlc-cedar-panic-shut.sh</execute>
          </action>
        </keybind>
    Then run: openbox --reconfigure
    Copy paste http://pastebin.com/AjFUrTgu to
    ~/.thunarscripts/cvlc-cedar-panic-shut.sh (chmod +rx)
  • Use Thunar file manager to get more features.
    The Debian image supports reading all storage volumes in your PengPod including Android.





  • Install NoScript Add-on in Firefox for a faster page load!
  • Install a YouTube videos downloader Add-on in Firefox. There is no hardware acceleration for HTML5 playback, so download the video then play back using cvlc (see above).
  • Command line tips:
  •   battery status: 
      grep -e "STATUS\|HEALTH\|CAPACITY" /sys/class/power_supply/battery/uevent | tr "=" " " | awk '{print $2}'
    
      on screen keyboard:
      xvkbd -geometry 1024x250+0+300
    
      blank the screen:
      xscreensaver-command -activate
    
      stop the touch screen:
      sudo modprobe -r ft5x_ts
    


    Documentation

    To enable touch
    change "define CONFIG_FT5X0X_MULTITOUCH (1)" to "undef CONFIG_FT5X0X_MULTITOUCH" in linux-sunxi/drivers/input/touchscreen/ft5x_ts.h
    Xorg configuration /usr/share/X11/xorg.conf.d/99-mali400.conf
     Section "ServerFlags"
     Option "AIGLX" "false"
     Option "DRI2" "true"
     EndSection
    
     Section "Device"
           Identifier      "Allwinner A10/A13 FBDEV"
           Driver          "sunxifb"
           Option          "fbdev" "/dev/fb0"
     EndSection
    
     Section "InputClass"
        Identifier   "evdev touchscreen catchall mouse"
        MatchProduct   "ft5x_ts"
        Option  "Transformation Matrix" "0 1 0 1 0 0 0 0 1"
        Option   "Calibration"   "0 600 0 1024"
        Option  "EmulateThirdButton" "1"
        Option  "EmulateThirdButtonTimeout" "750"
        Option  "EmulateThirdButtonThreshold" "30"
     EndSection
    


    To enable iptables
    kernel re-build using cross-compile on Debian x64: cat /etc/apt/sources.list
      deb http://ftp.nl.debian.org/debian/ sid main non-free contrib
      deb-src http://ftp.nl.debian.org/debian/ sid main non-free contrib #Added by software-properties
      deb http://emdebian.org/debian/ unstable main
      deb http://emdebian.org/~thibg/repo/ sid main
    
      aptitude install emdebian-archive-keyring gcc-4.5-arm-linux-gnueabihf \
      g++-4.5-arm-linux-gnueabihf build-essential git debootstrap u-boot-tools
    
      ln -s /usr/bin/arm-linux-gnueabihf-gcc-4.5 /usr/bin/arm-linux-gnueabihf-gcc
      ln -s /usr/bin/arm-linux-gnueabihf-gcov-4.5 /usr/bin/arm-linux-gnueabihf-gcov
      ln -s /usr/bin/arm-linux-gnueabihf-g++-4.5 /usr/bin/arm-linux-gnueabihf-g++
      ln -s /usr/bin/arm-linux-gnueabihf-cpp-4.5 /usr/bin/arm-linux-gnueabihf-cpp
    

     git clone https://github.com/npeacock/linux-sunxi 
     cd linux-sunxi
    
     diff -Naur arch/arm/configs/pengpod_a10_max_defconfig-orig 
                arch/arm/configs/pengpod_a10_max_defconfig
     --- arch/arm/configs/pengpod_a10_max_defconfig-orig 2013-05-01 13:36:17.443311902 +0200
     +++ arch/arm/configs/pengpod_a10_max_defconfig 2013-05-01 13:39:40.384318325 +0200
     @@ -506,7 +506,19 @@
      # CONFIG_ANDROID_PARANOID_NETWORK is not set
      CONFIG_NET_ACTIVITY_STATS=y
      CONFIG_NETWORK_SECMARK=y
     -# CONFIG_NETFILTER is not set
     +CONFIG_NETFILTER=y
     +CONFIG_IP_NF_IPTABLES=y
     +CONFIG_PACKET=y
     +CONFIG_NETFILTER=y
     +CONFIG_IP_NF_CONNTRACK=y
     +CONFIG_IP_NF_FTP=y
     +CONFIG_IP_NF_IRC=y
     +CONFIG_IP_NF_FILTER=y
     +CONFIG_IP_NF_NAT=y
     +CONFIG_IP_NF_MATCH_STATE=y
     +CONFIG_IP_NF_TARGET_LOG=y
     +CONFIG_IP_NF_MATCH_LIMIT=y
     +CONFIG_IP_NF_TARGET_MASQUERADE=y
      # CONFIG_ATM is not set
      # CONFIG_L2TP is not set
      CONFIG_STP=y
    
     make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- pengpod_a10_max_defconfig
     make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- uImage modules
     make ARCH=arm CROSS_COMPILE=arm-linux-gnueabihf- INSTALL_MOD_PATH=output modules_install
    
    There are two pieces that are needed. Your uImage file in arch/arm/boot/uImage needs to replace in one in the boot partition. Your lib folder in output needs to be copied over the one in the root partition to install all your new modules.


    To enable mali400 & DRI2 in Xorg
    insmod mali.ko via /etc/rc.local
    Then followed wiki here: http://linux-sunxi.org/Binary_drivers
    The default permissions of /dev/ump and /dev/mali make these unusable for normal users. Add a file to /etc/udev/rules.d/, perhaps called 50-mali.rules, with the following content:
            KERNEL=="mali", MODE="0660", GROUP="video"
            KERNEL=="ump", MODE="0660", GROUP="video"
            adduser debian video
    
    Then recompile the driver:
            apt-get install build-essential libdri-dev xorg-dev xutils-dev
            git clone https://github.com/robclark/libdri2
            configure/make/install
            
            git clone https://github.com/linux-sunxi/sunxi-mali.git
            cd sunxi-mali
            git submodule init
            git submodule update
            make install
    
            apt-get install build-essential xorg-dev xutils-dev x11proto-dri2-dev \
            libltdl-dev libtool automake 
            git clone https://github.com/ssvb/xf86-video-sunxifb.git       
            autoreconf -vi
            ./configure --prefix=/usr
            make
            make install
    
     ln -s /usr/local/lib/libdri2.so.1 /lib/libdri2.so.1 


    To enable rotation
    Copy paste from Linaro latest image
     cp /usr/lib/libconfig.so.8 /lib/
     cp /etc/pengrotate/ /etc
     cp /usr/share/X11/xorg.conf.d/98-fbdev.conf /usr/share/X11/xorg.conf.d/
     cp -r /usr/bin/pengrotate /bin/
    


    Initial image creation
    1. First I downloaded and flashed the latest Pengpod image: dd if=PengPod1000-Linaro.img of=/dev/sdX
    2. I mounted the flashed SD-card and removed the Linaro system: rm -R root/*
    3. Then I downloaded the Debian image with LXDE desktop from here: https://www.miniand.com/forums/forums/development/topics/debian-wheezy-lxde-armhf-build (debian-wheezy-lxde-armhf-mk802ii-1080p60-25-03-2013) found via: http://linux-sunxi.org/Bootable_OS_images#Debian
    4. Then I mounted the root partition of the Debian image using: mount -o loop,ro,offset=XXXX Read here: http://www.andremiller.net/content/mounting-hard-disk-image-including-partitions-using-linux
    5. Then I used cp -ax to copy the root file system from the Debian image to the SD-card.
    6. Then I followed the instruction on the Peng forum http://pengpod.com/forum/viewtopic.php?f=3&t=11 and removed the modules from the Debian image: rm -R /lib/modules from the SD-card and rm -R/etc/modules from the SD-card
    7. The first build I created, used the kernel and modules from Linaro: I inserted the SD-card (with external cardreader) in my running Pengpod and copied the modules from Linaro to the Debian SD-card: cp -ax /lib/modules /mnt/lib/ , cp -ax /etc/modules /mnt/etc/ remember that later I recompiled and trew this modules away.






    bandwidth provided by




    By Barry on Tuesday, April 23, 2013 | , , | 19 comments
    19 responses to “PengPod1000 Debian Wheezy LXDE armhf Bootable Image!”
    1. vmsbob says:

      Hey Barry,

      your debian image is great! loads / installes as expected. I've been busy installing packages all morning

      thanks again,
      bob

    2. this is some fantastic work! everything works great! i reccomend this a try for everyone!
      is there a way to make the pengpod act as a mass storage device when plugged into a pc?
      and a way to remove pesky nand used by android when installed into internal flash?
      anyone kow a great snes emulator for linaro or debian?
      and will it be able to setup a build enviroment?

      stewbrowne

    3. Anonymous says:

      thank you, this image feels much more useable over stock. i did an aptitude safe-upgrade to testing(jessie) repositories. working nicely. was able to play some youtube video (albeit very poorly), and some other videos over the local network. the virtual terminals seem to behave better and faster (still noticed a bit of laggy pixels now and again though)

    4. still an awsome build.
      how can i go about flashing debian to the internal flash?
      i installed cairo dock and pithos. works freekin awsome.

    5. Unknown says:

      I would be willing to help try to get this to work on the 700 if possible. I really want to use the Bodhi Enlightenment UI, and it is designed for debian (very unstable on linaro). What steps in this process would need to be altered for a 700? I know the Wifi hardware is different, but not too much else.

      Thanks for your work.

    6. Anonymous says:

      Try this:
      http://pengpod.com/pengwiki/index.php?title=Porting_a_new_distro&action=edit

      OR

      flash one sd card with the linaro 700 image, flash one other sd card with my debian image,
      then copy /etc/modules and /lib/modules from the linaro to the debian image.
      also copy the entire boot partition of linaro to debian.

      That will probably work to. (Kernel recompiling and compiling drivers for GPU is the better way to go
      but a bit more complicated.)

      The above will give you an unoptimized debian to start from.

    7. DjSadhu says:

      Hi there,

      After modifying script.bin (using bin2fex -> fex2bin) and setting the right screen resolution (800x480), the right ctp parameters, and copying a bunch of other settings from a previous script.bin that worked, this image runs like a CHARM.
      I had been trying for two weeks to get CedarX, Mali and ft5x_ts to run, but you seem to have done a great job here.

      The only problems are heavy artifacts in CedarX playback, a decent auto-popup on-screen keyboard, and I'm trying to get a web cam running. Other than that it's a great image.

      Hardware: QWare Tab Pro3 7", Cortex A8 cpu, 1Gb RAM, 800x480 resolution, 16Gb micro-SD.

    8. Anonymous says:

      Has anyone had issues with the 0bda:8179 wireless chipset not finding wireless devices even while the wifi shows up in the list of devices in ifconfig and iwconfig?

    9. stewbrowne says:

      Still a fantastic rootfs. I was having problems with it setting the wallpaper image in lxde until I installed gnome3 and removed lxde. I thought it would be slower but I sure can't even tell. I think it may even boot quicker into gnome than lxde. Any suggestions on how to add gestures. I'm given easystroke a try. Gnome installs a battery meter but its not correct at all is like to figure out how to fix that up.

    10. Barry says:

      Easystroke is the only one I know of see http://pengpod.com/forum/viewtopic.php?f=4&t=4489&p=6556&hilit=easystroke#p6556

    11. Great job Barry!
      I launched your image on my Ainol NOVO7 Elf (it is similar to pengpod by hardware)
      Almost all work perfectly out of the box (except touchscreen, which is goodix touch gt801)

      I have a question. My knowledge of Linux not allows me to resolve it myself.
      I connected my tablet to LCD monitor with resolution 1280x1024 by passing kernel parameter "disp.screen0_output_mode=EDID:1280x1024p60"
      Desktop and consoles displays correct, but when watching video, the image is stretched vertically. (it thinks that my aspect ratio is 1024:600, while it is 5:4)
      I played with all "aspect-ratio" command-line parameters of VLC, but without effect.
      What can I do to resolve this problem?

    12. Great job Barry!
      I launched your image on my Ainol NOVO7 Elf (it is similar to pengpod by hardware)
      Almost all work perfectly out of the box (except touchscreen, which is goodix touch gt801)

      I have a question. My knowledge of Linux not allows me to resolve it myself.
      I connected my tablet to LCD monitor with resolution 1280x1024 by passing kernel parameter "disp.screen0_output_mode=EDID:1280x1024p60"
      Desktop and consoles displays correct, but when watching video, the image is stretched vertically. (it thinks that my aspect ratio is 1024:600, while it is 5:4)
      I played with all "aspect-ratio" command-line parameters of VLC, but without effect.
      What can I do to resolve this problem?

    13. Barry says:

      Well HD playback can only be achieved with the CedarX driver in a custom build of VLC, http://pengpod.com/forum/viewtopic.php?t=4296

      You probably need to ask this question at the developer of CedarX.

      For touch screen identify the driver your devices needs by checking script.bin / script.fex file in your boot partition
      (https://www.olimex.com/forum/index.php?topic=184.0 answer number 4)

      then enable touch in X:
      http://pengpod.com/pengwiki/index.php?title=Debian
      Read under 'To enable touch'

    14. Hi. I somehow managed to completely screw up the SD card for my PengPod 1000 while attempting to add a Word-compatible program. Can you prepare a fully loaded card for me and I pay you via PayPal? I tried to format a card myself, but it was an epic failure. Please let me know if you or someone you know can help. I tried to purchase a card on the PengPod site, but evidently no selling is taking place there anymore.

      I appreciate your help.

    15. Barry says:

      Hello Fredrick,

      I can send a 2GB pengpod 1000 SD card for Debian or Fedora for 12 euro. If you want a larger SD card, you can send it to me or add it to the price. You can use the PayPal button on this site. Barry.

    16. I'd like a 16GB card. How much will that run me?

    17. Barry says:

      https://m.bol.com/nl/p/kingston-microsd-kaart-16-gb/9005000010464536/

      with shipping is an additional 18 euro.

      So grand total will be 30 euro. Including shipping to wherever you are. I will ship in 3 working days max.

    18. staul62 says:

      Does a disabled network imply I may have the wrong v3ersion of the wi-fi hardware for this Debian image? It looks great otherwise by the way.

    19. staul62 says:

      Please ignore my earlier question - I found the answer for enabling wireless in the forum. I even deduced that a 'right-click' is achieved by a prolonged touch on the touch-screen. Thanks again.

    Leave a Reply