summaryrefslogtreecommitdiff
path: root/apps/system/cdcacm
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-10-08 11:34:22 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-10-08 11:34:22 -0600
commit59ac0e4d0352fad72b80018438e350ba405294b5 (patch)
treee11ebcb862370c10e4d8633d77673d4377d51a66 /apps/system/cdcacm
parent68c842108f9509299434ceb6f1595f0e4ddd4505 (diff)
downloadnuttx-59ac0e4d0352fad72b80018438e350ba405294b5.tar.gz
nuttx-59ac0e4d0352fad72b80018438e350ba405294b5.tar.bz2
nuttx-59ac0e4d0352fad72b80018438e350ba405294b5.zip
Update everything under apps/ to use the corrected syslog interfaces
Diffstat (limited to 'apps/system/cdcacm')
-rw-r--r--apps/system/cdcacm/cdcacm.h20
-rw-r--r--apps/system/cdcacm/cdcacm_main.c14
2 files changed, 7 insertions, 27 deletions
diff --git a/apps/system/cdcacm/cdcacm.h b/apps/system/cdcacm/cdcacm.h
index bc9cf2f9e..d8a351239 100644
--- a/apps/system/cdcacm/cdcacm.h
+++ b/apps/system/cdcacm/cdcacm.h
@@ -108,26 +108,6 @@
#define TRACE_BITSET (TRACE_INIT_BITS|TRACE_ERROR_BITS|TRACE_CLASS_BITS|\
TRACE_TRANSFER_BITS|TRACE_CONTROLLER_BITS|TRACE_INTERRUPT_BITS)
-/* Debug ********************************************************************/
-
-#ifdef CONFIG_CPP_HAVE_VARARGS
-# ifdef CONFIG_DEBUG
-# define message(...) lowsyslog(__VA_ARGS__)
-# define msgflush()
-# else
-# define message(...) printf(__VA_ARGS__)
-# define msgflush() fflush(stdout)
-# endif
-#else
-# ifdef CONFIG_DEBUG
-# define message lowsyslog
-# define msgflush()
-# else
-# define message printf
-# define msgflush() fflush(stdout)
-# endif
-#endif
-
/****************************************************************************
* Public Types
****************************************************************************/
diff --git a/apps/system/cdcacm/cdcacm_main.c b/apps/system/cdcacm/cdcacm_main.c
index e8ebebb2d..a9f8b504c 100644
--- a/apps/system/cdcacm/cdcacm_main.c
+++ b/apps/system/cdcacm/cdcacm_main.c
@@ -50,7 +50,7 @@
#include "cdcacm.h"
/****************************************************************************
- * Definitions
+ * Pre-processor Definitions
****************************************************************************/
/****************************************************************************
@@ -93,7 +93,7 @@ int sercon_main(int argc, char *argv[])
if (g_cdcacm.handle)
{
- message("sercon:: ERROR: Already connected\n");
+ printf("sercon:: ERROR: Already connected\n");
return EXIT_FAILURE;
}
@@ -105,15 +105,15 @@ int sercon_main(int argc, char *argv[])
/* Initialize the USB CDC/ACM serial driver */
- message("sercon: Registering CDC/ACM serial driver\n");
+ printf("sercon: Registering CDC/ACM serial driver\n");
ret = cdcacm_initialize(CONFIG_SYSTEM_CDCACM_DEVMINOR, &g_cdcacm.handle);
if (ret < 0)
{
- message("sercon: ERROR: Failed to create the CDC/ACM serial device: %d\n", -ret);
+ printf("sercon: ERROR: Failed to create the CDC/ACM serial device: %d\n", -ret);
return EXIT_FAILURE;
}
- message("sercon: Successfully registered the CDC/ACM serial driver\n");
+ printf("sercon: Successfully registered the CDC/ACM serial driver\n");
return EXIT_SUCCESS;
}
@@ -136,7 +136,7 @@ int serdis_main(int argc, char *argv[])
if (!g_cdcacm.handle)
{
- message("serdis: ERROR: Not connected\n");
+ printf("serdis: ERROR: Not connected\n");
return EXIT_FAILURE;
}
@@ -150,6 +150,6 @@ int serdis_main(int argc, char *argv[])
cdcacm_uninitialize(g_cdcacm.handle);
g_cdcacm.handle = NULL;
- message("serdis: Disconnected\n");
+ printf("serdis: Disconnected\n");
return EXIT_SUCCESS;
}