Print image for first time it work. but next time layout change position [Thermal Printer Model GG-5805DD]
See original GitHub issue Future _printThermalBluetooth() async {
print('_printThermalBluetooth');
this
._screenshotCustomer
.capture(delay: Duration(milliseconds: 10), pixelRatio: 3)
.then((Uint8List captureImage) async {
print('_printThermalBluetooth ====> $captureImage');
bluetooth.isConnected.then((isConnected) async {
if (isConnected) {
var image = decodeImage(captureImage);
image = copyResize(image, width: 380);
Uint8List imageByte = encodePng(image);
print('_printThermalBluetooth ====> $imageByte');
print('_printThermalBluetooth asUint8List ====> ${imageByte.offsetInBytes} ${imageByte.lengthInBytes}');
bluetooth.printImageBytes(imageByte.buffer
.asUint8List(imageByte.offsetInBytes, imageByte.lengthInBytes));
bluetooth.printNewLine();
bluetooth.printNewLine();
bluetooth.printNewLine();
bluetooth.printNewLine();
bluetooth.printNewLine();
bluetooth.printNewLine();
bluetooth.printNewLine();
bluetooth.printNewLine();
bluetooth.printNewLine();
bluetooth.paperCut();
_disconnect();
}
});
});
}
Issue Analytics
- State:
- Created 2 years ago
- Comments:10
Top Results From Across the Web
POS Thermal Receipt Printer Troubleshoot - Not Printing Evenly
This is a troubleshooting video brought to you by Sintel Systems. This video is for a Thermal Receipt Printer. This video will explain...
Read more >Bitmap Printing | Mini Thermal Receipt Printers
This printer can produce bitmaps, which can add a touch of class to a receipt with your logo or similar. The first step...
Read more >Thermal Printer Protocols for Image and Text - Visuality
In order to print an image on the thermal printer, you have to process the image pixel by pixel using ESC/POS, which is...
Read more >Print image on center position on the Thermal Printer
Hi, I am interfacing RP203 Thermal Printer from PIC16F1938 using TTL. I can print text, barcodes and images on the Thermal Printer.
Read more >Printing an Image with textwrapping and Alignment in ESC ...
But this printer cannot print the Korean font since there is no Korean font in it. Furthermore, there is no time, so I...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I found a work around. So with my printer it seems the consecutive print misaligns if the height of the image is more than 200 px.
Image manipulation library I used: https://pub.dev/packages/image
here’s my code. it has been changed to match with your variable names. i’m not sure what your img_count variable is but the for loop must go on for the full height of the image.