PDA

View Full Version : Sending OSC Type Tag ,f not recognised?



SubstanceG
03-24-2010, 01:35 AM
Hi,


First of all - thanks for Osculator! It's a great product - good job!


My question is: I'm using my own client and sending to OSCulator. But whenever I use the OSC Type Tag ",f" it isn't recognised by OSCulator. Type Tag ",i" is recognised ok.


With ",f", OSCulator does receive something - I see a little green line right at the bottom of the Quick Look graph, so I think it's understanding the OSC Address Pattern ok, just not the Type Tag or Argument.


I checked my ",f" argument and I'm pretty sure I'm sending a valid 32-bit IEEE 754 value.


Thanks for any advice on what I can check!

camille
03-24-2010, 09:53 AM
Hey Substance,


Float values are used all over the place in OSCulator, so there is no doubt it can receive them.

Here's a little bunch of questions:

What kind of client are you using? Have you written it from scratch?

Have you checked the network endianness when writing the float value?

If you take a look at the Console application there is a possibility of some messages logged, that would be interesting to know if there is anything there.


Good luck!


Best,

Cam

SubstanceG
03-24-2010, 10:25 AM
Hi,


Thanks for the fast reply!


I'm using the mrmr client just at the moment. I saw that I need to set "Use Float Values" = OFF in the mrmr preferences for the argument value to be recognised by OSCulator. But this confused me, as "Use Float Values = OFF" sends out integer values between 0 and 1000, while Osculator recognised them (on the Quick Look graph) as float values between 0.0 and 1.0.


So I added some debug logging to mrmr and confirmed indeed that when it has "Use Float Values = OFF", it is sending out Type Tag = ",i" and the argument is big-endian two's complement int32. So I'm confused how OSCulator sees this as 0.0 to 1.0 - is there some conversion done on your side? (e.g. conditional on mrmr namespace)


With some more mrmr debug logging, I could confirm that with "Use Float Values = ON", it is sending out Type Tag = ",f" and the argument is big-endian IEEE 754 float32. But, as I mentioned, this isn't recognised by OSCulator. Though I'm fully prepared to accept that the bug is on my side... :-D


On Console - do you mean logs from OSCulator too?


Cheers!

SubstanceG
03-24-2010, 12:26 PM
Hi again,


I just did some more testing and replaced the "/mrmr" root Address Pattern with "/mrmx" and now OSCulator recognises my ints as 0-1000 ints and doesn't convert them to 0.0 - 1.0 (Quick Look reports correct 0-1000 values). So it suggests that OSCulator does indeed conditionally process the signals dependent on the "/mrmr" root ID. Can you confirm?

camille
03-24-2010, 01:40 PM
ok, now that makes sense!

:-)


Let's call it a feature rather than a bug.

When Mrmr didn't have a "Use Floats" button, lots of users were confused by the fact the values were not normalized to the [0.0 1.0] range. oscltr got around this by automatically configuring the input range to 0 1000. Now what I can do, is also check the type of the argument and apply the default scaling only if it is an integer.


On your side, all you have to do is to remove the scaling by editing the input min/max value in the scalings page.


Best,

Cam

SubstanceG
03-24-2010, 02:12 PM
Awesome! Your advice fixed the float question: it was because the scaling for float was also set at input 0-1000. When I changed the scaling input to 0-1.0 then my floats from mrmr appear in OSCulator correctly too!


Magic - thank you very much!

camille
03-24-2010, 05:35 PM
cool !