Springboard & OpenCV

Preview:

Citation preview

Springboard Setup &OpenCV

JerryICChen

Outline

Setup Springboard OpenCV for android

Setup environment to build OpenCV for Android OpenCV build tricks Demo sample

Springboard Robot Concept / Architecture Key point Usb-to-serial BT

Setup Springboard

Introduction http://www.viaspringboard.com/products/via-vab-600-springboard-kit.html

800Mhz Arm Cortex-A9 Soc 1GB DDR3 SDRAM on board 4GB on board eMMC flash Mini-HDMI port/ USB 2.0 Ethernet Micro SD card reader on board

Setup Springboard with Android4.0.3 Requisition:

Micro SD card 4GB above Download Android SW development package

http://www.viaspringboard.com/via-vab-600-springboard-software-development-packages.html

Extract ./bspinst, and .scriptcmd to SD card Insert SD card, and reboot springboard Reboot then enter firmware burning(~100%, blue

background) Remove SD card from springboard Reboot and enter Android OS

OpenCV for Android

OpenCV is a powerful open library for image processing and pattern recognition

OpenCV for win, linux , processing and OpenCV for Android

Download from : http://opencv.org/downloads.html

Info: http://docs.opencv.org/doc/tutorials/introduction/android_binary_package/O4A_SDK.html

Setup environment to build OpenCV for Android Require:

JDK : http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html

Eclipse or ADT-bundle Eclipse is an IDE for programming C, C++, Java, and android ADT-bundle = Eclipse + Android SDK

Released by Google. (I prefer to install ADT-bundle!) Assume install to <ADT-dir>

Android NDK, jni native code language development kit (Some OpenCV sample is built by jni ) Assume install to <NDK-dir>

Import OpenCV sdk

Extract OpenCV for Android to <OpenCV-sdk-dir>

Run eclipse FileImport

projectsAndroid Existing Android code into workspace

Choose the <OpenCV-sdk-dir>\sdk\java

Import OpenCV4Android samples Extract Android-NDK to <NDK-dir> Run eclipse

File->New Project Android Existing Android code into workspace

Choose <OpenCV-dir>\samples\<sample-name><sample-name> = face-detection, mixprocessing,…

OpenCV sample build trick

OpenCV4Android samples compile fails: “Cannot recognize android-10 !”

Open WindowSDK Manager, check the SDK version (android-17 or …) which is installed on local

,Change to local installed Android-SDK version

“Cannot find ndk-build.cmd !” Project->propertiesC/C++ build Builder

SettingsBuild command ${NDKROOT}\ndk-build.cmd Set path to <NDK-dir>\ndk-build.cmd

Before Upload & install OpenCV samples to Springboard After successully build OpenCV samples, we are

going to upload *.apk to Springboard Setup Springboard with a Ethernet ip-address

Springboard’s Android OSSettingsEthernet : enable and set a static ip address for it, <Target IP>.

Enter terminal C:\> (in Win), or bash$ (in linux) Find <ADT-dir>\sdk\platform-tools\adb.exe adb kill-server adb devices , (when debugging through USB cable) adb connect <Target IP> , (when debugging through

ethernet)

Upload & install OpenCV samples to Springboard In eclipse, “Run as Android application”, or

“Debug as Android application” Springboard will run the uploaded Android

application

Comment for Springboard ETK Android OS No Internet web browser apk No App Store (Google Play),

need to use adb install to upload *.apk Built-in script language,

python, ruby. Built-in library

Smart ETK, OpenCV, usb-to-serial, processing, and streaming rtsp library

Need Start-up tutorial on Android / Linux www.viaspringboard.com

OpenCV face-detection

More application !

Since OpenCV runs smoothly on Springboard Robotic visual Security surveillance

Other application NAT, media streaming Car mobile computing, since 12V is suitable for

Car power-supply Public area electronic-art decoration, with

Processing, light-sensor & light control Electronic advertisement

Springboard(Brain)OpenCV,

Pattern Recognition,Communation

Arduino(Spine)Collision Reflex,

Interrupts,

Chassis

Usb-to-serial

or BT

12V Battery

Reflex action

Afterward acknowledge

Radio / WiFi

Recommended