From: andreaskoepke Date: Tue, 12 Jun 2007 11:02:35 +0000 (+0000) Subject: handle TOSH_DATA_LENGTH more gracefully X-Git-Tag: release_tools_1_2_4_1~135 X-Git-Url: https://oss.titaniummirror.com/gitweb/?p=tinyos-2.x.git;a=commitdiff_plain;h=796bb709d30f07bc4118b1e2cbb656fda2d8bec3 handle TOSH_DATA_LENGTH more gracefully --- diff --git a/tos/platforms/eyesIFX/platform_message.h b/tos/platforms/eyesIFX/platform_message.h index 2f187dce..3a32c598 100644 --- a/tos/platforms/eyesIFX/platform_message.h +++ b/tos/platforms/eyesIFX/platform_message.h @@ -44,11 +44,9 @@ #include "Serial.h" #include "tda5250_message.h" -#ifdef TOSH_DATA_LENGTH -#undef TOSH_DATA_LENGTH -#endif - +#ifndef TOSH_DATA_LENGTH #define TOSH_DATA_LENGTH 48 +#endif typedef union message_header_t { tda5250_header_t radio; @@ -67,4 +65,8 @@ typedef tda5250_header_t message_radio_header_t; typedef tda5250_footer_t message_radio_footer_t; typedef tda5250_metadata_t message_radio_metadata_t; +#if TOSH_DATA_LENGTH < 33 +#error "TOSH_DATA_LENGH must be larger than 33 bytes for this platform." +#endif + #endif