Skip to content

Commit

Permalink
added small delay for Daly RS485/UART processing to remove no-bytes
Browse files Browse the repository at this point in the history
received message after issuing command 0x95
  • Loading branch information
ai-republic committed Jan 15, 2024
1 parent 5f6dca5 commit 447d1ff
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,11 @@ protected List<ByteBuffer> sendMessage(final int bmsNo, final DalyCommand cmd, f
port.sendFrame(sendBuffer);
LOG.debug("SEND: {}", Port.printBuffer(sendBuffer));

try {
Thread.sleep(50);
} catch (final InterruptedException e) {
}

// read the expected response frame(s)
for (int i = 0; i < frameCount; i++) {
final ByteBuffer receiveBuffer = port.receiveFrame(validator);
Expand Down

0 comments on commit 447d1ff

Please sign in to comment.