-
Notifications
You must be signed in to change notification settings - Fork 3
Home
Scott216 edited this page Apr 6, 2013
·
2 revisions
See if you can convert a typdef struct into a byte array and skip all the bit shifting.
For some ideas see:
http://stackoverflow.com/questions/2692383/convert-struct-into-bytes
One method that seems promising is:
typedef struct b { unsigned int x; unsigned int y; } b_s; typedef union a { b_s my_struct; char ary[sizeof(b)]; } a_u;
For the wire.h master, if the slave is turned off, the sketch gets stuck, need to see if there is a timeout.