mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-11-09 03:37:03 +01:00
CMF Watch Pro: Log outbound commands
This commit is contained in:
parent
9d3632d505
commit
ecda7b9f78
@ -80,7 +80,8 @@ public class CmfCharacteristic {
|
||||
public void sendCommand(final TransactionBuilder builder, final CmfCommand cmd, final byte[] payload) {
|
||||
final byte[][] chunks;
|
||||
|
||||
if (shouldEncrypt(cmd)) {
|
||||
final boolean encrypted = shouldEncrypt(cmd);
|
||||
if (encrypted) {
|
||||
chunks = makeChunksEncrypted(payload);
|
||||
} else {
|
||||
chunks = makeChunksPlaintext(payload);
|
||||
@ -91,6 +92,12 @@ public class CmfCharacteristic {
|
||||
return;
|
||||
}
|
||||
|
||||
LOG.debug(
|
||||
"Send command: cmd={}{}",
|
||||
cmd,
|
||||
payload.length > 0 ? " payload=" + GB.hexdump(payload) : ""
|
||||
);
|
||||
|
||||
for (int i = 0; i < chunks.length; i++) {
|
||||
final byte[] chunk = chunks[i];
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user