SlideShare uma empresa Scribd logo
1 de 36
HueMore
By Eric Kuxhausen
HueMore
• Android app
• Controls the Phillips Hue lighting system
• ST: Applied Human Computer Interaction
project
• Published:
https://play.google.com/store/apps/details?id=com.kuxhausen.huemore
BACKGROUND
The Phillips Hue ecosystem
Philips Hue LED bulbs
Photo Credit: http://www.amazon.com/gp/product/B00BSN8DN4/ref=noref?ie=UTF8&psc=1&s=hi
Smartphone Controlled Lighting
Photo Credit: http://www.multiroom.fr/zigbee-light-link-la-norme-de-reference-pour-le-controle-declairage/
USE CASES
Using smartphones to integrate controlled lighting into everyday life
Multipurpose space
• Manipulate color temperature (red vs blue tint
in whitish light)
• Reuse room for concentration and relaxation
Set the Mood
• Colorful and time variant lighting options
• Anything from candlelight dinner to dance
party
Sleep Assistant
• Dim the lights as bedtime approaches
• Fade the lights on to gently wake up in
morning
Optimized Circadian Biorhythm
• Automatically vary color temperature
throughout the day to match to sunlight color
• Fight seasonal affectiveness disorder with
brighter light in the winter
Control Away from Home
• Run lights while on vacation to appear home
• Save power by turning off lights when last
person leaves
DESIGN CONCERNS
Convenience
• Minimize the number of clicks in everyday use
cases
• Physical light switches not viable
• Users can save settings to NFC tags and place
on walls instead of lightswitches
– NFC tags reprogrammable to auto-apply presets
or bring up onscreen options
Access Control
• How does this scale for family use?
SCREENSHOTS
Select a group of lights Then apply a mood
Schedule Alarms Create new moods
DEVELOPMENT
Process
• IDE: Eclipse with Android plugins
• Version control: git via Github
• Unit testing for NFC subcomponent
• Compatibility testing across Android Virtual
Machines representing:
– Android versions 2.3 to 4.2
– Small smartphones up to tablets
Magnitude of Project
• 20+ screens the user might see
• 60+ java classes
• 10,000+ lines of code
• Translated into 4 languages
• Developed in 2 months
Kilolines of code modified
Architecture
• Heavy use of OO design principles
• 5 major elements:
– View
– ModelView (integrated with Model)
– Persistence
– Networking
– System-Event interaction (Alarms and NFC)
View
• 30 layouts built from standard UI elements
• Defined with Android layout xml files
• Different versions between screen
sizes, Android versions
ModelView
• Java code extending Android Activity and
Fragment classes
• Used Android supportV4 library to backport UI
elements to legacy Android devices
• Manual bindings to Views handle UI
interaction, data population
Persistence
• Databases wrapped by Android
ContentProvider implementation
• 3 mySQL lite databases for:
– Groups
– Moods
– Alarms
• Android’s key-value preference system to track
database patches, user settings, etc
Networking
• Extensions of Android AsycTask
• Philips Hue API
• Android standard Apache library for http get,
post, put requests
• Gson library translates between internal java
objects representation and json for API
requests & responses
System-Event Interactions
• Alarms
– Schedule with PendingIntent
– Receive with BroadcastListener
• NFC
– Write NDEF messages containing URL with
appended data (custom dataencoding protocol)
– Read with system IntentFilter
HUEMORE NFC PROTOCOL 1.0
Encoding light moods on nfc tags with as little as 46 bytes of storage
Constraints
• NFC tags on the market that store as little as
46 bytes of usable storage
• Needs to support entire Hue bulbs API to be
forwards compatible with the rest of HueMore
Data wrapper
• NDEF record on tag containing a URL to
www.kuxhausen.com/HueMore/nfc?
• Websafe base64 data appended to end of URL
Data bitstring
• 4 bit version number
• 50 bit bulbs included flags
• 7 bit number of states
• Sequential listing of states
State subbitstring
• 9 bits flagging optional inclusion of the following:
– 1 bit on
– 8 bit brightness number
– 16 bit hue number
– 8 bit saturation number
– 64 bit xy float pair
– 9 bit color temperature number
– 2 bit alerts enums
– 4 bit effect enums
– 16 bit transitiontime number
Protocol Analysis
• Numbers are big endian
• Flags are bit strings (little endian)
• No checksum (as of V1)
• Orders of magnitude more space efficent tha
storing json api calls
DEPLOYMENT
Distributed on Google Play
FUTURE

Mais conteúdo relacionado

Destaque

surge diverters
surge diverterssurge diverters
surge divertersnehakardam
 
L01 New Technology 2017 Course Description
L01 New Technology 2017 Course DescriptionL01 New Technology 2017 Course Description
L01 New Technology 2017 Course DescriptionÓlafur Andri Ragnarsson
 
New Technology 2017 L02 Evolution of Technology
New Technology 2017 L02 Evolution of TechnologyNew Technology 2017 L02 Evolution of Technology
New Technology 2017 L02 Evolution of TechnologyÓlafur Andri Ragnarsson
 
New Media New Technology 2017 workshop 1
New Media New Technology 2017 workshop 1New Media New Technology 2017 workshop 1
New Media New Technology 2017 workshop 1Peter Van Der Putten
 
Establishing a Successful International Web Presence #InternationalSEO #SMX W...
Establishing a Successful International Web Presence #InternationalSEO #SMX W...Establishing a Successful International Web Presence #InternationalSEO #SMX W...
Establishing a Successful International Web Presence #InternationalSEO #SMX W...Aleyda Solís
 
Virtual Reality-Seminar presentation
Virtual Reality-Seminar  presentationVirtual Reality-Seminar  presentation
Virtual Reality-Seminar presentationShreyansh Vijay Singh
 
Technology powerpoint presentations
Technology powerpoint presentationsTechnology powerpoint presentations
Technology powerpoint presentationsismailraesha
 

Destaque (13)

surge diverters
surge diverterssurge diverters
surge diverters
 
New Technology 2017 L04 Exponential World
New Technology 2017 L04 Exponential WorldNew Technology 2017 L04 Exponential World
New Technology 2017 L04 Exponential World
 
L01 New Technology 2017 Course Description
L01 New Technology 2017 Course DescriptionL01 New Technology 2017 Course Description
L01 New Technology 2017 Course Description
 
New Technology 2017 L02 Evolution of Technology
New Technology 2017 L02 Evolution of TechnologyNew Technology 2017 L02 Evolution of Technology
New Technology 2017 L02 Evolution of Technology
 
Power Management in BMS
Power Management in BMSPower Management in BMS
Power Management in BMS
 
New Technology 2017 L01 introduction
New Technology 2017 L01 introductionNew Technology 2017 L01 introduction
New Technology 2017 L01 introduction
 
New Media New Technology 2017 workshop 1
New Media New Technology 2017 workshop 1New Media New Technology 2017 workshop 1
New Media New Technology 2017 workshop 1
 
Virtual reality
Virtual realityVirtual reality
Virtual reality
 
Virtual Reality
Virtual RealityVirtual Reality
Virtual Reality
 
Virtual Reality
Virtual RealityVirtual Reality
Virtual Reality
 
Establishing a Successful International Web Presence #InternationalSEO #SMX W...
Establishing a Successful International Web Presence #InternationalSEO #SMX W...Establishing a Successful International Web Presence #InternationalSEO #SMX W...
Establishing a Successful International Web Presence #InternationalSEO #SMX W...
 
Virtual Reality-Seminar presentation
Virtual Reality-Seminar  presentationVirtual Reality-Seminar  presentation
Virtual Reality-Seminar presentation
 
Technology powerpoint presentations
Technology powerpoint presentationsTechnology powerpoint presentations
Technology powerpoint presentations
 

Semelhante a Control Your Home's Lighting from Anywhere with HueMore

Developing Apps for Windows Phone 8
Developing Apps for Windows Phone 8Developing Apps for Windows Phone 8
Developing Apps for Windows Phone 8KMS Technology
 
Machine learning from software developers point of view
Machine learning from software developers point of viewMachine learning from software developers point of view
Machine learning from software developers point of viewPierre Paci
 
DevBy. Apple Watch Kit 1.0 (RU) & NFC
DevBy. Apple Watch Kit 1.0 (RU) & NFCDevBy. Apple Watch Kit 1.0 (RU) & NFC
DevBy. Apple Watch Kit 1.0 (RU) & NFCVladimir Hudnitsky
 
Developing windows 10 universal apps
Developing windows 10 universal appsDeveloping windows 10 universal apps
Developing windows 10 universal appsChris Dufour
 
Android Programming Basic
Android Programming BasicAndroid Programming Basic
Android Programming BasicDuy Do Phan
 
Docker Online Meetup #31: Unikernels
Docker Online Meetup #31: UnikernelsDocker Online Meetup #31: Unikernels
Docker Online Meetup #31: UnikernelsDocker, Inc.
 
Application Design, Development and User Experience Methodologies for the 2 i...
Application Design, Development and User Experience Methodologies for the 2 i...Application Design, Development and User Experience Methodologies for the 2 i...
Application Design, Development and User Experience Methodologies for the 2 i...Intel® Software
 
MIPI DevCon 2016: Accelerating Software Development for MIPI CSI-2 Cameras
MIPI DevCon 2016: Accelerating Software Development for MIPI CSI-2 CamerasMIPI DevCon 2016: Accelerating Software Development for MIPI CSI-2 Cameras
MIPI DevCon 2016: Accelerating Software Development for MIPI CSI-2 CamerasMIPI Alliance
 
Android Application Development Training by NITIN GUPTA
Android Application Development Training by NITIN GUPTA Android Application Development Training by NITIN GUPTA
Android Application Development Training by NITIN GUPTA NITIN GUPTA
 
Embedded Systems Design and Programming & Internet of Things
Embedded Systems Design and Programming & Internet of ThingsEmbedded Systems Design and Programming & Internet of Things
Embedded Systems Design and Programming & Internet of ThingsVasundhara Sharma
 
NUX Presentation from TechMixer Birmingham 2011
NUX Presentation from TechMixer Birmingham 2011NUX Presentation from TechMixer Birmingham 2011
NUX Presentation from TechMixer Birmingham 2011Michael Heydt
 
Building a More Connected World
Building a More Connected WorldBuilding a More Connected World
Building a More Connected WorldSilicon Labs
 
Track 2 session 4 - st dev con 2016 - opensoftwarex
Track 2   session 4 - st dev con 2016 - opensoftwarexTrack 2   session 4 - st dev con 2016 - opensoftwarex
Track 2 session 4 - st dev con 2016 - opensoftwarexST_World
 
ASP.NET MVC 4 Overview
ASP.NET MVC 4 OverviewASP.NET MVC 4 Overview
ASP.NET MVC 4 OverviewGunnar Peipman
 

Semelhante a Control Your Home's Lighting from Anywhere with HueMore (20)

Developing Apps for Windows Phone 8
Developing Apps for Windows Phone 8Developing Apps for Windows Phone 8
Developing Apps for Windows Phone 8
 
Machine learning from software developers point of view
Machine learning from software developers point of viewMachine learning from software developers point of view
Machine learning from software developers point of view
 
Meeting-Room-Alert-System
Meeting-Room-Alert-SystemMeeting-Room-Alert-System
Meeting-Room-Alert-System
 
DevBy. Apple Watch Kit 1.0 (RU) & NFC
DevBy. Apple Watch Kit 1.0 (RU) & NFCDevBy. Apple Watch Kit 1.0 (RU) & NFC
DevBy. Apple Watch Kit 1.0 (RU) & NFC
 
Google android os
Google android osGoogle android os
Google android os
 
IWESEP 2013
IWESEP 2013IWESEP 2013
IWESEP 2013
 
Developing windows 10 universal apps
Developing windows 10 universal appsDeveloping windows 10 universal apps
Developing windows 10 universal apps
 
Android Programming Basic
Android Programming BasicAndroid Programming Basic
Android Programming Basic
 
Docker Online Meetup #31: Unikernels
Docker Online Meetup #31: UnikernelsDocker Online Meetup #31: Unikernels
Docker Online Meetup #31: Unikernels
 
Application Design, Development and User Experience Methodologies for the 2 i...
Application Design, Development and User Experience Methodologies for the 2 i...Application Design, Development and User Experience Methodologies for the 2 i...
Application Design, Development and User Experience Methodologies for the 2 i...
 
Android Presentation
Android PresentationAndroid Presentation
Android Presentation
 
MIPI DevCon 2016: Accelerating Software Development for MIPI CSI-2 Cameras
MIPI DevCon 2016: Accelerating Software Development for MIPI CSI-2 CamerasMIPI DevCon 2016: Accelerating Software Development for MIPI CSI-2 Cameras
MIPI DevCon 2016: Accelerating Software Development for MIPI CSI-2 Cameras
 
Android Application Development Training by NITIN GUPTA
Android Application Development Training by NITIN GUPTA Android Application Development Training by NITIN GUPTA
Android Application Development Training by NITIN GUPTA
 
Embedded Systems Design and Programming & Internet of Things
Embedded Systems Design and Programming & Internet of ThingsEmbedded Systems Design and Programming & Internet of Things
Embedded Systems Design and Programming & Internet of Things
 
NUX Presentation from TechMixer Birmingham 2011
NUX Presentation from TechMixer Birmingham 2011NUX Presentation from TechMixer Birmingham 2011
NUX Presentation from TechMixer Birmingham 2011
 
Building a More Connected World
Building a More Connected WorldBuilding a More Connected World
Building a More Connected World
 
Track 2 session 4 - st dev con 2016 - opensoftwarex
Track 2   session 4 - st dev con 2016 - opensoftwarexTrack 2   session 4 - st dev con 2016 - opensoftwarex
Track 2 session 4 - st dev con 2016 - opensoftwarex
 
ASP.NET MVC 4 Overview
ASP.NET MVC 4 OverviewASP.NET MVC 4 Overview
ASP.NET MVC 4 Overview
 
C#: Past, Present and Future
C#: Past, Present and FutureC#: Past, Present and Future
C#: Past, Present and Future
 
Introduction to FIWARE Open Ecosystem
Introduction to FIWARE Open EcosystemIntroduction to FIWARE Open Ecosystem
Introduction to FIWARE Open Ecosystem
 

Último

Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilV3cube
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 

Último (20)

Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 

Control Your Home's Lighting from Anywhere with HueMore

  • 2. HueMore • Android app • Controls the Phillips Hue lighting system • ST: Applied Human Computer Interaction project • Published: https://play.google.com/store/apps/details?id=com.kuxhausen.huemore
  • 4. Philips Hue LED bulbs Photo Credit: http://www.amazon.com/gp/product/B00BSN8DN4/ref=noref?ie=UTF8&psc=1&s=hi
  • 5. Smartphone Controlled Lighting Photo Credit: http://www.multiroom.fr/zigbee-light-link-la-norme-de-reference-pour-le-controle-declairage/
  • 6. USE CASES Using smartphones to integrate controlled lighting into everyday life
  • 7. Multipurpose space • Manipulate color temperature (red vs blue tint in whitish light) • Reuse room for concentration and relaxation
  • 8. Set the Mood • Colorful and time variant lighting options • Anything from candlelight dinner to dance party
  • 9. Sleep Assistant • Dim the lights as bedtime approaches • Fade the lights on to gently wake up in morning
  • 10. Optimized Circadian Biorhythm • Automatically vary color temperature throughout the day to match to sunlight color • Fight seasonal affectiveness disorder with brighter light in the winter
  • 11. Control Away from Home • Run lights while on vacation to appear home • Save power by turning off lights when last person leaves
  • 13. Convenience • Minimize the number of clicks in everyday use cases • Physical light switches not viable • Users can save settings to NFC tags and place on walls instead of lightswitches – NFC tags reprogrammable to auto-apply presets or bring up onscreen options
  • 14. Access Control • How does this scale for family use?
  • 16. Select a group of lights Then apply a mood
  • 19. Process • IDE: Eclipse with Android plugins • Version control: git via Github • Unit testing for NFC subcomponent • Compatibility testing across Android Virtual Machines representing: – Android versions 2.3 to 4.2 – Small smartphones up to tablets
  • 20. Magnitude of Project • 20+ screens the user might see • 60+ java classes • 10,000+ lines of code • Translated into 4 languages • Developed in 2 months
  • 21. Kilolines of code modified
  • 22. Architecture • Heavy use of OO design principles • 5 major elements: – View – ModelView (integrated with Model) – Persistence – Networking – System-Event interaction (Alarms and NFC)
  • 23. View • 30 layouts built from standard UI elements • Defined with Android layout xml files • Different versions between screen sizes, Android versions
  • 24. ModelView • Java code extending Android Activity and Fragment classes • Used Android supportV4 library to backport UI elements to legacy Android devices • Manual bindings to Views handle UI interaction, data population
  • 25. Persistence • Databases wrapped by Android ContentProvider implementation • 3 mySQL lite databases for: – Groups – Moods – Alarms • Android’s key-value preference system to track database patches, user settings, etc
  • 26. Networking • Extensions of Android AsycTask • Philips Hue API • Android standard Apache library for http get, post, put requests • Gson library translates between internal java objects representation and json for API requests & responses
  • 27. System-Event Interactions • Alarms – Schedule with PendingIntent – Receive with BroadcastListener • NFC – Write NDEF messages containing URL with appended data (custom dataencoding protocol) – Read with system IntentFilter
  • 28. HUEMORE NFC PROTOCOL 1.0 Encoding light moods on nfc tags with as little as 46 bytes of storage
  • 29. Constraints • NFC tags on the market that store as little as 46 bytes of usable storage • Needs to support entire Hue bulbs API to be forwards compatible with the rest of HueMore
  • 30. Data wrapper • NDEF record on tag containing a URL to www.kuxhausen.com/HueMore/nfc? • Websafe base64 data appended to end of URL
  • 31. Data bitstring • 4 bit version number • 50 bit bulbs included flags • 7 bit number of states • Sequential listing of states
  • 32. State subbitstring • 9 bits flagging optional inclusion of the following: – 1 bit on – 8 bit brightness number – 16 bit hue number – 8 bit saturation number – 64 bit xy float pair – 9 bit color temperature number – 2 bit alerts enums – 4 bit effect enums – 16 bit transitiontime number
  • 33. Protocol Analysis • Numbers are big endian • Flags are bit strings (little endian) • No checksum (as of V1) • Orders of magnitude more space efficent tha storing json api calls