Skip to content

Commit

Permalink
Merge pull request #261 from OpenKNX/remove-byteorder-rp2040
Browse files Browse the repository at this point in the history
remove byteorder macros for rp2040 platform
  • Loading branch information
thelsing authored Nov 3, 2023
2 parents f8f34c5 + 354e5f5 commit e602b59
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/knx/bits.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

#if defined(__linux__)
#include <arpa/inet.h>
#elif defined(ARDUINO_ARCH_SAMD) || defined(ARDUINO_ARCH_RP2040) || defined(ARDUINO_ARCH_STM32) || defined (DeviceFamily_CC13X0)
#elif defined(ARDUINO_ARCH_SAMD) || defined(ARDUINO_ARCH_STM32) || defined (DeviceFamily_CC13X0)
#define getbyte(x,n) (*(((uint8_t*)&(x))+n))
#define htons(x) ( (getbyte(x,0)<<8) | getbyte(x,1) )
#define htonl(x) ( (getbyte(x,0)<<24) | (getbyte(x,1)<<16) | (getbyte(x,2)<<8) | getbyte(x,3) )
Expand Down

0 comments on commit e602b59

Please sign in to comment.