Skip to content

arabed/motion-night-light

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Motion Night Light

This is a simple motion detect-triggered night light using arduino compatible micro module.

State Machine

The following is the state machine of this device.

---
title: Motion Night Light State Diagram
---
stateDiagram-v2
    state if_light <<choice>>
    state if_motion <<choice>>

    [*] --> Setup
    Setup --> MainLoop
    MainLoop --> if_motion
    if_motion --> MainLoop: No motion detected
    if_motion --> if_light: Motion detected
    if_light --> Leds_ON: NO light (it's night)
    if_light --> Leds_OFF: Light (it's day)
    Leds_ON --> MainLoop    
    Leds_OFF --> MainLoop
Loading

Circuitary

The following diagram is illustrated the electronic componets and the related wiring.

Fell free to change the analog or digital ports as you like. Just remember to modify the code th mach your changes.

draw.io source file here

enclosure

I designed a simple enclosure for this project.

You can find the STL files for front cover here and back cover here.

Reference

The Pro Micro pinout for reference:

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages