Add support for vendor sensor type 3

Will be used for big image access to accelerometer.

Bug: 79257265
Test: compile only, not used yet
Change-Id: I045bf0968219986cb54c1039ad023e0550756127
diff --git a/core/include/chre/core/sensor_type.h b/core/include/chre/core/sensor_type.h
index e542794..047f5ad 100644
--- a/core/include/chre/core/sensor_type.h
+++ b/core/include/chre/core/sensor_type.h
@@ -58,6 +58,7 @@
   VendorType0,
   VendorType1,
   VendorType2,
+  VendorType3,
 
   // Note to future developers: don't forget to update the implementation of
   // 1) getSensorTypeName,
@@ -85,6 +86,7 @@
   Vendor0,
   Vendor1,
   Vendor2,
+  Vendor3,
   Unknown,
 };
 
diff --git a/core/sensor_type.cc b/core/sensor_type.cc
index 4bac1eb..d1a486f 100644
--- a/core/sensor_type.cc
+++ b/core/sensor_type.cc
@@ -62,6 +62,8 @@
       return "Vendor Type 1";
     case SensorType::VendorType2:
       return "Vendor Type 2";
+    case SensorType::VendorType3:
+      return "Vendor Type 3";
     default:
       CHRE_ASSERT(false);
       return "";
@@ -116,6 +118,8 @@
       return SensorType::VendorType1;
     case (CHRE_SENSOR_TYPE_VENDOR_START + 2):
       return SensorType::VendorType2;
+    case (CHRE_SENSOR_TYPE_VENDOR_START + 3):
+      return SensorType::VendorType3;
     default:
       return SensorType::Unknown;
   }
@@ -157,6 +161,8 @@
       return (CHRE_SENSOR_TYPE_VENDOR_START + 1);
     case SensorType::VendorType2:
       return (CHRE_SENSOR_TYPE_VENDOR_START + 2);
+    case SensorType::VendorType3:
+      return (CHRE_SENSOR_TYPE_VENDOR_START + 3);
     default:
       // Update implementation to prevent undefined or SensorType::Unknown from
       // being used.
@@ -201,12 +207,16 @@
       return SensorSampleType::Occurrence;
     case SensorType::Proximity:
       return SensorSampleType::Byte;
+#ifdef CHREX_SENSOR_SUPPORT
     case SensorType::VendorType0:
       return SensorSampleType::Vendor0;
     case SensorType::VendorType1:
       return SensorSampleType::Vendor1;
     case SensorType::VendorType2:
       return SensorSampleType::Vendor2;
+    case SensorType::VendorType3:
+      return SensorSampleType::Vendor3;
+#endif  // CHREX_SENSOR_SUPPORT
     case SensorType::Unknown:
       return SensorSampleType::Unknown;
     default:
diff --git a/platform/slpi/see/see_helper.cc b/platform/slpi/see/see_helper.cc
index 536f68e..324d236 100644
--- a/platform/slpi/see/see_helper.cc
+++ b/platform/slpi/see/see_helper.cc
@@ -805,6 +805,15 @@
         timestampDelta = &event->readings[index].timestampDelta;
         break;
       }
+
+      case SensorSampleType::Vendor3: {
+        auto *event = reinterpret_cast<chrexSensorVendor3Data *>(
+            data->event.get());
+        memcpy(event->readings[index].values, val,
+               sizeof(event->readings[index].values));
+        timestampDelta = &event->readings[index].timestampDelta;
+        break;
+      }
 #endif  // CHREX_SENSOR_SUPPORT
 
       default:
@@ -1245,6 +1254,10 @@
     case SensorSampleType::Vendor2:
       sampleSize = sizeof(chrexSensorVendor2SampleData);
       break;
+
+    case SensorSampleType::Vendor3:
+      sampleSize = sizeof(chrexSensorVendor3SampleData);
+      break;
 #endif  // CHREX_SENSOR_SUPPORT
 
     default: