Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install for CLI on RPI #37

Open
MadTooler opened this issue Apr 22, 2023 · 5 comments
Open

Install for CLI on RPI #37

MadTooler opened this issue Apr 22, 2023 · 5 comments

Comments

@MadTooler
Copy link

I would like to run the CLI on a raspberry pi 4b running Pi OS 64bit. Is there any documentation of the installation of svg2gcode for this purpose?

For running CLI, is there documentation of the parameters?

Thanks!

@MadTooler
Copy link
Author

MadTooler commented Apr 23, 2023

I haven't found any documentation on the install, but here is what I was able to make work.

Install rust and cargo with this script per https://doc.rust-lang.org/cargo/getting-started/installation.html
curl https://sh.rustup.rs -sSf | sh

Clone the svg2gcode github repo
sudo git clone https://github.com/sameer/svg2gcode.git

I had to set permissions of directories or else I was getting a Permission denied (os error 13):
sudo chown -R $(whoami) /home/pi/svg2gcode/

(Edit: After a new install on another pi, looks like chown of .cargo is not necessary ...)

and again here, but I am not sure this one was needed:
sudo chown -R $(whoami) /home/pi/.cargo/

Note, on the first run of the cargo svg2gcode, it will take a long time as it builds the project. Afterwards, it is quick.

Example CLI call if running from the root directory with example of an svg file in the desktop with an output to the desktop:

cargo  run --manifest-path svg2gcode/Cargo.toml  --release -- /home/pi/Desktop/drawing.svg --off 'M5' --on 'M4' -o /home/pi/out.gcode

@sameer
Copy link
Owner

sameer commented Apr 23, 2023 via email

@MadTooler
Copy link
Author

I am still not anymore familiar with rust as I only run your project from within it. When updating to your latest git, what all needs to be run?

Thanks.

@MadTooler
Copy link
Author

I tried to pull without success. I eventually deleted the svg2gcode directory and re cloned.

@sameer
Copy link
Owner

sameer commented Aug 8, 2024

I am still not anymore familiar with rust as I only run your project from within it. When updating to your latest git, what all needs to be run?

Thanks.

Hey, sorry I missed this! Running the below should be sufficient to get the CLI built and running locally

cargo run --release -p svg2gcode-cli -- <ARGS>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants