Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit7c06309

Browse files
author
Michael Cooper
committed
Adding packed to the structs
1 parentcc855bc commit7c06309

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

‎MeshBase.h

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,8 @@
55
#include"RF24.h"
66
#include"LinkedList.h"
77

8+
#definePACKED__attribute__ ((packed))
9+
810
class MeshBase
911
{
1012
public:
@@ -24,7 +26,7 @@ class MeshBase
2426
boolsplit_enabled :1;
2527
uint8_tsplit_part :7;
2628
uint32_taddress_from;
27-
};
29+
} PACKED;
2830

2931
// -- Message types --
3032
enum message_type {
@@ -65,7 +67,7 @@ class MeshBase
6567
uint8_tapplication_capabilities;// What type of data do I expose
6668
uint16_tnum_peers;// Number of direct peers
6769
uint32_tuptime;// Seconds since boot
68-
};
70+
} PACKED;
6971

7072
};
7173

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp