startRecordLineFile method
Implementation
Future<bool> startRecordLineFile(int timestamp, int event,
{int timeout = 5, int channel = 4, int frameNo = 0, int key = 0}) async {
bool ret = await writeCgi(
"livestream.cgi?streamid=5&ntsamp=$timestamp&event=$event&framenum=$frameNo&recch=$channel&key=$key&",
timeout: timeout);
if (ret) {
CommandResult result = await waitCommandResult((int cmd, Uint8List data) {
return cmd == 24631;
}, timeout);
if (result.isSuccess) {
Map data = result.getMap();
return data["result"] == "0";
}
}
return false;
}