I have problem with my code for Automatic Home Lighting system . Need help!!!

I want to do an project on AUTOMATIC HOME LIGHTING SYSTEM.
Project is to work in such a way that If someone enters a room the light should be ON with that if that person want to turn the light off he can also control that using a bluetooth module (HC-05). And this system will only work when there is no sunlight in order to save energy using LDR.
I have tried to write the code upto the bluetooth module. I have attached the code upto the BLuetooth module I have tired but this is not working well.

So Kindly please help me with a working code for this project.

Thank you so much in advance.

PIR_HC05.ino (1.13 KB)

I would be concerned about a home lightning project!

Thanks for spelling correction. But it will be more helpfull if you the same with the code. :slight_smile: