Sub btnImage_Click
Printer1.Reset
Dim bmp As Bitmap
' Load an image to print and resize it to the maximum mage dimensions for the printer
'bmp.InitializeResize(File.DirAssets, "F-35Brefuel.jpg", 576, 512, True) 'ignore
'bmp.InitializeResize(File.DirAssets, "Avro_Lancaster.jpg", 576, 512, True) 'ignore
bmp.Initialize(File.DirAssets,"test01.jpg") ' <-------
' Convert the RGB image to one with luminance values
Dim myimage As AnImage = Printer1.ImageToBWIMage(bmp)
' Choose thresholding the image or dithering it to get a black and white bit image
'myimage = Printer1.ThresholdImage(myimage, 128)
'myimage = Printer1.DitherImage1D(myimage, 128)
myimage = Printer1.DitherImage2D(myimage, 128)
' Send the black and white bit image to the printer
myimage= Printer1.PackImage(myimage)
Printer1.WriteString(CRLF) ' nudge the printer to show the user something is happening
Printer1.PrintImage(myimage)
Printer1.WriteString(CRLF & "Ended" & CRLF)
End Sub