Resolution of Ping) sensor - Music as therapy
pacman
Posts: 327
One of the guys at work, has a wife who works with diabled kids.
One of the tools that she had (before the break in) was a 'music board"
This board sat in a fixed stand and used ultrasonic (we think) to pick up the position of the kids head - as the kid moved their head side to side (often the only movement they have) they played sounds - apparently the smiles on their face was worth it.
Funds are short (there is a lot of other stuff than needs to be sourced first) so I voulunteered to see what I could knock-up. - Perhaps not my wisest moment...
Current 'thoughs", ping sensor - connected to propeller - connected to midi unit.
Setup would be tilt head left - press button - this sets distance 1, tilt head right - press button - this sets distance 2. anything between distance 1 and distance 2 = sense/play/appropiate noise
Questions are:-
Will the ping sensor have enough resolution?
Will the ping sensor 'bounce' off a persons head?
Are there better sensors to use?
Does any particualr object in the OBEX seem like a really good fit for the ping side of the world?
Does anyone have a midi 'object' they would like to share?
Thanks in nadvance
Paul
One of the tools that she had (before the break in) was a 'music board"
This board sat in a fixed stand and used ultrasonic (we think) to pick up the position of the kids head - as the kid moved their head side to side (often the only movement they have) they played sounds - apparently the smiles on their face was worth it.
Funds are short (there is a lot of other stuff than needs to be sourced first) so I voulunteered to see what I could knock-up. - Perhaps not my wisest moment...
Current 'thoughs", ping sensor - connected to propeller - connected to midi unit.
Setup would be tilt head left - press button - this sets distance 1, tilt head right - press button - this sets distance 2. anything between distance 1 and distance 2 = sense/play/appropiate noise
Questions are:-
Will the ping sensor have enough resolution?
Will the ping sensor 'bounce' off a persons head?
Are there better sensors to use?
Does any particualr object in the OBEX seem like a really good fit for the ping side of the world?
Does anyone have a midi 'object' they would like to share?
Thanks in nadvance
Paul
Comments
Has the makings of a great project. Can I suggest you google something like ultrasonic positioning.
Download the Parallax PING)) documentation from here.
Download the dualping object from the OBEX
And experiment.
Check out the OBEX for MIDI objects.
I did view the obex, hence my question about which of the ping object would be recommended (so big thanks for that) and none of the Midi objects I found seemed to be for 'making' a packet (only decoding one). My musical tallent is nil - so I was kinda hoping that 'use object xxx' would make the midi sending interface _real_ easy.
Had a look at that documentaion - must have mised it the first time. Thanks for the link.
You are 100% correct - experimentation is going to be the key.
Thanks for the words of encouragemnt...
However, I dont have one (yet) and thus whilst waiting for delivery - was hoping to get a start.
I have no idea when it comes to a midi interface (yes, google will be my friend) so, again, I was tring to lessen the learning curve.
EDIT: In the meantime the following links may be of interest:
http://forums.parallax.com/showthread.php/127635-MIDI-Examples
http://forums.parallax.com/showthread.php/132826-Retronitus-Noise-from-the-past!
http://forums.parallax.com/showthread.php/115258-TheBlackBox-Release-v2.0-Propeller-HSS-FX-Sequencer-with-Digital-Audio-SPDIF
Remeber, my muscial tallent = my musical skill = nil.
I get the principle, but if I was to say want a 'cowbell' sound what is the simplest way to transmit the data based on position.
The midi 'receiver' is what does the "make cowbell noise based on the data", but the data stream appears to be a somewhat complex beast.
I think for a protoype I just need to do the original head position limits of travel, divided into 8 zones (1 zone = 1 note. more/less? suggestions welcome) and just transmit that stream, but then it goes and gets all compex and add stuff like duration/speed/channel. Surley I just need something as simple as "each time a new note is 'played' (head movement), send a data stream to channel 1 (?, all?, just the even nnmbere channels??) to play the new note for 1 second" - pitch = ???
I don't know what I dont know. It's a very tall mountin at the moment.
If someone could point me at the idiots guide to MIDI - with particular information on how to generate a data stream for a very simple instrument that would be a _really_ big help to my understanding.
Thanks in advance
I just saw a paper on some similar technology for disabled individuals. The paper included several very detailed descriptions, such as classes with a reflective IR sensor (I think) installed at the top of the frame that could detect looking forward vs looking up (when looking forward only the light color of the sclera is detected). As with your example, small movements were used to trigger music and other things that might be pleasing. And, not surprisingly, an increase in these movements shows that the individuals do enjoy the stimulation. It isn't out yet, but it should be soon. (Its in an issue with one of my papers, I've been waiting for it to come out forever). I can post it later. It sounds like something you and your wife might be interested in.
A single ping mounted in the front, facing the child, should allow you to detect in centimeters how close the child is to the sensor. This way you can constantly use the ping methods to find the how close the child is, and divide this distance into groups. You could for example say that if there is no object within 30cm, play no sounds. If there is an object between 30 and 20cm, play sound A, if there is an object between 20 and 15cm play sound B, etc. I think you could set this up so that rocking back and forth or nodding would change the sounds.
For head tilting left/right, multiple pings might be better. Although you could mount a ping so that the sensor detects the side of the head, the sensor might also detect the shoulder.
If you mount two pings facing the front of the child, you could conceivable detect if the child's head is in the ping's detection range, and how close it is. This would let you do more like what you described in the first post.
Keep in mind the sensor's range. They expand in a conical shape. Also keep in mind that both pings should not activate simultaneously. You should alternate in rapid succession. (Actually, it looks like the dualping object takes care of this. I always alternated manually). I think you can do this alternate between the pair 10 times a second with no problems. I have played with multiple pings in close proximity before, you can easily get enough measurements per second even when you alternate between using ping 1 and ping 2.
Finally, midi is great but does it have to be midi? What about synthesizing sounds using the propeller? Synthesizing musical tones is pretty easy with something like the synth object in the obex. Granted the tones are simple, but you can generate music. What about playing WAV files from an SD card? What about other non-auditory stimulation? For now, I recommend getting the pings connected and using something like LEDs just to help you set up the sensors.
Anyway, keep us posted.
Also, it maybe better to discard the MIDI output concept in favour of a .wav output with thw .wav files stored on an SD card. One less obstacle as there has been significant development of this using a Prop.
A SD card with 8 'tones' on it would be fine. She is even prepared to have multiple SD with different sounds depending on the child (so cows might be for child 1, but child 2 needs dinosaur "roars").
The two axis idea got her very excited. But we will walk (crawl?) before we run.
More details - and I'm sure questions - to follow...
See Technology-aided programs for persons with severe/profound and multiple disabilities: A selective review.
This paper has descriptions of some of the micro-switch activated devices I mentioned. Could be useful.
Have managed to get my ping sensors reading and have successfully played wav files using Kwabena's player. Though the player seems to be VERY hissy - early days.
Actually planning on setting up a demo (using my demo board) in the next week - nothing flash, more of a proof of concept....
Code/questions/results to follow....
Showed this to my colleagues wife --> She was impressed.
Told her could probably 'make' them for under $200 -> she was stunned
Reinforced the 'I intend to release the design under open source as per the original discussions we had' -> "you mean 'to the world,and anyone could make one - for free" " -> she almost wet herself (perhaps she did - I didn't check)
Forward a couple of weeks - one of her clients comes from a family who were planning on buying a "soundwave" setup (which I'm told is in the vicinity of {I'm told} $6000 AUD, who; when told of the "PingSound" {it's working name} asked lots of questions like "could it be made 'portable'?", "Could it be adapted to the side of a chair?", and "Could it be configured to speak things like yes/no/food/drink/toilet?"
So sometime in the next few weeks I need to 'demo' this unit to the boss of colleagues wife and "soundwave family".
And it's still only in pro-type form... I'll admit I'm a little scared as to where MY IMAGINATION fancies this might be headed...