send method
Sendet fertige ESC/POS-bytes. Wirft nicht — das Ergebnis (gesendet
oder Fehler) kommt im KeckPrintResult.
Implementation
@override
Future<KeckPrintResult> send(List<int> bytes) async {
if (bytes.isEmpty) return const KeckPrintResult.failure('Keine Bytes zum Drucken.');
try {
final BluetoothDevice device = await _ensureConnected();
await writeToBluetoothDevice(device, bytes);
return const KeckPrintResult.success();
} catch (e) {
return KeckPrintResult.failure('Bluetooth-Druck fehlgeschlagen ($address): $e');
}
}