mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-08-13 17:38:59 +00:00
update
git-svn-id: http://svn.openzap.org/svn/openzap/trunk@186 a93c3328-9c30-0410-af19-c9cd2b2d52af
This commit is contained in:
@@ -317,14 +317,13 @@ struct zap_io_interface {
|
||||
zio_configure_t configure;
|
||||
zio_open_t open;
|
||||
zio_close_t close;
|
||||
zio_destroy_channel_t destroy_channel;
|
||||
zio_command_t command;
|
||||
zio_wait_t wait;
|
||||
zio_read_t read;
|
||||
zio_write_t write;
|
||||
zio_span_poll_event_t poll_event;
|
||||
zio_span_next_event_t next_event;
|
||||
uint32_t span_index;
|
||||
struct zap_span spans[ZAP_MAX_SPANS_INTERFACE];
|
||||
};
|
||||
|
||||
void zap_channel_rotate_tokens(zap_channel_t *zchan);
|
||||
@@ -337,15 +336,15 @@ zap_status_t zap_channel_queue_dtmf(zap_channel_t *zchan, const char *dtmf);
|
||||
zap_time_t zap_current_time_in_ms(void);
|
||||
zap_status_t zap_span_poll_event(zap_span_t *span, uint32_t ms);
|
||||
zap_status_t zap_span_next_event(zap_span_t *span, zap_event_t **event);
|
||||
zap_status_t zap_span_find(const char *name, uint32_t id, zap_span_t **span);
|
||||
zap_status_t zap_span_find(uint32_t id, zap_span_t **span);
|
||||
zap_status_t zap_span_create(zap_io_interface_t *zio, zap_span_t **span);
|
||||
zap_status_t zap_span_close_all(zap_io_interface_t *zio);
|
||||
zap_status_t zap_span_add_channel(zap_span_t *span, zap_socket_t sockfd, zap_chan_type_t type, zap_channel_t **chan);
|
||||
zap_status_t zap_span_set_event_callback(zap_span_t *span, zio_event_cb_t event_callback);
|
||||
zap_status_t zap_channel_set_event_callback(zap_channel_t *zchan, zio_event_cb_t event_callback);
|
||||
zap_status_t zap_channel_open(const char *name, uint32_t span_id, uint32_t chan_id, zap_channel_t **zchan);
|
||||
zap_status_t zap_channel_open(uint32_t span_id, uint32_t chan_id, zap_channel_t **zchan);
|
||||
zap_status_t zap_channel_open_chan(zap_channel_t *zchan);
|
||||
zap_status_t zap_channel_open_any(const char *name, uint32_t span_id, zap_direction_t direction, zap_channel_t **zchan);
|
||||
zap_status_t zap_channel_open_any(uint32_t span_id, zap_direction_t direction, zap_channel_t **zchan);
|
||||
zap_status_t zap_channel_close(zap_channel_t **zchan);
|
||||
zap_status_t zap_channel_command(zap_channel_t *zchan, zap_command_t command, void *obj);
|
||||
zap_status_t zap_channel_wait(zap_channel_t *zchan, zap_wait_flag_t *flags, int32_t to);
|
||||
|
@@ -102,8 +102,6 @@ typedef enum {
|
||||
ZAP_SIGEVENT_TRANSFER,
|
||||
ZAP_SIGEVENT_ANSWER,
|
||||
ZAP_SIGEVENT_UP,
|
||||
ZAP_SIGEVENT_HOLD,
|
||||
ZAP_SIGEVENT_UNHOLD,
|
||||
ZAP_SIGEVENT_FLASH,
|
||||
ZAP_SIGEVENT_PROGRESS,
|
||||
ZAP_SIGEVENT_PROGRESS_MEDIA,
|
||||
@@ -111,7 +109,7 @@ typedef enum {
|
||||
ZAP_SIGEVENT_MISC,
|
||||
ZAP_SIGEVENT_INVALID
|
||||
} zap_signal_event_t;
|
||||
#define SIGNAL_STRINGS "START", "STOP", "TRANSFER", "ANSWER", "UP", "HOLD", "UNHOLD", "FLASH", "PROGRESS", "PROGRESS_MEDIA", "NOTIFY", "MISC", "INVALID"
|
||||
#define SIGNAL_STRINGS "START", "STOP", "TRANSFER", "ANSWER", "UP", "FLASH", "PROGRESS", "PROGRESS_MEDIA", "NOTIFY", "MISC", "INVALID"
|
||||
ZAP_STR2ENUM_P(zap_str2zap_signal_event, zap_signal_event2str, zap_signal_event_t)
|
||||
|
||||
typedef enum {
|
||||
@@ -222,7 +220,8 @@ typedef enum {
|
||||
ZAP_CHANNEL_WINK = (1 << 9),
|
||||
ZAP_CHANNEL_FLASH = (1 << 10),
|
||||
ZAP_CHANNEL_STATE_CHANGE = (1 << 11),
|
||||
ZAP_CHANNEL_HOLD = (1 << 12)
|
||||
ZAP_CHANNEL_HOLD = (1 << 12),
|
||||
ZAP_CHANNEL_INUSE = (1 << 13)
|
||||
} zap_channel_flag_t;
|
||||
|
||||
|
||||
@@ -240,6 +239,7 @@ typedef struct zap_span zap_span_t;
|
||||
#define ZIO_CONFIGURE_ARGS (const char *category, const char *var, const char *val, int lineno)
|
||||
#define ZIO_OPEN_ARGS (zap_channel_t *zchan)
|
||||
#define ZIO_CLOSE_ARGS (zap_channel_t *zchan)
|
||||
#define ZIO_DESTROY_CHANNEL_ARGS (zap_channel_t *zchan)
|
||||
#define ZIO_COMMAND_ARGS (zap_channel_t *zchan, zap_command_t command, void *obj)
|
||||
#define ZIO_WAIT_ARGS (zap_channel_t *zchan, zap_wait_flag_t *flags, int32_t to)
|
||||
#define ZIO_READ_ARGS (zap_channel_t *zchan, void *data, zap_size_t *datalen)
|
||||
@@ -254,6 +254,7 @@ typedef zap_status_t (*zio_configure_span_t) ZIO_CONFIGURE_SPAN_ARGS ;
|
||||
typedef zap_status_t (*zio_configure_t) ZIO_CONFIGURE_ARGS ;
|
||||
typedef zap_status_t (*zio_open_t) ZIO_OPEN_ARGS ;
|
||||
typedef zap_status_t (*zio_close_t) ZIO_CLOSE_ARGS ;
|
||||
typedef zap_status_t (*zio_destroy_channel_t) ZIO_DESTROY_CHANNEL_ARGS ;
|
||||
typedef zap_status_t (*zio_command_t) ZIO_COMMAND_ARGS ;
|
||||
typedef zap_status_t (*zio_wait_t) ZIO_WAIT_ARGS ;
|
||||
typedef zap_status_t (*zio_read_t) ZIO_READ_ARGS ;
|
||||
@@ -268,6 +269,7 @@ typedef zap_status_t (*zio_write_t) ZIO_WRITE_ARGS ;
|
||||
#define ZIO_CONFIGURE_FUNCTION(name) zap_status_t name ZIO_CONFIGURE_ARGS
|
||||
#define ZIO_OPEN_FUNCTION(name) zap_status_t name ZIO_OPEN_ARGS
|
||||
#define ZIO_CLOSE_FUNCTION(name) zap_status_t name ZIO_CLOSE_ARGS
|
||||
#define ZIO_DESTROY_CHANNEL_FUNCTION(name) zap_status_t name ZIO_DESTROY_CHANNEL_ARGS
|
||||
#define ZIO_COMMAND_FUNCTION(name) zap_status_t name ZIO_COMMAND_ARGS
|
||||
#define ZIO_WAIT_FUNCTION(name) zap_status_t name ZIO_WAIT_ARGS
|
||||
#define ZIO_READ_FUNCTION(name) zap_status_t name ZIO_READ_ARGS
|
||||
|
@@ -89,25 +89,25 @@ struct zt_gains {
|
||||
|
||||
/* Used with ioctl: ZT_SPANSTAT */
|
||||
struct zt_spaninfo {
|
||||
int span_no; /* span number (-1 to use name) */
|
||||
char name[20]; /* Name of span */
|
||||
char description[40]; /* Description of span */
|
||||
int alarms; /* alarms status */
|
||||
int transmit_level; /* Transmit level */
|
||||
int receive_level; /* Receive level */
|
||||
int bpv_count; /* Current BPV count */
|
||||
int crc4_count; /* Current CRC4 error count */
|
||||
int ebit_count; /* Current E-bit error count */
|
||||
int fas_count; /* Current FAS error count */
|
||||
int irq_misses; /* Current IRQ misses */
|
||||
int sync_src; /* Span # of sync source (0 = free run) */
|
||||
int configured_chan_count; /* Count of channels configured on the span */
|
||||
int channel_count; /* Total count of channels on the span */
|
||||
int span_no; /* span number (-1 to use name) */
|
||||
char name[20]; /* Name of span */
|
||||
char description[40]; /* Description of span */
|
||||
int alarms; /* alarms status */
|
||||
int transmit_level; /* Transmit level */
|
||||
int receive_level; /* Receive level */
|
||||
int bpv_count; /* Current BPV count */
|
||||
int crc4_count; /* Current CRC4 error count */
|
||||
int ebit_count; /* Current E-bit error count */
|
||||
int fas_count; /* Current FAS error count */
|
||||
int irq_misses; /* Current IRQ misses */
|
||||
int sync_src; /* Span # of sync source (0 = free run) */
|
||||
int configured_chan_count; /* Count of channels configured on the span */
|
||||
int channel_count; /* Total count of channels on the span */
|
||||
int span_count; /* Total count of zaptel spans on the system*/
|
||||
};
|
||||
|
||||
struct zt_maintinfo {
|
||||
int span_no; /* span number */
|
||||
int span_no; /* span number */
|
||||
int command; /* Maintenance mode to set (from zt_maintenance_mode_t) */
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user