Is there a way to run a gcode from a remote computer

on the buildbotiics controller,

is there a way to run a gcode file from a remote computer (without a human manning the web interface)? I would still monitor what’s going on, but don’t want to use the web interface because it’s too time consuming when I go through dozens of files, and managing many files is really hard without folders.

is there any sort of API for the controller? even if only ssh, that should be enough to do a lot.

Hi Stephane – I’m not entirely what you mean. There is no way to “send” gcode to the OF without using the controller. You can pull up the controller’s UI from your computer if you have the controller on the network. As far as I know, there is no API. You can certainly SSH into the RPI and drop files on to it, but I don’t know how to ‘play’ the files without the UI. I’m sure you can dig into the code, see what actually happens when you click play, find those routines, and then code up a REST interface if you want. But that seems like a lot of work if you think the current UI is too time consuming already. What sort of problem are you trying to solve other than the ‘amount’ of time scrolling through ‘dozens of files’? You know you can delete the old files, right?

-Tom

1 Like

If you’re using Vectric, there’s an option to send GCode directly to the machine from your computer.

1 Like

Hey Stephane,

you can transfer your g-code file without the UI, you have to put it into /var/lib/bbctrl/upload. Then it is found automatically. The bbctrl application runs as ‘root’ (which is rather unusal and unnecessary and shows the original author did not grow up on unix)

so

scp -p my_g-code_file.ngc bbmc@onefinity.local:/var/lib/bbctrl/upload

will not work, you have to write it as ‘root’ because of the directories’ permissions. You can of course change the permissions of the directory, or simply transfer it with

scp -p my_g-code_file.ngc root@onefinity.local:/var/lib/bbctrl/upload

from a remote computer (if you set a root password on the onefinity controller).

Uploading the file triggers building some helper files in /var/lib/bbctrl/plans.

The file appears on the pull-down input field on the UI then.

The difficulty is then to run the file. You may trigger the UI page from remote with web tools or you may of course, as it’s open source, write something more comfortable easily if you get to know the code (onefinity-firmware / buildbotics-firmware).

Note: The password for user ‘bbmc’ is ‘onefinity’ and due to a sudoers rule, you become root with ‘sudo -i’ by supplying this password again.

Welcome to the forum!

2 Likes

I mostly use a remote computer. The only gcode file that lives permanently on the controller is spoilboard surfacing file. Every other one is uploaded from the remote computer before it’s run and then deleted afterward; yes primarily because it’s easy to manage files in subfolders on the remote computer. A browser on the remote computer just needs to be pointed to the IP address of the controller. It’s actually a better interface because you get a display of the tool path and its execution in real-time, something the Raspberry Pi in the controller is not powerful enough to do.

3 Likes

so you are doing all this manually right? you are not using a script, correct? I hoping to use a script

this looks promising, thank you Aiph5u

i read in other threads that 1F is not compatible with linuxcnc, did you find a way to run it?

“managing many files is really hard without folders”

I use the remote web UI 100% of the time. All of my project files live on the internal network. I never touch the files stored on the controller itself, other than to occasionally wipe them. When a file needs to be run, I simply pull it up from the network. My programs are well organized into folders by project name and even subfolders by version or part when applicable.

2 Likes

Hey Stephane @ultramarineblue, hey all,

I agree with @Matticustard and @Ruairisdad. When you use a remote computer to run the Onefinity User Interface in the web browser of your choice, and you want to upload a file to the Onefinity Controller by clicking on the upload button, you get a window with the filesystem of your remote computer. You are free to store your g-code files where you want there, including using subdirectories.

So there is no need to use a USB drive to bring your g-code files to the controller :slight_smile:, for this you have the Ethernet cable or the WiFi to connect a remote computer.

I would delete the g-code files on the Onefinity controller regularly (except those that serve as often-needed macros, as macros are not yet implemented1 (rsp. not yet backported from buildbotics)) and upload the g-code file that you need to be milled at the occasion.

The second advantage on using a remote web browser is as remote computers usually have a more capable graphics card with 3D-accelerated drivers installed, the built-in 3D toolpath simulation is shown, which is a very nice feature of the Onefinity/Buildbotics Controllers (note: the author of the buildbotics.com cnc system is also the author of camotics.org toolpath simulation software).


3 Likes

Hey Stephane,

here more info on the buildbotics-derived Onefinity CNC Controller system.