Miqipi/Debian8

From wiki
Jump to: navigation, search


This topic will help you to install debian Jessie on MiQi. We will use upstream u-boot and linux-4.4 kernel.
First just upload some pictures taken from MiQi.
key feature


steps


linaro@linaro-alip:~$ uname -a                                                                        
Linux linaro-alip 4.4.16 #4 SMP Tue Aug 23 16:07:08 CST 2016 armv7l GNU/Linux                         
linaro@linaro-alip:~$                                                                                 
linaro@linaro-alip:~$ cat /etc/os-release                                                             
PRETTY_NAME="Debian GNU/Linux 8 (jessie)"                                                             
NAME="Debian GNU/Linux"                                                                               
VERSION_ID="8"                                                                                        
VERSION="8 (jessie)"                                                                                  
ID=debian                                                                                             
HOME_URL="http://www.debian.org/"                                                                     
SUPPORT_URL="http://www.debian.org/support"                                                           
BUG_REPORT_URL="https://bugs.debian.org/"                                                             
linaro@linaro-alip:~$ cat /proc/cpuinfo                                                               
processor	: 0                                                                                         
model name	: ARMv7 Processor rev 1 (v7l)                                                             
BogoMIPS	: 115.20                                                                                    
Features	: half thumb fastmult vfp edsp thumbee neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm 
CPU implementer	: 0x41                                                                                
CPU architecture: 7                                                                                   
CPU variant	: 0x0                                                                                     
CPU part	: 0xc0d                                                                                     
CPU revision	: 1                                                                                     
                                                                                                      
processor	: 1                                                                                         
model name	: ARMv7 Processor rev 1 (v7l)                                                             
BogoMIPS	: 115.20                                                                                    
Features	: half thumb fastmult vfp edsp thumbee neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm 
CPU implementer	: 0x41                                                                                
CPU architecture: 7                                                                                   
CPU variant	: 0x0                                                                                     
CPU part	: 0xc0d                                                                                     
CPU revision	: 1                                                                                     
                                                                                                      
processor	: 2                                                                                         
model name	: ARMv7 Processor rev 1 (v7l)                                                             
BogoMIPS	: 115.20                                                                                    
Features	: half thumb fastmult vfp edsp thumbee neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm 
CPU implementer	: 0x41                                                                                
CPU architecture: 7                                                                                   
CPU variant	: 0x0                                                                                     
CPU part	: 0xc0d                                                                                     
CPU revision	: 1                                                                                     
                                                                                                      
processor	: 3                                                                                         
model name	: ARMv7 Processor rev 1 (v7l)                                                             
BogoMIPS	: 115.20                                                                                    
Features	: half thumb fastmult vfp edsp thumbee neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm 
CPU implementer	: 0x41                                                                                
CPU architecture: 7                                                                                   
CPU variant	: 0x0                                                                                     
CPU part	: 0xc0d                                                                                     
CPU revision	: 1                                                                                     
                                                                                                      
Hardware	: Rockchip (Device Tree)                                                                    
Revision	: 0000                                                                                      
Serial		: 0000000000000000        

download


  • Kernel Source

https://github.com/mqmaker/linux-rockchip/tree/develop-4.419

  • U-boot Source

https://github.com/mqmaker/u-boot-rockchip/tree/miqi/devel6

  • prebuilt u-boot images

https://github.com/mqmaker/miqi-prebuilt16

flash firmware


Here we help you to flash the upstream u-boot
Get prebuilt u-boot images

$git clone https://github.com/mqmaker/miqi-prebuilt10

run flash.sh scripts

$cd miqi-prebuilt/u-boot
$./flash.sh

When the script detect a MiQi device connected and the MiQi device is on MASKROM state, it will upgrade the loader to MiQi's eMMC automatically. You need to know how to let MiQi run into MASKROM mode. There is two ways

  • 1 Erase the start of eMMC, then restart If you have OS installed on MiQi,

you can erase the loader by the following command

dd if=/dev/zero of=/dev/mmcblk0 bs=1M count=20
  • 2 Short circuit cmd signal of eMMC at bootup

You can short circuit the resistance showed in the picture when you insert USB cable to host. The loader inside the SoC will detect this and switch to MASKROM mode

LOG

BTW, you need to have a TTL serial cable! so that you can run command on u-boot. If success, the flash.sh output

./flash.sh 
Waiting for rockchip device...
Bus 004 Device 017: ID 2207:320a  
Flashing RK3288_uboot.img...
Download boot ok.
Write LBA from file (100%)
Write LBA from file (100%)
Reset Device OK.     

The u-boot output:

U-Boot 2016.09-rc1-00210-g9073bdf-dirty (Aug 23 2016 - 13:41:04 +0800)

Model: rk3288-miqi
DRAM:  2 GiB
MMC:   dwmmc@ff0c0000: 0dwmmc@ff0f0000: 1
** First descriptor is NOT a primary desc on 1:1 **
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
miqi init
Net:   Net Initialization Skipped
No ethernet found.
Hit any key to stop autoboot:  0 
Card did not respond to voltage select!
** First descriptor is NOT a primary desc on 1:1 **
switch to partitions #0, OK
mmc1(part 0) is current device
** No partition table - mmc 1 **
=>                                      

On u-boot prombt, you can run

=> ums 0 mmc 1

After this, we will find new mass storage device found on your host, and you can put rootfs/dtb/rootfs on it now smiley on my host, the device is /dev/sdd