MYiR MYD-JX8MX Series User manual


1.1
1.2
1.3
1.4
1.4.1
1.4.2
1.4.3
1.5
1.5.1
1.5.2
1.5.3
1.5.4
1.5.5
1.5.6
1.5.7
1.5.8
1.5.9
1.5.10
1.6
TableofContents
Introduction
1.Softwareresources
2.Deploydevelopmentenvironment
3.Androidsystemprogramandcompile
3.1ProgramAndroidimagetoEMMC
3.2ProgramAndroidimagetoSDcard
3.3CompileAndroidsystem
4.Androidfunctionintroduction
4.1DM-verityconfiguration
4.2NETWORKtest
4.3WIFItest
4.4BLUETOOTHtest
4.5CSItest
4.6AUDIOtest
4.7UARTtest
4.84Gtest
4.9GPIOtest
4.10USER-KEYtest
AppendixWarranty&TechnicalSupportServices
2

MYD-JX8MXAndroid9DevelopmentGuide
Thisdocumentintroducehowtocompileandroid9sourcecode,programimageanduseonMYD-JX8MXseriesdevelopment
boards.
History
Version Note Date
V1.0 InitialVersion 2019.10.18
HardwareVersion
ThisdocumentappliestothefollowingseriesDevelopmentBoardofMYIRcurrently.
MYD-JX8MX
Atleast2GDDR.Thememorymodelisasfollows.
MT53B512M32D2NP062WT
MT53D512M32D2DS053WT:D
Wifimodulesonthebasebaord.
Fn-Link8274B-PR
Fn-Link6222B-PR
Introduction
3

1.Softwareresources
BesidestheYoctoLinuxandUbuntuLinux,MYIRalsooffersAndroidsystemforMYD-JX8MXseriesdevelopmentboard.It
providesrichsystemresourcesandsoftwareresources.Someofthefunctionshavetobeworkingwiththeextensionmodules.
Alistofresourcesasbellow:
Type Name Description SourceCode
Bootstrap U-boot bootstrap YES
Linuxkernel Boot BaseonNXPandroid9.0.0_2.0.0version YES
DeviceDriver PMIC BD71873driver YES
DeviceDriver USBHost USBHost3.0driver YES
DeviceDriver I2C I2Cbusdriver YES
DeviceDriver SPI SPIbusdriver YES
DeviceDriver Ethernet 10M/100M/1000Mdriver YES
DeviceDriver MMC MMC/EMMC/TFcardstoagedriver YES
DeviceDriver HDMI HDMIdriver YES
DeviceDriver PWM PWMcontroldriver YES
DeviceDriver RTC RealTimeClockdriver YES
DeviceDriver GPIO GPIOdriver YES
DeviceDriver Audio WM8904driver YES
DeviceDriver Camera Ov5640driver YES
DeviceDriver WiFi&BT QCA6174andRTL8822Bdriver YES
DeviceDriver Watchdog Watchdogdriver YES
DeviceDriver LTEmodule SupportEC20module,useUSBdriver NO
DeviceDriver M.2 NVMEdriver YES
Rootfs Androidsystem BaseonAndroid9rootfs YES
toolchain Crosscompiler gccversion4.9.x20150123(prerelease)(GCC) YES
1.Softwareresources
4

2.Deploydevelopmentenvironment
Beforethedevelopment,youneedtoinstalltheLinuxoperatingsystemonthePC.ItisrecommendedtousetheUbuntu16.04
64bitdistribution,8Gmemory,andmorethan500Gfreeharddisk.Connectthenetworkcableandconfigurethenetwork.For
subsequentoperations,youneedtoconnecttotheInternettoinstallordownloadrelatedsoftwarepackages.
YoucanalsorefertotheofficialNXPdocument<Android_User's_Guide.pdf>.
RepalcetheUbuntusources-list
Noticethatthisonlyappliestothedeveloperinchina.Ifyouareinchina,thetunaresourceshouldinsteadofthedefault.
Thewebsiteisasfollows:
https://mirrors.tuna.tsinghua.edu.cn/help/ubuntu/
Choose16.04,andthencopythecontentstoupdate/etc/apt/source.list.
Operatingprocedures:
1.Backupthedefaultfile
cp/etc/apt/sources.list/etc/apt/sources.list-bak
2.Copycontentsfromthetuna16.04columnto/etc/apt/sources.listfile.
3.Updatesource
apt-getupdate
PS:Iferrorhappenstoappstream3,youcanremovethepackagefirstandthenupdate.
apt-getremovelibappstream3
apt-getupdate
Hostpackages
EssentialYoctoProjecthostpackagesare:
sudoapt-getinstallgawkwgetgit-corediffstatunziptexinfogcc-multilibbuild-essentialchrpathsocatlibsd
l1.2-devu-boot-tools
sudoapt-getinstalllibsdl1.2-devxtermsedcvssubversioncoreutilstexi2htmldocbook-utilspython-pysqlite2
help2manmakegccg++desktop-file-utilslibgl1-mesa-devlibglu1-mesa-devmercurialautoconfautomakegroffcu
rllzopasciidoc
Setrepofile
Therepofileisusedtodownloadresources,anditislocatedin03-Tools/Repoforchinese,itshouldbeinstalledonyourcomputer
byperformingthesestep:
mkdir~/bin
cp~/03-Tools/Repo/repo~/bin
chmoda+x~/bin/repo
exportPATH=~/bin:$PATH
Pleasefollowbelowstepsinsteadofabove,ifyouareabletoaccessgoogle.
2.Deploydevelopmentenvironment
5

mkdir~/bin
curlhttps://storage.googleapis.com/git-repo-downloads/repo>~/bin/repo
chmoda+x~/bin/repo
exportPATH=~/bin:$PATH
Configuregit
Makesurethatgitissetupproperlywiththecommandsbelow.
gitconfig--globaluser.name"abc123"
gitconfig--globaluser.email"def456@gmail.com"
gitconfig--list
2.Deploydevelopmentenvironment
6

3.Androidsystemprogramandcompile
Androidimagecompilationtakesalongtime,youcanusethecompiledimagetoprogramtothedevelopmentboard,useUUU
toolstoprogram.ThischapterfirstdescribeshowtoprogramimagestoEMMCandSDcards,andthenintroducesthemethodof
compilingimages.
3.Androidsystemprogramandcompile
7

3.1ProgramAndroidimagetoEMMC
Thecompiledimageislocatedinthe02-Imagedirectory,andthendecompresseandroid_p9.0.0_2.0.0-ga_image_8mq-myd-
MT53D512M32D2DS-053.zipundertheWINDOWSsystem.
UUUwillcreateasoftlink,sopleaseopencmdwithadministratorprivileges,asshownbelow:
3-1-1cmdpicture
Jumptothedecompresseddirectoryandexecute
uuu_imx_android_flash.bat-fimx8mq-a-e-c7
3-1-2UUUcommand
PleasemakesurethattheTFcardslotofthedevelopmentboardisnotinserted,theType-Cportisconnectedtothecomputerand
theotherendisconnectedtotheType-Cport(J8)ofthebaseboard.TheDIPswitchissetto(sw1)LLHL(sw2)HL,andthen
poweron.
3.1ProgramAndroidimagetoEMMC
8

3-1-3boardconnection
Theprocessisasfollows:
3-1-4program
Afterprogramming,settheDIPswitchto(sw1)LLHL(sw2)LHtostart.
3.1ProgramAndroidimagetoEMMC
9

3.2ProgramAndroidimagestoSDcard
Thecompiledimageislocatedinthe02-Imagedirectory,andthendecompresseandroid_p9.0.0_2.0.0-ga_image_8mq-myd-
MT53D512M32D2DS-053.zipundertheWINDOWSsystem.
UUUwillcreateasoftlink,sopleaseopencmdwithadministratorprivileges,asshownbelow:
3-2-1cmdpicture
Jumptothedecompresseddirectoryandexecute
uuu_imx_android_flash.bat-fimx8mq-a-e-c7-tsd
3-2-2UUUcommand
PleasemakesurethattheTFcardslotofthedevelopmentboardisnotinserted,theTyep-Cportisconnectedtothecomputerand
theotherendisconnectedtotheTyep-Cport(J8)ofthebaseboard.TheDIPswitchissetto(sw1)LLHL(sw2)HL,andthen
poweron.
3.2ProgramAndroidimagetoSDcard
10

3-2-3boardconnection
Theprocessisasfollows:
3-2-4program
After3/3InsertTFcard,pleasepayattentiontothistime.
3-2-5TFprogram
Afterprogramming,settheDIPswitchto(sw1)HHLL(sw2)LHtostart.
3.2ProgramAndroidimagetoSDcard
11

3.2ProgramAndroidimagetoSDcard
12

3.3CompileAndroidsystem
Pleasedecompressethesourcemyir_android9.0.0_2.0.0.tar.gzandexecutesourcemyir_build.shtostartcompiling
mkdirandroid_dir
tar-zxfmyir_android9.0.0_2.0.0.tar.gz-Candroid_dir
cdandroid_dir
sourcemyir_build.sh
Thecontentofthemyir_build.shfile.
snip
#build_bootloader
#build_kernel
#build_dtbo
make-j42>&1|teebuild-log.txt
build_bootloadercompileuboot
build_kernelcompilekernel
build_dtbocompiledtbofile
make-j42>&1|teebuild-log.txtcompletecompilation
ImageName Note
u-boot-imx8mq.imx Bootloader(withpadding)forJX8MXboard
u-boot-imx8mq-evk-uuu.imx BootloaderusedbyUUUforJX8MXboard.ItisnotflashedtoMMC.
boot.img BootimageforJX8MXboard.
system.img SystemBootimageforJX8MXboard.
vendor.img VendorimageforJX8MXboard.
partition-table.img GPTtableimagefor16GBSDcardandeMMC
partition-table-7GB.img GPTtableimagefor8GBSDcard.
partition-table-28GB.img GPTtableimagefor32GBSDcard.
dtbo-imx8mq.img DeviceTreeimageforJX8MXboardtosupportHDMIoutput.
vbmeta-imx8mq.img AndroidVerifyBootmetadataImageforJX8MXboardtosupportHDMI.
3.3CompileAndroidsystem
13

4.Androidfunctionintroduction
Functionlist:
4Kplayback
MIPI-CSIfrontandbackcamera
Network
WIFI
Bluetooth
Audiorecord
Headphone
USB3.0interface
4Gmodule
Uart
Spi
Notsupportlist:
M.2SSDautomount
MIPI-DSIconverttoLVDS
4.Androidfunctionintroduction
14

4.1DM-verityconfiguration
DM-verity(device-mapper-verity)providestransparentintegritycheckingofblockdevices.Itcanpreventdevicefromrunning
unauthorizedimages.Thisfeatureisenabledbydefault.Replacingoneormorepartitions(boot,vendor,system,vbmeta)will
maketheboardunbootable.DisablingDM-verityprovidesconviencefordevelopers,butthedeviceisunprotected.
TodisableDM-verity,performthefollowingsteps:
1. setting->system->abouttabletclickbuildnumbertoopendevelopmentoptions
2. setting->system->developeroptionsenableOEMunlocking
3. adbrebootbootloader
4. fastbootoemunlock
5. afterthefourthstepandbootupthedevice,excuteadbroot,adbdisable-verity,adbreboot
4-1-1buildnumber
4-1-2oemunlock
4.1DM-verityconfiguration
15

4-1-3rebootbootloader
4-1-4disable-verity
4.1DM-verityconfiguration
16

4.2NETWORKtest
Android9needstobeauthenticatedafterconnectingtothenetwork.TheAndroid9authenticationURLdefaultsto
www.google.com,whichischangedtowww.baidu.com.
Reference
gitlog--pretty=oneline
0a683de2689c2f6e072e58931b8e3a3daec03b97[fix]ourmemoryonlyhave2G,soredueceCMA1280Mto960M
0850026deeb135977c37d5b3ecbed4be0f6bbb39[fix]usewww.badiu.comreplacewww.google.com
293158fe4683e0120476ac06157f7bd69bb87d82[fix]dnsmasqavcerr
1. Connectthenetworkcable.Thesignalmarkwiththequestionmarkappearsintheupperleftcorner.
2. Pulldownandclicksigntonetwork.
3. Thebrowseropensthewebpageandclickstousethisnetwork.
4-2-1network
4-2-2signtonetwork
4.2NETWORKtest
17

4-2-3choosenetwork
EthernetAPPcanviewmoreinformation.
4.2NETWORKtest
18

4.3WIFItest
WifiandBluetootharethesamemodule,wenowsupport2modules:
Modules Options Function
Fn-Link8274B-PR androidboot.wifivendor=qca supportSTA+APmode
Fn-Link6222B-PR androidboot.wifivendor=rtk notsupportSTA+APmode
Thertkmoduleisusedbydefault.Ifitisaqcamodule,pleaserefertosection4.1todisabletheDM-verityrestriction.Then
modifythebootargsinuboot,andchangeandroidboot.wifivendor=rtktoandroidboot.wifivendor=qcaandsaveit.
Buildimagecanconfigureandroid_build\device\fsl\imx8m\evk_8mq\BoardConfig.mk
#Defaultlyevk_8mquseBCM1CXBCM4356wifimodule,ifuseQCOMqca9377module,setandroidboot.wifivendor=qca
BOARD_KERNEL_CMDLINE+=androidboot.wifivendor=rtk
Thewifi`santennaisU6.
settings->Network&internet->Wi-FiisusedtoconnectwifiAP.
settings->Network&internet->Hostpot&tetheringisusedtoconfigureAP.
Thertkmodulecan'tconnecttowifiandgeneratethehotspotatthesametimeisduetothewiphyaddressisdifferent,therewill
beproblemsinthewificonprocess.
evk_8mq:/#iwwlan0info
Interfacewlan0
ifindex7
wdev0x1
addr18:bb:26:58:55:e4
typemanaged
wiphy0
evk_8mq:/#iwp2p0info
Interfacep2p0
ifindex8
wdev0x100000001
addr1a:bb:26:58:55:e4
typemanaged
wiphy1
Afterconnectingtowifihere,youalsoneedtobeauthenticatedtoaccesstheInternet.Referto4.2.
4.3WIFItest
19

4.4BLUETOOTHtest
Bluetoothfirstreference4.3settothecorrectwifimodule.
Thebluetooth`santennaisU5.
settings->connecteddevices->Pairnewdevice->Avaliabledevices
4.4BLUETOOTHtest
20
Table of contents
Other MYiR Motherboard manuals