new file button - dont work

More
5 years 3 months ago #215162 by zz912
I have LinuxCNC 2.8.2. If I click on "new file" button, it dont work.
 

Attachment not found



Python is not my friend. Could you help me?
Code:
# make a new file     def on_btn_new_clicked(self, widget, data=None):         tempfilename = os.path.join(_TEMPDIR, "temp.ngc")         content = self.get_ini_info.get_RS274_start_code()         if content == None:             content = " "         content += "\n\n\n\nM2"         gcodefile = open(tempfilename, "w")         gcodefile.write(content)         gcodefile.close()         if self.widgets.lbl_program.get_label() == tempfilename:             self.widgets.hal_action_reload.emit("activate")         else:             self.widgets.hal_action_open.load_file(tempfilename)             # self.command.program_open(tempfilename)         self.widgets.gcode_view.grab_focus()         self.widgets.btn_save.set_sensitive(False)     def on_tbtn_optional_blocks_toggled(self, widget, data=None):         opt_blocks = widget.get_active()         self.command.set_block_delete(opt_blocks)         self.prefs.putpref("blockdel", opt_blocks)         self.widgets.hal_action_reload.emit("activate")

Please Log in to join the conversation.

More
5 years 3 months ago #215556 by zz912
Replied by zz912 on topic new file button - dont work
Nobody knows? Am I the only one who has this problem?

Please Log in to join the conversation.

More
5 years 3 months ago #216276 by andypugh
I suspect that only Norbert will have the answer.

And he hasn't been on the forum for quite some time:
forum.linuxcnc.org/cb-profile/newbynobi

Please Log in to join the conversation.

More
5 years 3 months ago #216398 by newbynobi
Do you have an RS274 start code in your INI File?
If not try to add any code, i.e. G54 and report back.

Norbert

Please Log in to join the conversation.

More
5 years 3 months ago #216400 by HalaszAttila
Hello,
i tested with a RS274_STARTUP_CODE = G54, and it solve the problem. Thanks.

Please Log in to join the conversation.

More
5 years 2 months ago #216597 by zz912
Replied by zz912 on topic new file button - dont work
I added RS274_STARTUP_CODE = G54 and this not helped me.

Please Log in to join the conversation.

More
5 years 2 months ago #216604 by zz912
Replied by zz912 on topic new file button - dont work
RS274_STARTUP_CODE = G54 - it is probably wrong
RS274NGC_STARTUP_CODE = G54 - it should be better

I'll try and let you know.

linuxcnc.org/docs/2.5/html/config/ini_co...sub:RS274NGC-section

Please Log in to join the conversation.

More
5 years 2 months ago #216706 by zz912
Replied by zz912 on topic new file button - dont work
[RS274NGC]
RS274NGC_STARTUP_CODE = G90

It solved my problem.Thank you for help.

Please Log in to join the conversation.

Time to create page: 4.493 seconds
Powered by Kunena Forum