Question Any ideas on counting audio pulses ?

max2tall

New member
Joined
May 17, 2008
Messages
2
Programming Experience
Beginner
I'm using the pc's bluetooth & soundcard to receive pulses from a remote transmitter (basically rigged an old bluetooth phone earpiece to a heartrate monitor receiver to wirelessly log heartbeats).

PC receives 20ms pulses every heartbeat, which is roughly every second or so, varies between say 60 bpm to 200 or so bpm, i.e. about 1 to 3 hz square wave with extremely short on duty cycle.

Anyway, I can't fathom directsound examples of measuring volume etc. I think all I need to do is set some low threshold volume level and grab the time (to the millisecond) that a each pulse occurs, then use periods between thuds to generate heartrate. It's really easy to do with mouseclicks ! but I dont see how to get at the soundstream? - some examples I've seen involve pages of code but it just shouldn't be that involved should it ?

Can anyone help please ? I'm ok with the coding except for the sound time grabbing bit. Cheers.
 
Please post in the most appropriate forum for the topic of the thread. This question has nothing to do with Windows Forms so it doesn't belong in the Windows Forms forum. Moved.
 
Apologies

I'm writing a windows forms application so I figured I should post in the forms section, sorry, my misunderstanding.
 
Back
Top