CYCLE_TIME variable in INI file DISPLAY section

More
08 Dec 2013 12:24 #41408 by dbotos
I'm going through the stepper_mm.ini file from the stepper-gantry configuration (which I'm going to rename stepper_inch.ini since I'm in the US) line by line so I can get everything set up properly (and hopefully learn something in the process). I've come to the first line I don't quite understand and that is the CYCLE_TIME variable in the DISPLAY section. The default value in the file is 0.200 seconds and the comment says it's the time that the "display will sleep between polls". Can someone explain this a little further? Is this some kind of screen refresh rate for showing what the machine is doing?

Thanks,
David

Please Log in or Create an account to join the conversation.

More
08 Dec 2013 18:17 #41410 by ArcEye
Hi

If CYCLE_TIME is set, the GUI can use it as the rest period between polls to the underlying linuxcnc system.

The GUI polls to refresh its data, including things like DRO axis positions etc

These snippets from axis.py show it is parsed from the .ini file if it exists, or if not a default value is set
The resultant figure is used in the update function
update_ms = int(1000 * float(inifile.find("DISPLAY","CYCLE_TIME") or 0.020))
.
.
.
.
.
    def update(self):
        if not self.running.get():
            return
        try:
            self.stat.poll()
        except linuxcnc.error, detail:
            print "error", detail
            del self.stat
            return
        self.after = self.win.after(update_ms, self.update)

regards
The following user(s) said Thank You: dbotos

Please Log in or Create an account to join the conversation.

More
08 Dec 2013 23:36 - 08 Dec 2013 23:37 #41414 by dbotos
Okay, seems to make sense. I see the axis.py file uses a time in microseconds and that its default update time is lower than the one in the INI file. Is either one a better value or are they both so fast that I wouldn't see a difference?
Last edit: 08 Dec 2013 23:37 by dbotos.

Please Log in or Create an account to join the conversation.

More
08 Dec 2013 23:45 #41415 by ArcEye
Hi

I don't have any configs where this is set, so I am always using the default.
I was not aware that stepconf set it, but I have not used stepconf for years.

Obviously one is 10 times longer than the other, but I doubt you would notice the difference.

You could try setting it longer and longer until you notice something :laugh:

regards
The following user(s) said Thank You: dbotos

Please Log in or Create an account to join the conversation.

More
08 Dec 2013 23:47 #41416 by dbotos
Cool. I'll just leave the default and see how it looks. ;)

Please Log in or Create an account to join the conversation.

Time to create page: 0.062 seconds
Powered by Kunena Forum