from src.deFIBrillator import FIBG2, plot_stream_file

# Set up FIB
fib = FIBG2()
fib.set_fov(10, "um")
fib.set_beam(fib.Beams.Acceleration30kV.pA48)
print(fib)

# Create pattern
pat = fib.new_pattern()
pat.set_dwell_time(1, "us")
pat.set_material(pat.Materials.Au)
pat.set_depth(177, "nm")
pat.set_scan_style(pat.ScanStyles.contour_outward)

# Create bounds
bounds = pat.add.rectangle(x_span=4000, y_span=4000)

# Create honeycomb lattice
lattice = pat.add.lattice(rows=10, cols=10, alpha=350*2 + 100, beta=350*2 + 100, gamma=60,
                          shape=pat.add.regular_polygon(inner_radius=350, millable=False))

pat.write_stream("test")
plot_stream_file("test")


