avatar

Byron J.

Member Since: September 10, 2013

Country: United States

Profile

Apparently, the J is for JFET.

Enginursday: I'm Living In A Simulation

For this blog post, I was originally going to write a survey of some of my favorite tools - things that my workbench would be incomplete without. As I wrote more, I found that I’d written a whole lot about one specific tool. Rather than deleting it and starting over, I decided to change the…

Continue reading

Enginursday - Stupid Eagle Tricks

As an engineer at SparkFun, it’s a given that I’ll be using CadSoft Eagle on a regular basis. When I started here in September, I considered myself proficient, having designed a number of PCBs over the years. But I’ve also come to better terms with Eagle, learned more of its inner…

Continue reading

Sound Detector Hookup Guide

February 27th, 2014

The Sound Detector is a microphone with a binary output. This guide explains how it works and how you can use it in your projects.

Large Solderable Breadboard Hookup Guide

February 27th, 2014

This breadboard has a couple of tricks up it's sleeve!

VKey Voltage Keypad Hookup Guide

February 13th, 2014

A quick hookup for the VKey analog voltage keypad.
  • Product SEN-12642 | about a week ago

    There are a couple operating points that shift as the supply voltage changes. The DC bias on the mic capsule changes, which alters the sensitivity a bit. Also, the trip voltage for the Schmitt trigger is a function of the supply voltage. On a lower supply voltage, the threshold is lower, making it appear more sensitive.

    How are you adjusting the supply voltage?

    Ideally, the LED brightness control would be independent of the supply to rest of the circuit.

  • Product SEN-12642 | about a week ago

    In prototyping this board I had some real hassles getting it working at 3.3V. Here’s what I learned:

    1. Make sure that your 3.3V supply is stable. The first supply I tried actually output a 500 mV triangle wave, riding on top of a 3V DC offset. The noisy supply made the whole thing really touchy.
    2. Adjusting the gain for a specific input should help you suit your application more precisely. This portion of the hookup guide will walk you through that.
  • Product SEN-12642 | about a week ago

    Ahh, feedback. My old nemesis. We meet again.

    Your analysis is accurate - it’s the sound coming into the speaker, then back into the mic. From the perspective of feedback, gain is gain. It doesn’t really matter which stage applies it…the preamp on the sound detector, the Pandora, or the mono amp. Another decibel louder is another decibel louder.

    There are several approaches used to circumvent feedback. They aren’t always universally applicable, but each is worth experimenting with, or perhaps trying in tandem.

    First, adjust the physical proximity of the speaker and mic, if you can. Break the path that the sound waves are traveling. If you could put the mic inside the helmet, seal it sufficiently, then place the speaker outside (like in Vader’s chest pack or belt), connected in such a way that the sound and vibration don’t come back to the mic. It’s also worth a mention - it might not be sound waves traveling in air causing the feedback, but instead vibration coming physically through the structure. The tighter you connect things together, the more prevalent this phenomenon will be - likewise, looser, more resilient connections will tend to help prevent mechanical transmission. Of course, this approach runs somewhat counter to your thought of using the surface transducers.

    Second, we get into filtering. If we can remove the problem frequency, it won’t feed back. On large sound systems, 31-band graphic equalizers are used - you find the frequency of the feedback, and turn down the corresponding slider. The EQ is being used as a bank of notch filters. If the feedback is always the same frequency, you might be able to make a passive notch filter to remove that frequency.

    Can the Pandora do both your FX and a notch filter at the same time? That would avoid adding any more components.

    If not, there’s a simple passive notch in Horowitz and Hill’s Art Of Electronics, or see what Google comes up with - the twin-T or bridged-T topologies might be worth hunting for. If the frequency is extremely high or extremely low, a simple hipass or lopass filter might remove it.

    Filtering can be a little bit tricky. If there’s enough loop gain for one frequency to ring, there’s probably enough that other frequencies also want to ring…you solve one only to reveal the others. Also, depending on conditions, the frequency might not always be the same. Other factors like humidity, the exact orientation of the speaker and mic, and the acoustics of the room you’re in might alter the frequency.

    Third, a somewhat more esoteric approach would be to add a bit of delay. Feedback occurs when the sound travels around the loop almost instantaneously. Even a short delay, like 50 ms delay might keep it from happening. You might also find a short delay like that really disorienting and hard to talk through. Worth a try, though.

    You might work through various parameters inside the Pandora. If you’ve got any distortion, guitar amp modeling or compression running, try turning them off. Guitarists sometimes like it when their amp is right at the edge of feedback - it allows them to get long sustain. Compression can make quiet sounds louder, thus more likely to feedback. Also, try adding a noise gate - when you stop talking, it should mute the input, to help avoid feedback.

  • Product SEN-12642 | about a week ago

    Subbing 80 nF for R17 would give you 19.9 Hz lowpass function. If you really want 1Hz lowpass, 1.6uF will do it.

    But you’ll also need to scale the hipasses formed by C2 & R2 and C4 & R4. At the moment, they’re both at 15 Hz. There isn’t really much of a passband with a 15 Hz hipass followed by a 1 Hz lopass.

    The filter equations are:

    • First stage Hipass Fc = 1/(2piC2*R2) = ~15 Hz
    • First stage Lopass Fc = 1/(2piR3*(Cap subbed for R17)) = ~20 Hz with 80 uF cap
    • Second stage Hipass Fc = 1/(2piC4*R4) = ~15 Hz

    The peak detector is probably better expressed in terms of rise/fall time, than pass frequency.

    • Rise time (in seconds) is R8*C1 = 1 millisecond
    • Fall time (in seconds) is C1*R9 = 100 milliseconds

    R8 could even be 0 Ohms, if you want really fast peak detection. R8 and R9 were selected based mainly on aesthetic behavior. If R9 is too small, you may not see the LED blink, even when the output trips, and if R8 is small, the output becomes fairly glitchy. It acts as a degree of noise reduction.

  • Product COM-12852 | about 2 weeks ago

    The library in question may not actually be incorrect. There are a number of variants of the 2222. They’re electronically equivalent, but the pinout doesn’t always match. You need to verify the prefix and suffix of a given vendor’s part. For instance

    • These are the On Semi P2N2222A, with CBE pinout.
    • The nearly equivalent On Semi PN2222A has an EBC pinout.
    • I’m having trouble digging one up, but there are probably some Japanese transistors (Hitachi or Toshiba) with 2222 in the name that have a BCE input.

    You have to make sure you’ve got the datasheet specific to the device you’re working with.

  • Product SEN-12642 | about 3 weeks ago

    I’m not sure this circuit it especially suitable for an application like that - it might require significant tuning.

    First, you’d have to find a microphone element more suited to that frequency range. Many microphones are tailored to human hearing - the response is generally specified as starting at 20 Hz. The specs on the capsule here don’t even specify anything below 50 Hz. The matching tolerance from capsule to capsule isn’t particularly tight, either. I don’t offhand know of a similar infrasonic microphone that would just drop in…googling leads me to very high-spec Bruel and Kjaer capsules.

    A first-order lowpass filter isn’t especially hard - just put a cap in for R17. Using C = 1/(2pi * Rf * Fc), I get 80 nF, a reasonable value. Of course, this will change if you adjust the gain using the R3 || R17 combination.

    A higher order filter probably requires additional amplifier stages.

    The circuit also contains a couple of first-order highpass functions. The signal from the microphone is AC-coupled into the preamp stage. C2/R2 form a highpass filter at 16 Hz. The low frequency response would likely need to be extended for your application. The second filter is formed by R8/C1, to slow the rise-time of the peak detector a tiny bit - to make things more responsive, reduce R8.

    I take it that the projectiles make a measurable sound as they pass, and that the trajectory is predictable enough that they’ll pass through the areas covered by the dishes?

  • Product SEN-12642 | about a month ago

    We usually leave reference designators on the PCBs in layers that don’t get printed in the silk.

    The label on the SJ is an example of one reason we don’t: the boards are fabricated and populated as a panel with many boards. Each instance on the panel takes the next set of unique sequential numbers. “SJ11” tells us it was the 11th board on the panel.

    The label on the SJ has been fixed. The next batch of boards will all read as “SJ1.”

    The filtering is definitely an interesting idea, and I’ve been kicking a state-variable filter around on the workbench a bit. I’ll keep it in mind!

  • Product SEN-12642 | about 2 months ago

    I think the white LED will be similar to the Violet. The Vfwd and current ratings are pretty similar between them.

    For the violet LED, the first thing I’d try is putting it on the Gate output, with a 330-Ohm resistor in series. That blinks very nicely on my workbench, from either 4.5V or 4.8V supplies.

    Changing the gain set resistor will have more side effects than simply making the output signals stronger - it will also make the whole thing more sensitive to sound. If you increase it too much, it gets really touchy - cranked up too high, it triggers on quiet background sounds. In a noisy environment, it’d be on all the time.

    A buffer would be a DC amplifier of some sort that would provide more current, and possibly increase the voltage. The mono amp breakout (BOB-11044) isn’t suited to that, because it’s AC-coupled, and the envelope output is DC voltage.

    So please give the gate output a try first. I don’t have a good recommendation for an easy to use buffer off the top of my head, but I’ll ponder on it.

  • Product SEN-12642 | about 2 months ago

    Yes. They both use the same capsule, and the preamplifier circuit of the Sound Detector is similar to the Electret Breakout. If you only used the audio output of the Sound Detector, it’s similar to the electret breakout, the major difference being the gain.

  • Product PRT-12080 | about 2 months ago

    Yeah…something doesn’t quite jive there. You report a max reading of 504, we somehow both arrived at a max of 496. I just put your measurements into the spreadsheet, and here’s the resulting table.

    18.9    min
    42  step
    Key #   lower threshold mid point   upper threshold
    12  18.9    39.4    59.9
    11  60.9    81.4    101.9
    10  102.9   123.4   143.9
    9   144.9   165.4   185.9
    8   186.9   207.4   227.9
    7   228.9   249.4   269.9
    6   270.9   291.4   311.9
    5   312.9   333.4   353.9
    4   354.9   375.4   395.9
    3   396.9   417.4   437.9
    2   438.9   459.4   479.9
    1   480.9   501.4   521.9
    

    That gives me a min/step/max of 18/42/522. The values you measured are within 3 counts of the midpoint of each bin there, so you should be squarely within each.

    Please give that a try.

Name Pieces Total
Sound Detector Analog Example
8 31.15
Sound Detector Arduino Example
Parts for building the Sound Detector + Arduino example
3 31.4