Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -820,10 +820,6 @@ public class DerivedSensorsBitMask {
public final static int PPG_TO_HR1_12_13 = 1 << 6; // (0*8 + 6);
public final static int PPG_TO_HR2_1_14 = 1 << 7; // (0*8 + 7);

public final static int PPG_10_15 = 1 << 2; // (0*8 + 2);
public final static int PPG1_10_15 = 1 << 3; // (0*8 + 3);
public final static int PPG2_17_16 = 1 << 4; // (0*8 + 4);

// -------------- Derived Channels Byte 1 -------------------
public final static int ACTIVITY_MODULE = 1 << 8; // (1*8 + 0);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2061,7 +2061,8 @@ public boolean isShimmerVideoDevice(){

public boolean isSupportedSrProgViaDock() {
if(mShimmerVerObject.compareVersions(HW_ID.SHIMMER_3, FW_ID.BTSTREAM, 0, 7, 13)
|| mShimmerVerObject.compareVersions(HW_ID.SHIMMER_3, FW_ID.LOGANDSTREAM, 0, 8, 1)){
|| mShimmerVerObject.compareVersions(HW_ID.SHIMMER_3, FW_ID.LOGANDSTREAM, 0, 8, 1)
|| isShimmerGen3R()){
return true;
}
return false;
Expand Down Expand Up @@ -2093,6 +2094,7 @@ public static boolean isSupportedDerivedSensors(ShimmerVerObject svo){
if((isVerCompatibleWith(svo, HW_ID.SHIMMER_3, FW_ID.BTSTREAM, 0, 7, 0))
||(isVerCompatibleWith(svo, HW_ID.SHIMMER_3, FW_ID.SDLOG, 0, 8, 69))
||(isVerCompatibleWith(svo, HW_ID.SHIMMER_3, FW_ID.LOGANDSTREAM, 0, 3, 17))
||(svo.isShimmerGen3R())
||(svo.isShimmerGenGq())
||(svo.isShimmerGen4())){
// ||(isVerCompatibleWith(svo, HW_ID.SHIMMER_4_SDK, ShimmerVerDetails.ANY_VERSION, ShimmerVerDetails.ANY_VERSION, ShimmerVerDetails.ANY_VERSION, ShimmerVerDetails.ANY_VERSION))){
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1455,7 +1455,11 @@ else if (isShimmerGen3()) {
if (isSupportedDerivedSensors()){
//change name based on derived sensor value
if ((mDerivedSensors & DerivedSensorsBitMask.PPG2_1_14)>0){
sensorName = SensorPPG.ObjectClusterSensorName.PPG2_A1;
if(isShimmerGen3R()) {
sensorName = SensorPPG.ObjectClusterSensorName.PPG2_A3;
} else {
sensorName = SensorPPG.ObjectClusterSensorName.PPG2_A1;
}
}else if ((mDerivedSensors & DerivedSensorsBitMask.RES_AMP)>0){
sensorName = Shimmer3.ObjectClusterSensorName.RESISTANCE_AMP;
}else if((mDerivedSensors & DerivedSensorsBitMask.SKIN_TEMP)>0){
Expand Down Expand Up @@ -1497,20 +1501,20 @@ else if (isShimmerGen3()) {
//to Support derived sensor renaming
if (isSupportedDerivedSensors()){
//change name based on derived sensor value
if(isShimmerGen3R()) {
if ((mDerivedSensors & DerivedSensorsBitMask.PPG_10_15)>0){
if ((mDerivedSensors & DerivedSensorsBitMask.PPG_12_13)>0){
if (isShimmerGen3R()) {
sensorName = SensorPPG.ObjectClusterSensorName.PPG_A0;
} else if ((mDerivedSensors & DerivedSensorsBitMask.PPG1_10_15)>0){
sensorName = SensorPPG.ObjectClusterSensorName.PPG1_A0;
}
}else {
if ((mDerivedSensors & DerivedSensorsBitMask.PPG_12_13)>0){
} else {
sensorName = SensorPPG.ObjectClusterSensorName.PPG_A12;
} else if ((mDerivedSensors & DerivedSensorsBitMask.PPG1_12_13)>0){
}
} else if ((mDerivedSensors & DerivedSensorsBitMask.PPG1_12_13)>0){
if (isShimmerGen3R()) {
sensorName = SensorPPG.ObjectClusterSensorName.PPG1_A0;
} else {
sensorName = SensorPPG.ObjectClusterSensorName.PPG1_A12;
}
}

}

sensorNames[iA12]=sensorName;
Expand Down Expand Up @@ -1541,16 +1545,16 @@ else if (isShimmerGen3()) {
//to Support derived sensor renaming
if (isSupportedDerivedSensors()){
//change name based on derived sensor value
if(isShimmerGen3R()) {
if ((mDerivedSensors & DerivedSensorsBitMask.PPG_10_15)>0){
if ((mDerivedSensors & DerivedSensorsBitMask.PPG_12_13)>0){
if(isShimmerGen3R()) {
sensorName = SensorPPG.ObjectClusterSensorName.PPG_A1;
} else if ((mDerivedSensors & DerivedSensorsBitMask.PPG1_10_15)>0){
sensorName = SensorPPG.ObjectClusterSensorName.PPG1_A1;
}
}else {
if ((mDerivedSensors & DerivedSensorsBitMask.PPG_12_13)>0){
} else {
sensorName = SensorPPG.ObjectClusterSensorName.PPG_A13;
} else if ((mDerivedSensors & DerivedSensorsBitMask.PPG1_12_13)>0){
}
} else if ((mDerivedSensors & DerivedSensorsBitMask.PPG1_12_13)>0){
if(isShimmerGen3R()) {
sensorName = SensorPPG.ObjectClusterSensorName.PPG1_A1;
} else {
sensorName = SensorPPG.ObjectClusterSensorName.PPG1_A13;
}
}
Expand Down Expand Up @@ -1585,9 +1589,12 @@ else if (isShimmerGen3()) {
if (isSupportedDerivedSensors()){
//change name based on derived sensor value
if ((mDerivedSensors & DerivedSensorsBitMask.PPG2_1_14)>0){
sensorName = SensorPPG.ObjectClusterSensorName.PPG2_A14;
} else if ((mDerivedSensors & DerivedSensorsBitMask.PPG2_17_16)>0){
sensorName = SensorPPG.ObjectClusterSensorName.PPG2_A2;
if(isShimmerGen3R()) {
sensorName = SensorPPG.ObjectClusterSensorName.PPG2_A2;
}
else {
sensorName = SensorPPG.ObjectClusterSensorName.PPG2_A14;
}
}
}
sensorNames[iA14]=sensorName;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public class DatabaseChannelHandles{
public static final String PPG2_A3 = "F5437a_PPG2_A3";
}

public static class DatabaseConfigHandle{
public static class DatabaseConfigHandle{
public static final String PPG_ADC_SELECTION_BOARD = "PPG_ADC_Selection_Board";
public static final String PPG1_ADC_SELECTION_BOARD = "PPG1_ADC_Selection_Board";
public static final String PPG2_ADC_SELECTION_BOARD = "PPG2_ADC_Selection_Board";
Expand Down
Loading