device creation with qt enterprise embedded
play

Device Creation with Qt Enterprise Embedded Andy Nichols Overview - PowerPoint PPT Presentation

Device Creation with Qt Enterprise Embedded Andy Nichols Overview The challenges of device creation What is Qt Enterprise Embedded Prototyping a device Device creation 2 The Challenges of Device Creation 3 The Application is


  1. Device Creation with Qt Enterprise Embedded Andy Nichols

  2. Overview • The challenges of device creation • What is Qt Enterprise Embedded • Prototyping a device • Device creation 2

  3. The Challenges of Device Creation 3

  4. The Application is just one step • Qt is used to more easily produce Applications • Easy to share code across multiple platforms 4

  5. The Application dictates the hardware 5

  6. The Application and Hardware dictate the OS 6

  7. Provide your own SDK • Toolchain to generate binaries for your hardware • System image to fl ash to device • Sysroot containing the development fi les 7

  8. Device Creation with Qt • Qt abstracts away the details of the OS and hardware • It is still up to you to provide the platform 8

  9. What is Qt Enterprise Embedded? • Qt • Platform • Tooling 9

  10. Qt + Additional tools for Device Creators • Latest Qt Release • Charts API • Virtual Keyboard • 3D Data Visualisation • Enterprise Qt Quick Controls • Qt WebEngine • Wi fi Utilities • Qt Quick Compiler 10

  11. Virtual Keyboard 11

  12. Enterprise Qt Quick Controls 12

  13. Wi fi Utilities 13

  14. Charts and 3D Data Visualisation APIs 14

  15. Qt WebEngine 15

  16. What is Qt Enterprise Embedded? • Qt • Platform • Tooling 16

  17. Qt Enterprise Embedded provides the platform 17

  18. Embedded Linux Platform • Using Yocto Project tools • b2qt-meta layer to provide barebones distro for Qt 5 • Yocto is the industry standard • Many meta layers available for you to mix-n-match 18

  19. Embedded Android • Android Injection • No need to build the AOSP, use existing device images • Android without Java, Using Platform Developers APIs • Take advantage of a device that already fi ts your needs 19

  20. What is Qt Enterprise Embedded? • Qt • Platform • Tooling 20

  21. Qt Creator IDE 21

  22. Pre-con fi gured Kits for your Device • Linux: Use the SDK built by Yocto • Android: Just select the version of Android that is on your device 22

  23. One Click Deploy • USB • Ethernet 23

  24. Remote Debugging of C++ and QML 24

  25. Remote Pro fi ling 25

  26. Device Emulator 26

  27. Prototyping a Device 27

  28. Reference Hardware • Pre-built Images • SDKs • Start prototyping on hardware from Day 1 28

  29. Linux Reference Hardware • Beaglebone Black • Toradex Apalis iMX6 • Raspberry Pi • Freescale Sabre • Emulator • Boundary Devices Nitrogen6x 29

  30. Android Reference Devices • Nexus 7 (2012/2013) • Beaglebone Black • Freescale Sabre • Boundary Devices Nitrogen6x • Emulator 30

  31. Getting Started • Install the SDK for the device from the Qt Installer • Flash the image to the device with our deploy scripts • Plug in the USB and launch your App from Qt Creator 31

  32. Bene fi ts of Prototyping on real hardware • Test an SOC to see if its a good fi t for your product • Have a mock up to show your boss or VC • The code can be reused for the actual product 32

  33. Device Creation 33

  34. Linux device SDK • Use Yocto to generate base system image and SDK • Build Qt, Add-ons, and B2Qt Utilities • Register new SDK with Qt Creator 34

  35. Using Yocto • Base image and SDK for device • Vendor speci fi c meta-layers • De fi ne additional features and 3rd party libraries • Modify the kernel to meet your needs 35

  36. Build your own stack #Setup Yocto tools/repos � cd <BuildDir> � <INSTALL_DIR>/Boot2Qt-3.x/sources/b2qt-yocto-meta/b2qt-init-build-env . � export TEMPLATECONF=meta-b2qt/conf � export MACHINE=beaglebone � source poky/oe-init-build-env build-beaglebone � � #build base image � bitbake b2qt-embedded-image � � #build SDK (toolchain/sysroot) � bitbake meta-toolchain-b2qt-embedded-sdk 36

  37. Need help with Yocto? • Yocto User Manual • Yocto eBook • The Qt Company and its partners 37

  38. Building Qt, Add-ons, B2Qt Utils #Setup Build Environment � <INSTALL_DIR>/Boot2Qt-3.x/sources/b2qt-build-scripts/embedded-common/ init_build_env.sh <INSTALL_DIR>/Boot2Qt-3.x/sources/b2qt-build-scripts/embedded- linux/config.beaglebone � � #Build Qt Libraries � <INSTALL_DIR>/Boot2Qt-3.x/sources/b2qt-build-scripts/embedded-linux/build_qt.sh � � #Build Add-ons and Utils � <INSTALL_DIR>/Boot2Qt-3.x/sources/b2qt-build-scripts/embedded-linux/build_extras.sh � � #Generate new boot Image � <INSTALL_DIR>/Boot2Qt-3.x/sources/b2qt-build-scripts/embedded-linux/build_image.sh � � 38

  39. Building Qt for custom machines • con fi g.${MACHINE} • appcontroller.conf.${MACHINE} • qt.conf.${MACHINE} 39

  40. con fi g.${MACHINE} #beaglebone config � export PLATFORM="eLinux" � export MACHINE="beaglebone" � export DEVICE="linux-beaglebone-g++" � export ARCH="arm" � export SYSROOT="armv7ahf-vfp-neon-poky-linux-gnueabi" � export COMPILER="arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-" 40

  41. appcontroller.conf.${MACHINE} #beaglebone appcontroller environment � env=QML2_IMPORT_PATH=/data/user/qt/qmlplugins � env=QT_IM_MODULE=qtvirtualkeyboard � env=QT_QPA_EGLFS_FORCE888=0 � base=linux � platform=beaglebone 41

  42. qt.conf.${MACHINE} #beaglebone qt.conf � [Paths] � Sysroot=../../toolchain/sysroots/armv7ahf-vfp-neon-poky-linux-gnueabi � Prefix=/bin/../../../../qt5 � HostPrefix=.. � 42

  43. Register new SDK with Qt Creator #Register new Kit in Qt Creator � <INSTALL_DIR>/Boot2Qt-3.x/sources/b2qt-build-scripts/embedded-common/ setup_qtcreator.sh 43

  44. Android Device SDK • Android 4.2 or Android 4.4 • Root access • Unlocked bootloader 44

  45. Android Injection • Modify init.rc • Deploy payload based on Android version 45

  46. Android Injection: Nexus 4 #Modify boot image � abootimg -x ../boot.img � mkdir initrd � cd initrd � cat ../initrd.img | gunzip | cpio -vid � � #Modify the init.rc file using the sed file � sed -f <INSTALL_DIR>/Boot2Qt-3.x/generic-4.2-eAndroid/images/generic/modify_init_rc.sed -i init.rc � � #Repackage the boot.img � find . | cpio --create --format='newc' | gzip > ../myinitrd.img � abootimg --create myboot.img -f bootimg.cfg -k zImage -r myinitrd.img � � #Flash the new boot.img to the device � fastboot flash boot myboot.img � fastboot reboot 46

  47. Android Injection: Nexus 4 #Push Data Payload to the device � mkdir data � tar xf <INSTALL_DIR>/Qt/Boot2Qt-3.x/generic-4.2-eAndroid/images/data.tar.xz -C data/ � find data -type d -exec adb shell mkdir -p /{} \; � adb push data/. /data 2>&1 | grep -v '\ ->\ ' � #Push System Payload to the device � mkdir system � tar -xf <INSTALL_DIR>/Boot2Qt-3.x/generic-4.2-eAndroid/images/system.tar.xz -C system/ � cp <INSTALL_DIR>/Boot2Qt-3.x/generic-4.2-eAndroid/images/nexus7/appcontroller.conf . � cp appcontroller.conf system/bin/ � cp <INSTALL_DIR>/Boot2Qt-3.x/generic-4.2-eAndroid/images/common/gdbserver system/bin/ � adb remount � find system -type d -exec adb shell mkdir -p /{} \; � adb push system/. /system 2>&1 | grep -v '\ ->\ ' 47

  48. Demo Time! 48

  49. Future Research • Build Everything in Yocto • Low end pro fi le (DirectFB) • Multi-process support (Wayland) 49

  50. Questions? 50

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend