Archos Android based connected home solution - DroidCon Paris 2014
-
Upload
paris-android-user-group -
Category
Technology
-
view
328 -
download
0
description
Transcript of Archos Android based connected home solution - DroidCon Paris 2014
Archos connected home solutionMarc de Courville CTO
Archos who are we? 3 strategic pillars
Tablets
Smartphones
Connected home
• 2000: first HDD based MP3 player
• 2003: first PMP MP4 player
• 2009: first Android tablet
• 2012: first certified Android TV
• 201307: getting into phones
• 201406: Android based connected home solution
• Android since 1.5
• Google certification since 2011
Since July 2013Since June 2014
Tablet
Innovative connected
objects
CloudService
Client app
Archos connected home solution
• Central control unit for the home and bridge to the cloud
• Autonomous interaction between connected objects through scenarios and rule engine
• Simple and intuitive Android interface
• Discrete, non intrusive ultra minutarized objects
• Very low power and wireless
• Android, iOS compatible
Remote access management and notifications
House control at your finger tips anywhere anytime from your tablet/phone on Android/iOS
Infrastructure-less solution: no wires and wirering, no tools composed of 4 essential elements:
BLE+Wi-Fi+433MHz
Software architecture• Tablet Android firmware
• 2 major Android applications:– One Gateway service system (platform certificate)
running on the gateway
– One HACenter application running either on phone or gateway taking care of the user interface
• Each connected objects firmware
Flat / Colorful UI
For Phone and Tablets
4inches
7inches
10inches
Objects organized by rooms
User can freely organize objects in rooms with drag & drop
What does it do for me? Scenarios• Know when your kids are back from school/who
enters your home: camera ball and door sensor
• Aziz light! Lights on when you enter living room after sundown: smart plug and PIR: lights on at night!
• At 9:30pm close rooms 433MHz roller shutters and at sundown do the same in living room
+
+
Scenarios
• A set of rules to trigger actions based sensor inputs or time events
• How can we set rules: program editor!
Example of scenario: roller shutters• Rule editing:
– trigger at sunrise the opening of 433MHz roller shutters
Example of scenario: temperature monitoring• Rule editing:
– Send notification when it is too hot
Example of scenario: door• Rule editing:
– When door opens plays a ringtone on smart home tablet
More complex scenario: door• Rule editing:
– When door opens take a picture of who enters and send it via email from 8am to 8pm on some selected days of the week
Archos connected home technology bricks• Connected objects:
– Bluetooth smart with 10dBm TX power
– Support for 13 objects 24/7 always connected
– Power saving optimization
– Admissible Wi-Fi/BLE coexistence
– Proprietary GATT profiles
– Encrypted link with long terms keys
– Home tablet BLE heavily patched stack
• Remote connectivity:– SDP exchange with GCM
– STUN/ICE to establish connection
– TCP over UDP with SSL for secure communication
– Protobuf for data communication format
– UPnP port forwarding mechanism
• Cloud service:– Google Apps Engine hosted Archos server
– Gateway registration
– GCM relay and notifications
– APNS support
• All can be updated over the air:– Firmware though Archos OTA servers
– Gateway service and HACenter app through GooglePlay
– Object firmwares included in Gateway service apk (update speed has been optimized!)
• Wireless versatility– Wi-Fi/BLE and a new one 433MHz with learn
and play feature
Application/Service architecture
Remote connection scheme
Preserve security• IoT claimed not secure, our remedy:
– No user data stored in the cloud, all is on the gateway
– Communications: TCP over UDP for SSL secure links
– BLE communications using 128-bit AES with Counter Mode CBC-MAC in connected mode
– Secure pairing of the objects requiring manual pairing mode via physical button pressed
– Gateway knows server Certificate to prevent redirection to fake servers
– Secure pairing between gateway and remote phone/tablet using either local connectivity or secure token with manual confirmation on gateway
Technical challenges solved• Low power consumption and ultra miniaturized connected objects:
– Choice of Bluetooth Low Energy (BT4.0) technology which compared to Zigbee offers a predictive transmission over the air (slotted TDD) allowing for the accessories mastered and longer sleep periods and a more energy efficient modulation
• Grant a maximum range comparable to Wi-Fi– Maximum EIRP transmit power of 10mW (10dBm)
– Careful antenna design both on tablet and accessory sides
– GFSK modulation index of 0.5 granting longer transmission range than Bluetooth
• Push BLE usage to its limits:– Heavily modified Android Bluetooth stack on tablet side to:
• Increase number of simultaneous connected objects from 4 to 13
• Grant 24/7 operation without interruption
– Ensure peaceful BLE-Wi-Fi coexistence on the tablet while sharing same antenna and frequency band (competition)
Bluetooth Low Energy enhancements• Observation: BLE on 4.3/4.4
is still flaky at most
• Archos Home is running 4.2 with 4.4+/L BLE stack backports and custom modifications in order to: ensure 24/7 operation in connected mode– BLE/Wi-Fi coexistence (chip fw
and traffic priority)/Power saving/Stability
• Related changes shared openly with Google/BCM/ bluetooth.org(soon)
BLE stack improvements (zoom)Issue Archos solution Android AOSP
Limited number of simultaneous connected objects : 4 Stack limit increased to 32 but limited by chip implementation to 13 7 in Android L
Limited number of notification types for a given object (4) per app Stack limit increased to 10 7 in Android L
Pairing keys database not always up to date Remove and save keys when needed Solved in Android L
Default connection timings were too aggressive leading to disconnections
Set acceptable timings Solved in android L
Cannot switch connection parameters at will (only once per connection)
Be able to switch any time Solved in android L
Same connection parameters can be requested several times We prevent this as it can take long time to switch Not solved
Connection timing are switched back to default when discovering services
Discard if new timings are faster Not solved
BLE commands are discarded without any feedback if one is already in the pipe
We reply with a busy state Not solved
Random crash of the stack Pointer issue when crossing the stack layers Solved in android L
A connection could not be cancelled if it was not established Case fixed Solved in Android KitKat
Sometimes the connection data were not well cleaned Do more cleaning Solved in Android KitKat
Only the first peripheral in whitelist can connect Fix suspend/resume command Not solved
Disabling Bluetooth can fail if lots of peripherals are connected Increase timeout to let time for proper disconnections Not solved
Packets lost in stack when we are receiving lots of data and application does not handle them quickly enough
Increase number of buffers used but can still be improved as buffer size is 4K and BLE message uses less
Not solved
When enabling service changed indication, sometimes after a while no notification can be received from app
Decrease timeout for indication response (important for fw updates)
Not solved
Peripheral disconnections if several connected at same time Some fixes around round robin implementation Not solved
Range and coverage consideration• Our BLE solution achieves similar or better range than Wi-Fi
IEEE802.11g OFDM lowest 6Mbps rate:– BLE rate is 1Mbps
– Energy per bit boost factor for BLE is 6, i.e. 7.8dB, transmit power of BLE for our solution is 10dBm and for Wi-Fi around 15-17dBm for most routers
• All other BLE solutions are more for body area networks and are transmitting at 0dBm. What is the impact in coverage?– Path loss model for indoor ITU-R P.1238-7,
f=2400MHz• L
total=20log
10(f)+30log
10(d)–28 in dB
– Range impact is thus 1010/30 around 0.46x reduction in distance (more than halved)
BLE 0dBm
Wi-Fi 15dBm
BLE 10dBmd
MiniCam: a strange animal• First and only BLE VGA camera
– optimized for low power consumption
• Battery life:– Able to take more than 1200 pictures transmitted consecutively every 5mn
before running out of battery at 3m with average size pictures (30kB)
– Mileage may vary depending on image size, battery chemistry (internal resistance), range, foreign Wi-Fi traffic interference
• Ingredients: – Take internally two pictures (one for auto-gain and white balance), optimized
JPG compression matrix for image size, clever buffer management for image retransmission, manage camera IC/BLE module intercommunication buffers, use of retention. Dynamic connection timing management for high data rate and power saving. Battery monitory @120Hz. Non acknowledged notifications to reach maximum throughput.
Expand compatibility: 433MHz• Tablet embeds a 433MHz ASK transceiver (10dBm) and
support has been added to Android
• Primary use: extend compatibility of tablet to foreign accessories through learn and play of remote signal providing compatibility with most of the On-Off Keying (OOK) based devices available on the market– Chacon (DI-O), Blyss, Phenix, Auchan, IDK, Home Confort (SRST2-
E27)
– Support for some popular rolling codes is being added
Opening up
• Archos is considering opening up to developers to provide– Direct access to our own BLE accessories
(gattlib)
– Communication with our Gateway Service through intents
– Links with external applications:• Archos can call tasker through intent picker
• Compatibility with IFTTT under consideration
Evolve towards ubiquity and universality
– Accessibility: get away from the professional programmatic approach and gain in ubiquity through self learning and auto-organization
• E.g.: automatic heating adjustment based on presence detection, thermal home characteristics, weather parameters to optimize cost or comfort metric
– Convergence: unite a fragmented world composed of pseudo-standards and evolve towards a perceived universal solution
• Challenges and required evolution:
Time/roadmap
Technologies/standard
Compatibility/brands
433MHz
• Two major players in standard convergence:– Thread-group/homekit
What comes next
• Strengthen portfolio around 2 axis for Archos connected home offering:– Security/monitoring:
– Comfort/energy management