Simple Gcode Visualization In Javascript

$ 30.00 — 250.00 USD
The task is to build a one-way gcode visualization function using canvas and javascript.
Attached is an example of a possible input and output:


G1 X0 Y20
G3 X10 Y30 I0 J10
G1 X30 Y30
G1 X30 Y10
G2 X30 Y-10 I0 J-10
G1 X30 Y-25
G1 X20 Y-20
G2 X0 Y-20 I-10 J0
G3 X20 Y0 I0 J20
G1 X20 Y20
G1 X20 Y25 Z5
G0 X0 Y30
G1 X0 Y30 Z0
G1 X-10 Y10
G1 X0 Y-10
G1 X10 Y10
G1 X0 Y30



1.
The script only needs to support commands G0, G1, G2 and G3.
2.
Only valid gcode will be provided, using only the above 4 commands.
3.
The script should allow zooming with mouse wheel, panning and rotating with mouse button drag.
4.
Canvas size and default stroke/color can be hardcoded.
5.
The script should be able to accept parameters present in the first gcode comment passed as valid JSON.
For example:
G2 X30 Y-10 I0 J-10 ({"lineColor": "#abcdef"})
This should draw the segment using the provided color.

G1 X30 Y-25 ({}) ({"lineColor": "#fedcba"})
This should draw the segment using the default color, because only the first comment contains functional parameters
Only two parameters should be supported: lineColor and strokeWidth.
6.
Arrows and grid are not necessary.

The delivered function should take two parameters:
Parameter 1 is an array of strings that make up the gcode script.
Each element of the array is always a valid gcode line.

Parameter 2 is an object literal containing options, please use best judgement to determine what options should be supported.
A good starting point would be the default lineColor and strokeWidth.

The result of the function is not highly relevant, as the primary output is the canvas rendering.

For reference, this implementation is very close to what we have in mind: https://nraynaud.github.io/webgcode/ please see the 3d (top right) canvas area, you can use the example gcode provided above.

Similar Freelance jobs:

Correcciones Css Y Responsive Aplicación Web
Fix css and responsive webapp http://test.moogo.com.co see attach file with issues.Correcciones css y responsive aplicación web http://test.moogo.com.co ver archivo adjunto con los issues, por favor cuéntame en cuanto tiempo me lo entregas, te agradezco que este tiempo sea estimado lo más concienzudo posible. 
Full Description of Correcciones css y responsive aplicación web
Courier Online Platform
Need a platform that has a website , app, geolocation capability and algorithm to determine best routes and optimise for drivers and customers . Similar to uber
Full Description of Courier online platform
I Need An App Developer
Job brief We are looking for a qualified mobile and backend developer to join our start up team. You will be working with our organisation to develop and maintain a high quality mobile application for Android, iOS and others. If you’re passionate about mobile platforms and translating code into user-friendly apps, we would like to meet you. As a member of our development team, you’ll collaborate with internal teams to develop our application both for mobile and the corresponding back…
Full Description of I need an App developer
Develop A Responsive Website Using Flutter
i have an app that need to be developed as website using Flutter. it has to be responsive and compatible with multiple screen sizes and most used browsers (edge, chrome, safari, firefox ). keep in mind that you'll only do the front end, as the backend is already made. i will provide you with and API so all you have to do is post/get information through urls
Full Description of develop a responsive website using flutter
Crear Un Software
Software de ingeniería aplicada a la geología para ingreso de datos, generación de gráficos y entorno de consultas. Sistema operativo Windows, posteriormente a iOS y Android.
Full Description of Crear un software
I Want To Build A Tool Using Hap.py Benchmarking (nist) To Validate Any Vcf File By Running The File
The inputs to hap.py are two VCF files (a "truth" and a "query" file), the truth file is found here https://www.nature.com/articles/sdata201625/tables/3 which includes extensive genome sequencing for 1 person. So we can validate any VCF file by comparing our VCF with the truth VCF and the outcome will include a table with TP FP TN FN and precision with the sensitivity you can read more about it on this page: https://github.com/RealTimeGenomics/rtg-tools https://github.com/Illumina/hap.py/blob/master/doc/happy.md#working-with-genome-vcfs
Full Description of I want to build a tool using Hap.py…
Nft Marketplace, Own Blockchain, Governance Token + Mobile App
Hello, I'm looking for a team to help with coding my business into blockchain (fork of BSC or ETH). It's going to be linking a website to an NFT marketplace along with a governance token and mobile app together with interactive features that connect with the marketplace/blockchain. NFT Marketplace like RARIBLE, OpenSea, etc. I have a budget of $2500 USD right now. Let me know if we can work and how long it will take you
Full Description of NFT Marketplace, Own blockchain, Governance token + Mobile…
Software Centro Fitness
Desarrollador de software para centro fitness, registro de clientes, contratos automatizados, check in, reservas de clases, programación de eventos, etc
Full Description of Software centro fitness
Online Tutoring Platform
Hi, I work with a big E-learning company and I am looking to hire a team that can create an online tutoring platform that automatically matches tutor with the client. REQUIREMENTS - PLEASE DO NOT RESPOND IF YOU DO NOT MEET THE FOLLOWING: I will hire USA or native English only. Team must be professional and HAVE EXPERIENCE ALREADY CREATING A SIMILAR SYSTEM IN THE PAST My goal is to do this as fast as possible and correctly. I do…
Full Description of Online Tutoring Platform
Promio App -- 2
Promio es la aplicación que tiene como objetivo concentrar todas las actividades relacionadas con promociones, concursos o premios que requieren de la interacción del usuario con quién está realizando alguna publicación. Público Objetivo La aplicación considera clientes corporativos, que interactúan para cargar sus requerimientos y usuarios de la aplicación que interactúan con los clientes corporativos, participando en alguna de sus publicaciones. Usuarios Interactivos: Son todas aquellas personas que decidieron participar de alguna Publicación realizada por el Cliente Corporativo y que…
Full Description of Promio App -- 2
Build Websocket User Interface For Remote Voicetracking
I need a webpage driven by websocket communication from VB6 and page via javascript. It will list a playlist of music tracks, and allow user to record a voice track and insert and preview the result. It will also upload back to vb6 server the voicetrack and changes to playlist. I will be working directing using simple json and blob communication from vb6 app. See attached spec for more details.
Full Description of Build Websocket user interface for Remote Voicetracking
Personal Financial Planning Tools -- 2
I have a website on optimizepress 3 theme. There are 2 pages - retirement planner and goal planner which i want you to develop for me. Providing the exact requirement document, 1 sample basic - html, JavaScript code to start with. This should work seamlessly on desktop, laptop, tablet, mobile, etc on any device. So responsive design and cross browser compatible. Earlier these 2 pages were developed on OP2 and now it is not working on OP3 theme. Whatever is…
Full Description of Personal Financial Planning Tools -- 2
Create A Vuejs App That Pushes Signature To Outlook Web
Hi! I need to replicate this functionality in a simple app. 1- Loggin to the microsoft exchange acount and list the users 2- Push signatures to outlook web with a button to all accounts (signature content can be only the name) I made 2 videos, 1 describing how a competitor uses it https://www.youtube.com/watch?v=Snw1wdOwKYo And the other what i spect from the simple app https://www.youtube.com/watch?v=W1IhtD22gHg
Full Description of Create a VueJS App That Pushes Signature to…
Rebuild Our Custom Website
1.Make our new frontend responsive (stocking) - so that it changes shape with any shaped screen including mobiles. 2.Have a new filter system that allows customer to narrow down their search of what they want. With the ability to add extra pages at anytime that can look like another company with a custom header banner and colour changes. 3.Have SEO, heat mapping and other important features build in. 4.Have it communicate fully both ways with Zero accounting software. 5.An easier…
Full Description of Rebuild our custom website
© 2006 — 2026 hirelancer.com is an affiliate website, listing the freelance projects. We are collaborating with other sites like getFreelancer.com. Feel free to bid on any project and good luck! You will need register first, before bidding or posting projects. Basic memberhsip is always free. We might earn commissions from referring you. You will never ever pay additional fees for we referred you.