aboutsummaryrefslogtreecommitdiff
path: root/AT91SAM7S256/Source/BtTest.inc
diff options
context:
space:
mode:
Diffstat (limited to 'AT91SAM7S256/Source/BtTest.inc')
-rw-r--r--AT91SAM7S256/Source/BtTest.inc12
1 files changed, 10 insertions, 2 deletions
diff --git a/AT91SAM7S256/Source/BtTest.inc b/AT91SAM7S256/Source/BtTest.inc
index 31d9373..f879e20 100644
--- a/AT91SAM7S256/Source/BtTest.inc
+++ b/AT91SAM7S256/Source/BtTest.inc
@@ -1,15 +1,18 @@
//******* TestPrg ************************************************************
+//#define TESTPRG // If defined the test program will be included
+
+#ifdef TESTPRG
#include "Test1.txt"
#include "Test2.txt"
-//#define TESTPRG // If defined the test program will be included
+#endif
extern void BtIo(void);
const char BUILD_DATE[] = __DATE__;
const char BUILD_TIME[] = __TIME__;
-const char MONTH[] = "JanFebMarAprMajJunJulAugSepOktNovDec";
+const char MONTH[] = "JanFebMarAprMayJunJulAugSepOctNovDec";
void GetProtocolVersion(UBYTE *String)
{
@@ -19,7 +22,12 @@ void GetProtocolVersion(UBYTE *String)
if (Tmp < 100)
{
+#ifdef CUSTOM_FIRMWAREVERSION
+ int pad = (sizeof (CUSTOM_FIRMWAREVERSION) - 1) > 7 ? 1 : 1 + 7 - (sizeof (CUSTOM_FIRMWAREVERSION) - 1);
+ sprintf((char*)String,"FW %*u.%02ui-%.7s", pad, (FIRMWAREVERSION >> 8) & 0x00FF,Tmp & 0x00FF, CUSTOM_FIRMWAREVERSION);
+#else
sprintf((char*)String,"FW %3u.%02u",(FIRMWAREVERSION >> 8) & 0x00FF,Tmp & 0x00FF);
+#endif
}
else
{