I am a beginner in electronics,
my project is the following: I am trying to build a simple circuit to switch on and off my garden lights according to the brightness level. More to the point, I'd like the lights to turn on when it's dark and off in the morning.
After much thought and some help I came up with this solution which works fine in extreme situations (very very dark and very very bright)
The problems are the following:
1)According to the NPN 2N3904 datasheet, the max current through the collector should be 100mA am I right? However the load of 32 Ohms needs at least 300mA to work properly (375 should be better). Should I change transistor? If yes, what kind should I use?
2)More importantly, using this schematics in LTSpice I noticed that the transistor starts to drive full current (375mA) as soon as the photoresistor hits the 1K Ohms which is obviously too low in order to light up the lights when the sun sets, how can I tune this parameter? Should I change photoresistor as well? Here below is the LTSpice simulation of the current through the load as R changes
In case you need them, here are the datasheets
Photocell (Photoresistor) https://learn.adafruit.com/downloads/pdf/photocells.pdf