usrBanner.c
上传用户:luoyougen
上传日期:2008-05-12
资源大小:23136k
文件大小:2k
源码类别:

VxWorks

开发平台:

C/C++

  1. /* usrBanner.c - print the shell banner */
  2. /* Copyright 1984-2001 Wind River Systems, Inc. */
  3. /*
  4. modification history
  5. --------------------
  6. 01d,29jan02,g_h  Added WDB_COMM_VTMD as a possible WDB_COMM_TYPE_STR
  7. 01c,12sep01,jhw  Added WDB_PIPE as a possible WDB_COMM_TYPE_STR
  8.  Fixed display alignment of WDB Comm Type.
  9. 01b,21aug01,jhw  Added WDB_COMM_TYPE to banner (SPR 9559)
  10. 01a,02jun98,ms   written
  11. */
  12. /*
  13. DESCRIPTION
  14. */
  15. #ifdef INCLUDE_WDB_COMM_NETWORK
  16. #define WDB_COMM_TYPE_STR "WDB_COMM_NETWORK"
  17. #endif /* INCLUDE_WDB_COMM_NETWORK */
  18. #ifdef INCLUDE_WDB_COMM_SERIAL
  19. #define WDB_COMM_TYPE_STR "WDB_COMM_SERIAL"
  20. #endif /* INCLUDE_WDB_COMM_SERIAL */
  21. #ifdef INCLUDE_WDB_COMM_TYCODRV_5_2
  22. #define WDB_COMM_TYPE_STR "WDB_COMM_TYCODRV_5_2"
  23. #endif /* INCLUDE_WDB_COMM_TYCODRV_5_2 */
  24. #ifdef INCLUDE_WDB_COMM_NETROM
  25. #define WDB_COMM_TYPE_STR "WDB_COMM_NETROM"
  26. #endif /* INCLUDE_WDB_COMM_NETROM */
  27. #ifdef INCLUDE_WDB_COMM_VTMD
  28. #define WDB_COMM_TYPE_STR "WDB_COMM_VTMD"
  29. #endif /* INCLUDE_WDB_COMM_VTMD */
  30. #ifdef INCLUDE_WDB_COMM_END
  31. #define WDB_COMM_TYPE_STR "WDB_COMM_END"
  32. #endif /* INCLUDE_WDB_COMM_END */
  33. #ifdef INCLUDE_WDB_COMM_CUSTOM
  34. #define WDB_COMM_TYPE_STR "WDB_COMM_CUSTOM"
  35. #endif /* INCLUDE_WDB_COMM_CUSTOM */
  36. #ifdef INCLUDE_WDB_COMM_PIPE
  37. #define WDB_COMM_TYPE_STR "WDB_COMM_PIPE"
  38. #endif /* INCLUDE_WDB_COMM_PIPE */
  39. #ifndef WDB_COMM_TYPE_STR
  40. #define WDB_COMM_TYPE_STR "Unknown"
  41. #endif /* WDB_COMM_TYPE_STR */
  42. /******************************************************************************
  43. *
  44. * usrBanner - print the banner information to the Target Shell
  45. *
  46. * This routine prints out the banner information to the Target Shell.
  47. *
  48. * RETURNS :
  49. * None
  50. *
  51. * NOMANUAL
  52. */
  53.  
  54. void usrBanner (void)
  55.     {
  56.     printLogo ();                               /* print out the banner page */
  57.     printf ("                               ");
  58.     printf ("CPU: %s.  Processor #%d.n", sysModel (), sysProcNumGet ());
  59.     printf ("                              ");
  60.     printf ("Memory Size: 0x%x.",
  61. (UINT)(sysMemTop () - (char *)LOCAL_MEM_LOCAL_ADRS));
  62.     printf ("  BSP version " BSP_VERSION BSP_REV ".n");
  63. #ifdef INCLUDE_WDB
  64.     printf ("                             WDB Comm Type: %sn",
  65.          WDB_COMM_TYPE_STR );
  66.     printf ("                            WDB: %s.n",
  67.             ((wdbRunsExternal () || wdbRunsTasking ()) ?
  68.                  "Ready" : "Agent configuration failed") );
  69. #endif
  70.     }