From ed07df16da675c4c123e02a996822daf13d69c63 Mon Sep 17 00:00:00 2001
From: lhoerl <coder@lolux.de>
Date: 周一, 03 8月 2015 22:42:07 +0800
Subject: [PATCH] added full SCPI error messages added list for device dependent error messages some minor changes to get rid of compiler warnings added support for Keil ARM compiler added support for National Instruments CVI compiler removed bug if(c = '\0')...

---
 libscpi/inc/scpi/config.h |   29 +++++++++++++++++++++++++++++
 1 files changed, 29 insertions(+), 0 deletions(-)

diff --git a/libscpi/inc/scpi/config.h b/libscpi/inc/scpi/config.h
index 811d5a4..bb59d4f 100644
--- a/libscpi/inc/scpi/config.h
+++ b/libscpi/inc/scpi/config.h
@@ -41,7 +41,36 @@
 extern "C" {
 #endif
 
+/* set the termination character(s)   */
+#define ENDCODE_CR              1      /*   use a <CR> carriage return aka '\r' as termination charcter */
+#define ENDCODE_LF              2      /*   use a <LF> line feed aka       '\n' as termination charcter */
+#define ENDCODE_CRLF            3      /*   use <CR><LF> carriage return + line feed aka "\r\n" as termination charcters */
+   
+#define USED_ENDCODE            ENDCODE_LF
+   
+/* select the error list(s) */
+#define ERR_SCPI_MINIMUM        1
+#define ERR_SCPI_FULL           2
+#define ERR_SCPI_MIN_PLUS_USER  3
+#define ERR_SCPI_FULL_PLUS_USER 4
+
+#define USED_SCPI_ERROR_LIST    ERR_SCPI_MIN_PLUS_USER
+   
 /* Compiler specific */
+/* ARM, e.g. Cortex-M CPUs */
+#if defined(__arm__)
+#define HAVE_STRNLEN            0
+#define HAVE_STRNCASECMP        1
+#define HAVE_STRNICMP           0
+#endif
+
+/* National Instruments (R) CVI x86/x64 PC platform */
+#if defined(_CVI_)
+#define HAVE_STRNLEN            0
+#define HAVE_STRNCASECMP        0
+#define HAVE_STRNICMP           0
+#endif
+
 /* 8bit PIC - PIC16, etc */
 #if defined(_MPC_)
 #define HAVE_STRNLEN            0

--
Gitblit v1.9.1