From 13d52c269c25c85065bda0c6f842261dc619521e Mon Sep 17 00:00:00 2001 From: maniacbug Date: Tue, 14 Jun 2011 20:03:25 -0700 Subject: [PATCH] Removed time from header. Added reserved byte for future use. --- RF24Network.cpp | 2 +- RF24Network.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/RF24Network.cpp b/RF24Network.cpp index 6039f084..2961d754 100644 --- a/RF24Network.cpp +++ b/RF24Network.cpp @@ -283,7 +283,7 @@ bool RF24Network::write_to_pipe( uint16_t node, uint8_t pipe ) const char* RF24NetworkHeader::toString(void) const { static char buffer[45]; - snprintf(buffer,sizeof(buffer),"id %04x from %04x to %04x type %c time %04x",id,from_node,to_node,type,time); + snprintf(buffer,sizeof(buffer),"id %04x from %04x to %04x type %c",id,from_node,to_node,type); return buffer; } diff --git a/RF24Network.h b/RF24Network.h index be599352..5b2d2dc5 100644 --- a/RF24Network.h +++ b/RF24Network.h @@ -52,8 +52,8 @@ struct RF24NetworkHeader uint16_t from_node; /**< Logical address where the message was generated */ uint16_t to_node; /**< Logical address where the message is going */ uint16_t id; /**< Sequential message ID, incremented every message */ - uint16_t time; /**< Time of the sending machine when sent. */ unsigned char type; /**< Type of the packet. 0-127 are user-defined types, 128-255 are reserved for system */ + unsigned char reserved; /**< Reserved for future use */ static uint16_t next_id; /**< The message ID of the next message to be sent */ @@ -76,7 +76,7 @@ struct RF24NetworkHeader * * @param _to The logical node address where the message is going */ - RF24NetworkHeader(uint16_t _to, unsigned char _type = 0): to_node(_to), id(next_id++), time(millis()&0xffff), type(_type&0x7f) {} + RF24NetworkHeader(uint16_t _to, unsigned char _type = 0): to_node(_to), id(next_id++), type(_type&0x7f) {} /** * Create debugging string