Project: Transmitting airspeed from aircraft to ground (1500m line of sight)

Started by Istria, November 03, 2014, 06:53:03 PM

HeneryH

As for the why...

There are different types of data in most languages.  For instance in your example there are "character" strings and "volatile byte" strings.

Radio data must be a volatile byte pointer and when you try to assign that to payload which is a character pointer the compiler chokes.

Of course, with C++ the compiler gives you enough rope to hang yourself with and it allows you to override the error by simply forcing the cast to the new type.

If you want to assign a volatile pointer to a char pointer well then fine, you can do that.  Just force it!