From 2509f5ac9cbe438e372f782728fe29aa15d64c40 Mon Sep 17 00:00:00 2001
From: Adhidarma Hadiwinoto <me@adhisimon.org>
Date: Mon, 5 Aug 2019 21:23:57 +0700
Subject: [PATCH] Coba delimiter

---
 lib/modem.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/modem.js b/lib/modem.js
index 5307d8d..3bbad99 100644
--- a/lib/modem.js
+++ b/lib/modem.js
@@ -2,7 +2,7 @@
 
 const INTERVAL_BEETWEN_SIGNAL_STRENGTH_MS = 60000;
 const MAX_LAST_DATA_AGE_MS = 3 * 60 * 1000;
-const REGEX_WAIT_FOR_OK_OR_ERROR = /\n(?:OK|ERROR)\r/;
+const REGEX_WAIT_FOR_OK_OR_ERROR = /[\r\n]+(?:OK|ERROR)\r/;
 
 const moment = require('moment');
 const SerialPort = require('serialport');
-- 
1.9.0