Jump to content

SkySurveyBanner.jpg.21855908fce40597655603b6c9af720d.jpg

SpectrumLab functions: now and time


Recommended Posts

From the documentation, I understand that the time function: returns the time when the last line of the waterfall (FFT) has been calculated. Depending on the scrolling speed, this can be different from "now". The unit is the same as for "now" (seconds elapsed since 1970-01-01 00:00:00.0 UTC).

and the now function: returns the current time (including the date) in the internal format of the program, which is a combination of date plus time as a floating point number.

 

Does anyone know why these functions return such greatly different times?  I would expect it to be only a few seconds difference at most? (or have I missed someting).

Example, 

now:  2020-08-12 09:11:00 UTC

time: 2020-08-12 06:55:22 UTC

 

 

Link to comment
Share on other sites

My understanding of these functions is that, time  returns a value that can be subject to the vagueries of processor busyness speed etc.  and will be subject to variable delays (the author of Spectrum Lab explained this in Spectrum. Lab User Forum iogroups some time back).  Now was introduce to overcome these problems and gives the most accurate report of time at the time the function is called.  Your processor must be very busy 🙂 for such a  difference.   Seriously, there difference you talk about seems wrong.   It will also be dependent on  the context of where it is used in your conditional actions script - if the functions are side by side in  a long loop process or the FFTs are large for example. 

 

Link to comment
Share on other sites

Certainly seems weird that they're so far off. I've got button labels using now and time image.png.29c428fce55c3120f5109e9865b7e4e6.png

 

It's annoying, because I had about 4-5 days of data and my actions were using a mix of time and now - so the times between log entries, and filenames for captures etc. don't correlate properly and it took a while to find time to properly investigate.  I've sorted everything out and using 'now' throughout.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. By using this site, you agree to our Terms of Use.