Turn On/Off sensors power using PNP transistor

Started by jamithaawawn, February 27, 2016, 09:57:07 AM

jamithaawawn

Hello,

I cannot turn On and Off two STH10 sensors with an Arduino and two PNP transistors.  Using STH1X library, each sensor has its own clock and data pins on Arduino as well as a digital output pin that is used to control the PNP's base. This control pin is set high to turn off the sensor and low to turn on.

The schematic for each sensor connection attached here is based on the discussion in forum: https://lowpowerlab.com/forum/index.php/topic,896.0.html.
STH10 Sensor datasheet http://www.tme.eu/gb/Document/da31bc9c3d5630a360f87dcb7145cc83/sht1.pdf
BC558B Transistor datasheet javascript:openreq('http://pdf.datasheetcatalog.com/datasheet2/b/0ftqtsk05hl545ardkhr41fur27y.pdf')

Can someone please tell what I am missing or doing wrong?

Many thanks.

TomWS

Quote from: jamithaawawn on February 27, 2016, 09:57:07 AM
Hello,

I cannot turn On and Off two STH10 sensors with an Arduino and two PNP transistors.  Using STH1X library, each sensor has its own clock and data pins on Arduino as well as a digital output pin that is used to control the PNP's base. This control pin is set high to turn off the sensor and low to turn on.

The schematic for each sensor connection attached here is based on the discussion in forum: https://lowpowerlab.com/forum/index.php/topic,896.0.html.
STH10 Sensor datasheet http://www.tme.eu/gb/Document/da31bc9c3d5630a360f87dcb7145cc83/sht1.pdf
BC558B Transistor datasheet javascript:openreq('http://pdf.datasheetcatalog.com/datasheet2/b/0ftqtsk05hl545ardkhr41fur27y.pdf')

Can someone please tell what I am missing or doing wrong?

Many thanks.
The correct wiring for a PNP switch is shown in the PDF included with https://lowpowerlab.com/forum/index.php/topic,896.msg6016.html#msg6016


jamithaawawn

Quote
The correct wiring for a PNP switch is shown in the PDF included with https://lowpowerlab.com/forum/index.php/topic,896.msg6016.html#msg6016

Thanks TomWS for the link.

My schematic attached in the first post is based on yours.
And here's just to make sure if I get the wiring right:

Transistor Emitter pin to Sensor power pin
Transistor Base pin to Base resistor (2.2KΩ), which is connected to a control pin on the Arduino
Transistor Collector pin to Power supply (5V)
Sensor GND pin to circuit GND

For the programming:

Set control pin to low to turn on the sensor
Set control pin to high to turn off the sensor




TomWS

Quote from: jamithaawawn on February 27, 2016, 11:10:03 AM
Quote
The correct wiring for a PNP switch is shown in the PDF included with https://lowpowerlab.com/forum/index.php/topic,896.msg6016.html#msg6016

Thanks TomWS for the link.

My schematic attached in the first post is based on yours.
And here's just to make sure if I get the wiring right:

Transistor Emitter pin to Sensor power pin
Transistor Base pin to Base resistor (2.2KΩ), which is connected to a control pin on the Arduino
Transistor Collector pin to Power supply (5V)
Sensor GND pin to circuit GND

For the programming:

Set control pin to low to turn on the sensor
Set control pin to high to turn off the sensor
My apologies, I didn't notice that you had included a schematic in your first posting.  The schematic that you included in the first posting is correct, EXCEPT, you need a 10K pull up resistor on the SH1X data line.  This pullup resistor SHOULD be tied to the SH1X power line rather than 5V so that is switched as well. 

Your description of the schematic, however, is incorrect.  In your original schematic and in mine, the Emitter is connected to the power supply and the collector is connected to the Sensor Power pin.  Here is a reliable source of datasheet for the BC558: https://www.fairchildsemi.com/datasheets/BC/BC557.pdf

Tom