Closed mobil750 closed 7 months ago
the byteorder macros for the rp2040 plattform are already defined by the arduino-pico core. Did you define LWIP_DONT_PROVIDE_BYTEORDER_FUNCTIONS ? You must not.
I didn't define LWIP_DONT_PROVIDE_BYTEORDER_FUNCTIONS - as far as I'm aware of. I checked my files and didn't find the name. Where should it be defined?
Where should it be defined?
It should NOT be defined. The rp2040 plattforms relies on the byteorder macros defined by the pico-core, which usually defines them, at least if you did not configure it otherwise. You must find out why in your environment pico-core does not define them.
I don't think you are right. The problem is that the mentioned definitions are missing ("ntohs(x), ntohl(x)"). There is no hint regarding LWIP_DONT_PROVIDE_BYTEORDER_FUNCTIONS in bits.h It is only an issue within the bits.h file and adding " || defined (ARDUINO_ARCH_RP2040)" solves the compile issue. The binary works well. From my point of view it is obvious that the RP2040 part is missing. Compare the two parts of the bit.h file below.
pragma once
Maybe the "DeviceFamily_CC13X0" is wrong and should be "ARDUINO_ARCH_RP2040" as in the second part?
Can you agree?
Can you agree?
not at all.
You may know that I am the author of the rp2040 support in this stack and I use it every day, as it is used in the complete OpenKNX Team. So - it just works. For all but you.
The problem is that the mentioned definitions are missing ("ntohs(x), ntohl(x)").
I understood your problem. And I told you, that these macros - they are called byteorder macros - should already be defined by the arduino-pico core. There should not be more then one definition, this is the reason why this plattform, which is made and intended for the use with the arduino-pico core, does not define the byteorder macros intentionally. You must find out why in you environment these macros are not defined.
Here you can see, that this macro is defined and the sketch builds.
OK understood and sorry for bothering.
I found the LWIP_DONT_PROVIDE_BYTEORDER_FUNCTIONS which I wasn't aware of.
Thanks
Thanks @Ing-Dom for the support.
Hi, today I started after a longer period again on my knx project (RP2040 based) and therefore pulled the current master branch of KNX.
After that compilation failed because "ntohs(x)" was not defined ... I checked and found in bits.h the following
As I'm using RP2040 I added " || defined (ARDUINO_ARCH_RP2040)" to the above line and compilation is OK again.
Is there an intension to avoid "ARDUINO_ARCH_RP2040" here or is it just missing?
Regards Helmut