Using Liblo to write my own version of oscdump


#1

Hi,

It has been a while since I wrote ANSI-C, so I hope someone can help me. I want to build an oscdump that instead of just displaying/printf-ing the values returns the values in a struct which I can than either insert in a database or allows me to do calculations with. So for example take the average value of the four alpha/beta/etc channels and detect significant changes in either frequency band or creating sessions and seeing average power per band and such.

I looked at the source of oscdump.c but it just calls this function: [TABLE=“class: memberdecls, height: 22”]
[TR=“class: memitem:gaebef3611d24e4b5f60f16cce76a9e271”]
[TD=“class: memItemLeft, bgcolor: #F9FAFC, align: right”]int [/TD]
[TD=“class: memItemRight, bgcolor: #F9FAFC”]lo_server_recv (lo_server s)[/TD]
[/TR]
[/TABLE]

Which is a bit useless because the int it returns are just the amount of bytes. And by going into the code of the function it didn’t become much clearer where the “printf” is being done so that I can add a variable with those value.

Does any one have an idea how I can find this? The API wasnt very helpful on this yet.

Dammas


#2

If you want to analyze data, muse-player will convert live OSC streams into csv, or Matlab files for you to analyze.

It’s also an open source tool so you can modify the source code itself to do any kind of data manipulation as well.


#3

Good idea! Where can i find the source?


#4

If you install the SDK, all the code is located in the Installation folder.
The Defaults are:
Mac: /Applications/Muse
Windows: C:/Program Files (x86)/Muse


#5

I see muse player is a script. I didnt now that, i thought it was a binary. Thanks!


#6

Hi Farough,

My data from muse-player is like this
1415220858.379000, /muse/acc, 74.218864, 972.6578, 226.56285
1415220858.513000, /muse/eeg, 814.26526, 825.78015, 825.78015, 825.78015
1415220858.513000, /muse/eeg/quantization, 1, 1, 1, 1
1415220858.513000, /muse/eeg, 815.9103, 822.4902, 825.78015, 832.36005
1415220858.513000, /muse/eeg, 815.9103, 825.78015, 822.4902, 820.8452

--------------------so on…
How can i analyze these data into emotions?