Python Forum
Search Results
Post Author Forum Replies Views Posted [asc]
    Thread: Help moding python script to edit Gcode
Post: RE: Help moding python script to edit Gcode

(Jan-03-2021, 06:16 PM)buran Wrote: Your best friend is the documentation. If in doubt - check the docs.My head is spinning LOL **cry** This document you speak of. where might's I find it? I think...
AntaresSky General Coding Help 13 4,937 Jan-04-2021, 12:06 AM
    Thread: Help moding python script to edit Gcode
Post: RE: Help moding python script to edit Gcode

Interesting! So the line in the original script L.Lstrip is different then your script Line.strip? I take it the Line.Lstrip is telling it to removed the whole line? But I'm still not totally clear o...
AntaresSky General Coding Help 13 4,937 Jan-03-2021, 04:05 PM
    Thread: Help moding python script to edit Gcode
Post: RE: Help moding python script to edit Gcode

(Jan-03-2021, 03:06 AM)snippsat Wrote: Some fix done,try this. import sys import os if len(sys.argv) != 2: print('Usage: python nocomment.py <file.gcode>') sys.exit(1) in_file = os.pa...
AntaresSky General Coding Help 13 4,937 Jan-03-2021, 03:20 AM
    Thread: Help moding python script to edit Gcode
Post: RE: Help moding python script to edit Gcode

Ok getting closer edited it to get ride of the . and changed it to _ HERE---- out.lines ------ but now it looks like this. (; LightBurn 0.9.20 )(; GRBL-M3 (1.1e or earlier) device profile, user ori...
AntaresSky General Coding Help 13 4,937 Jan-03-2021, 02:45 AM
    Thread: Help moding python script to edit Gcode
Post: RE: Help moding python script to edit Gcode

import sys import os if len(sys.argv) != 2: print('Usage: python nocomment.py <file.gcode>') sys.exit(1) in_file = os.path.abspath(sys.argv[1]) if not os.path.isfile(in_file): ...
AntaresSky General Coding Help 13 4,937 Jan-03-2021, 02:31 AM
    Thread: Help moding python script to edit Gcode
Post: RE: Help moding python script to edit Gcode

Hi, Thanks for the help! I gave it a try and this is the message I'm getting in the command prompt window. I tried moving the Else around on the line a bit but didn't help. Microsoft Windows [Version...
AntaresSky General Coding Help 13 4,937 Jan-03-2021, 02:27 AM
    Thread: Help moding python script to edit Gcode
Post: Help moding python script to edit Gcode

Hi there! I'm new to python, haven't done any coding in 20 years. I used to do Basic code for the Basic stamp controller. Anyways, I have a script that a nice person made for me that will strip the co...
AntaresSky General Coding Help 13 4,937 Jan-03-2021, 01:37 AM

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020