From 06f416935f8b23464181c6998084adb217382201 Mon Sep 17 00:00:00 2001
From: jgromes <jan.gromes@gmail.com>
Date: Sun, 5 Jan 2025 17:46:42 +0100
Subject: [PATCH] [SX128x] Added explicit typecast

---
 src/modules/SX128x/SX128x.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/modules/SX128x/SX128x.cpp b/src/modules/SX128x/SX128x.cpp
index a86d82ab..139fac55 100644
--- a/src/modules/SX128x/SX128x.cpp
+++ b/src/modules/SX128x/SX128x.cpp
@@ -482,7 +482,7 @@ int16_t SX128x::standby(uint8_t mode, bool wakeup) {
   if(wakeup) {
     // send a NOP command - this pulls the NSS low to exit the sleep mode,
     // while preventing interference with possible other SPI transactions
-    (void)this->mod->SPIwriteStream(RADIOLIB_SX128X_CMD_NOP, NULL, 0, false, false);
+    (void)this->mod->SPIwriteStream((uint16_t)RADIOLIB_SX128X_CMD_NOP, NULL, 0, false, false);
   }
 
   uint8_t data[] = { mode };