To add to what @cusma wrote, the LatestTimestamp is the timestamp that is taken from the previous block header ( i.e. that last block that was agreed upon ).
It’s the proposer who sets this value; this value has two limitation:
- it must be monotonic growing.
- it must be at most 25s greater then the preceding block header timestamp.
As long as we have constant block rate of 4.3 seconds, it always works fine. However, when the network have longer round times ( it does happen from time to time ), the value of the LatestTimestamp might be lagging behind for a while.
The reason I’m mentioning this is so that you won’t try to use this as an atomic clock - there are no guarantees about the accuracy of this clock. The Algorand blockchain itself doesn’t use this value, other than providing it as a service for the smart contracts.