Tony,
Yep, that was a typo. Thanks for the
explanation. I’m working on an openzap API command. My thought process
is going something like this:
Create an openzap command, using the
One option is “openzap span x”
where x = the span number to view. (Think analogous to, but better than, *’s
“pri show span” command)
I take x, validate that it is an integer,
then plug it in to zap_span_find to see if I end up with a pointer to span x
If I get a pointer then I start dumping
span info, else print an error message…
Let me know if that seems like a
reasonable place to start. Ultimately I’m trying to help Jerris with the
ISDN stuff and it would be nice to have an API cmd that lets us view the state
machine info. When I know my ‘openzap span x’ command is working
then I’ll move on to the ISDN layer; I’ll also investigate dumping
information specific to analog spans and even the boost/SS7 spans if you think
that would be a useful utility.
Thanks,
MC
From:
freeswitch-dev-bounces@lists.freeswitch.org
[mailto:freeswitch-dev-bounces@lists.freeswitch.org] On Behalf Of Anthony Minessale
Sent: Friday, March 07, 2008 6:07
AM
To:
Subject: Re: [Freeswitch-dev] OZ
Question: zap_span_find()
correct,
Assuming the typo in the example was an accident.
(span not my_span_pointer declared on the first line)
zap_span_t
*my_span_pointer = NULL;
uint32_t
span_id = 1;
zap_status_t
result;
result
= zap_span_find(span_id, &my_span_pointer);
if it returns ZAP_SUCCESS, that indicates that the desired span exists, is in
use and that the pointer will now point to it.
Anthony Minessale II
FreeSWITCH http://www.freeswitch.org/
ClueCon http://www.cluecon.com/
AIM: anthm
MSN:anthony_minessale@hotmail.com
GTALK/JABBER/PAYPAL:anthony.minessale@gmail.com
IRC: irc.freenode.net #freeswitch
FreeSWITCH Developer Conference
sip:888@conference.freeswitch.org
iax:guest@conference.freeswitch.org/888
googletalk:conf+888@conference.freeswitch.org
pstn:213-799-1400
----- Original Message
----
From:
To:
Sent: Thursday, March 6, 2008 8:27:35 PM
Subject: [Freeswitch-dev] OZ Question: zap_span_find()
Does this function do what I think it does? If I give
it a span number to look for, it returns ZAP_SUCCESS if it finds the span and
it sets the value of the pointer variable that I call it with?
Example, what happens if I do this, assuming span 1 is a
real span?
zap_span_t *span = NULL;
uint32_t span_id = 1;
result = zap_span_find(span_id,
&my_span_pointer);
Does *my_span_pointer now point to span 1? Any caveats
that I should be aware of?
Thanks,
MC
-----Inline Attachment Follows-----
_______________________________________________
Freeswitch-dev mailing list
Freeswitch-dev@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-dev
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-dev
http://www.freeswitch.org
Looking for last minute shopping deals? Find
them fast with Yahoo! Search.