logging readings with there own timestamp
Hi,
I want to discuss something, lets say I have a sensor that sends me readings and also the time stamp of this readings, this timestamp is not the same as the timestamp of the machine that runs thingworx and the database, so i want thingworx to use this timestamp that came with the sensor data to store it in the database as the timestamp of the readings, so that when i try to query these readings and say i want it from timestamp 1 to timestamp 2 they will be stored in the database with timestamp 1 & 2 that has been set using a timestamp originally from the sensor data not the machine or server timestamp,
when looked into it i found that i have to use this function in my subscribers and cancel the need to the log checkbox in the properties UI .
// Log multiple properties in a single ValueStream entry
Things["ValueStreamThingName"].AddStreamEntry({
source: me.name,
tags: undefined,
timestamp: timestamp,
values: {
Temperature: me.Temperature,
Humidity: me.Humidity,
Pressure: me.Pressure
}
});
Am I correct ? or there is a better or more generic way to do it, like put the function as something general for anything to use so that it can log its own data
thank you,

