Back to project page BLE-Heart-rate-variability-demo.
The source code is released under:
MIT License
If you think the Android project BLE-Heart-rate-variability-demo listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.sample.hrv.sensor; /* w w w. j a v a 2s. com*/ import java.util.HashMap; /** * Created by steven on 9/4/13. * Modified by olli on 3/28/2014. */ public class BleSensors { private static HashMap<String, BleSensor<?>> SENSORS = new HashMap<String, BleSensor<?>>(); static { final BleTestSensor testSensor = new BleTestSensor(); final BleHeartRateSensor heartRateSensor = new BleHeartRateSensor(); SENSORS.put(testSensor.getServiceUUID(), testSensor); SENSORS.put(heartRateSensor.getServiceUUID(), heartRateSensor); } public static BleSensor<?> getSensor(String uuid) { return SENSORS.get(uuid); } }