Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

4
  • The object is serialised fine, but I think that there might be inconsistencies between the vtables allocated on the two boards. The aim is to have an arduino launching functions on another one which I planned to do encapsulating lambdas inside polymorphic objects. I may just fall back to a plain old switch statement. Commented Aug 5, 2017 at 12:29
  • 2
    I looks like you want to send some code (as opposed some data) to be executed at the other Arduino. Arduino uses Harvard architecture, so you can't put code in RAM and execute it. I'm curious about what are you trying to do. Commented Aug 5, 2017 at 12:36
  • Also take in mind sometimes on different CPUs int values from 2 to 4 bytes can be stored differently (it's called little/big endian). Commented Aug 5, 2017 at 17:02
  • @DarioP the point is that you can't serialize the methods of an object between machines of this type; you can only serialize the data which uniquely specifies of object of the class. You need to have a compatible class on the receiving side, and inflate an instance of it with a constructor taking the serialized data. Commented Aug 6, 2017 at 20:54