Echolink Info message in event sources

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

Echolink Info message in event sources

sp2ong
Is it possible get last INFO message from connected node to svxlink
via event sources ??? I have see in log svxlink that
Echolink Info message have nice information

Fri May  5 14:03:18 2017: --- EchoLink info message received from SR1G-R ---
Fri May  5 14:03:18 2017: SvxLink 1.5.0 - SR1G-R (5)
Fri May  5 14:03:18 2017:
Fri May  5 14:03:18 2017: SR1G-R         Przemiennik kolobrzeski
Fri May  5 14:03:18 2017: LB0OG-L         Aalesund link
Fri May  5 14:03:18 2017: SQ2YC-L         144.975 Mhz, Torun
Fri May  5 14:03:18 2017: SP1KJK         PASJONACI RADIA
Fri May  5 14:03:18 2017: SP1NKF         Jacek
Fri May  5 14:03:18 2017: 3Z6AET         www.dasr.pl

I would like put this on my Web Status Svxlink where via event sources I have
information about connected to our local node stations but it will be
nice have to
information about which nodes connected to other node via EchoLink Info message

like:
 --- EchoLink info message received from SR1G-R ---
 SvxLink 1.5.0 - SR1G-R (5)
 SR1G-R         Przemiennik kolobrzeski
 LB0OG-L         Aalesund link
 SQ2YC-L         144.975 Mhz, Torun
 SP1KJK         PASJONACI RADIA
 SP1NKF         Jacek
 3Z6AET         www.dasr.pl


But I am not sure that is possible get via event sources without modify
Qsoimp.cpp or I can add publishStateEvent in Echolink tcl ???

73 Waldek SP2ONG

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

Rob Janssen
[hidden email] wrote:
> Is it possible get last INFO message from connected node to svxlink
> via event sources ??? I have see in log svxlink that
> Echolink Info message have nice information
>

Not yet.  And this is a bit difficult to program because the eventsource mechanism
is line-oriented and has fixed separator characters.  So sending random text over this
mechanism can only be done when it is suitably escaped (like URLescape for example).

Rob

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

IZ2PRA Nic
Also I would show on my web the link's name.
I think to create script in bash

Step 1  -->tail -f /var/log/svxlink
Step 2 ---> by grep cut the first sting until :

This could it be a solution?

Nic IZ2PRA


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

sp2ong
Hi Nic,

At current I have nice status echolink node use Rob scripts from sources

https://github.com/sm0svx/svxlink/tree/master/src/svxlink/scripts/eventsource

but I would like add more information  about connected stations  to
connected nodes to my node.

You can see on my or others status:

http://sq2yc.ddns.net/index.php?id=status
http://do7sk.ddns.net/signal.php
http://pe1chl.nl.eu.org/repeaters/

73 Waldek

2017-05-05 17:30 GMT+02:00 IZ2PRA Nic <[hidden email]>:

> Also I would show on my web the link's name.
> I think to create script in bash
>
> Step 1  -->tail -f /var/log/svxlink
> Step 2 ---> by grep cut the first sting until :
>
> This could it be a solution?
>
> Nic IZ2PRA
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Svxlink-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

sp2ong
In reply to this post by IZ2PRA Nic
Hi Nic,

I thing that via bash script it is not possible because numbers of
rows --- EchoLink info message received from .... are not constants
and don't
exist any end marker of info messages in log of svxlink

73 Waldek SP2ONG

2017-05-05 17:30 GMT+02:00 IZ2PRA Nic <[hidden email]>:

> Also I would show on my web the link's name.
> I think to create script in bash
>
> Step 1  -->tail -f /var/log/svxlink
> Step 2 ---> by grep cut the first sting until :
>
> This could it be a solution?
>
> Nic IZ2PRA
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Svxlink-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

Tobias Blomberg
In reply to this post by sp2ong
Hi Waldek,

I have now added a new TCL event handing function in EchoLink.tcl,
info_received, that can be used to get the info message out of SvxLink.
Writing the info to a file and polling that file from the web UI would
be one way to do it.

Getting the info via event source is probably not possible due to its
simple format, as also Rob wrote.

Some day there will be a better way to get information out from SvxLink
since it's a very popular request to get information out to publish on a
web page.

73's de SM0SVX / Tobias


On 2017-05-05 14:54, [hidden email] wrote:

> Is it possible get last INFO message from connected node to svxlink
> via event sources ??? I have see in log svxlink that
> Echolink Info message have nice information
>
> Fri May  5 14:03:18 2017: --- EchoLink info message received from SR1G-R ---
> Fri May  5 14:03:18 2017: SvxLink 1.5.0 - SR1G-R (5)
> Fri May  5 14:03:18 2017:
> Fri May  5 14:03:18 2017: SR1G-R         Przemiennik kolobrzeski
> Fri May  5 14:03:18 2017: LB0OG-L         Aalesund link
> Fri May  5 14:03:18 2017: SQ2YC-L         144.975 Mhz, Torun
> Fri May  5 14:03:18 2017: SP1KJK         PASJONACI RADIA
> Fri May  5 14:03:18 2017: SP1NKF         Jacek
> Fri May  5 14:03:18 2017: 3Z6AET         www.dasr.pl
>
> I would like put this on my Web Status Svxlink where via event sources I have
> information about connected to our local node stations but it will be
> nice have to
> information about which nodes connected to other node via EchoLink Info message
>
> like:
>   --- EchoLink info message received from SR1G-R ---
>   SvxLink 1.5.0 - SR1G-R (5)
>   SR1G-R         Przemiennik kolobrzeski
>   LB0OG-L         Aalesund link
>   SQ2YC-L         144.975 Mhz, Torun
>   SP1KJK         PASJONACI RADIA
>   SP1NKF         Jacek
>   3Z6AET         www.dasr.pl
>
>
> But I am not sure that is possible get via event sources without modify
> Qsoimp.cpp or I can add publishStateEvent in Echolink tcl ???
>
> 73 Waldek SP2ONG
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Svxlink-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/svxlink-devel



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

Rob Janssen
Tobias Blomberg wrote:
> Getting the info via event source is probably not possible due to its
> simple format, as also Rob wrote.
>

Maybe a way would be to make a URL-encode function in TCL and use that to encode the message
to a string that does not include spaces and special characters. Then, it can be safely sent over
the event publish interface and the receiver of the event can decode it again using an URL-decode
function in the language used on that side (e.g. Javascript).

I found this TCL URL-encode function on the net:

proc <http://wiki.tcl.tk/proc>  init{}  {
     variable <http://wiki.tcl.tk/variable>  map
     variable <http://wiki.tcl.tk/variable>  alphanumeric a-zA-Z0-9
     for <http://wiki.tcl.tk/for>  {set <http://wiki.tcl.tk/set>  i0}  {$i  <=  256}  {incr <http://wiki.tcl.tk/incr>  i}  {  
         set <http://wiki.tcl.tk/set>  c[format <http://wiki.tcl.tk/format>  %c$i]
         if <http://wiki.tcl.tk/if>  {![string <http://wiki.tcl.tk/string>  match\[$alphanumeric\]  $c]}  {
             set <http://wiki.tcl.tk/set>  map($c)  %[format <http://wiki.tcl.tk/format>  %.2x$i]
         }
     }
# These are handled specially
     arrayset <http://wiki.tcl.tk/set>  map{  " "  +  \n%0d%0a}
}
init

proc <http://wiki.tcl.tk/proc>  url-encode{string <http://wiki.tcl.tk/string>}  {
     variable <http://wiki.tcl.tk/variable>  map
     variable <http://wiki.tcl.tk/variable>  alphanumeric

# The spec says: "non-alphanumeric characters are replaced by '%HH'"
# 1 leave alphanumerics characters alone
# 2 Convert every other character to an array lookup
# 3 Escape constructs that are "special" to the tcl parser
# 4 "subst" the result, doing all the array substitutions

     regsub <http://wiki.tcl.tk/regsub>  -all\[^$alphanumeric\]  $string  {$map(&)}  string <http://wiki.tcl.tk/string>
# This quotes cases like $map([) or $map($) => $map(\[) ...
     regsub <http://wiki.tcl.tk/regsub>  -all{[][{})\\]\)}  $string  {\\&}  string <http://wiki.tcl.tk/string>
     return <http://wiki.tcl.tk/return>  [subst <http://wiki.tcl.tk/subst>  -nocommand$string]
} I don't know if such a thing is also included with TCL in some library package. Rob



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

Rob Janssen
Rob Janssen wrote:
> I found this TCL URL-encode function on the net:
>
>

Sorry, my attempt to paste it resulted in garbage, ignore it and google it yourself.

Rob

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

Tobias Blomberg
:-D

Or maybe base64 encode the info message before using the event source
mechanism. This is a function I found here: http://wiki.tcl.tk/775

proc b64en str {
     binary scan $str B* bits
     switch [expr {[string length $bits]%6}] {
         0 {set tail {}}
         2 {append bits 0000; set tail ==}
         4 {append bits 00; set tail =}
     }
     return [string map {
         000000 A 000001 B 000010 C 000011 D 000100 E 000101 F
         000110 G 000111 H 001000 I 001001 J 001010 K 001011 L
         001100 M 001101 N 001110 O 001111 P 010000 Q 010001 R
         010010 S 010011 T 010100 U 010101 V 010110 W 010111 X
         011000 Y 011001 Z 011010 a 011011 b 011100 c 011101 d
         011110 e 011111 f 100000 g 100001 h 100010 i 100011 j
         100100 k 100101 l 100110 m 100111 n 101000 o 101001 p
         101010 q 101011 r 101100 s 101101 t 101110 u 101111 v
         110000 w 110001 x 110010 y 110011 z 110100 0 110101 1
         110110 2 110111 3 111000 4 111001 5 111010 6 111011 7
         111100 8 111101 9 111110 + 111111 /
     } $bits]$tail
}

Don't know if it's complete but it seems to work. Just a random function
I found. I guess the URL encode format would be more compact though and
more readable. The base64 variant may be better if one would want to
send binary data.

73's de SM0SVX / Tobias


On 2017-05-13 16:38, Rob Janssen wrote:

> Rob Janssen wrote:
>> I found this TCL URL-encode function on the net:
>>
>>
> Sorry, my attempt to paste it resulted in garbage, ignore it and google it yourself.
>
> Rob
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Svxlink-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/svxlink-devel



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

sp2ong
In reply to this post by Tobias Blomberg
Hi Tobias,

Thank you for info_recived from Echolink module and it will be nice to
have access to Node List form SVXReflector client similar like
clients list from EcholInk module

This all information available  we can put public on Web or use to
Admin Web UI with restriction access and we can monitoring svxlink
maybe in future allow reload / or stop/start svxlink from web UI.


73 Waldek sp2ong

2017-05-13 16:06 GMT+02:00 Tobias Blomberg <[hidden email]>:

> Hi Waldek,
>
> I have now added a new TCL event handing function in EchoLink.tcl,
> info_received, that can be used to get the info message out of SvxLink.
> Writing the info to a file and polling that file from the web UI would
> be one way to do it.
>
> Getting the info via event source is probably not possible due to its
> simple format, as also Rob wrote.
>
> Some day there will be a better way to get information out from SvxLink
> since it's a very popular request to get information out to publish on a
> web page.
>
> 73's de SM0SVX / Tobias
>
>
> On 2017-05-05 14:54, [hidden email] wrote:
>> Is it possible get last INFO message from connected node to svxlink
>> via event sources ??? I have see in log svxlink that
>> Echolink Info message have nice information
>>
>> Fri May  5 14:03:18 2017: --- EchoLink info message received from SR1G-R ---
>> Fri May  5 14:03:18 2017: SvxLink 1.5.0 - SR1G-R (5)
>> Fri May  5 14:03:18 2017:
>> Fri May  5 14:03:18 2017: SR1G-R         Przemiennik kolobrzeski
>> Fri May  5 14:03:18 2017: LB0OG-L         Aalesund link
>> Fri May  5 14:03:18 2017: SQ2YC-L         144.975 Mhz, Torun
>> Fri May  5 14:03:18 2017: SP1KJK         PASJONACI RADIA
>> Fri May  5 14:03:18 2017: SP1NKF         Jacek
>> Fri May  5 14:03:18 2017: 3Z6AET         www.dasr.pl
>>
>> I would like put this on my Web Status Svxlink where via event sources I have
>> information about connected to our local node stations but it will be
>> nice have to
>> information about which nodes connected to other node via EchoLink Info message
>>
>> like:
>>   --- EchoLink info message received from SR1G-R ---
>>   SvxLink 1.5.0 - SR1G-R (5)
>>   SR1G-R         Przemiennik kolobrzeski
>>   LB0OG-L         Aalesund link
>>   SQ2YC-L         144.975 Mhz, Torun
>>   SP1KJK         PASJONACI RADIA
>>   SP1NKF         Jacek
>>   3Z6AET         www.dasr.pl
>>
>>
>> But I am not sure that is possible get via event sources without modify
>> Qsoimp.cpp or I can add publishStateEvent in Echolink tcl ???
>>
>> 73 Waldek SP2ONG
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> Svxlink-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Svxlink-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

sp2ong
In reply to this post by Tobias Blomberg
Hi Tobias,

I have updated svxlink with git and modify in EchoLink.tcl module

proc info_received {call msg} {
set outputFile [open /tmp/info_msg.txt w];
puts $outputFile "$call: $msg";
close $outputFile;
}

and I have info message in file

Thnaks

73 Waldek

2017-05-13 16:06 GMT+02:00 Tobias Blomberg <[hidden email]>:

> Hi Waldek,
>
> I have now added a new TCL event handing function in EchoLink.tcl,
> info_received, that can be used to get the info message out of SvxLink.
> Writing the info to a file and polling that file from the web UI would
> be one way to do it.
>
> Getting the info via event source is probably not possible due to its
> simple format, as also Rob wrote.
>
> Some day there will be a better way to get information out from SvxLink
> since it's a very popular request to get information out to publish on a
> web page.
>
> 73's de SM0SVX / Tobias
>
>
> On 2017-05-05 14:54, [hidden email] wrote:
>> Is it possible get last INFO message from connected node to svxlink
>> via event sources ??? I have see in log svxlink that
>> Echolink Info message have nice information
>>
>> Fri May  5 14:03:18 2017: --- EchoLink info message received from SR1G-R ---
>> Fri May  5 14:03:18 2017: SvxLink 1.5.0 - SR1G-R (5)
>> Fri May  5 14:03:18 2017:
>> Fri May  5 14:03:18 2017: SR1G-R         Przemiennik kolobrzeski
>> Fri May  5 14:03:18 2017: LB0OG-L         Aalesund link
>> Fri May  5 14:03:18 2017: SQ2YC-L         144.975 Mhz, Torun
>> Fri May  5 14:03:18 2017: SP1KJK         PASJONACI RADIA
>> Fri May  5 14:03:18 2017: SP1NKF         Jacek
>> Fri May  5 14:03:18 2017: 3Z6AET         www.dasr.pl
>>
>> I would like put this on my Web Status Svxlink where via event sources I have
>> information about connected to our local node stations but it will be
>> nice have to
>> information about which nodes connected to other node via EchoLink Info message
>>
>> like:
>>   --- EchoLink info message received from SR1G-R ---
>>   SvxLink 1.5.0 - SR1G-R (5)
>>   SR1G-R         Przemiennik kolobrzeski
>>   LB0OG-L         Aalesund link
>>   SQ2YC-L         144.975 Mhz, Torun
>>   SP1KJK         PASJONACI RADIA
>>   SP1NKF         Jacek
>>   3Z6AET         www.dasr.pl
>>
>>
>> But I am not sure that is possible get via event sources without modify
>> Qsoimp.cpp or I can add publishStateEvent in Echolink tcl ???
>>
>> 73 Waldek SP2ONG
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> Svxlink-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Svxlink-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

Tobias Blomberg
Great that it's working!

Just a note on the implementation, to be fully correct, you should write
the information to a temporary file and move it to the target file. That
is to avoid a race condition where the web UI read the file while
SvxLink is writing it. The reader may then get a half written file. A
move is atomic, an undividable opeation, so the reader can never get a
half written file. It will either get the old or the new file.

73's de SM0SVX / Tobias


On 2017-05-13 18:45, [hidden email] wrote:

> Hi Tobias,
>
> I have updated svxlink with git and modify in EchoLink.tcl module
>
> proc info_received {call msg} {
> set outputFile [open /tmp/info_msg.txt w];
> puts $outputFile "$call: $msg";
> close $outputFile;
> }
>
> and I have info message in file
>
> Thnaks
>
> 73 Waldek
>
> 2017-05-13 16:06 GMT+02:00 Tobias Blomberg <[hidden email]>:
>> Hi Waldek,
>>
>> I have now added a new TCL event handing function in EchoLink.tcl,
>> info_received, that can be used to get the info message out of SvxLink.
>> Writing the info to a file and polling that file from the web UI would
>> be one way to do it.
>>
>> Getting the info via event source is probably not possible due to its
>> simple format, as also Rob wrote.
>>
>> Some day there will be a better way to get information out from SvxLink
>> since it's a very popular request to get information out to publish on a
>> web page.
>>
>> 73's de SM0SVX / Tobias
>>
>>
>> On 2017-05-05 14:54, [hidden email] wrote:
>>> Is it possible get last INFO message from connected node to svxlink
>>> via event sources ??? I have see in log svxlink that
>>> Echolink Info message have nice information
>>>
>>> Fri May  5 14:03:18 2017: --- EchoLink info message received from SR1G-R ---
>>> Fri May  5 14:03:18 2017: SvxLink 1.5.0 - SR1G-R (5)
>>> Fri May  5 14:03:18 2017:
>>> Fri May  5 14:03:18 2017: SR1G-R         Przemiennik kolobrzeski
>>> Fri May  5 14:03:18 2017: LB0OG-L         Aalesund link
>>> Fri May  5 14:03:18 2017: SQ2YC-L         144.975 Mhz, Torun
>>> Fri May  5 14:03:18 2017: SP1KJK         PASJONACI RADIA
>>> Fri May  5 14:03:18 2017: SP1NKF         Jacek
>>> Fri May  5 14:03:18 2017: 3Z6AET         www.dasr.pl
>>>
>>> I would like put this on my Web Status Svxlink where via event sources I have
>>> information about connected to our local node stations but it will be
>>> nice have to
>>> information about which nodes connected to other node via EchoLink Info message
>>>
>>> like:
>>>    --- EchoLink info message received from SR1G-R ---
>>>    SvxLink 1.5.0 - SR1G-R (5)
>>>    SR1G-R         Przemiennik kolobrzeski
>>>    LB0OG-L         Aalesund link
>>>    SQ2YC-L         144.975 Mhz, Torun
>>>    SP1KJK         PASJONACI RADIA
>>>    SP1NKF         Jacek
>>>    3Z6AET         www.dasr.pl
>>>
>>>
>>> But I am not sure that is possible get via event sources without modify
>>> Qsoimp.cpp or I can add publishStateEvent in Echolink tcl ???
>>>
>>> 73 Waldek SP2ONG
>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> _______________________________________________
>>> Svxlink-devel mailing list
>>> [hidden email]
>>> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>>
>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> Svxlink-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Svxlink-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/svxlink-devel



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel
Reply | Threaded
Open this post in threaded view
|

Re: Echolink Info message in event sources

sp2ong
Hi Tobias,

Ok now I have add to status page  lastest received info message from
connected stations:

 http://sq2yc.ddns.net/index.php?id=status

I have add in procedure current time

73 Waldek

2017-05-13 19:45 GMT+02:00 Tobias Blomberg <[hidden email]>:

> Great that it's working!
>
> Just a note on the implementation, to be fully correct, you should write
> the information to a temporary file and move it to the target file. That
> is to avoid a race condition where the web UI read the file while
> SvxLink is writing it. The reader may then get a half written file. A
> move is atomic, an undividable opeation, so the reader can never get a
> half written file. It will either get the old or the new file.
>
> 73's de SM0SVX / Tobias
>
>
> On 2017-05-13 18:45, [hidden email] wrote:
>> Hi Tobias,
>>
>> I have updated svxlink with git and modify in EchoLink.tcl module
>>
>> proc info_received {call msg} {
>> set outputFile [open /tmp/info_msg.txt w];
>> puts $outputFile "$call: $msg";
>> close $outputFile;
>> }
>>
>> and I have info message in file
>>
>> Thnaks
>>
>> 73 Waldek
>>
>> 2017-05-13 16:06 GMT+02:00 Tobias Blomberg <[hidden email]>:
>>> Hi Waldek,
>>>
>>> I have now added a new TCL event handing function in EchoLink.tcl,
>>> info_received, that can be used to get the info message out of SvxLink.
>>> Writing the info to a file and polling that file from the web UI would
>>> be one way to do it.
>>>
>>> Getting the info via event source is probably not possible due to its
>>> simple format, as also Rob wrote.
>>>
>>> Some day there will be a better way to get information out from SvxLink
>>> since it's a very popular request to get information out to publish on a
>>> web page.
>>>
>>> 73's de SM0SVX / Tobias
>>>
>>>
>>> On 2017-05-05 14:54, [hidden email] wrote:
>>>> Is it possible get last INFO message from connected node to svxlink
>>>> via event sources ??? I have see in log svxlink that
>>>> Echolink Info message have nice information
>>>>
>>>> Fri May  5 14:03:18 2017: --- EchoLink info message received from SR1G-R ---
>>>> Fri May  5 14:03:18 2017: SvxLink 1.5.0 - SR1G-R (5)
>>>> Fri May  5 14:03:18 2017:
>>>> Fri May  5 14:03:18 2017: SR1G-R         Przemiennik kolobrzeski
>>>> Fri May  5 14:03:18 2017: LB0OG-L         Aalesund link
>>>> Fri May  5 14:03:18 2017: SQ2YC-L         144.975 Mhz, Torun
>>>> Fri May  5 14:03:18 2017: SP1KJK         PASJONACI RADIA
>>>> Fri May  5 14:03:18 2017: SP1NKF         Jacek
>>>> Fri May  5 14:03:18 2017: 3Z6AET         www.dasr.pl
>>>>
>>>> I would like put this on my Web Status Svxlink where via event sources I have
>>>> information about connected to our local node stations but it will be
>>>> nice have to
>>>> information about which nodes connected to other node via EchoLink Info message
>>>>
>>>> like:
>>>>    --- EchoLink info message received from SR1G-R ---
>>>>    SvxLink 1.5.0 - SR1G-R (5)
>>>>    SR1G-R         Przemiennik kolobrzeski
>>>>    LB0OG-L         Aalesund link
>>>>    SQ2YC-L         144.975 Mhz, Torun
>>>>    SP1KJK         PASJONACI RADIA
>>>>    SP1NKF         Jacek
>>>>    3Z6AET         www.dasr.pl
>>>>
>>>>
>>>> But I am not sure that is possible get via event sources without modify
>>>> Qsoimp.cpp or I can add publishStateEvent in Echolink tcl ???
>>>>
>>>> 73 Waldek SP2ONG
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Check out the vibrant tech community on one of the world's most
>>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>>> _______________________________________________
>>>> Svxlink-devel mailing list
>>>> [hidden email]
>>>> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> _______________________________________________
>>> Svxlink-devel mailing list
>>> [hidden email]
>>> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>>>
>> ------------------------------------------------------------------------------
>> Check out the vibrant tech community on one of the world's most
>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>> _______________________________________________
>> Svxlink-devel mailing list
>> [hidden email]
>> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> Svxlink-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/svxlink-devel
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Svxlink-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/svxlink-devel