Difference between revisions of "Phonegap Healthcare Adapter"

From CDOT Wiki
Jump to: navigation, search
 
(54 intermediate revisions by 5 users not shown)
Line 1: Line 1:
[[category: NexJ Current Projects]]
+
{{Admon/obsolete}}
[[category: NexJ Express SQLite]]
 
  
<big><big> PhoneGap Healthcare Adapter for NexJ </big></big>
 
  
 +
''''' NexJ Medical Peripheral Mobile Adapter '''''
 +
will be designed to enable NexJ's Mobile Healthcare solutions to interact with Bluetooth peripherals.
  
== Project Goal ==
+
: ''{{See Also|Phonegap Healthcare Adapter Questions|Phonegap Healthcare Adapter Backlog}}''
Develop an adapter to enable NexJ's Mobile Healthcare solutions to interact with Bluetooth peripherals.
+
: ''{{Category See Also|NexJ Express Research}}''
  
 +
{{TOC limit}}
  
 
== Contributors ==
 
== Contributors ==
 +
 
* [[User:Cwdesautels|Carl Desautels]]
 
* [[User:Cwdesautels|Carl Desautels]]
* [[User:Wei.song | Wei Song]]
+
* [[User:Wei.song|Wei Song]]
 +
 
 +
== Problem ==
 +
 
 +
[[File:NexjMobile.png|thumb|right]]
 +
 
 +
NexJ's mobile health solution requires its smartphone health coach application to have the ability to read medical measurement data from Bluetooth-capable devices, The devices included in the initial project proposal are as follows: blood pressure device, glucose level measuring device and a weight measuring device.
 +
 
 +
The health coach application will be designed to use PhoneGap, a rising technology that blurs the line between mobile operating systems. Implementing native Bluetooth adapters becomes only part of the solution. The health coach application will interact with a unified API in JavaScript to retrieve data from Bluetooth-capable medical peripherals.
  
 +
The unified JavaScript API will be developed to utilize PhoneGap's JavaScript API to make native code calls. These native calls will focus on a medical Bluetooth device adapter which also must be implemented. This Bluetooth adapter will be extended for each supported measuring device and implemented on each supported mobile operating system.
 +
 +
== Project Scope ==
 +
 +
* Not responsible for communication with the server.
 +
* Responsible for communication with Bluetooth peripherals.
  
 
== Supported Versions ==
 
== Supported Versions ==
 +
 
* [http://phonegap.com/download PhoneGap] 2.0.0, released July 20, 2012
 
* [http://phonegap.com/download PhoneGap] 2.0.0, released July 20, 2012
 +
 
=== [http://docs.phonegap.com/en/2.0.0/guide_getting-started_ios_index.md.html#Getting%20Started%20with%20iOS OSX] ===
 
=== [http://docs.phonegap.com/en/2.0.0/guide_getting-started_ios_index.md.html#Getting%20Started%20with%20iOS OSX] ===
 +
 
* Xcode 4.3 +
 
* Xcode 4.3 +
 
* OSX 10.7 +
 
* OSX 10.7 +
Line 23: Line 42:
  
 
=== [http://docs.phonegap.com/en/2.0.0/guide_getting-started_android_index.md.html#Getting%20Started%20with%20Android Android] ===
 
=== [http://docs.phonegap.com/en/2.0.0/guide_getting-started_android_index.md.html#Getting%20Started%20with%20Android Android] ===
 +
 
* Eclipse 3.6.2 +
 
* Eclipse 3.6.2 +
 
* ADT Latest
 
* ADT Latest
Line 30: Line 50:
 
* Bluetooth SPP capable
 
* Bluetooth SPP capable
  
 +
== [[Phonegap_Healthcare_Adapter_Backlog|Project Status]] ==
  
== Project Status==
+
* '''Current Sprint''' : [[Phonegap_Healthcare_Adapter_Backlog#Investigation|Investigation]]
* '''Current Sprint''' : [[Phonegap_Healthcare_Adapter#Investigation | Investigation]]
 
  
 +
== [[:Category:NexJ_Express_Research|Research]] ==
  
== Project Backlog ==
+
* Bluetooth communication outline: [[Phonegap_Healthcare_Adapter_Bluetooth_Spec|Spec]]
=== Investigation ===
+
* Bluetooth native implementation: [[Phonegap_Healthcare_Adapter_Bluetooth_Implementation|Details]]
==== iOS ====
+
* Project Design: [[Phonegap_Healthcare_Adapter_Design|Design Page]]
* Bluetooth can work on simulators.
+
* Phonegap cross platform plugin solution: [[Phonegap_Healthcare_Adapter_Plugin_Implementation|Tutorial]]
* Deploy to devices, requiring enrollment in the [https://developer.apple.com/programs/ios/ developer program].
 
* Understand Objective C.
 
* Understand iOS best practice development.
 
* Understand iOS PhoneGap plugin best practices.
 
  
==== Android ====
+
== Project Repository ==
* Bluetooth does '''not''' work on the emulator.
 
* Understand ADK best practice development.
 
* Understand ADK PhoneGap plugin best practices.
 
  
=== The Problem ===
+
* https://bitbucket.org/cwdesautels/nexj-mobile-bluetooth-adapter
NexJ's mobile health solution requires its smartphone health coach application to have the ability to read medical measurement data from Bluetooth-capable devices, The devices included in the initial project proposal are as follows: blood pressure device, glucose level measuring device and a weight measuring device.
 
  
The health coach application will be designed to use PhoneGap, a rising technology that blurs the line between mobile operating systems. Implementing native Bluetooth adapters becomes only part of the solution. The health coach application will interact with a unified API in JavaScript to retrieve data from Bluetooth-capable medical peripherals.
+
=== Mercurical HowTo ===
  
The unified JavaScript API will be developed to utilize Phonegap's JavaScript API to make native code calls. These native calls will focus on a medical Bluetooth device adapter which also must be implemented. This Bluetooth adapter will have be extended for each supported measuring device and implemented on each supported mobile operating system.
+
* [https://developer.mozilla.org/en-US/docs/Mercurial Mozilla Mercurial Docs]
  
 +
=== Branching Rules ===
  
[[File:nexjMobile.png]]
 
 
=== PhoneGap API ===
 
* Design a unified API in JavaScript that will allow the NexJ application to interact with Bluetooth devices.
 
* Define a project architecture that facilitates multiple device compatibility.
 
 
=== Blood Pressure Device ===
 
==== iOS ====
 
* Create native Bluetooth adapter for this device.
 
 
==== Android ====
 
* Create native Bluetooth adapter for this device.
 
 
=== Glucose Level Device ===
 
==== iOS ====
 
* Extend native Bluetooth adapter for this device.
 
 
==== Android ====
 
* Extend native Bluetooth adapter for this device.
 
 
=== Weight Scale Device ===
 
==== iOS ====
 
* Extend native Bluetooth adapter for this device.
 
==== Android ====
 
* Extend native Bluetooth adapter for this device.
 
 
 
== Project Functionality Description ==
 
 
=== Project task ===
 
Design and implement PhoneGap plugins on iOS and Android platforms to realize the collection and storage of healthcare measurements (blood pressure, blood glucose, and weight) using Bluetooth® wireless technology.
 
=== Bluetooth Profile ===
 
Serial Port Profile (SPP).
 
=== Bluetooth protocols ===
 
RFCOMM and Service Discovery protocols.
 
=== Pairing ===
 
Secure Simple Pairing
 
=== Data transmission ===
 
Measurement date/time, measurement values, Bluetooth Id of remote unit, mode, and serial number of A&D PBT Series.
 
=== Master devices ===
 
A&D Bluetooth® devices PBT series, including blood pressure meter, blood glucose meter, and weight scale.
 
=== Slave devices/Access Points ===
 
mobile devices, including iOS and Android smartphones/tablets.
 
 
[[File:NexjPhoneGap.png]]
 
 
=== PhoneGap Plugin Functionalities ===
 
The PhoneGap plugins to be developed on iOS and Android should have the following JavaScript functions:
 
==== 1. Enable Bluetooth ====
 
This function turns on Bluetooth on the mobile device.
 
==== 2. Disable Bluetooth ====
 
This function turns off Bluetooth on the mobile device.
 
==== 3. List Bluetooth Devices ====
 
This function search and list all detected Bluetooth devices.
 
==== 4. List Paired Devices ====
 
This function lists all A&D Bluetooth devices which have bound to the mobile smartphone/tablet.
 
==== 5. Unpair device ====
 
This function removes an A&D Bluetooth device from paired device list.
 
==== 6. Start Listing ====
 
* This function starts Bluetooth communication as SPP server on the mobile device through native application and makes the device available to receive the health measurements from A&D Bluetooth devices.
 
* This function should be called after Bluetooth is enabled on the mobile device.
 
* For first connection between an A&D Bluetooth and a mobile device, a native screen will pop up to allow user to input PIN code to configure the connection. Upon the success of connection, the two devices are paired. Then PIN code is no longer needed afterward.
 
* After receiving the communication packet from the A&D PBT Series (master) device, the packet is parsed and the obtained measurement date/time, measurement values, Bluetooth Id of remote unit, mode, and serial number of A&D PBT Series plus the Bluetooth ID of access point (the mobile device) will be stored in local database. The number of records is controlled less than 100.
 
* Upon the record successfully stored (Other situations are not covered here for conciseness), the access point needs to wait for about 250msec and to return “Data Accepted” within “Acknowledge & Configuration Packet” back to the master device ( A&D PBT series device).
 
* Shows mobile user with message that a measurement was successfully received.
 
==== 7. Stop Listing ====
 
This function stops the SPP server on the mobile device.
 
==== 8. Get recently received records ====
 
This function return received measurements in different ways:
 
* All records in brief
 
* A specific record by record id
 
* Blood pressure records
 
* Blood glucose records
 
* Weight scale records
 
 
 
== Project Repository ==
 
* https://bitbucket.org/cwdesautels/nexj-mobile-bluetooth-adapter
 
=== Mercurical HowTo ===
 
* [https://developer.mozilla.org/en-US/docs/Mercurial Mozilla Mercurial Docs]
 
=== Branching Rules ===
 
 
* Nobody commits to ''default''.
 
* Nobody commits to ''default''.
 
** ''default'' is the master branch we will use to generate submissions back to NexJ
 
** ''default'' is the master branch we will use to generate submissions back to NexJ
Line 154: Line 87:
  
 
== Resources ==
 
== Resources ==
 +
* Research
 +
** [[:Category:NexJ_Express_Research|Notes]]
 
* Dowloads:
 
* Dowloads:
 
** [http://docs.phonegap.com/en/2.0.0/guide_getting-started_ios_index.md.html#Getting%20Started%20with%20iOS PhoneGap: Getting Started with iOs]
 
** [http://docs.phonegap.com/en/2.0.0/guide_getting-started_ios_index.md.html#Getting%20Started%20with%20iOS PhoneGap: Getting Started with iOs]
 
** [http://docs.phonegap.com/en/2.0.0/guide_getting-started_android_index.md.html#Getting%20Started%20with%20Android PhoneGap: Getting Started with Android]
 
** [http://docs.phonegap.com/en/2.0.0/guide_getting-started_android_index.md.html#Getting%20Started%20with%20Android PhoneGap: Getting Started with Android]
 
* Documentation:
 
* Documentation:
** Bluetooth Developer Portal:  
+
** Bluetooth Developer Portal:
 
*** [http://developer.bluetooth.org/KnowledgeCenter/Pages/White-Papers.aspx Bluetooth White papers]
 
*** [http://developer.bluetooth.org/KnowledgeCenter/Pages/White-Papers.aspx Bluetooth White papers]
 
*** [http://developer.bluetooth.org/DevelopmentResources/Pages/Introduction-to-Bluetooth-Application-Development.aspx Development Resources]
 
*** [http://developer.bluetooth.org/DevelopmentResources/Pages/Introduction-to-Bluetooth-Application-Development.aspx Development Resources]
** iOS Developer Resource
+
** iOS Developer Resource
 
*** [http://developer.apple.com/library/ios/#technotes/tn2295/_index.html Bluetooth on Simulators]
 
*** [http://developer.apple.com/library/ios/#technotes/tn2295/_index.html Bluetooth on Simulators]
 
*** [http://hiediutley.com/2011/03/30/phonegap-tutorial-series-4-using-a-third-party-plugin/ PhoneGap Tutorial]
 
*** [http://hiediutley.com/2011/03/30/phonegap-tutorial-series-4-using-a-third-party-plugin/ PhoneGap Tutorial]

Latest revision as of 19:51, 26 January 2014

Important.png
This page may be obsolete.
It contains historical information.


NexJ Medical Peripheral Mobile Adapter will be designed to enable NexJ's Mobile Healthcare solutions to interact with Bluetooth peripherals.

Contributors

Problem

NexjMobile.png

NexJ's mobile health solution requires its smartphone health coach application to have the ability to read medical measurement data from Bluetooth-capable devices, The devices included in the initial project proposal are as follows: blood pressure device, glucose level measuring device and a weight measuring device.

The health coach application will be designed to use PhoneGap, a rising technology that blurs the line between mobile operating systems. Implementing native Bluetooth adapters becomes only part of the solution. The health coach application will interact with a unified API in JavaScript to retrieve data from Bluetooth-capable medical peripherals.

The unified JavaScript API will be developed to utilize PhoneGap's JavaScript API to make native code calls. These native calls will focus on a medical Bluetooth device adapter which also must be implemented. This Bluetooth adapter will be extended for each supported measuring device and implemented on each supported mobile operating system.

Project Scope

  • Not responsible for communication with the server.
  • Responsible for communication with Bluetooth peripherals.

Supported Versions

OSX

  • Xcode 4.3 +
  • OSX 10.7 +
  • iOS 4.3 +
  • Bluetooth SPP capable

Android

  • Eclipse 3.6.2 +
  • ADT Latest
  • Java 1.6 +
  • Minimum OS: 2.2
  • Recommended OS: latest
  • Bluetooth SPP capable

Project Status

Research

  • Bluetooth communication outline: Spec
  • Bluetooth native implementation: Details
  • Project Design: Design Page
  • Phonegap cross platform plugin solution: Tutorial

Project Repository

Mercurical HowTo

Branching Rules

  • Nobody commits to default.
    • default is the master branch we will use to generate submissions back to NexJ
  • Nobody commits to dev.
    • dev is the branch were the latest completed features and bug fixes come together for testing
  • Keep branches relevant.
    • If the focus of what your coding changes, make a new branch
  • Best practice is to branch off of dev.
    • Exceptional scenarios call for branching off of default or other branches, you will not encounter them
  • Branch names in lowercase.
  • Hyphenate branch names if required.
    • bluetooth-plugin
  • Branch names must either be:
    • A bitbucket issue, example: issue-14 OR bug-14
    • A feature name, example: cryptography-bug

Resources