Final project-coding help

hey guys. for the final project i was thinking of using an ir sensor to detect when the person enters, and when he/ she does i was hoping for the light to switch on. now i am having some trouble as to how do i code this. my question is basically how do i take the input from the ir sensor and send it to my bolt module which later creates an output by switching on the light. any help will be highly appreciated. thanks in advance.

Hi @kunsharora0912

You could use IR sensor at an input pin and see that if the sensor value reaches a certain threshold, it sends the command to send the HIGH signal at a certain pin where you would connect the light.

OMRON has a thermal sensor that can detect stationary thermal objects as opposed to standard PIR motion sensor that only detect motion. The OMRON D6T thermal sensor is able to detect the presence of stationary humans by detecting body heat, and can therefore be used to automatically switch off unnecessary lighting, air conditioning, etc. when people are not present (regardless of whether they move or not).

hi @lankabhedi thanks for the reply and suggestion. but the sensor that you have shared with me is way too expensive and I was hoping to be able to do this by taking the input of the ir sensor such as this one:

to make the project. can you please suggest on how i could do that. thanks.
@vishalvats2000, @akshayan.sinha, @PPV please help me out here.

Works the same as any other sensor. But difference? - It is a digitalRead pin. That is only for 1 & 0 output.

1 Like

I have done similar kind of project, named intrusion detector. You can use arduino board to collect data and send it to bolt iot board and for threshold checking purpose you can write python code for same.