How to save/load from memory some value

  • aleksamc
  • aleksamc's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
More
04 Apr 2019 15:19 #130292 by aleksamc
How to save/load from memory some value was created by aleksamc
Hello all.

In PyVCP panel I want to use value Tool Diameter, that I want to change with help of spinbox.
In spinbox parameters I have <initval>, that is constant.

But tool diameter should be change one time per month only. Can I load this value to some memory after closing linuxcnc and after each start read this value?

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

More
04 Apr 2019 16:25 #130295 by andypugh
Replied by andypugh on topic How to save/load from memory some value
Doesn't tool diameter "belong" in the tool table?

(And that is automatically saved and loaded)

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

  • aleksamc
  • aleksamc's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
More
04 Apr 2019 20:40 #130308 by aleksamc
Replied by aleksamc on topic How to save/load from memory some value
Sorry for my nuby question, but...
Is it possible to connect pyVCP spinbox to variable #5410 (Tool diameter)?
At start up it should read value of the tool-1, for example, and after turning off - save it to *.var file.

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

More
04 Apr 2019 20:47 #130310 by andypugh
Replied by andypugh on topic How to save/load from memory some value
Yes, it is probably possible. (though you would have to use something other than #5410, as that is read-only).

What are you trying to do? Why would you not write the new diameter to the tool table instead?

(use a spinbox with a handler that sends an M10 command on MDI)

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

Time to create page: 0.060 seconds
Powered by Kunena Forum