printRaw method
*printRaw
This method you can send a raw esc/pos string to the printer. see the example folder for more instructions how to do it!
Implementation
Future<int> printRaw(List<int> rawList) async {
await reset();
Map<String, dynamic> mapParam = new Map();
Uint8List _list = Uint8List.fromList(rawList);
mapParam['data'] = _list;
mapParam['bytes'] = _list.lengthInBytes;
int? _raw =
await platform?.invokeMethod('printRaw', {'rawArgs': mapParam}) ?? 9999;
if (_raw < 0) {
throw ElginException(_raw);
}
return _raw;
}