You can subscribe to this list here.
2004 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(4) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
(3) |
Jul
|
Aug
(7) |
Sep
|
Oct
(2) |
Nov
(1) |
Dec
(7) |
2006 |
Jan
(1) |
Feb
(2) |
Mar
(3) |
Apr
(3) |
May
(5) |
Jun
(1) |
Jul
|
Aug
(2) |
Sep
(4) |
Oct
(17) |
Nov
(18) |
Dec
(1) |
2007 |
Jan
|
Feb
|
Mar
(8) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
(6) |
Dec
(1) |
2008 |
Jan
(17) |
Feb
(20) |
Mar
(8) |
Apr
(8) |
May
(10) |
Jun
(4) |
Jul
(5) |
Aug
(6) |
Sep
(9) |
Oct
(19) |
Nov
(4) |
Dec
(35) |
2009 |
Jan
(40) |
Feb
(16) |
Mar
(7) |
Apr
(6) |
May
|
Jun
(5) |
Jul
(5) |
Aug
(4) |
Sep
(1) |
Oct
(2) |
Nov
(15) |
Dec
(15) |
2010 |
Jan
(5) |
Feb
(20) |
Mar
(12) |
Apr
|
May
(2) |
Jun
(4) |
Jul
|
Aug
(11) |
Sep
(1) |
Oct
(1) |
Nov
(3) |
Dec
|
2011 |
Jan
(8) |
Feb
(19) |
Mar
|
Apr
(12) |
May
(7) |
Jun
(8) |
Jul
|
Aug
(1) |
Sep
(21) |
Oct
(7) |
Nov
(4) |
Dec
|
2012 |
Jan
(3) |
Feb
(25) |
Mar
(8) |
Apr
(10) |
May
|
Jun
(14) |
Jul
(5) |
Aug
(12) |
Sep
(3) |
Oct
(14) |
Nov
|
Dec
|
2013 |
Jan
(10) |
Feb
(4) |
Mar
(10) |
Apr
(14) |
May
(6) |
Jun
(13) |
Jul
(37) |
Aug
(20) |
Sep
(11) |
Oct
(1) |
Nov
(34) |
Dec
|
2014 |
Jan
(8) |
Feb
(26) |
Mar
(24) |
Apr
(5) |
May
|
Jun
|
Jul
|
Aug
(4) |
Sep
(28) |
Oct
(4) |
Nov
(4) |
Dec
(2) |
2015 |
Jan
|
Feb
|
Mar
(2) |
Apr
|
May
|
Jun
(13) |
Jul
|
Aug
(3) |
Sep
(8) |
Oct
(11) |
Nov
(16) |
Dec
|
2016 |
Jan
|
Feb
(6) |
Mar
|
Apr
(9) |
May
(23) |
Jun
(3) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
(1) |
2017 |
Jan
|
Feb
|
Mar
|
Apr
(7) |
May
(3) |
Jun
|
Jul
(3) |
Aug
|
Sep
(8) |
Oct
|
Nov
|
Dec
(3) |
2018 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2019 |
Jan
(4) |
Feb
|
Mar
(2) |
Apr
(6) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2020 |
Jan
|
Feb
|
Mar
|
Apr
(31) |
May
|
Jun
|
Jul
|
Aug
(7) |
Sep
|
Oct
|
Nov
|
Dec
(1) |
2021 |
Jan
(2) |
Feb
(2) |
Mar
(5) |
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2022 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
|
|
|
|
1
|
2
|
3
|
4
|
5
|
6
|
7
|
8
|
9
|
10
|
11
|
12
|
13
|
14
|
15
(2) |
16
|
17
(1) |
18
|
19
(1) |
20
|
21
|
22
|
23
|
24
|
25
(1) |
26
(2) |
27
|
28
|
29
|
30
|
|
|
|
|
|
|
From: Stephen S. <rad...@gm...> - 2017-04-26 21:22:25
|
On Wed, Apr 26, 2017 at 6:03 PM, Erik Ronström <er...@om...> wrote: > Thanks for your answer! > >> You can also avoid threading issues by not using them at all. If you use the lo_server >> interface instead of lo_server_thread, no threads will be created, and >> you can check for new messages using lo_server_recv() or >> lo_server_recv_noblock(). > > That’s great advice; I’ll probably go with that solution! > > A followup question: if I call lo_server_recv(), it reads and dispatches messages directly, on the same thread. Lets assume a TCP connection from a client, the client sends a message, it is dispatched to a handler, and the handler ”answers” by sending an osc message back to the client. Now, if the client has disconnected, or is busy, or for whatever reason doesn’t read its incoming TCP messages fast enough – would this mean that the message handler in the server would block, when the underlying TCP buffer is full? Would there be any way to prevent this from happening? I would use UDP whenever you can get away with it, but the TCP implementation uses buffering during receive. It doesn't presume that a single call to recv() is sufficient, and if less than a whole message is read before it must return, it will not block but leave the data in a buffer until next time. The send code is a little less sophisticated, it does indeed loop until the whole message is transmitted. Only way around that without improving liblo is to use threads. I should mention that there is an open issue in that it is easy to DoS a liblo server -- you can overload it with messages. I was working on it for a while but didn't finish anything significant. >> There is no way to get the message source without receiving a message > > I was thinking that maybe it’s possible to get the client address just from the client *connecting* to the server – but I don’t have enough knowledge of TCP/IP to tell if that would be possible at all. I see. If you look in lo_types_internal.h you'll see that the sources are just an array of lo_address called "sources" in the lo_server data structure, indexed by socket number. But there is no public accessor for this list at the moment. You could propose one if it seems useful. Note that because of how it's indexed not all entries are valid, so be careful using it. >> char *url = lo_address_get_url(source); >> lo_address stored_address = lo_address_new_from_url(url); >> free(url); > > I actually patched liblo with the following function (in address.c): > > lo_address lo_address_new_from_copy(lo_address source) > { > lo_address a = calloc(1, sizeof(struct _lo_address)); > if (!a) return NULL; > lo_address_copy(a, source); > return a; > } > > I now see that was not necessary :) I already added a _clone function for messages, perhaps it makes sense for address too. Feel free to propose lo_address_clone(), it's likely more efficient than using an intermediate string. regards, Steve |
From: Erik R. <er...@om...> - 2017-04-26 21:03:34
|
Thanks for your answer! > You can also avoid threading issues by not using them at all. If you use the lo_server > interface instead of lo_server_thread, no threads will be created, and > you can check for new messages using lo_server_recv() or > lo_server_recv_noblock(). That’s great advice; I’ll probably go with that solution! A followup question: if I call lo_server_recv(), it reads and dispatches messages directly, on the same thread. Lets assume a TCP connection from a client, the client sends a message, it is dispatched to a handler, and the handler ”answers” by sending an osc message back to the client. Now, if the client has disconnected, or is busy, or for whatever reason doesn’t read its incoming TCP messages fast enough – would this mean that the message handler in the server would block, when the underlying TCP buffer is full? Would there be any way to prevent this from happening? > There is no way to get the message source without receiving a message I was thinking that maybe it’s possible to get the client address just from the client *connecting* to the server – but I don’t have enough knowledge of TCP/IP to tell if that would be possible at all. > char *url = lo_address_get_url(source); > lo_address stored_address = lo_address_new_from_url(url); > free(url); I actually patched liblo with the following function (in address.c): lo_address lo_address_new_from_copy(lo_address source) { lo_address a = calloc(1, sizeof(struct _lo_address)); if (!a) return NULL; lo_address_copy(a, source); return a; } I now see that was not necessary :) Erik > 25 apr. 2017 kl. 23:05 skrev Stephen Sinclair <rad...@gm...>: > > On Wed, Apr 19, 2017 at 5:52 AM, Erik Ronström <er...@om...> wrote: >> Hi all, >> >> I have an OSC server, which ”answers” to incoming osc messages using lo_send_from. But I also need to send notifications to the client about things that don’t originate in incoming osc messages: hardware setup changes etc. So these messages are not sent from the liblo server thread. So far, I have been using a mutex to prevent threading issues, but my questions is if this is really needed, or if there is any way to avoid this setup! >> >> And another question: in the message handlers, I use the following pattern: >> >> int some_handler(const char *path, const char *types, lo_arg ** argv, int argc, lo_message message, void *user_data) >> { >> lo_send_from(lo_message_get_source(message), (lo_server)user_data, LO_TT_IMMEDIATE, …) >> } >> >> That is, I get the client address from the incoming message using lo_message_get_source. But when sending ”asynchronous” osc messages (i.e. not from a message handler), that is obviously not possible, and so far I have solved this by caching the address in one of the message handlers. That is hardly an optimal solution (for one thing, simply because I can’t send any such messages until that message handler has been called the first time). Is there a better way? >> > > Hi, sorry for the delay. Using a mutex is fine. You can also avoid > threading issues by not using them at all. If you use the lo_server > interface instead of lo_server_thread, no threads will be created, and > you can check for new messages using lo_server_recv() or > lo_server_recv_noblock(). Any incoming messages will be dispatched > (i.e. the message handlers will be called) before these functions > return, on the same thread. > > There is no way to get the message source without receiving a message, > so if you have no alternative way to get the destination where you'd > like to send a message, then storing the result of > lo_message_get_source(message) is indeed correct, except that the data > it points to may be temporary in the handler, so you should make a > copy using > > char *url = lo_address_get_url(source); > lo_address stored_address = lo_address_new_from_url(url); > free(url); > > How you store and organize these addresses (only one, or a queue, or a > limited array, or an expandable std::vector, etc) is up to you, and > depends on the use case. > > Steve > > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > _______________________________________________ > liblo-devel mailing list > lib...@li... > https://lists.sourceforge.net/lists/listinfo/liblo-devel |
From: Stephen S. <rad...@gm...> - 2017-04-25 21:05:49
|
On Wed, Apr 19, 2017 at 5:52 AM, Erik Ronström <er...@om...> wrote: > Hi all, > > I have an OSC server, which ”answers” to incoming osc messages using lo_send_from. But I also need to send notifications to the client about things that don’t originate in incoming osc messages: hardware setup changes etc. So these messages are not sent from the liblo server thread. So far, I have been using a mutex to prevent threading issues, but my questions is if this is really needed, or if there is any way to avoid this setup! > > And another question: in the message handlers, I use the following pattern: > > int some_handler(const char *path, const char *types, lo_arg ** argv, int argc, lo_message message, void *user_data) > { > lo_send_from(lo_message_get_source(message), (lo_server)user_data, LO_TT_IMMEDIATE, …) > } > > That is, I get the client address from the incoming message using lo_message_get_source. But when sending ”asynchronous” osc messages (i.e. not from a message handler), that is obviously not possible, and so far I have solved this by caching the address in one of the message handlers. That is hardly an optimal solution (for one thing, simply because I can’t send any such messages until that message handler has been called the first time). Is there a better way? > Hi, sorry for the delay. Using a mutex is fine. You can also avoid threading issues by not using them at all. If you use the lo_server interface instead of lo_server_thread, no threads will be created, and you can check for new messages using lo_server_recv() or lo_server_recv_noblock(). Any incoming messages will be dispatched (i.e. the message handlers will be called) before these functions return, on the same thread. There is no way to get the message source without receiving a message, so if you have no alternative way to get the destination where you'd like to send a message, then storing the result of lo_message_get_source(message) is indeed correct, except that the data it points to may be temporary in the handler, so you should make a copy using char *url = lo_address_get_url(source); lo_address stored_address = lo_address_new_from_url(url); free(url); How you store and organize these addresses (only one, or a queue, or a limited array, or an expandable std::vector, etc) is up to you, and depends on the use case. Steve |
From: Erik R. <er...@om...> - 2017-04-19 09:10:07
|
Hi all, I have an OSC server, which ”answers” to incoming osc messages using lo_send_from. But I also need to send notifications to the client about things that don’t originate in incoming osc messages: hardware setup changes etc. So these messages are not sent from the liblo server thread. So far, I have been using a mutex to prevent threading issues, but my questions is if this is really needed, or if there is any way to avoid this setup! And another question: in the message handlers, I use the following pattern: int some_handler(const char *path, const char *types, lo_arg ** argv, int argc, lo_message message, void *user_data) { lo_send_from(lo_message_get_source(message), (lo_server)user_data, LO_TT_IMMEDIATE, …) } That is, I get the client address from the incoming message using lo_message_get_source. But when sending ”asynchronous” osc messages (i.e. not from a message handler), that is obviously not possible, and so far I have solved this by caching the address in one of the message handlers. That is hardly an optimal solution (for one thing, simply because I can’t send any such messages until that message handler has been called the first time). Is there a better way? Regards Erik |
From: Stephen S. <rad...@gm...> - 2017-04-17 15:38:05
|
On Sat, Apr 15, 2017 at 12:10 PM, cristiano piatti <cri...@gm...> wrote: > Good morning, > how can i receive OSC data through UDP from localhost ? > Could someone please make me an example ? The basic examples in the "examples" directory do this. Just run example_server in one terminal window and example_client in the other. It is the default behaviour if you pass NULL as the first argument to lo_address_new. (For sending.) To receive, nothing special is necessary as far as I remember. Steve |
From: John ff <jp...@co...> - 2017-04-15 16:05:14
|
What environment? We do it simply in Csound. So more details please. Sent from TypeApp On 15 Apr 2017, 16:11, at 16:11, cristiano piatti <cri...@gm...> wrote: >Good morning, >how can i receive OSC data through UDP from localhost ? >Could someone please make me an example ? >Thanks a lot. > >------------------------------------------------------------------------------ >Check out the vibrant tech community on one of the world's most >engaging tech sites, Slashdot.org! http://sdm.link/slashdot >_______________________________________________ >liblo-devel mailing list >lib...@li... >https://lists.sourceforge.net/lists/listinfo/liblo-devel |
From: cristiano p. <cri...@gm...> - 2017-04-15 15:11:01
|
Good morning, how can i receive OSC data through UDP from localhost ? Could someone please make me an example ? Thanks a lot. |