Code Monkey home page Code Monkey logo

webgcode's Introduction

Webgcode

The beginning of a browser integrated CNC milling machine.

A bit of History

I have a Mac, and there are no real software to control a milling machine from that kind of computer. I decided to hack some random pieces of technology together. Other people might be interested so I did everything in web technologies for easy trial.

I am trying to remove the dependency on g-code, because I don't like it, but I might retain some compatibility, so that users can tip toe into the system.

I started by creating a g-code parser with a viewer, and generated the steps from that and was able to send them to the embedded system. That's when I decided on the name of the project.

Today, there is no explicit way to send some g-code into the system. The parser is there, it's plugged etc. I just don't have an UI to put it into the system. I'm really into creating my own toolpath now, so it's an incentive to develop the code when I need something. It's also a trap, because anything new (say a drag knife, a laser head or an extruder) needs few weeks of development before being able to use it.

Web Stuff

visucam screen capture visucam screen capture

A preliminary CAM system for toolpath generation is present here: http://nraynaud.github.io/webgcode/webapp/visucamTest.html#/

The application can import (drop the file on the window) STL, SVG, gerber and excellon file formats.

There is a g-code simulator here: http://nraynaud.github.io/webgcode/ (that's where the name of the project comes from).

Controller Board

Controller board schematics

The controller is a STM32F4-DISCOVERY board directly connected to the stepper drivers isolators (open drain configuration). There is a USB cable between the board and the laptop, where a Chrome application controls the machine. The controller is quite dumb, it gets a list of steps, direction and their timing from the computer and executes them. The interpolation is entirely done offline on the computer.

Pushing the user button (blue) enter the manual control mode, receiving a program on USB automatically exits the manual mode. The orange LED is on when manual is on. The manual control is made through joysticks.

The controller is also connected to the VFD through an SPI isolated breakout board.

The wiring is described in the main.c and manual.c files.

Yes, I called the directory "interpolator" and no, there is no interpolation code in it.

IO Board

IO board schematics

There is an IO board to connect the MCU to various things, mainly the Huanyang VFD. On this last one, the output optoisolators (UPF and DRV) were not populated, so I just bought some on eBay and soldered them on (ok, I admit, I might have shorted the pins while the chips were in the mail, please don't tell my mom, yes she knows what 300VDC is, she taught me when I was a kid). The board consists of one 74HC595 and one 74HC165, behind a digital isolator; the MCU communicates over SPI to get isolated IOs.

Chrome Application

controller screen capture

On the computer, you can send the program to the machine. The application's main part is simply an iframe with the normal CAM html page in it (they talk with messages).

The USB protocol is custom since I couldn't find any standard, tell me if you know of any USB protocol to send sequences of steps to a machine (there is no g-code interpolator in the embedded system).

This is all Chrome technology in the hope to remove OS re-compilation/deployment efforts.

License

This code is licensed under MIT and Affero GPL double licensing.

Contact

To contact me about anything, you can use the issues system, there is no traffic on it.

webgcode's People

Contributors

nraynaud avatar kmichel avatar cyril-sf avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.