Uint8List stringToBytes(String string) { Uint8List tmp = Uint8List.fromList(utf8.encode(string)); return tmp; }