gpakErrs.h 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  1. /*
  2. * Copyright (c) 2002 - 2004, Adaptive Digital Technologies, Inc.
  3. *
  4. * File Name: GpakErrs.h
  5. *
  6. * Description:
  7. * This file contains DSP reply status codes used by G.PAK API functions to
  8. * indicate specific errors.
  9. *
  10. * Version: 1.0
  11. *
  12. * Revision History:
  13. * 10/17/01 - Initial release.
  14. * 07/03/02 - Updates for conferencing.
  15. * 06/15/04 - Tone type updates.
  16. *
  17. * This program has been released under the terms of the GPL version 2 by
  18. * permission of Adaptive Digital Technologies, Inc.
  19. */
  20. /*
  21. * See http://www.asterisk.org for more information about
  22. * the Asterisk project. Please do not directly contact
  23. * any of the maintainers of this project for assistance;
  24. * the project provides a web site, mailing lists and IRC
  25. * channels for your use.
  26. *
  27. * This program is free software, distributed under the terms of
  28. * the GNU General Public License Version 2 as published by the
  29. * Free Software Foundation. See the LICENSE file included with
  30. * this program for more details.
  31. */
  32. #ifndef _GPAKERRS_H /* prevent multiple inclusion */
  33. #define _GPAKERRS_H
  34. /* Configure Serial Ports reply status codes. */
  35. typedef enum
  36. {
  37. Pc_Success = 0, /* serial ports configured successfully */
  38. Pc_ChannelsActive = 1, /* unable to configure while channels active */
  39. Pc_TooManySlots1 = 2, /* too many slots selected for port 1 */
  40. Pc_InvalidBlockCombo1 = 3, /* invalid combination of blocks for port 1 */
  41. Pc_NoSlots1 = 4, /* no slots selected for port 1 */
  42. Pc_InvalidSlots1 = 5, /* invalid slot (> max) selected for port 1 */
  43. Pc_TooManySlots2 = 6, /* too many slots selected for port 2 */
  44. Pc_InvalidBlockCombo2 = 7, /* invalid combination of blocks for port 2 */
  45. Pc_NoSlots2 = 8, /* no slots selected for port 2 */
  46. Pc_InvalidSlots2 = 9, /* invalid slot (> max) selected for port 2 */
  47. Pc_TooManySlots3 = 10, /* too many slots selected for port 3 */
  48. Pc_InvalidBlockCombo3 = 11, /* invalid combination of blocks for port 3 */
  49. Pc_NoSlots3 = 12, /* no slots selected for port 3 */
  50. Pc_InvalidSlots3 = 13 /* invalid slot (> max) selected for port 3 */
  51. } GPAK_PortConfigStat_t;
  52. /* Configure Channel reply status codes. */
  53. typedef enum
  54. {
  55. Cc_Success = 0, /* channel configured successfully */
  56. Cc_InvalidChannelType = 1, /* invalid Channel Type */
  57. Cc_InvalidChannel = 2, /* invalid Channel A Id */
  58. Cc_ChannelActiveA = 3, /* Channel A is currently active */
  59. Cc_InvalidInputPortA = 4, /* invalid Input A Port */
  60. Cc_InvalidInputSlotA = 5, /* invalid Input A Slot */
  61. Cc_BusyInputSlotA = 6, /* busy Input A Slot */
  62. Cc_InvalidOutputPortA = 7, /* invalid Output A Port */
  63. Cc_InvalidOutputSlotA = 8, /* invalid Output A Slot */
  64. Cc_BusyOutputSlotA = 9, /* busy Output A Slot */
  65. Cc_InvalidInputPortB = 10, /* invalid Input B Port */
  66. Cc_InvalidInputSlotB = 11, /* invalid Input B Slot */
  67. Cc_BusyInputSlotB = 12, /* busy Input B Slot */
  68. Cc_InvalidPktInCodingA = 13, /* invalid Packet In A Coding */
  69. Cc_InvalidPktOutCodingA = 14, /* invalid Packet Out A Coding */
  70. Cc_InvalidPktInSizeA = 15, /* invalid Packet In A Frame Size */
  71. Cc_InvalidPktOutSizeA = 16, /* invalid Packet Out A Frame Size */
  72. Cc_ChanTypeNotConfigured = 21, /* channel type was not configured */
  73. Cc_InsuffECResources = 22, /* insufficient ecan resources avail. */
  74. Cc_InsuffTDMResources = 23, /* insufficient tdm block resources avail. */
  75. Cc_InsuffPktBufResources = 25, /* insufficient pkt buffer resources avail. */
  76. Cc_InsuffPcmBufResources = 26, /* insufficient pcm buffer resources avail. */
  77. Cc_BadPcmEcNlpType = 30, /* invalid EC Nlp type */
  78. Cc_BadPcmEcTapLength = 31, /* invalid EC tap length */
  79. Cc_BadPcmEcDblTalkThresh = 32, /* invalid EC double-talk threshold */
  80. Cc_BadPcmEcNlpThreshold = 33, /* invalid EC Nlp threshold */
  81. Cc_BadPcmEcCngThreshold = 34, /* invalid EC Cng threshold */
  82. Cc_BadPcmEcAdaptLimit = 35, /* invalid EC Adapt Limit */
  83. Cc_BadPcmEcCrossCorrLim = 36, /* invalid EC Cross Correlation Limit */
  84. Cc_BadPcmEcNumFirSegs = 37, /* invalid EC Number of FirSegments */
  85. Cc_BadPcmEcFirSegLen = 38, /* invalid EC Fir Segment Length */
  86. /*Cc_InvalidNumEcsEnabled = 48, */ /* more than 1 Ec enabled on channel */
  87. Cc_InvalidFrameRate = 49, /* invalid gpak frame rate */
  88. Cc_InvalidSoftCompand = 50, /* invalid softCompanding type */
  89. Cc_InvalidMuteToneA = 51, /* invalid MuteToneA set, no detector */
  90. Cc_InvalidMuteToneB = 52, /* invalid MuteToneB set, no detector */
  91. Cc_InsuffFaxCngDetResources = 53, /* insufficient tdm block resources avail. */
  92. Cc_PortDmaNotStarted = 54, /* SerialPort not ready */
  93. Cc_ChannelDebugActive = 55, /* Debug Channel is not active */
  94. Cc_ChannelDebugEnabled = 56 /* Channel already been debugged */
  95. } GPAK_ChannelConfigStat_t;
  96. /* Tear Down Channel reply status codes. */
  97. typedef enum
  98. {
  99. Td_Success = 0, /* channel torn down successfully */
  100. Td_InvalidChannel = 1, /* invalid Channel Id */
  101. Td_ChannelNotActive = 2 /* channel is not active */
  102. } GPAK_TearDownChanStat_t;
  103. typedef enum
  104. {
  105. Ac_Success = 0, /* algorithm control is successfull */
  106. Ac_InvalidChannel = 1, /* invalid channel identifier */
  107. Ac_InvalidCode = 2, /* invalid algorithm control code */
  108. Ac_ECNotEnabled = 3, /* echo canceller was not allocated */
  109. Ac_InvalidSoftComp = 4, /* invalid softcompanding, 'cause serial port not in companding mode */
  110. Ac_InvalidDTMFMuteA = 5, /* A side invalid Mute, since no dtmf detector */
  111. Ac_InvalidDTMFMuteB = 6, /* B side invalid Mute, since no dtmf detector */
  112. Ac_InvalidFaxCngA = 7, /* A side FAXCNG detector not available */
  113. Ac_InvalidFaxCngB = 8, /* B side FAXCNG detector not available */
  114. Ac_InvalidSysConfig = 9 /* No new system parameters (DTMF config) wrriten yet */
  115. } GPAK_AlgControlStat_t;
  116. /* Write System Parameters reply status codes. */
  117. typedef enum
  118. {
  119. Sp_Success = 0, /* System Parameters written successfully */
  120. Sp_BadTwistThresh = 29 /* invalid twist threshold */
  121. } GPAK_SysParmsStat_t;
  122. #endif /* prevent multiple inclusion */