v1pi: Raspberry Pi Image with Octoprint and CNC.js (and wifi hotspot)

New Home Forum Software / Firmware Development v1pi: Raspberry Pi Image with Octoprint and CNC.js (and wifi hotspot)

This topic contains 160 replies, has 39 voices, and was last updated by  John 1 month, 4 weeks ago.

Viewing 30 posts - 121 through 150 (of 161 total)
  • Author
    Posts
  • #89014

    BT
    Participant

    I use V1Pi on my LowRider and can use my phone to control it through the Pi and specifically use Octoprint to send the gcode to my miniRambo.  IIRC, there is a plug-in for octoprint specifically for mobile phones that simplifies the interface and looks like I think a pendant would.  Homing should work just as you expect it to since you’re effectively sending gcode to execute the commands.

    2 users thanked author for this post.
    #89015

    Ian
    Participant

    Thanks for the reply, I will give it a go. – I will order another pi today and give it a go at the weekend. – I will report back on how it goes.

    UPDATE:

    I received the Pi yesterday and literally took 15 mins to get this set up. I simply replaced my laptop running RepetierHost with the pi running v1pi. I liked the look of cnc.js and am very familiar with Octoprint. I connected Octoprint to the printer and used OctoRemote to jog the router around a bit. All was fine until I realized that natively Octoprint doesn’t show the X,Y,Z coordinates. You have to issue an M114 to see the current position. I thought maybe that was a show stopper. – I took a look to see if they had plugin for this but I saw clearly that they don’t recommend realtime coordinate reading but they do have some code to create a custom control that allows you to receive the current position on demand.

    I then thought giving cnc.js would be a good option, I connected it using the Marlin button but very quickly found that when trying to move the router around the software crashed and did not recover. After several attempts it left me without a choice but to forego that option.

    I went back to Octoprint and started setting up the job that I had previously machined using RepetierHost without too much grief. I set the job up on the table and homed my X, Y then jogged my router into position with my phone running Octoremote. I had one hiccup here, I accidentally hit the home Z and it drove my cutter straight down and would not quit. I had to quickly pull the plug but I think I have damaged one of the PLA parts which I will need to reprint (gotta love having a mostly printed CNC). Once I had the position I sent an M114 and noted the co-ordinates before zeroing. – I do this in case something goes wrong and emergency stop is required, this can change the X,Y,Z zero so getting back to the half finished job can be hard unless you have a reference to go from. Anyway, I then zeroed my co-ordinates using a G92 X0 Y0 and the same for Z0 – I have found that separating these is usually best for my set up as I move the X,Y from zero to set up Z. Once it was set to go, I let Octoprint do its thing by starting the print with OctoRemote. – I have installed the software emergency stop on Octoprint but for some strange reason on the MPCNC instance of Octoprint it keeps disappearing (I use it on my Tevo instances (Carlos and Amelia) without a problem.

    The net outcome was that it machined the job flawlessly however, I think given this approach I am going to hard wire a physical emergency stop that shuts down both the router and the Rambo board.

    I have also noted that the legs to my MPCNC are too short as most of the jobs I have done have been raised up thus I am working on the limit of the retracted height for the Z axis. I am going to make longer ones.

     

    #90993

    miribota
    Participant

    I’ve been looking for a way to replace my various control PCs in the basement with a headless solution, and recently saw this, thank you putting this image together.

    One thing I want is a way to jog and zero while at the machine and not at a workstation. CNCJS provides some good looking pendant options that can be used on a tablet or mobile phone.

    It took me a bit to figure out the best way to get mount points setup with CNCJS on the image, but I thought I’d include it here for anyone else that may want to try it out.

    I’ve started with trying out the Tinyweb pendant (https://github.com/cncjs/cncjs-pendant-tinyweb) and will be looking at the ‘shop floor tablet’ as well (https://github.com/cncjs/cncjs-shopfloor-tablet).

    I downloaded tinyweb to /home/pi/cncjs/tinyweb

    Update DAEMON_ARGS to include the mount point in ‘/etc/default/cncjs’

    DAEMON_ARGS="--host=$HOST --port=$PORT -m /pendant:/home/pi/cncjs/tinyweb/src"

    1 user thanked author for this post.
    #95623

    martin
    Participant

    I’m a bit confused and maybe some one can bump me in the right direction. I have a raspbery pi 3b+ connected to an arduino with a ramps1.4. If I open octoprint or cncjs the ports available to select is /dev/ttyAMA0 and /dev/ttyACM0.

    Which one do you select ? If I pick AMA0 the cpu and memory gets depleted to a stage where you have to pull the power.

    If I pick ACM0 it is stable so is this the right one ? Running the v1pi version of software.

     

    Thanks

    #95633

    Jeffeb3
    Participant

    If you disconnect it, which one goes away (or isn’t there after reboot)?

    It’s probably ACM though.

    #95642

    martin
    Participant

    Thanks,

    Jip correct. If i pull the usb cable to the arduino ttyACM0 is gone.So we assume this is the right port then.

    I’m trying to install node-red but this break cncjs. So I assume it have to do with nodejs version compatibility.

    #95643

    Jeffeb3
    Participant

    I’m trying to install node-red but this break cncjs. So I assume it have to do with nodejs version compatibility.

    I am not sure. I haven’t used node-red in a long time. I tried to install node.js several times, in different ways, and the only one that worked was downloading and installing a precompiled version. Here is the script that generates it for the image:

    https://github.com/jeffeb3/v1pi/blob/master/src/modules/nodejs/start_chroot_script#L18

    And here are the params it uses:

    https://github.com/jeffeb3/v1pi/blob/master/src/modules/nodejs/config

    1 user thanked author for this post.
    #95662

    martin
    Participant

    Got a running version now with:

    Node.js – v10.15.3

    CNCjs – V1.9.18

    octopi – V1.3.10

    Node-RED – V0.20.3

    rasbian stretch

    Raspberry Pi 3 Model B Plus Rev 1.3

     

     

    Attachments:
    #96572

    John Boiles
    Participant

    I’m up and running with cncjs! Thanks @jeffeb3!

    I added a 5″ touchscreen and set up kiosk mode with the Tinyweb pendant but the Tinyweb pendant doesn’t support Marlin yet. I’ve started changing the code to make it work. I’m at the point where the pendant now will control jogging on my laptop, but the pendant still doesn’t do anything from the touchscreen on the pi. But I think I’m close!

    I definitely lost some time on the ‘first move’ bug before I came back and read the forums more thoroughly. Is the right fix cheton’s solution in the issue? I’d be happy to give implementing that a go.

    #96585

    Jeffeb3
    Participant

    Oh neat. That should be a nice interface. You could even do it with a second pi in the shop, connected via wifi if, for example, you had a low rider and didn’t want to chase it around for the interface or have a big cable.

    As for the bug, I was assuming he would fix it, and the next version would work. I’ve also found that some builds of Marlin are fine, and I suspect it has to do with which features (which comes down to a race condition). Long story short, I am not sure, but you should go ahead and make that PR. If nothing else, it will give it a kick start.

    #96802

    John Boiles
    Participant

    OK I made the PR. I’ll try it out this weekend. It would be great if others get a chance to validate it as well since this is an intermittent issue.

    #96990

    John Boiles
    Participant

    I’m seeing the same issue as @FX where the GCode processing is jerky in CNCJS (but not OctoPrint). I’m just using the TestCrown file but dialing up the speed to F7200 and I can really obviously see major differences between OctoPrint and CNCJS. My MPCNC pauses mid-arc. I could make a side-by-side video if anyone is interested.

    I’ve filed a MPCNC issue

    1 user thanked author for this post.
    #97016

    Jeffeb3
    Participant

    That is awesome. Thank you.

    #97032

    John Boiles
    Participant

    I made a comparison video and updated the issue with some early thoughts about causes for slowness based on my digging through code.

    4 users thanked author for this post.
    #97472

    Jeffeb3
    Participant

    Big thanks to John Boilea. John and Cheton are making good progress on the bug and I think this will get fixed or worked around by the next CNC.js release. I’ll make a new cut of v1pi then too. The video is solid gold. There are so many questions it answers.

    #97486

    Ryan
    Keymaster

    Wow the troubleshooting in that thread is impressive.

    #99076

    Jeffeb3
    Participant

    I built another version of v1pi. This one (v0.16.0) has these features:

    – CNC.js 0.9.20, with two specific Marlin bugfixes
    – OctoPrint 1.3.10 and based on OctoPi 0.16.0
    – Added buttons to start or stop the servers to the landing page
    – Disabled the https to the landing page, since connecting to the servers wasn’t secure anyway
    – Enabled OctoPrint api functions to connect without adding the :4080 to the address
    – Changed the landing page server to be flask based, which will be slightly more secure
    – Built using docker, not that it matters to v1pi users
    – Based off of raspian 2019-04-08-raspbian-stretch-lite.zip

    Auto hot spot isn’t working right now. I’m not really sure how many people use it. I like the feature, but I don’t like this implementation. I can fix it if there’s interest.

    I did not connect this to my low rider. I’ve just been playing with it on my desk, but I know some people are having trouble with the old CNC.js so I pushed it forward a bit.

    5 users thanked author for this post.
    #99077

    kd2018
    Participant

    I for one use the hotspot…

     

    Thank you for the updates!

    1 user thanked author for this post.
    #99123

    Jeffeb3
    Participant

    I for one use the hotspot…

    Thanks for letting me know. I’ve made a poll here, just so I can get a sense of it. It’s not going to be a majority wins or anything.

    v1pi hotspot

    As a separate item, I can add a line to the html so the website will “call home” to google analytics and I can get a count of how many people actually use it. That feels a little too Big Brother for a web page on a pi, but maybe I’m the only one? It is really hard to know how many people actually use it, since I don’t have many statistics on it.

    #99126

    Jeffeb3
    Participant

    n/m I can see the download count, and although that’s maybe not as good as knowing the number of people actively using it, it’s still better than adding a tracker to your home pi.

    If I were as cool as octoprint, I would make it an option…

    #99146

    Dennis
    Participant

    Hello Jeff.

    Thank you very much I will get to work with it, I will let you know how it goes.
    Is it possible to connect the pi with an ethernet cable? I still have an old desktop on which I put ubunto, but now it is not connecting. the computer is not equipped with WiFi

    #99158

    Jeffeb3
    Participant

    Ethernet works on all versions without modification.

    #99838

    Bill Vance
    Participant

    Hi Jeff.  I was hoping you could point me in the right direction on a few issues I’m having with the V1Pi. I’m very new to all of the CNC, and Pi and maybe I’ve bit off more than I can chew. I’ve built an 18″x 18″ work area MPCNC with 4″ of z axis travel, using a preloaded RAMBO 1.4 from Ryan. No duel endstops yet but I have the parts and wiring for it at some point. The MPCNC is working great through ESTLCam and Repetier.  I wanted to set up wireless control because its one of my only complaints about my Prusa MK2S, running an SD card back and forth. I hooked up the Pi and flashed your image and was able to make a connection through Octoprint and manually jog the spindle, but I’m having issues with cncjs.  I can’t get the spindle to move manually. Running a G0Z0 command doesn’t  seem to help anything.  Also, if I connect to Octoprint and then disconnect to try and connect to cncjs I get an error that the server isn’t available and I have to reboot the Pi

    I know these have come up before in the past but I’m not sure I understand how to fix them.  I was able to edit the file for the wifi so I think if I knew what to edit I could do it, but I’d need pretty explicit instructions on what to change.

    I also bought a 5 inch touchscreen hoping to be able to use it as a pendant but if I’m correct, it doesn’t look like the functionality is there yet.

    Thanks,

    Bill

    #99860

    Jeffeb3
    Participant

    I don’t know of any specific issues like this. I can tell you a few things:

    1) You can’t connect CNC.js and octoprint at the same time. You do need to connect to the same port.
    2) You need to select Marlin in CNC.js.
    3) You need a space, I’m pretty sure, between G0 and Z0. That also won’t do any movements, because the machine was likely restarted and it’s already at Z=0.
    4) The pendant is not as simple. It is possible, but you need to install the desktop, set up the plugin for the pendant and then set up chrone to open it.

    #99862

    Melvin
    Participant

    [CNC.js] I had to change the baud to 250000. I think it was defaulted to something else. It was the only way I could get it to work.

    Thanks for this Jeff. And also to John for making realize where the pauses were related to. So glad I touched on this thread again. Will be updating to new V1pi tomorrow!

     

    FYI, i do not use the hotspot feature. I would not mind the tracker if it helps you, but the machine is off the net anyway.

    1 user thanked author for this post.
    #100068

    Melvin
    Participant

    Wow, what a difference Octoprint made in the cut speed and smoothness. I’m blown away. Always thought that the jitter I got in CNC.js was just to be expected.

    I flashed a new SD card with the recent V1Pi, and unfortunately I have not noticed any difference in CNC.js (0.9.20). Octoprint is great for my 3d printer, but man is it a PIA to work with the MPCNC. I just want the smoothness of Octoprint with CNC.js. I really hope all the smart minds here can make that happen still.

    If anyone needs me to test anything out, I’m willing.

    #100520

    kd2018
    Participant

    I got the latest v1pi image up and running. Got some questions

    1. What do I have to change make either octoprint or cncjs not started by default.
    2. Where in the filesystem can I find the cncjs webserver’s files? I need to make some changes such as modify the home button to not crash my z as well as some other tweaks
    3. Is there a plugin or a way to have ‘macro’ functionality in octoprint like we have in cncjs?
    #100577

    Jeffeb3
    Participant

    What do I have to change make either octoprint or cncjs not started by default.

    You can use sudo update-rc.d cncjs disable to disable cncjs. The enable will reenable it. I think you can still start it after that, but it won’t be running automatically, I’m not sure.

    Where in the filesystem can I find the cncjs webserver’s files? I need to make some changes such as modify the home button to not crash my z as well as some other tweaks

    It’s installed from npm, so not from source. It gets minified, IIRC. The files are in /usr/local/lib/node_modules/cncjs. But I’m not sure you’ll be able to edit it as well as if you had installed it from source.

    Is there a plugin or a way to have ‘macro’ functionality in octoprint like we have in cncjs?

    I looked for a few minutes, but couldn’t find one. I could have sworn I have seen this before somewhere… You could get around it by making a .gcode file with your command and uploading it. Seems like a good plugin to have. I do know you can add gcode to the menu at the top (that currently has shutdown, reboot, etc.).

    1 user thanked author for this post.
    #100960

    Melvin
    Participant

    Is there a plugin or a way to have ‘macro’ functionality in octoprint like we have in cncjs?

    I looked for a few minutes, but couldn’t find one. I could have sworn I have seen this before somewhere…

    Take a look at this one. It’s the one I used on my 3d printer, and am going to use on the MPCNC if I cant get CNC.js to work smoothly. https://plugins.octoprint.org/plugins/TerminalCommands/

    2 users thanked author for this post.
    #100965

    Jeffeb3
    Participant

    Take a look at this one. It’s the one I used on my 3d printer, and am going to use on the MPCNC if I cant get CNC.js to work smoothly. https://plugins.octoprint.org/plugins/TerminalCommands/%5B/quote%5D

    Nice. Thanks for posting this.

Viewing 30 posts - 121 through 150 (of 161 total)

You must be logged in to reply to this topic.