from Gcode_generator import Gcode
from Gcode_generator import Machine    

machine_type = Machine.LASER

   # Create an instance of the Gcode class
gcode = Gcode(
    file="test_gcode",      # Output file name (no .gcode extension)
    mm_per_px=0.1,       # Conversion factor: mm per pixel
    speed=1000,          # Speed in mm/min
    machine=machine_type,
    
)

# Draw a line from (10, 20) to (30, 40)
gcode.draw_line(10, 20, 30, 40)


# Finish the G-code file
gcode.end_gcode()

print("G-code file generated: example.gcode")