Most recent activity
-
-
I have bought a couple "C7210" ultrasound emitter / receiver.
The emitter needs a 40khz pulse, and I would like to analyze the echoed signal on the receiver.
I tried to proceed like this:
C9 => Emitter
C5 => Receiver( the second pin of emitter and receiver is to GND ).
// wout is the waveform I want to send to the emitter var wout = new Waveform(256); for (var i=0;i<256;i++) wout.buffer[i] = 128+Math.sin(i*Math.PI/128)*127; // win is the waveform I want to record from the receiver var win = new Waveform(512); win.on("finish", function(buf) { drawBuffer(buf); // ( I have a small lcd on which I draw the waveform ) win.startInput(C5,40000,{repeat:false}); // I want to record the next 512 bytes }); C9.reset(); C5.reset(); // How do I output a 40khz waveform ? analogWrite(C9,0.5,{ freq:40000}); // pwm at 40khz ? wout.startOutput(C9, 4000, { repeat:true }); // modulates the pwm ? // How do I record an analog signal on a pin? win.startInput(C5,40000,{repeat:false});
Also I am not sure if the 3.3V of the esperuino are enough to make the ultrasound emitter.
So far it looks like I've recorded only parasites. Can the espruino generate and record a 40khz signal? Am I missing something?
-
- 5 comments
- 3,727 views
-
I am quite amazed: the ideal module would be the "GSM2 click", as used by @Hardware_Hacks , but the module costs 45€, more than twice the price of a full-blown gsm phone.
I just fall on this:
http://hackaday.com/2010/10/18/cheap-and-easy-sms-via-gsm-for-your-mcu/It looks possible to do the trick via some USB dongle.
If anyone already had a success this way, please share! -
-
-
-
It works. I found out how a "pulldown resistor" would solve the noise problem, and a with a bit of testing I was able to generate the 40khz pwm and record it in a 4096 bytes waveform at 20khz.
Here is a photo of the nokia LCD on which I visualize the result.
The Chirp duration was 100ms, during which 4 spikes were recorded.
I will try to record the signal with my raspberrypi, maybe it can handle a higher frequency.
Now one of the issue I have left is the 3.3V. Is there a way - of course with an external source of power - to have the 40khz PWM at twice or thrice the voltage?
With some googling I found circuits such as:
MAX756 or LT1073
The MAX757 spec specifies an "Oper. Freq." of 500kHz. Does this mean that If I provide it with a 40khz PWMed 3.3V from the espruino it will deliver a 40khz square signal at 5.0V ?