Author Topic: Using op amps and PIR sensors...  (Read 5311 times)

0 Members and 1 Guest are viewing this topic.

Offline TrickyNekroTopic starter

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,208
  • Helpful? 15
  • Hardware and Firmware Designer
    • The Hellinic Robots Portal
Using op amps and PIR sensors...
« on: August 20, 2008, 01:58:03 PM »
Hello guys,

seems I want your help here...

I have some PIR sensor I want to use... I know I need an non-inverting op amp but I have some questions so that I have my head clean....

I want to make a heat turret...
First:
Do I need any kinda Fresnel lens for this or not... cause I want a narrow beam...

Second:
I hate to admit it but I'm still no good with analog circuitry mainly cause I don't have an oscilloscope to measure them...
Is it better to compare the signals with the op amp or do I amplify both and compare them with an AVR...
It's that I need a non-inverting or a

Third:
I think that if supply for the op amp is not greater that 5V then the Vout is not higher.... right?
For whom the interrupts toll...

Offline RobD

  • Full Member
  • ***
  • Posts: 64
  • Helpful? 0
Re: Using op amps and PIR sensors...
« Reply #1 on: August 23, 2008, 01:32:43 AM »
I'm not real familiar with PIR sensors other than reading about them.  Op Amps, however, used to be my main mode of electronics work until I discovered the power of software over hardware  ;D

Quote
Is it better to compare the signals with the op amp or do I amplify both and compare them with an AVR...

Personally, my intuition nowadays is to amplify with analog and compare with computer.

Quote
I think that if supply for the op amp is not greater that 5V then the Vout is not higher.... right?

Correct.  If you are building this circuit from scratch then you need to consider your power supply to the Op Amp carefully also taking into consideration the voltage levels you will need for analog to digital conversion.  A general rule of thumb that I was taught back in the day was 1.5 Volts from the supply rails to avoid saturating (or clipping) the Op Amp.  Your Op Amp's data sheet should supply adequate information.  This could be a factor for you depending on your voltage gain requirements and, more specifically, if you run your Op Amp from a single supply voltage.   

Google "Op Amps for Everyone" and "Handbook of Operational Amplifiers"  from TI's website.   - or reply here and I'll try to help the best I can.

Regards
Rob   

Offline TrickyNekroTopic starter

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,208
  • Helpful? 15
  • Hardware and Firmware Designer
    • The Hellinic Robots Portal
Re: Using op amps and PIR sensors...
« Reply #2 on: August 25, 2008, 08:49:12 AM »
The problem is that I don't know where to look...

From my readings (although got em using a very noisy supply) the sensor's value varies from 0V6 to 0V9 let's say from 0V5 to 1V to
be sure...

What I need is a non inverting op amp with an output from 1V to 5V let's say...
To calculate the resistors needed should I use the max ratings... so with 1V @ Vin I get 5V @ Vout...

But then I need a fixed resistor... cause with two known numbers you can't get two unknown with a simple equation...

For instance I'll use a LM358 dual op amp with single supply and fixed gain...


It's my first step on analog electronics so I need as many help as I can get...
I also got the books... what am I supposed to read first???  :P

Thanks for the reply...

Best Regards...
Lefteris, Greece...
« Last Edit: August 25, 2008, 09:01:39 AM by TrickyNekro »
For whom the interrupts toll...

Offline RobD

  • Full Member
  • ***
  • Posts: 64
  • Helpful? 0
Re: Using op amps and PIR sensors...
« Reply #3 on: August 26, 2008, 06:13:00 PM »
Sorry for the delay in etting back to you!

First of all - you are treading on slightly unstable ground using a non-inverting configuration..  Doesn't mean it's not advisable, just requires some tinkering to get things right.  Not such a big deal wih a single input however.

If you want to see 1v become 5v then you are looking at a gain of 5.  Gain is "basically" the ratio of the output to the input whether it's volts, current, watts, etc...

I'm assuming you read "Op Amps for Everyone"   ;) but I'll go ahead and give you the spoiler.   Don't read further unless you give up haha! 

In a nutshell, the gain of a non-inverting op amp is set by the voltage divider network applied to the inverting (-) input of the op amp... plus one (don't forget that).  so... lets see a picture and go from there.



R1 and R2 create a voltage divider network applied to the (-) input of the op amp.  So if R1 is 2K and R2 is 500 then the ratio is 4 (2000/500).  Add 1 to it and that equals 5.  Thats what you want --- a gain of 5.  It's simple but yet it's complex.  I always hated analog circuit design  :D

Now, the Rs on the input?  That our tweaking resistor.  It doesn't affect the gain of the circuit but it helps "clear the mud' I guess you could say.  Make that resistor somewhat near the value of the parallel resistance of R1 and R2.  Here's another hint... it's gonna be close to the ratio of R1 and R2 usually.   ;D

Hope that helps!

Rob

 ***edited because my math was taking a nose dive***

***second edit****

Here's the math:

Vout/Vin = R2/R1 +1

You are right that you can't get the numbers with only a simple equation and two numbers.  Pick a pseudo-random value for R2 and start extrapolating and matheme-cating :D   
Here is how my simple brain works:  Say I want to take a 0v5 signal and make it a 2v5 signal?  I divide 2.5/0.5 and get 5.  That's my gain.  So how do I get it?  I subtract one from it and design the circuit around a gain of 4 (if it's a non-inverting amp).   



 



« Last Edit: August 26, 2008, 06:57:41 PM by RobD »

Offline TrickyNekroTopic starter

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,208
  • Helpful? 15
  • Hardware and Firmware Designer
    • The Hellinic Robots Portal
Re: Using op amps and PIR sensors...
« Reply #4 on: August 27, 2008, 06:41:53 AM »
Man! that's what I call help!!!

Thank you!!!!!!

Nice! I got it now, although it turns out that these PIR sensors are a disappointment.
That's because they can "unfortunately" suit themselves to environmental changes...
They can only detect if there is a change in infra light volume in the field of view but
can not actually measure the amount of infra light on them....

Not that it is impossible to do the whole project but.... hell that requires you KNOW programming...
But I'll give a try... I just can't stand....

Anyways man, thanks a lot!!!
Hope you can help me with any other question I'll come up to....

Best Regards, Lefteris

BTW If I want to build a sound amplifier with at least 100W on channel.... can you help me???
For whom the interrupts toll...

Offline RobD

  • Full Member
  • ***
  • Posts: 64
  • Helpful? 0
Re: Using op amps and PIR sensors...
« Reply #5 on: August 27, 2008, 09:51:17 PM »
No prob.  I plan on using the 'smart battery monitor'.  Thanks!

Quote
If I want to build a sound amplifier with at least 100W on channel....

That would be a nice project!  I'm not very good with RF design.  Still learning (working on building a wideband tuner)  :)

 

Offline TrickyNekroTopic starter

  • Contest Winner
  • Supreme Robot
  • ****
  • Posts: 1,208
  • Helpful? 15
  • Hardware and Firmware Designer
    • The Hellinic Robots Portal
Re: Using op amps and PIR sensors...
« Reply #6 on: August 28, 2008, 06:21:26 PM »
No prob.  I plan on using the 'smart battery monitor'.  Thanks!

Quote
If I want to build a sound amplifier with at least 100W on channel....

That would be a nice project!  I'm not very good with RF design.  Still learning (working on building a wideband tuner)  :)

 

I've got some idea, but not big deal.... really...

Basically, do I need a power amp to drive the Mosfets.... many make this pre-amp with some npn transistor and that...
what is best???

Thanks again!!!
For whom the interrupts toll...

 


Get Your Ad Here

data_list