I/O salad ...
		
		
				
				
		
			
				
					Hi, 
The first thing I see is you have mixed inputs and outputs ... 
ex; if PIR = 1 then ... etc.etc. ... and PIR is declared as an output ( possible ... but really surprising here !!! )
same for "lights" ...
Begin by checking all your I/0 declares ... ( 0 for OUTPUT and 1 for Input = simple !!! )
Alain
				
			 
			
		 
			
                        	
		         
			
			************************************************** ***********************
Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
************************************************** ***********************
IF there is the word "Problem" in your question ...
certainly the answer is " RTFM " or " RTFDataSheet " !!!
*****************************************
			
			
		 
	
Bookmarks