element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet & Tria Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • About Us
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      • Japan
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Vietnam
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Experts, Learning and Guidance
  • Technologies
  • More
Experts, Learning and Guidance
Ask an Expert Forum PIR Sensor ultra sensitive
  • Blog
  • Forum
  • Documents
  • Leaderboard
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Experts, Learning and Guidance to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Not Answered
  • Replies 20 replies
  • Subscribers 297 subscribers
  • Views 2061 views
  • Users 0 members are here
Related
See a helpful answer?

Be sure to click 'more' and select 'suggest as answer'!

If you're the thread creator, be sure to click 'more' then 'Verify as Answer'!

PIR Sensor ultra sensitive

tonyd512
tonyd512 11 months ago

Hello,

New to Element 14

Needing a PIR sensor (or something more appropriate) sensitive enough to detect box elder bugs. They are about 1/4 inch long. Sensor needs to have short range maybe 3-4 ft or so.

ideally it would trigger a smart phone on a tripod aimed at the target area. These bugs crawl quite slowly mostly but do fly as well.

Need a little guidance choosing an appropriate sensor for the project. This will be indoors.

Tony D

  • Sign in to reply
  • Cancel

Top Replies

  • kmikemoo
    kmikemoo 11 months ago +2
    While electronics would be cool, if you can't localize the point of entry based on sightings, I would go with a simpler approach. They could also be "replicating" inside. You might be able to secure…
  • shabaz
    shabaz 11 months ago +1
    What's the actual goal? What is the use-case? By 'trigger a smart phone aimed at the target area' do you mean to trigger a smart phone camera? Or something else? If all you wish to do is to take photos…
  • shabaz
    shabaz 11 months ago in reply to tonyd512 +1
    There are some interesting solutions described here: https://stackoverflow.com/questions/189943/how-can-i-quantify-difference-between-two-images There's a simple one mentioned there which is to just…
  • shabaz
    0 shabaz 11 months ago

    What's the actual goal? What is the use-case? By 'trigger a smart phone aimed at the target area' do you mean to trigger a smart phone camera? Or something else?

    If all you wish to do is to take photos of them, then if they move slowly, you could simply just take a photo say every minute without sensing them, because storage is cheap. Then there would be no need for a sensor other than the camera, and you could process the photos to extract the ones that are sufficiently different, to identify the interesting photos.

    If there's some other aim in mind, then it would help to know it, to come up with an appropriate solution.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • tonyd512
    0 tonyd512 11 months ago in reply to shabaz

    Hello,

    Goal is to figure out where these bugs are getting into the house and then plugging the holes. They can get in the tiniest cracks. They are insidious and sneaky little buggers. They leave a trail pheromones for others to follow when they find a new way in. They are to be admired really. They are testing of my tenacity and resolve. I have organic vegetarian friends who have resorted to spraying their whole house with pesticides to stop them!

    PIR would trigger phone or camera to take photo when one goes by which then identifies an area they are getting in.

    Over the past year I have diligently sealed up cracks and holes where they were getting in. We are getting 80% less getting inside than the last season but still an annoying 12-24 per day on sunny days in the winter in NW Oregon.

    I have thought about time lapse every 15-30 seconds or so, but I would have to sit there and view 5,000 pictures over a 24 hr of recording to spot any that might go by!

    I have done a fair amount of Photoshop work but I'm not familiar with how to identify "sufficiently different" photos. That may be the simplest solution if you could teach me how to do that!

    Thank you so much for your help

    Tony D

     

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • shabaz
    0 shabaz 11 months ago in reply to tonyd512

    There are some interesting solutions described here:

    https://stackoverflow.com/questions/189943/how-can-i-quantify-difference-between-two-images

    There's a simple one mentioned there which is to just have some code to compare the jog file sizes, because any image with sufficiently different content may have a noticeably different file size. 

    To test this, you could take a photo of an example location, and then add some artificial bugs if none exist, using say photoshot, and then subjecting the images to some of the solutions mentioned at that link, to see what works best. 

    One other approach could be to try a microwave sensor. Sometimes they can detect very slight changes (including vibration of the mount). But it would require experimentation, I have no idea if it would detect a slow-moving bug. There's an example microwave detector article here:

    /technologies/embedded/b/blog/posts/experimenting-with-microwave-based-sensors-for-presence-detection#mcetoc_1h0c077bia

    PIR is unfortunately very unlikely to work, because the amount of heat energy will be tiny, and most PIR sensors need sufficient movement too.

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • beacon_dave
    0 beacon_dave 11 months ago

    If they are localised to the one area and slow-moving, then I would start with Shabaz's suggestion of a simple camera with intervalometer.

    Initially set it to take an image every minute or so and leave it running for a day. Review the captured images by using a photo viewer app that allows you to quickly flick through a folder of images until you find any activity. Or you can turn the image sequence into a video and watch the video which will then playback at the frame rate you encoded at, typically around 30fps.

    If you don't want to tie up an existing camera all day, then perhaps look at a cheap 'nature cam' which usually have intervalometer features.

    You can then reposition the camera as necessary and then reduce the time interval to get more detail.

    The issue you may have is that they may enter the room elsewhere then quickly fly to the location you are seeing them in before they start crawling slowly.

    Comparing file sizes may not work for you here depending on how the light varies, the file compression being used and how much of the image changes. I have successfully used it in the past for detecting the likes of sunrise and sunset though.

    You might have more success with the likes of OpenCV for this.

       Images Comparison with Opencv and Python
       https://www.youtube.com/playlist?list=PL6Yc5OUgcoTlQuAdhtnByty15Ea9-cQly

    If it is to be a longer term project then perhaps a R Pi with camera running OpenCV to automate the process. 

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • BigG
    0 BigG 11 months ago in reply to tonyd512

    You certainly have an interesting challenge on your hand.

    Before thinking of possible solutions I wanted to understand more about your intended sensing locality or proximity to these pesky little bugs. You mentioned that the sensor needs to have short range maybe 3-4 ft or so. How narrow focused does the sensor of choice need to be, or what sort of field of view would you require at 3-4 ft away? Are you intending to keep an eye on monitoring just the hole or crack, for example. If it's a crack, how long are the cracks?

    My thinking is that if these cracks are no more than an inch or two long then you could potentially shrink things down a bit where a sensor is merely a couple of inches away, for example.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • tonyd512
    0 tonyd512 11 months ago in reply to BigG

    Good questions BigG

    I've sealed up the most obvious and straightforward  cracks and holes such as a crack around a window or gap in a door weather stripping. What I need to observe over time is areas that may lead to gaps in the ceiling over kitchen cabinets which might lead to a void between a floor and ceiling, that may lead to a crack in the roofing where they begin their entry. They will follow the longest winding path that you can't believe to get in. It's impossible to tell from the outside since they are all over the house looking for ways to get in. So if I could observe an area about 4 ft away from the camera and around 4 ft of target area that should do it. If set up my camera for about 24 hours and don't see a bug then I move the camera to a different area. Keep in mind it's down to about 15 bugs per day so if they were all getting in the same spot then it would be around 1 per 2 hours, or less if they are getting in more than one spot (very likely!)

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • tonyd512
    0 tonyd512 11 months ago in reply to beacon_dave

    This is a long term project as I have been at it for 2 seasons now (about a year) I will try these image comparison suggestions and see how it works. Since this will be over 24 hr observation period lighting will vary from day to night. I'm guessing I will have to have bright lights on the area to minimize ambient variations.......

    I will post my results after I learn and  experiment with the software solutions. I conclude from all this feedback that a PIR sensor is not practical for this application.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • robogary
    0 robogary 11 months ago

    This sounds like a job for raspberry pi & camera with object recognition ! Pir may not detect a cold bug especially a slow moving one.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • kmikemoo
    0 kmikemoo 11 months ago

    While electronics would be cool, if you can't localize the point of entry based on sightings, I would go with a simpler approach.  They could also be "replicating" inside. Thumbsdown

    You might be able to secure the perimeter of your house with a high fragrance spray.  If they track by pheromones, this will disrupt the trail.  The Dollar Store has a lavender cleaning spray that even I consider a bit over the top.  With the consistency that you have, you could even do zones to further narrow the points of entry.     A long time ago, I lived in sub-standard military housing and we had cockroaches.  One of the ways that we kept them in check was to go visit family.  Clean before you leave.  ZERO food for a few days.  Spray the perimeter immediately upon return - even before unloading the car.  The defensive perimeter worked.
    When we lived in Texas... nothing worked - because they came in through the crawlspace under the house.  Boric acid (powder) and running shoes.  Yup.  I got pretty accurate throwing a sneaker at the cockroaches - a trick I learned living in a rental mobile home in North Carolina.

    My final encouragement is the stick vacuum - with crevice tool.  Any place you find the bugs, vacuum every crevice anywhere near.  Spray with that overpowering lavender spray.  As the shampoo bottle says... lather, rinse, repeat.  Being bald, that's funny to me.  Good luck. Thumbsup

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • tonyd512
    0 tonyd512 11 months ago in reply to kmikemoo

    According to Google they don't breed inside and they don't eat inside, they are just looking for dry place to spend the winter I think. (What can we believe anymore these days!) I think I agree from what I have observed about them.

    Tried all sorts of essential oils (but not lavender) to no avail. I would bet one of the neighbors has tried it tho.....

    Those were funny stories about the roaches.

    There were 3 inch, huge ones, on these merchant ships I worked on in hot climates. Luckily they stayed in humid fan rooms!

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
>
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube