

Project Overview
I created a house with a light that gradually turns on if it is dark and an alarm connected to the door that triggers and sends an email if someone enters the house! This project, "Domus-Logic," is a rigorous implementation of Asynchronous Smart-Home Forensics and Multi-Actuator Orchestration. Designed as a comprehensive domestic-automation model, the system utilizes an Arduino Uno to manage both environmental lighting and gateway security. The project explores the sophisticated mapping of ambient photoresistive-transients into deterministic PWM lighting-harmonics, implementing a Blynk-IoT Security Heuristic to establish real-time email telemetry upon unauthorized perimeter breaches. The build emphasizes analog-sensor analytics, solid-state load-switching, and wireless IoT-diagnostics.
Technical Deep-Dive
- Ambient-Photometric & Automation Forensics:
- The Photoresistive Logic-Hub: Utilizing a Light Dependent Resistor (LDR) in a voltage-divider topology (with a 2K resistor) to monitor ambient lux-levels. Forensics involve the measurement of the "Analog-to-Digital Conversion (ADC) Precision"; the system continuously polls the divider-node via
analogRead(). The diagnostics focus on "Illumination-Curve Analytics," translating the 10-bit analog vector into an inverse 8-bitanalogWrite()PWM-signal, thereby orchestrating a seamless, automated fade-in during dusk-transients. - Transistor-Switching Power-Logic: Utilizing an NPN junction-transistor to drive the primary bulb-actuator. Forensics include the verification of the "Collector-Emitter Saturation"; the Arduino's low-current logic-pin manipulates the base-current, effectively isolating the high-current photometric-load from the delicate microcontroller bus.
- The Photoresistive Logic-Hub: Utilizing a Light Dependent Resistor (LDR) in a voltage-divider topology (with a 2K resistor) to monitor ambient lux-levels. Forensics involve the measurement of the "Analog-to-Digital Conversion (ADC) Precision"; the system continuously polls the divider-node via
- IoT-Security & Perimeter Diagnostics:
- Magnetic Contact-Sensor (Reed Switch) Node: Establishing a binary logic-gate on the model's primary entryway. Forensics focus on "Contact-Bounce Mitigation," ensuring that the
digitalRead()function registers a clean '0' state when the perimeter is secure, and a definitive '1' upon breach-diagnostics.
- Blynk-IoT Email Telemetry: Integrating the Blynk middleware platform. The diagnostics focus on "Network-Handshake Latency"; upon registering a breach-vector, the system leverages the Blynk Email-Widget to transmit an asynchronous alert-payload, demonstrating professional-grade remote security forensics.
- Magnetic Contact-Sensor (Reed Switch) Node: Establishing a binary logic-gate on the model's primary entryway. Forensics focus on "Contact-Bounce Mitigation," ensuring that the
Step 1: Make the circuit

Use my Fritzing file to copy the circuit I realized. You will need:
- LED
- buzz
- bulb
You can add a potenziometer (for buzz volume) and everything you'd like! Upload the casa.ino file into your board!
Engineering & Implementation
- Circuit-Topology & Substrate Forensics:
- Multi-Modal Indicator Analytics: Integrating a piezo-buzzer alongside the IoT-telemetry. Forensics include the measurement of "Aural-Alert Persistence," providing immediate, localized sound-pressure diagnostics simultaneous with the remote email-transmission.
- Fritzing-Model Fidelity: Utilizing Fritzing CAD heuristics for circuit-layout. Forensics focus on "Bus-Routing Integrity," ensuring interference-free operation between the analog LDR-node and the digital security-node.
- System-Logic & Workflow Heuristics:
- The implementation demonstrates a "Holistic Automation Aesthetic," fusing closed-loop environmental-control (lighting) with open-loop event-driven telemetry (security). Forensics include the measurement of the "Instruction-Cycle Interleaved-Latency," absolute for managing simultaneous analog-PWM and IoT-network operations.
Step 2: Set the light

On my file is already done!
Link a bulb lamp to a transistor and the transistor with one of your Arduino's pin. Create a circuit with a 2K resistence and a fotoresistence, this is useful to read the voltage in the connection of two resistence.
Done! The lamp turns on in the dark! I did analogRead from fotoresistence and then analogWrite to transistor!
Step 3: Set the alarm




Download Blynk app! (http://www.blynk.cc/)
Create a circuit with a push button, and a contact sensor for the door: when the door is closed digitalRead(button) should be 0! Create an email widget on the app! It's done! My code sends an email when the door's open!
Conclusion
Domus-Logic represents the pinnacle of Asynchronous Smart-Home Diagnostics. By mastering Photoresistive Forensics and IoT-Telemetry Heuristics, this project delivers a robust, professional-grade automation framework that provides absolute domestic-clarity through sophisticated multi-modal diagnostics.