diff --git a/scripts/writesensor.mako.cpp b/scripts/writesensor.mako.cpp
index 5b1ffd7..b2da7ca 100644
--- a/scripts/writesensor.mako.cpp
+++ b/scripts/writesensor.mako.cpp
@@ -10,14 +10,17 @@
     serviceInterface = sensor["serviceInterface"]
     if serviceInterface == "org.freedesktop.DBus.Properties":
         updateFunc = "set::"
+        getFunc = "get::"
     elif serviceInterface == "xyz.openbmc_project.Inventory.Manager":
         updateFunc = "notify::"
+        getFunc = "inventory::get::"
     else:
         assert "Un-supported interface: " + serviceInterface
     endif
     if serviceInterface not in interfaceDict:
         interfaceDict[serviceInterface] = {}
         interfaceDict[serviceInterface]["updateFunc"] = updateFunc
+        interfaceDict[serviceInterface]["getFunc"] = getFunc
 %>\
 % endfor
 
@@ -46,6 +49,16 @@
     return set::readingAssertion<${type}>(cmdData, sensorInfo);
 }
 
+namespace get
+{
+
+inline GetSensorResponse readingAssertion(const Info& sensorInfo)
+{
+    return ipmi::sensor::get::readingAssertion<${type}>(sensorInfo);
+}
+
+} //namespace get
+
 } // namespace sensor_${key}
 
 %elif "readingData" == readingType:
@@ -59,6 +72,16 @@
     return set::readingData<${type}>(cmdData, sensorInfo);
 }
 
+namespace get
+{
+
+inline GetSensorResponse readingData(const Info& sensorInfo)
+{
+    return ipmi::sensor::get::readingData<${type}>(sensorInfo);
+}
+
+} //namespace get
+
 } // namespace sensor_${key}
 
 %endif
@@ -81,17 +104,21 @@
        valueReadingType = sensor["readingType"]
        updateFunc = interfaceDict[serviceInterface]["updateFunc"]
        updateFunc += sensor["readingType"]
+       getFunc = interfaceDict[serviceInterface]["getFunc"]
+       getFunc += sensor["readingType"]
        if "readingAssertion" == valueReadingType:
            updateFunc = "sensor_" + str(key) + "::" + valueReadingType
+           getFunc = "sensor_" + str(key) + "::get::" + valueReadingType
        elif "readingData" == valueReadingType:
            updateFunc = "sensor_" + str(key) + "::" + valueReadingType
+           getFunc = "sensor_" + str(key) + "::get::" + valueReadingType
        sensorInterface = serviceInterface
        if serviceInterface == "org.freedesktop.DBus.Properties":
            sensorInterface = next(iter(interfaces))
        mutability = sensor.get("mutability", "Mutability::Read")
 %>
         ${sensorType},"${path}","${sensorInterface}",${readingType},${multiplier},
-        ${offset},${exp},${offset * pow(10,exp)},${updateFunc},Mutability(${mutability}),{
+        ${offset},${exp},${offset * pow(10,exp)},${updateFunc},${getFunc},Mutability(${mutability}),{
     % for interface,properties in interfaces.items():
             {"${interface}",{
             % for dbus_property,property_value in properties.items():
