Browser2CAMBrowser2CAM Tutorials

Beginner · about 15 minutes

Convert DXF to G-code

Browser2CAM converts a DXF drawing to CNC G-code directly in your browser. Your file stays on your device. This tutorial shows the complete workflow using demo.dxf.

Convert your own DXF to G-code ↗
DXFContour millingSimulationG-code
Example filedemo.dxf · 90 × 60 mm
You needA suitable end mill and your machine data
1

Open demo.dxf

Open Browser2CAM. On the start page, click demo.dxf below the main button. This loads exactly the drawing used in this tutorial.

  1. Click demo.dxf.
  2. Wait for the DXF preview and import panel.
2

Check the DXF settings and import

Browser2CAM recognizes the drawing as 90 × 60 mm. Keep the drawing unit at mm, scale at 100% and rotation at 0°.

  1. Leave the drawing unit at mm.
  2. Check the 100% scale.
  3. Enter a suitable finished-part thickness for your practice stock.
  4. Click Import DXF.
DXF import preview of demo.dxf with import settings
The import preview shows demo.dxf at 90 × 60 mm, 100% scale and 10 mm finished-part thickness.
3

Check the setup

Open Setup. The finished-part thickness is carried over from the DXF import. Also verify the safety height, approach height and approach feed rate.

  1. Compare the finished-part thickness with your stock.
  2. Choose a safety height that clears all clamps.
  3. Adapt the approach height and approach feed rate to your machine.
  4. If required, choose Select workpiece zero and click the desired standard snap point.
Setup panel with workpiece zero, finished-part thickness, safety height, approach height and approach feed rate
Use “Setup” to define the workpiece zero and project-wide heights. The example shows a 3 mm finished-part thickness, 10 mm safety height, 1 mm approach height and 1000 mm/min approach feed rate.
The red coordinate axes show the active workpiece zero. Every operation depth is referenced to it.
4

Select the outside contour

Close Setup and switch to the top view. Leave geometry selection on Automatic. One click then selects a connected closed contour.

  1. Select the Top view.
  2. Leave geometry selection on Automatic.
  3. Click the outside contour – it turns green.
  4. Check that only the required closed outside contour is highlighted in green. Use X to deselect an incorrect or no longer required geometry selection.
  5. Use + Operation to create an operation.
Browser2CAM geometry selection with Automatic enabled
Leave geometry selection on “Automatic”.
Outside contour of demo.dxf highlighted in green
After the click, the fully selected outside contour is shown in green.
The X and + Operation buttons in Browser2CAM
“+ Operation” creates a new operation for the selected contour. “X” deselects the current geometry selection.
5

Create the contour operation

Name the operation, select a tool and enter the cutting data. This example uses a 6 mm solid-carbide end mill and the Contour operation type.

  1. Enter a name such as My first contour operation.
  2. Select the 6 mm solid-carbide end mill under Tool.
  3. Enter the XY feed rate, ramp feed rate and spindle speed for your tool, material and machine.
  4. Choose Contour as the operation type.
  5. Set the path side to Outside.
  6. Choose Ramp as the entry strategy and set a 3° ramp angle.
  7. Set the start height to 0 mm, the cutting depth to −3 mm and the depth per pass to −1 mm. This produces three passes.
  8. Finally, click Create operation.
Basic settings of the first contour operation with a 6 mm tool, feed rates and spindle speed
The operation name, 6 mm tool, feed rates and spindle speed are defined in the operation dialog.
Contour settings with Outside path side, Ramp entry and a 3 degree ramp angle
The outside contour uses the “Outside” path side, “Ramp” entry strategy and a 3° ramp angle.
Contour height settings with a 0 millimetre start height, minus 3 millimetre cutting depth and minus 1 millimetre depth per pass
A 0 mm start height, −3 mm cutting depth and −1 mm depth per pass machine the contour in three passes.
The cutting data shown are examples. Use values that suit your actual tool, material and machine. The tool radius determines the cutter-center path, so make sure Outside is selected.
6

Inspect the toolpath preview

After creating the operation, a preview of the calculated toolpath appears in the workspace. The created operation is shown on the right.

  1. Check that the orange toolpath runs outside the contour.
  2. If necessary, drag the start point marked S to a suitable position on the contour with the mouse.
  3. Check that the panel on the right shows the Contour operation and depths from 0 to −3 mm.
  4. Inspect the complete path, including all three depth passes.
Orange toolpath preview with draggable start point S and the created contour operation in the panel on the right
The orange toolpath is shown with the corrected material thickness. You can drag start point S with the mouse, and the created operation is visible on the right.
7

Simulate the operation

The button with the blue play symbol simulates this individual operation. It is located directly on the operation card in the panel on the right.

  1. Click the blue play symbol on My first contour operation.
    My first contour operation card with the blue play button used to start the simulation
    The play button on the operation card starts the simulation for this operation.
  2. Play all three passes to the end.
  3. Look for collisions, unexpected linking moves and incorrect material removal.
  4. If anything is wrong, change the operation and simulate again.
Outside-contour simulation with the tool and the workpiece shown in green
The simulation shows the tool motion and material removal for the contour operation. Play all three passes to the end.
8

Generate G-code

Use the button with the code symbol to generate G-code for the operation. Browser2CAM uses the currently selected postprocessor.

Button with a code symbol used to generate G-code
Use the code symbol to generate G-code.

If you want to change the postprocessor, click the person icon. You can find the settings under Manage machines.

Personal settings behind the person icon showing the Machine section and Manage machines button
Machine management is located behind the person icon.

Done – final checklist

  • Correct machine and postprocessor are active
  • Workpiece zero matches the real setup
  • Tool diameter, cutting length and stickout are correct
  • Spindle speed, feeds and depths suit the material and machine
  • The full simulation shows no unexpected material removal
  • G-code has been inspected and a dry run is planned

Convert a DXF to G-code yourself

Open Browser2CAM and select demo.dxf on the start page, or import your own DXF file. This tutorial remains open in its own tab.

Convert your own DXF to G-code ↗