{"id":1644,"date":"2019-05-31T02:17:06","date_gmt":"2019-05-30T20:17:06","guid":{"rendered":"https:\/\/us.rs-online.com\/expert\/?p=1644"},"modified":"2021-12-01T08:45:04","modified_gmt":"2021-12-01T14:45:04","slug":"sensor-connections-pnp-versus-npn","status":"publish","type":"post","link":"https:\/\/us.rs-online.com\/expert\/sensor-connections-pnp-versus-npn\/","title":{"rendered":"Sensor Connections: PNP versus NPN and Sourcing versus Sinking"},"content":{"rendered":"<div class=\"wpb-content-wrapper\"><div id=\"tdi_1\" class=\"tdc-row\"><div class=\"vc_row tdi_2  wpb_row td-pb-row\" >\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_2,\r\n                .tdi_2 .tdc-columns{\r\n                    min-height: 0;\r\n                }.tdi_2,\r\n\t\t\t\t.tdi_2 .tdc-columns{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_2 .tdc-columns{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}\n<\/style><div class=\"vc_column tdi_4  wpb_column vc_column_container tdc-column td-pb-span12\">\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_4{\r\n                    vertical-align: baseline;\r\n                }.tdi_4 > .wpb_wrapper,\r\n\t\t\t\t.tdi_4 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_4 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}.tdi_4 > .wpb_wrapper > .vc_row_inner{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t}.tdi_4 > .wpb_wrapper{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t    height: auto;\r\n\t\t\t\t}\n<\/style><div class=\"wpb_wrapper\" >[vc_column_text]<em>Since so many typical industrial automation sensors operate at 24 Vdc, it is important to understand two of the main variations of these solid-state devices.<\/em><\/p>\n<p>Automation systems rely on discrete I\/O signals, such as inputs from <a href=\"https:\/\/us.rs-online.com\/expert\/category\/sensors\/\" target=\"_blank\" rel=\"noopener noreferrer\">sensors<\/a> and outputs to field devices. In some industries, these signals are operated at 120 Vac. A safer and more common option is to use 24 Vdc, and many end users choose devices with plug-and-cord connectors for easy installation and servicing. As it turns out, a little planning is necessary to ensure 24 Vdc sensors and PLC discrete input (DI) modules are connected properly.<\/p>\n<p>The two types of 24 Vdc sensors are called PNP and NPN. These must be correctly matched with sinking and sourcing DI modules in order to function. It isn\u2019t difficult, and in fact there is somewhat of a standard or at least a typical approach, as explained below.<\/p>\n<h2><strong><img loading=\"lazy\" decoding=\"async\" class=\"alignright size-full\" src=\"https:\/\/res.cloudinary.com\/mktg-allied-electronics-automation\/image\/upload\/v1559232454\/Expert%20Advice\/PNP-and-NPN-transistors.jpg\" alt=\"connections for PNP and NPN transistors\" width=\"275\" height=\"216\" \/>Transistor Effects<\/strong><\/h2>\n<p>Solid-state electronics for discrete on\/off sensor applications incorporate <a href=\"https:\/\/www.alliedelec.com\/discrete-semiconductors\/transistors-modules\/\" target=\"_blank\" rel=\"noopener noreferrer\">transistors<\/a>, which are semiconductor devices configured to operate as tiny relays. They amplify a very small signal, such as the position sensing portion of a proximity switch, to turn a larger signal on or off. This larger signal can go to a DI point or an indicating light, or to any other device with an acceptable current rating. Transistors come in two types: PNP, or sourcing, and NPN, or sinking.<\/p>\n<p>For PNP and NPN transistors, \u201cP\u201d and \u201cN\u201d refer to the arrangement of semiconductor materials. Transistors have connections termed as the base, collector and emitter. Fortunately, for industrial automation purposes, it really isn\u2019t necessary to understand semiconductor physics.<\/p>\n<h2><strong>PNP versus NPN Switching<\/strong><\/h2>\n<p>Solid-state devices are active as opposed to passive, and therefore usually require some small amount of operating power. They are typically designed as three-wire devices with leads or connections for:<\/p>\n<ul>\n<li>+24 Vdc<\/li>\n<li>0 Vdc<\/li>\n<li>Switched or sensor signal<\/li>\n<\/ul>\n<p>The +24 Vdc and 0 Vdc wires power the device. PNP or NPN style defines how the sensor operates the switched lead. Here are the two basic things to remember about PNP versus NPN field sensor operation when there is an \u201con\u201d signal:[\/vc_column_text]<\/div><\/div><\/div><\/div><div id=\"tdi_5\" class=\"tdc-row\"><div class=\"vc_row tdi_6  wpb_row td-pb-row\" >\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_6,\r\n                .tdi_6 .tdc-columns{\r\n                    min-height: 0;\r\n                }.tdi_6,\r\n\t\t\t\t.tdi_6 .tdc-columns{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_6 .tdc-columns{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}\n<\/style><div class=\"vc_column tdi_8  wpb_column vc_column_container tdc-column td-pb-span12\">\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_8{\r\n                    vertical-align: baseline;\r\n                }.tdi_8 > .wpb_wrapper,\r\n\t\t\t\t.tdi_8 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_8 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}.tdi_8 > .wpb_wrapper > .vc_row_inner{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t}.tdi_8 > .wpb_wrapper{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t    height: auto;\r\n\t\t\t\t}\n<\/style><div class=\"wpb_wrapper\" >[vc_column_text]<img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full\" src=\"https:\/\/res.cloudinary.com\/mktg-allied-electronics-automation\/image\/upload\/v1559232454\/Expert%20Advice\/PNP_versus_NPN_Sensor_Wiring.jpg\" alt=\"PNP and NPN field devices connected to DI points\" width=\"1097\" height=\"308\" \/>[\/vc_column_text]<\/div><\/div><\/div><\/div><div id=\"tdi_9\" class=\"tdc-row\"><div class=\"vc_row tdi_10  wpb_row td-pb-row\" >\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_10,\r\n                .tdi_10 .tdc-columns{\r\n                    min-height: 0;\r\n                }.tdi_10,\r\n\t\t\t\t.tdi_10 .tdc-columns{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_10 .tdc-columns{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}\n<\/style><div class=\"vc_column tdi_12  wpb_column vc_column_container tdc-column td-pb-span8\">\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_12{\r\n                    vertical-align: baseline;\r\n                }.tdi_12 > .wpb_wrapper,\r\n\t\t\t\t.tdi_12 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_12 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}.tdi_12 > .wpb_wrapper > .vc_row_inner{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t}.tdi_12 > .wpb_wrapper{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t    height: auto;\r\n\t\t\t\t}\n<\/style><div class=\"wpb_wrapper\" >[vc_column_text css=&#8221;.vc_custom_1559241943981{padding-top: 30px !important;}&#8221;]<\/p>\n<h2><strong>Three-Wire Devices and Leakage Current<\/strong><\/h2>\n<p>Many of these three-wire sensors use standard M12 connectors and cordsets. Sometimes more wires are included for extra functions, but always review data sheets for the exact connections.<\/p>\n<p>Leakage current is a term indicating how much current might leak out on the switched lead even if the switch is off. This is usually more of an issue for AC devices than DC devices. However, be aware that a field device with an unusually high leakage current might falsely turn on a DI module with a low input current switching threshold.[\/vc_column_text]<\/div><\/div><div class=\"vc_column tdi_14  wpb_column vc_column_container tdc-column td-pb-span4\">\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_14{\r\n                    vertical-align: baseline;\r\n                }.tdi_14 > .wpb_wrapper,\r\n\t\t\t\t.tdi_14 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_14 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}.tdi_14 > .wpb_wrapper > .vc_row_inner{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t}.tdi_14 > .wpb_wrapper{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t    height: auto;\r\n\t\t\t\t}\n<\/style><div class=\"wpb_wrapper\" >[vc_single_image source=&#8221;external_link&#8221; external_img_size=&#8221;250&#215;173&#8243; alignment=&#8221;center&#8221; css_animation=&#8221;slideInRight&#8221; custom_src=&#8221;https:\/\/res.cloudinary.com\/mktg-allied-electronics-automation\/image\/upload\/v1559233907\/Expert%20Advice\/electronic_M12_sensor_cordset.jpg&#8221; css=&#8221;.vc_custom_1559241986181{padding-top: 40px !important;}&#8221; caption=&#8221;Connectorized M12 cordsets are commonly used with both PNP and NPN sensors&#8221;]<\/div><\/div><\/div><\/div><div id=\"tdi_15\" class=\"tdc-row\"><div class=\"vc_row tdi_16  wpb_row td-pb-row\" >\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_16,\r\n                .tdi_16 .tdc-columns{\r\n                    min-height: 0;\r\n                }.tdi_16,\r\n\t\t\t\t.tdi_16 .tdc-columns{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_16 .tdc-columns{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}\n<\/style><div class=\"vc_column tdi_18  wpb_column vc_column_container tdc-column td-pb-span8\">\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_18{\r\n                    vertical-align: baseline;\r\n                }.tdi_18 > .wpb_wrapper,\r\n\t\t\t\t.tdi_18 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_18 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}.tdi_18 > .wpb_wrapper > .vc_row_inner{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t}.tdi_18 > .wpb_wrapper{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t    height: auto;\r\n\t\t\t\t}\n<\/style><div class=\"wpb_wrapper\" >[vc_column_text]<\/p>\n<h2><strong>Sourcing versus Sinking Circuits<\/strong><\/h2>\n<p>In terms of PLC discrete input (DI) modules, they are available as sinking or sourcing, and some PLCs can be configured either way. The PLC DI type must be complementary (opposite) of the field device type:<\/p>\n<ul>\n<li>A sinking PLC DI is suitable for PNP field sensor devices and looks for +24 Vdc on the DI channel coming from the sensor switched lead to indicate a logical true condition.<\/li>\n<li>A sourcing PLC DI is suitable for NPN field sensor devices and looks for 0 Vdc on the DI channel coming from the sensor switched lead to indicate a logic true condition.<\/li>\n<\/ul>\n<p>Evaluate PLC DI modules carefully and examine their wiring diagrams because sometimes the sinking\/sourcing terminology may be used in an alternate manner. A diagram may state that a DI point is compatible with sourcing field devices, which means the DI point is effectively sinking.<\/p>\n<h2><strong>Benefits of PNP versus NPN<\/strong><\/h2>\n<p>PNP sensors connect +24 Vdc to the switched lead when true, while NPN sensors connect 0 Vdc to the switched lead when true. If a PNP cable is damaged there is a chance the signal could short to ground and damage the sensor. If an NPN cable is damaged there is the chance the signal could short to ground and cause a false true signal, but there would be no damage to the circuit.<\/p>\n<p>Perhaps the major benefit of using PNP instead of NPN is the resulting logic because +24 Vdc=On=True is easier for programmers and technicians to use and troubleshoot than 0 Vdc=On=True.<\/p>\n<h2><strong>It\u2019s an International Issue<\/strong><\/h2>\n<p>Anecdotal investigation indicates that most European and North American designers generally choose PNP sensors combined with sinking PLC DI modules, while Asian countries have tended toward NPN sensors with sourcing PLC DI modules.<\/p>\n<p>Designers should look to the readily available products from their distributors. For instance, those in the US will likely find a much greater variety of PNP sensors. However, it is important to be aware of both product types because end users could find themselves interfacing with or repairing equipment using NPN devices.<\/p>\n<h2><strong>Check the Part Numbers<\/strong><\/h2>\n<p>One final caution is to carefully check the device part numbers. Sometimes, the difference between PNP and NPN is determined by only one character or number. Certain devices may have both capabilities built into them, so they will need to be connected and configured carefully.<\/p>\n<p>The PNP versus NPN discussion is somewhat related to, but not to be confused with, the discussion of normally open versus normally closed contact configurations and control circuits, a topic that will be covered in another article.[\/vc_column_text]<\/div><\/div><div class=\"vc_column tdi_20  wpb_column vc_column_container tdc-column td-pb-span4\">\n<style scoped>\n\/* custom css - generated by TagDiv Composer *\/\n\n\/* custom css - generated by TagDiv Composer *\/\n\/* custom css - generated by TagDiv Composer *\/\n.tdi_20{\r\n                    vertical-align: baseline;\r\n                }.tdi_20 > .wpb_wrapper,\r\n\t\t\t\t.tdi_20 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    display: block;\r\n\t\t\t\t}.tdi_20 > .wpb_wrapper > .tdc-elements{\r\n\t\t\t\t    width: 100%;\r\n\t\t\t\t}.tdi_20 > .wpb_wrapper > .vc_row_inner{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t}.tdi_20 > .wpb_wrapper{\r\n\t\t\t\t    width: auto;\r\n\t\t\t\t    height: auto;\r\n\t\t\t\t}\n<\/style><div class=\"wpb_wrapper\" >[vc_single_image source=&#8221;external_link&#8221; external_img_size=&#8221;250&#215;219&#8243; alignment=&#8221;center&#8221; css_animation=&#8221;slideInRight&#8221; custom_src=&#8221;https:\/\/res.cloudinary.com\/mktg-allied-electronics-automation\/image\/upload\/v1559235989\/Expert%20Advice\/Bipolar_NPN_PNP_Photoelectric_Sensor.jpg&#8221; caption=&#8221;Photoelectric Sensor with Both PNP and NPN&#8221;][vc_single_image source=&#8221;external_link&#8221; external_img_size=&#8221;250&#215;129&#8243; alignment=&#8221;center&#8221; css_animation=&#8221;slideInRight&#8221; custom_src=&#8221;https:\/\/res.cloudinary.com\/mktg-allied-electronics-automation\/image\/upload\/v1559235989\/Expert%20Advice\/8mm_PNP_Inductive_Proximity_Sensor.jpg&#8221; caption=&#8221;Inductive Proximity Sensor with PNP&#8221;][vc_single_image source=&#8221;external_link&#8221; external_img_size=&#8221;250&#215;191&#8243; alignment=&#8221;center&#8221; css_animation=&#8221;slideInRight&#8221; custom_src=&#8221;https:\/\/res.cloudinary.com\/mktg-allied-electronics-automation\/image\/upload\/v1559235989\/Expert%20Advice\/M18_NPN_Capacitive_Proximity_Sensor.jpg&#8221; caption=&#8221;Capacitive Proximity Sensor with NPN&#8221;]<\/div><\/div><\/div><\/div>\n<p><a href=\"https:\/\/www.alliedelec.com\/sensors\/\" target=\"_blank\" rel=\"noopener noreferrer\"><span class=\"td_btn td_btn_md td_default_btn\">Shop Sensors<\/span><\/a><\/p>\n<div style='text-align:left' class='yasr-auto-insert-visitor'><\/div><\/div>","protected":false},"excerpt":{"rendered":"<p>Shop Sensors<\/p>\n","protected":false},"author":14,"featured_media":1655,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"yasr_overall_rating":0,"yasr_post_is_review":"","yasr_auto_insert_disabled":"","yasr_review_type":"Other","_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_hide_featured_image":false,"_jetpack_featured_image_duplicate_dismissed":0,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_post_was_ever_published":false},"categories":[342,331,333,335,340],"tags":[],"class_list":["post-1644","post","type-post","status-publish","format-standard","has-post-thumbnail","category-discrete","category-industrial-communications","category-industrial-control","category-process-control","category-sensing"],"yasr_visitor_votes":{"stars_attributes":{"read_only":false,"span_bottom":false},"number_of_votes":37,"sum_votes":182},"jetpack_sharing_enabled":true,"jetpack_featured_media_url":"https:\/\/res.cloudinary.com\/mktg-allied-electronics-automation\/image\/upload\/v1559232454\/Expert%20Advice\/Industrial_Automation_System_Production_Line.jpg","_links":{"self":[{"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/posts\/1644","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/users\/14"}],"replies":[{"embeddable":true,"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/comments?post=1644"}],"version-history":[{"count":1,"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/posts\/1644\/revisions"}],"predecessor-version":[{"id":2858,"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/posts\/1644\/revisions\/2858"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/media\/1655"}],"wp:attachment":[{"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/media?parent=1644"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/categories?post=1644"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/us.rs-online.com\/expert\/wp-json\/wp\/v2\/tags?post=1644"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}