{"product_id":"infrared-counting-sensor-module","title":"Infrared Counting Sensor Module","description":"\u003cp\u003e\u003cspan\u003eCount or detect objects that move through the U-shaped uprights.\u003c\/span\u003e\u003c\/p\u003e\n\u003ch2\u003eDESCRIPTION\u003c\/h2\u003e\n\u003cp\u003eThe Infrared Counting Sensor Module is used to count or detect objects that move through the U-shaped detector uprights.\u003c\/p\u003e\n\u003ch2\u003e\u003cstrong\u003ePACKAGE INCLUDES:\u003c\/strong\u003e\u003c\/h2\u003e\n\u003cul\u003e\n\u003cli\u003eInfrared Counting Sensor Module\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003ch2\u003e\u003cstrong\u003eKEY FEATURES OF INFRARED COUNTING SENSOR MODULE  MODULE:\u003c\/strong\u003e\u003c\/h2\u003e\n\u003cul\u003e\n\u003cli\u003eIR transmitter \/ receiver pair\u003c\/li\u003e\n\u003cli\u003eLM393 comparator circuit for clean detection\u003c\/li\u003e\n\u003cli\u003eLED indicator of detection\u003c\/li\u003e\n\u003cli\u003e3.3 and 5V compatible\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003eThe module has an IR transmitter and receiver pair that face each other across a U-shaped housing.  An object moving through these uprights breaks the IR beam.\u003c\/p\u003e\n\u003cp\u003eThese modules are typically used to count something as it passes through the uprights.  This could be cogs on a wheel if it is counting revolutions or RPM, or something like pellets dropping through a chute if it is part of a feeder for a pellet stove or rabbit.  Another use is as an optical limit switch  or to detect when something is open or closed if it causes an object to move in or out of the beam.\u003c\/p\u003e\n\u003cp\u003eThe sensor output is normally LOW and the red LED on the module will be normally lit.  If the IR beam between the uprights is broken, the output goes HIGH and the LED goes off.\u003c\/p\u003e\n\u003ch3\u003eModule Connections\u003c\/h3\u003e\n\u003cp\u003eThe module has a 3 pin header for making connections.\u003c\/p\u003e\n\u003cp\u003e\u003cstrong\u003e1 x 3 Header \u003c\/strong\u003e\u003c\/p\u003e\n\u003cul\u003e\n\u003cli\u003e\n\u003cstrong\u003eGND\u003c\/strong\u003e\u003cspan\u003e \u003c\/span\u003e– Ground\u003c\/li\u003e\n\u003cli\u003e\n\u003cstrong\u003eOUT\u003c\/strong\u003e\u003cspan\u003e \u003c\/span\u003e– Output, normally LOW.  Goes HIGH when IR beam is broken\u003c\/li\u003e\n\u003cli\u003e\n\u003cstrong\u003eVCC\u003c\/strong\u003e\u003cspan\u003e \u003c\/span\u003e– 3.3 – 5V\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003eThe module has two holes for mounting.\u003c\/p\u003e\n\u003ch2\u003e\u003cstrong\u003eOUR EVALUATION RESULTS:\u003c\/strong\u003e\u003c\/h2\u003e\n\u003cp\u003eWhile this module is similar in functionality to the less expensive Light Block Sensor Module, the Infrared Counting Sensor Module has much higher and wider detector uprights and a LM393 comparator circuit that make it more robust and flexible in applications it can be used in.\u003c\/p\u003e\n\u003cp\u003eThe example program below simply monitors the output of the module and if the beam is broken, it turns the on-board LED on.  It used pin 8 in the example, but this can be changed to any digital input pin.\u003c\/p\u003e\n\u003ch3\u003eInfrared Counting Sensor Module Test Program\u003c\/h3\u003e\n\u003cpre class=\"copy-the-code-target\"\u003e\u003cspan\u003e\/*\u003c\/span\u003e\n\u003cspan\u003eLight Interrupter Sensor Test\u003c\/span\u003e\n\n\u003cspan\u003eMonitor output from sensor module and light the on-board LED when\u003c\/span\u003e\n\u003cspan\u003ean object is blocking the IR beam between the sensor uprights.\u003c\/span\u003e\n\u003cspan\u003e*\/\u003c\/span\u003e\n\u003cspan\u003eint\u003c\/span\u003e \u003cspan\u003esensorPin\u003c\/span\u003e \u003cspan\u003e=\u003c\/span\u003e \u003cspan\u003e8\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e   \u003cspan\u003e\/\/ Can be any digital input pin\u003c\/span\u003e\n\u003cspan\u003eint\u003c\/span\u003e \u003cspan\u003eledPin\u003c\/span\u003e \u003cspan\u003e=\u003c\/span\u003e \u003cspan\u003e13\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e       \u003cspan\u003e\/\/ Pin that on-board LED is connected to\u003c\/span\u003e\n\u003cspan\u003eint\u003c\/span\u003e \u003cspan\u003esensorVal\u003c\/span\u003e \u003cspan\u003e=\u003c\/span\u003e \u003cspan\u003e0\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e  \u003cspan\u003e\/\/ variable to store the value coming from the sensor\u003c\/span\u003e\n\u003cspan\u003e\/\/===============================================================================\u003c\/span\u003e\n\u003cspan\u003e\/\/  Initialization\u003c\/span\u003e\n\u003cspan\u003e\/\/===============================================================================\u003c\/span\u003e\n\u003cspan\u003evoid\u003c\/span\u003e \u003cspan\u003esetup\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e \u003cspan\u003e{\u003c\/span\u003e\n  \u003cspan\u003epinMode\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003eledPin\u003c\/span\u003e\u003cspan\u003e,\u003c\/span\u003e \u003cspan\u003eOUTPUT\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e \u003cspan\u003e\/\/ LED pin as output\u003c\/span\u003e\n  \u003cspan\u003epinMode\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003esensorPin\u003c\/span\u003e\u003cspan\u003e,\u003c\/span\u003e \u003cspan\u003eINPUT\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e \u003cspan\u003e\/\/Sensor pin as input\u003c\/span\u003e\n\u003cspan\u003e}\u003c\/span\u003e\n\u003cspan\u003e\/\/===============================================================================\u003c\/span\u003e\n\u003cspan\u003e\/\/  Main\u003c\/span\u003e\n\u003cspan\u003e\/\/=============================================================================== \u003c\/span\u003e\n\u003cspan\u003evoid\u003c\/span\u003e \u003cspan\u003eloop\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e \u003cspan\u003e{\u003c\/span\u003e\n  \u003cspan\u003esensorVal\u003c\/span\u003e \u003cspan\u003e=\u003c\/span\u003e \u003cspan\u003edigitalRead\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003esensorPin\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e \u003cspan\u003e\/\/read the value of the sensor \u003c\/span\u003e\n  \u003cspan\u003eif\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003esensorVal\u003c\/span\u003e \u003cspan\u003e==\u003c\/span\u003e \u003cspan\u003eHIGH\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e \u003cspan\u003e\/\/ turn on LED when sensor is blocked \u003c\/span\u003e\n  \u003cspan\u003e{\u003c\/span\u003e\n    \u003cspan\u003edigitalWrite\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003eledPin\u003c\/span\u003e\u003cspan\u003e,\u003c\/span\u003e\u003cspan\u003eHIGH\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e\n  \u003cspan\u003e}\u003c\/span\u003e\n  \u003cspan\u003eelse\u003c\/span\u003e\n  \u003cspan\u003e{\u003c\/span\u003e\n    \u003cspan\u003edigitalWrite\u003c\/span\u003e\u003cspan\u003e(\u003c\/span\u003e\u003cspan\u003eledPin\u003c\/span\u003e\u003cspan\u003e,\u003c\/span\u003e\u003cspan\u003eLOW\u003c\/span\u003e\u003cspan\u003e)\u003c\/span\u003e\u003cspan\u003e;\u003c\/span\u003e\n  \u003cspan\u003e}\u003c\/span\u003e\n\u003cspan\u003e}\u003c\/span\u003e\u003cbutton class=\"copy-the-code-button\" data-style=\"svg-icon\" title=\"Copy\"\u003e\u003csvg aria-hidden=\"true\" role=\"img\" class=\"copy-icon\" viewbox=\"0 0 16 16\" width=\"16\" height=\"16\" fill=\"currentColor\" focusable=\"false\"\u003e\u003cpath d=\"M0 6.75C0 5.784.784 5 1.75 5h1.5a.75.75 0 0 1 0 1.5h-1.5a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-1.5a.75.75 0 0 1 1.5 0v1.5A1.75 1.75 0 0 1 9.25 16h-7.5A1.75 1.75 0 0 1 0 14.25Z\"\u003e\u003c\/path\u003e\u003cpath d=\"M5 1.75C5 .784 5.784 0 6.75 0h7.5C15.216 0 16 .784 16 1.75v7.5A1.75 1.75 0 0 1 14.25 11h-7.5A1.75 1.75 0 0 1 5 9.25Zm1.75-.25a.25.25 0 0 0-.25.25v7.5c0 .138.112.25.25.25h7.5a.25.25 0 0 0 .25-.25v-7.5a.25.25 0 0 0-.25-.25Z\"\u003e\u003c\/path\u003e\u003c\/svg\u003e\u003c\/button\u003e\u003c\/pre\u003e\n\u003ch2\u003e\u003cstrong\u003eBEFORE THEY ARE SHIPPED, THESE MODULES ARE:\u003c\/strong\u003e\u003c\/h2\u003e\n\u003cul\u003e\n\u003cli\u003eSample inspected and tested per incoming shipment\u003c\/li\u003e\n\u003c\/ul\u003e\n\u003cp\u003e\u003cem\u003eNotes: \u003c\/em\u003e\u003c\/p\u003e\n\u003col\u003e\n\u003cli\u003e\u003ci\u003eNone\u003c\/i\u003e\u003c\/li\u003e\n\u003c\/ol\u003e\n\u003chr\u003e\n\u003ch2\u003eTECHNICAL SPECIFICATIONS\u003c\/h2\u003e\n\u003ctable class=\"table table-hover\" width=\"1015\"\u003e\n\u003ctbody\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003cstrong\u003eOperating Ratings\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003e Vcc Range\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e3.3-5V\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003e Logic high (Vcc = 5V)\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e\u0026gt; 3.5V\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003eLogic Low\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e\u0026lt; 0.2V\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e \u003cstrong\u003eDimensions\u003c\/strong\u003e\n\u003c\/td\u003e\n\u003ctd width=\"264\"\u003eL x W (PCB)\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e25 x 20mm  (1 x 0.8″)\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003eHeight U-Channel\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e15mm  (0.59″)\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003eH x W (Inside U-Channel)\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e12 x 10mm  (0.47 x 0.39″)\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003eDepth of intrusion into U-Channel to interrupt beam\u003c\/td\u003e\n\u003ctd width=\"229\"\u003e3mm  (0.12″)\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003ctr\u003e\n\u003ctd width=\"145\"\u003e\u003cstrong\u003eCountry of Origin\u003c\/strong\u003e\u003c\/td\u003e\n\u003ctd width=\"264\"\u003e\u003c\/td\u003e\n\u003ctd width=\"229\"\u003eChina\u003c\/td\u003e\n\u003c\/tr\u003e\n\u003c\/tbody\u003e\n\u003c\/table\u003e\n\u003c!----\u003e","brand":"Keszoox","offers":[{"title":"Default Title","offer_id":45681300865259,"sku":"","price":3.22,"currency_code":"USD","in_stock":true}],"thumbnail_url":"\/\/cdn.shopify.com\/s\/files\/1\/0677\/1005\/8731\/files\/Infrared-Counting-Sensor-Module-1.jpg?v=1723006080","url":"https:\/\/keszooxstore.com\/products\/infrared-counting-sensor-module","provider":"Keszoox","version":"1.0","type":"link"}