I'm afraid you're right! there was no need to swap the bits... this is weird... or I find it weird, because on the LightBlue app, it shows that the format the data was found was as a 4-byte Float little Endian...
I didn't have time to look at all the details of the earlier messages and was under the impression that byte order needed to be reversed. I'd have to spend a little time digging through the details to see why/when it is/isn't needed.
I am wondering tho which do you think its less memory consuming for the app, this implementation or using a memcpy function?
It looks like any extra memory is local variables and the space is no longer in use after the conversion is done, so it shouldn't have much impact on memory use. If your iOS app is struggling for a few extra bytes for a few microseconds you've got bigger problems to deal with...
Doing an extra copy of a few bytes may take a little extra time, but most Apps have far more significant time/memory issues that should be dealt with before micromanaging small, infrequent data conversions like this. (Often the compiler/run-time do all sorts of optimizations --- micromanaging code for time/space takes a lot of effort and study to be effective on a platform like iOS. It's usually best to focus on the big-picture items first: code clarity, good code architecture, correctness, and efficiency of high-level algorithms.)
mrwilljackson & maverik0106: Thanks, I'll have to take a rain check on the coffee,