0
\$\begingroup\$

schematic

simulate this circuit – Schematic created using CircuitLab

I have looked at a few guides, both on this forum and elsewhere, for choosing a transistor. I know to look for things like Hfe and the collector-emitter voltage, but on the datasheets I am seeing multiple values and don't know which one to look at. In my application I will have a comparator (powered by 5 V) connected to the base of the transistor. The emitter will be connected to GND and the emitter will be connected to the GND of a 1.5 V vibration motor. Based on those voltages, how should I go about looking for a transistor? Also, here is an example of multiple Hfe values. For the future, how would I decipher which one to use for calculations?

I have included a schematic. "U2" is the HC-SR04 Distance Sensor and the Speaker is a 1.5 V 50 mA vibration motor. That op amp and comparator are the main point of contention. The functionality I am looking for is it to compare the voltage coming from the distance sensor to some reference voltage I can find later, and if it is above that voltage open up a gate that allows current to flow from the battery to the vibration motor.

\$\endgroup\$
5
  • \$\begingroup\$ Well, I'm not even sure you will be using the comparator correctly. Please note that some of them already come with an open drain or open collector output. So you might start out by considering one of those. Probably the most important details you left out are the worst case vibration motor current and the minimum allowable operating voltage for the motor. \$\beta\$ is way down on the list, right now. Do you have a spec sheet for the motor? \$\endgroup\$
    – jonk
    Oct 25, 2017 at 18:52
  • 2
    \$\begingroup\$ Since you say this is for a low power application, don't use a bipolar transistor, use a MOSFET instead. The latter are voltage driven and do not waste current driving the base. But to answer your question, you always have to design with the worst case value. \$\endgroup\$
    – Trevor_G
    Oct 25, 2017 at 18:54
  • \$\begingroup\$ Please put in a schematic so we can double-check stuff. In your written description, you mention emitter twice. I think it is the collector that is connected to the motor. But who knows? Be sure to list the true part number for your comparator. \$\endgroup\$
    – user57037
    Oct 26, 2017 at 4:32
  • 1
    \$\begingroup\$ To add a schematic, edit your original question. Then, at the top of the edit area, there is a button that looks like schematic symbol elements. Click on that button to bring up the schematic editor. \$\endgroup\$
    – user57037
    Oct 26, 2017 at 4:33
  • \$\begingroup\$ I just updated my post to include a schematic \$\endgroup\$ Oct 27, 2017 at 13:38

2 Answers 2

1
\$\begingroup\$

Since you say this is for a low power application, you would be better off ditching the bipolar transistor, and using a MOSFET instead. The latter are voltage driven and do not waste current driving the base.

But to answer your question, you always have to design with worst case values.

Moreover, when presented with minimum and maximum values, it is often prudent to recalculate your equations with both to determine if the circuit will function within your requirements across the full variation of the part.

For example, you need to use the minimum \$\beta\$ value to calculate the largest base resistor you can use for a desired collector current, but at the same time you may need to use the maximum \$\beta\$ value to check your collector current is not too large with the resistor you calculated in the first part.

Ultimately, which is important when is dictated by the rest of the circuit, or the application of the part.

As for your design, as Jonk mentioned, most comparators have open-collector outputs anyway, so, with the right comparator, you may not even need a transistor.

\$\endgroup\$
4
  • \$\begingroup\$ Could you link one that might work for this application? I'm finding ones with 2 reference voltages but none with an open collector. \$\endgroup\$ Oct 25, 2017 at 20:41
  • 1
    \$\begingroup\$ @GabeSpound "Ones with two reference voltages?" Me thinks your idea of what a comparator is may be suspect. Post a link of what you are looking at. (I also cant suggest a part sine you have supplied too little information of what you are doing.. and no schematic.) \$\endgroup\$
    – Trevor_G
    Oct 25, 2017 at 20:52
  • 1
    \$\begingroup\$ +1 - 100k pull is 300uA, nothing fun ultra low power \$\endgroup\$
    – jaskij
    Oct 26, 2017 at 6:57
  • \$\begingroup\$ I updated my post to include a schematic and an explanation in the "edit" section \$\endgroup\$ Oct 27, 2017 at 13:38
0
\$\begingroup\$

This is not at all how this ranging module would be connected.

First, you need to provide a 10us trigger pulse, repetitively, to cause the sensor to perform ranging. Then the output pulse's width is proportional to the distance. There are only two voltage levels: logic high and logic low.

If the trigger pulses are provided at a fixed frequency, then the duty cycle of the output signal will be proportional to range. You can then low-pass filter the digital output signal and thus obtain its average value, proportional to the duty cycle, and thus to the range.

Thus, what you need is:

  1. A source of trigger pulses going to the TRIG input. That can perhaps be an NE555, or an op-amp based pulse generator circuit.

  2. A low-pass filter on the ECHO output.

  3. A comparator that compares the output of the low-pass filter with some reference voltage.

All of those functions can be easily implemented using a quad op-amp, thus you could have a single-chip solution with some passive external components. In addition, you'll need a transistor to turn the vibrating motor on. Given the low power nature of it all, a low-power signal transistor or a small mosfet will be sufficient.

You'll also need a 5V voltage regulator. But 9V batteries are not particularly efficient. You could use a little boost module to take 1.5V from an AA cell up to 5V. There's a multitude of those available on the market.

The total current consumption of the circuit would be below 50mA, so a 50mA (or higher) 1.5-to-5V boost module would be more than sufficient. The cheap boost modules have an electrically noisy output usually, so I'd suggest a passive LC filter on the output. The size of the total solution could fit into the volume of three AA batteries, even if the op-amp circuit was implemented through-hole on a strip of breadboard/veroboard.

The block schematic would look like this:

schematic

simulate this circuit – Schematic created using CircuitLab

I assume that the comparator CMP has open-collector output. If it'd be an op-amp instead, then a Schottky diode would be needed from the R3-C6 filter centerpoint to CMP's output.

C1-L1-C2 is a supply voltage PI filter. The recommended series resistance for L1 is <2 Ohm, to keep the voltage drop to less than 100mV.

VR1 sets the distance threshold.

R3-C6 sets the duration of the vibration after the distance threshold has been crossed.

An additional circuit may be necessary to suppress the vibration when the echo is absent. This could be as simple as a yet another RC filter and a transistor.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.