[YMCS/YDMP Free Trial Program]Yealink would like to offer Free Trial Program of Yealink device management service for our current eligible customers. You can see the details below.
https://www.yealink.com/ydmp-freetrial-2020


Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Status Text on display (only few chars)
Author Message
GeorgSchwarz Offline
Junior Member
**

Posts: 28
Joined: May 2013
Reputation: 0
Post: #3
RE: Status Text on display (only few chars)
Hi!

having progressed, I'd like to share my Results with you...
Here a short perl-demonstration-script that sends a message to a phone...

@Forum-Admins: I hope you regard this as appropriate...
#!/usr/bin/perl
use IO::Socket;
use strict;

my %config = qw(NOTIFY_LOCAL_IP 172.27.255.254 NOTIFY_SOURCE_USER msgdispatch SOURCE_PORT 8888);

sipSendNotify('4711','10.27.0.12',"Redir on (102)",45);


sub sipSendNotify
# 0: Phone-User
# 1: Phone-IP
# 2: Message
# 3: Timeout
{
my $phoneIP = $_[1];
my $phoneUser = $_[0];
my $msg = $_[2];
my $timeout = $_[3];

my $payload="<YealinkIPPhoneStatus Beep=\"yes\" wrapList=\"no\" Timeout=\"$timeout\">
<Session>0</Session>
<Message Size=\"large\" Align=\"center\" Icon=\"Forward\">$msg</Message>
</YealinkIPPhoneStatus>
";

my $MESG="NOTIFY sip:$phoneUser\@$phoneIP:5062 SIP/2.0
Via: SIP/2.0/UDP $config{NOTIFY_LOCAL_IP}
From: <sip:$config{NOTIFY_SOURCE_USER}\@$config{NOTIFY_LOCAL_IP}>
To: <sip:$phoneUser\@$phoneIP>
Date: ".localtime(time())."
Call-ID: ".time()."msgto$phoneUser\@$config{NOTIFY_LOCAL_IP}
CSeq: 1300 NOTIFY
Contact: <sip:$config{NOTIFY_SOURCE_USER}\@$config{NOTIFY_LOCAL_IP}>
Event: yealink-xml
Content-Type: application/xml
Content-Length:".length($payload)."

$payload";



my $sock = new IO::Socket::INET (
LocalPort => $config{SOURCE_PORT},
PeerAddr => $phoneIP,
PeerPort => '5062',
Proto => 'udp',
);
die "Could not create socket: $!\n" unless $sock;

print $sock $MESG;



}
(This post was last modified: 12-12-2013 08:45 PM by GeorgSchwarz.)
12-12-2013 08:00 PM
Find all posts by this user    like0    dislike0 Quote this message in a reply
Post Reply 


Messages In This Thread
RE: Status Text on display (only few chars) - GeorgSchwarz - 12-12-2013 08:00 PM

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Option of having DSS or DIalpad display on touchscreen after pressing DSS Prefix brourk 0 1,564 09-06-2022 10:04 PM
Last Post: brourk
  Availability status on phone screen Frank Drews 2 11,832 03-02-2018 02:47 PM
Last Post: syadnom
  Date/Time display in STATUS tab njackson 3 12,211 01-22-2018 08:04 PM
Last Post: KNERD
  Display custom text in-call Luke Escude 1 7,813 11-30-2017 08:44 AM
Last Post: Elaine_Yealink
  "On the Phone" or "User Busy" status display into caller phone LCD ugo.viti 12 52,923 09-29-2016 09:43 PM
Last Post: jolouis
  Call Information Display Method brourk 1 8,127 01-27-2016 03:17 AM
Last Post: Klaus_Yealink
  Agent queue status on DSS key johandezwaan 10 42,197 09-19-2015 12:26 AM
Last Post: topnotch
  Ability to alter call display format TM2-Megatron 0 6,640 08-15-2015 10:10 PM
Last Post: TM2-Megatron
Star T48G - Status Icon on DSS URL Button cotwild 1 10,156 12-12-2014 04:48 PM
Last Post: James_Yealink
  T48 Wallpaper (White Text or Black Text) elementpbx 1 8,289 12-01-2014 04:05 PM
Last Post: tb303

Forum Jump:


User(s) browsing this thread: 1 Guest(s)

Contact Us   Yealink   Return to Top   Return to Content   Lite (Archive) Mode   RSS Syndication