From fe99a96406b294282622cc1c3af2e2f3ae1c8ad5 Mon Sep 17 00:00:00 2001 From: tuxmain Date: Thu, 1 Sep 2022 15:53:01 +0200 Subject: [PATCH] Initial commit --- .gitignore | 1 + README.md | 30 + alarmclock/alarmclock.kicad_pcb | 2 + alarmclock/alarmclock.kicad_prl | 75 ++ alarmclock/alarmclock.kicad_pro | 326 +++++++ alarmclock/alarmclock.kicad_sch | 1509 +++++++++++++++++++++++++++++++ matrixclock/matrixclock.ino | 233 +++++ 7 files changed, 2176 insertions(+) create mode 100644 .gitignore create mode 100644 README.md create mode 100644 alarmclock/alarmclock.kicad_pcb create mode 100644 alarmclock/alarmclock.kicad_prl create mode 100644 alarmclock/alarmclock.kicad_pro create mode 100644 alarmclock/alarmclock.kicad_sch create mode 100644 matrixclock/matrixclock.ino diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f305ecc --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/alarmclock/alarmclock-backups diff --git a/README.md b/README.md new file mode 100644 index 0000000..3d45aa5 --- /dev/null +++ b/README.md @@ -0,0 +1,30 @@ +# Alarm clock + +Arduino alarm clock with binary matrix LED display and IR remote control. + +## Features + +* 8×8 LED display using two 74HC595N +* hour-minute-second binary display +* buzzer alarm +* IR remote control for settings and stopping alarm +* big pushbutton for stopping alarm +* light sensor for dimming display + +## TODO + +* supercapacitor & low-voltage detection +* casing +* multiple alarms +* better LED dimming (maybe use PWM on 74HC's OE) +* date (at least weekday) +* connection with online timetable? +* progressive alarm ringing + +## License + +GNU AGPL v3, CopyLeft 2022 Pascal Engélibert + +This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, version 3 of the License. +This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details. +You should have received a copy of the GNU Affero General Public License along with this program. If not, see https://www.gnu.org/licenses/. diff --git a/alarmclock/alarmclock.kicad_pcb b/alarmclock/alarmclock.kicad_pcb new file mode 100644 index 0000000..28b47a1 --- /dev/null +++ b/alarmclock/alarmclock.kicad_pcb @@ -0,0 +1,2 @@ +(kicad_pcb (version 20211014) (generator pcbnew) +) \ No newline at end of file diff --git a/alarmclock/alarmclock.kicad_prl b/alarmclock/alarmclock.kicad_prl new file mode 100644 index 0000000..40666a6 --- /dev/null +++ b/alarmclock/alarmclock.kicad_prl @@ -0,0 +1,75 @@ +{ + "board": { + "active_layer": 0, + "active_layer_preset": "", + "auto_track_width": true, + "hidden_nets": [], + "high_contrast_mode": 0, + "net_color_mode": 1, + "opacity": { + "pads": 1.0, + "tracks": 1.0, + "vias": 1.0, + "zones": 0.6 + }, + "ratsnest_display_mode": 0, + "selection_filter": { + "dimensions": true, + "footprints": true, + "graphics": true, + "keepouts": true, + "lockedItems": true, + "otherItems": true, + "pads": true, + "text": true, + "tracks": true, + "vias": true, + "zones": true + }, + "visible_items": [ + 0, + 1, + 2, + 3, + 4, + 5, + 8, + 9, + 10, + 11, + 12, + 13, + 14, + 15, + 16, + 17, + 18, + 19, + 20, + 21, + 22, + 23, + 24, + 25, + 26, + 27, + 28, + 29, + 30, + 32, + 33, + 34, + 35, + 36 + ], + "visible_layers": "fffffff_ffffffff", + "zone_display_mode": 0 + }, + "meta": { + "filename": "alarmclock.kicad_prl", + "version": 3 + }, + "project": { + "files": [] + } +} diff --git a/alarmclock/alarmclock.kicad_pro b/alarmclock/alarmclock.kicad_pro new file mode 100644 index 0000000..e1ba2b4 --- /dev/null +++ b/alarmclock/alarmclock.kicad_pro @@ -0,0 +1,326 @@ +{ + "board": { + "design_settings": { + "defaults": { + "board_outline_line_width": 0.1, + "copper_line_width": 0.2, + "copper_text_size_h": 1.5, + "copper_text_size_v": 1.5, + "copper_text_thickness": 0.3, + "other_line_width": 0.15, + "silk_line_width": 0.15, + "silk_text_size_h": 1.0, + "silk_text_size_v": 1.0, + "silk_text_thickness": 0.15 + }, + "diff_pair_dimensions": [], + "drc_exclusions": [], + "rules": { + "min_copper_edge_clearance": 0.0, + "solder_mask_clearance": 0.0, + "solder_mask_min_width": 0.0 + }, + "track_widths": [], + "via_dimensions": [] + }, + "layer_presets": [] + }, + "boards": [], + "cvpcb": { + "equivalence_files": [] + }, + "erc": { + "erc_exclusions": [], + "meta": { + "version": 0 + }, + "pin_map": [ + [ + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 0, + 0, + 0, + 0, + 2 + ], + [ + 0, + 2, + 0, + 1, + 0, + 0, + 1, + 0, + 2, + 2, + 2, + 2 + ], + [ + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 0, + 1, + 0, + 1, + 2 + ], + [ + 0, + 1, + 0, + 0, + 0, + 0, + 1, + 1, + 2, + 1, + 1, + 2 + ], + [ + 0, + 0, + 0, + 0, + 0, + 0, + 1, + 0, + 0, + 0, + 0, + 2 + ], + [ + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 0, + 2 + ], + [ + 1, + 1, + 1, + 1, + 1, + 0, + 1, + 1, + 1, + 1, + 1, + 2 + ], + [ + 0, + 0, + 0, + 1, + 0, + 0, + 1, + 0, + 0, + 0, + 0, + 2 + ], + [ + 0, + 2, + 1, + 2, + 0, + 0, + 1, + 0, + 2, + 2, + 2, + 2 + ], + [ + 0, + 2, + 0, + 1, + 0, + 0, + 1, + 0, + 2, + 0, + 0, + 2 + ], + [ + 0, + 2, + 1, + 1, + 0, + 0, + 1, + 0, + 2, + 0, + 0, + 2 + ], + [ + 2, + 2, + 2, + 2, + 2, + 2, + 2, + 2, + 2, + 2, + 2, + 2 + ] + ], + "rule_severities": { + "bus_definition_conflict": "error", + "bus_entry_needed": "error", + "bus_label_syntax": "error", + "bus_to_bus_conflict": "error", + "bus_to_net_conflict": "error", + "different_unit_footprint": "error", + "different_unit_net": "error", + "duplicate_reference": "error", + "duplicate_sheet_names": "error", + "extra_units": "error", + "global_label_dangling": "warning", + "hier_label_mismatch": "error", + "label_dangling": "error", + "lib_symbol_issues": "warning", + "multiple_net_names": "warning", + "net_not_bus_member": "warning", + "no_connect_connected": "warning", + "no_connect_dangling": "warning", + "pin_not_connected": "error", + "pin_not_driven": "error", + "pin_to_pin": "warning", + "power_pin_not_driven": "error", + "similar_labels": "warning", + "unannotated": "error", + "unit_value_mismatch": "error", + "unresolved_variable": "error", + "wire_dangling": "error" + } + }, + "libraries": { + "pinned_footprint_libs": [], + "pinned_symbol_libs": [] + }, + "meta": { + "filename": "alarmclock.kicad_pro", + "version": 1 + }, + "net_settings": { + "classes": [ + { + "bus_width": 12.0, + "clearance": 0.2, + "diff_pair_gap": 0.25, + "diff_pair_via_gap": 0.25, + "diff_pair_width": 0.2, + "line_style": 0, + "microvia_diameter": 0.3, + "microvia_drill": 0.1, + "name": "Default", + "pcb_color": "rgba(0, 0, 0, 0.000)", + "schematic_color": "rgba(0, 0, 0, 0.000)", + "track_width": 0.25, + "via_diameter": 0.8, + "via_drill": 0.4, + "wire_width": 6.0 + } + ], + "meta": { + "version": 2 + }, + "net_colors": null + }, + "pcbnew": { + "last_paths": { + "gencad": "", + "idf": "", + "netlist": "", + "specctra_dsn": "", + "step": "", + "vrml": "" + }, + "page_layout_descr_file": "" + }, + "schematic": { + "annotate_start_num": 0, + "drawing": { + "default_line_thickness": 6.0, + "default_text_size": 50.0, + "field_names": [], + "intersheets_ref_own_page": false, + "intersheets_ref_prefix": "", + "intersheets_ref_short": false, + "intersheets_ref_show": false, + "intersheets_ref_suffix": "", + "junction_size_choice": 3, + "label_size_ratio": 0.375, + "pin_symbol_size": 25.0, + "text_offset_ratio": 0.15 + }, + "legacy_lib_dir": "", + "legacy_lib_list": [], + "meta": { + "version": 1 + }, + "net_format_name": "", + "ngspice": { + "fix_include_paths": true, + "fix_passive_vals": false, + "meta": { + "version": 0 + }, + "model_mode": 0, + "workbook_filename": "" + }, + "page_layout_descr_file": "", + "plot_directory": "", + "spice_adjust_passive_values": false, + "spice_external_command": "spice \"%I\"", + "subpart_first_id": 65, + "subpart_id_separator": 0 + }, + "sheets": [ + [ + "31f0e89d-6653-4742-b71a-b6b31bd0b8fd", + "" + ] + ], + "text_variables": {} +} diff --git a/alarmclock/alarmclock.kicad_sch b/alarmclock/alarmclock.kicad_sch new file mode 100644 index 0000000..92a48af --- /dev/null +++ b/alarmclock/alarmclock.kicad_sch @@ -0,0 +1,1509 @@ +(kicad_sch (version 20211123) (generator eeschema) + + (uuid 31f0e89d-6653-4742-b71a-b6b31bd0b8fd) + + (paper "A4") + + (lib_symbols + (symbol "74xx:74HC595" (in_bom yes) (on_board yes) + (property "Reference" "U" (id 0) (at -7.62 13.97 0) + (effects (font (size 1.27 1.27))) + ) + (property "Value" "74HC595" (id 1) (at -7.62 -16.51 0) + (effects (font (size 1.27 1.27))) + ) + (property "Footprint" "" (id 2) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "http://www.ti.com/lit/ds/symlink/sn74hc595.pdf" (id 3) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "HCMOS SR 3State" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "8-bit serial in/out Shift Register 3-State Outputs" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_fp_filters" "DIP*W7.62mm* SOIC*3.9x9.9mm*P1.27mm* TSSOP*4.4x5mm*P0.65mm* SOIC*5.3x10.2mm*P1.27mm* SOIC*7.5x10.3mm*P1.27mm*" (id 6) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "74HC595_1_0" + (pin tri_state line (at 10.16 7.62 180) (length 2.54) + (name "QB" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + (pin input line (at -10.16 2.54 0) (length 2.54) + (name "~{SRCLR}" (effects (font (size 1.27 1.27)))) + (number "10" (effects (font (size 1.27 1.27)))) + ) + (pin input line (at -10.16 5.08 0) (length 2.54) + (name "SRCLK" (effects (font (size 1.27 1.27)))) + (number "11" (effects (font (size 1.27 1.27)))) + ) + (pin input line (at -10.16 -2.54 0) (length 2.54) + (name "RCLK" (effects (font (size 1.27 1.27)))) + (number "12" (effects (font (size 1.27 1.27)))) + ) + (pin input line (at -10.16 -5.08 0) (length 2.54) + (name "~{OE}" (effects (font (size 1.27 1.27)))) + (number "13" (effects (font (size 1.27 1.27)))) + ) + (pin input line (at -10.16 10.16 0) (length 2.54) + (name "SER" (effects (font (size 1.27 1.27)))) + (number "14" (effects (font (size 1.27 1.27)))) + ) + (pin tri_state line (at 10.16 10.16 180) (length 2.54) + (name "QA" (effects (font (size 1.27 1.27)))) + (number "15" (effects (font (size 1.27 1.27)))) + ) + (pin power_in line (at 0 15.24 270) (length 2.54) + (name "VCC" (effects (font (size 1.27 1.27)))) + (number "16" (effects (font (size 1.27 1.27)))) + ) + (pin tri_state line (at 10.16 5.08 180) (length 2.54) + (name "QC" (effects (font (size 1.27 1.27)))) + (number "2" (effects (font (size 1.27 1.27)))) + ) + (pin tri_state line (at 10.16 2.54 180) (length 2.54) + (name "QD" (effects (font (size 1.27 1.27)))) + (number "3" (effects (font (size 1.27 1.27)))) + ) + (pin tri_state line (at 10.16 0 180) (length 2.54) + (name "QE" (effects (font (size 1.27 1.27)))) + (number "4" (effects (font (size 1.27 1.27)))) + ) + (pin tri_state line (at 10.16 -2.54 180) (length 2.54) + (name "QF" (effects (font (size 1.27 1.27)))) + (number "5" (effects (font (size 1.27 1.27)))) + ) + (pin tri_state line (at 10.16 -5.08 180) (length 2.54) + (name "QG" (effects (font (size 1.27 1.27)))) + (number "6" (effects (font (size 1.27 1.27)))) + ) + (pin tri_state line (at 10.16 -7.62 180) (length 2.54) + (name "QH" (effects (font (size 1.27 1.27)))) + (number "7" (effects (font (size 1.27 1.27)))) + ) + (pin power_in line (at 0 -17.78 90) (length 2.54) + (name "GND" (effects (font (size 1.27 1.27)))) + (number "8" (effects (font (size 1.27 1.27)))) + ) + (pin output line (at 10.16 -12.7 180) (length 2.54) + (name "QH'" (effects (font (size 1.27 1.27)))) + (number "9" (effects (font (size 1.27 1.27)))) + ) + ) + (symbol "74HC595_1_1" + (rectangle (start -7.62 12.7) (end 7.62 -15.24) + (stroke (width 0.254) (type default) (color 0 0 0 0)) + (fill (type background)) + ) + ) + ) + (symbol "Device:Buzzer" (pin_names (offset 0.0254) hide) (in_bom yes) (on_board yes) + (property "Reference" "BZ" (id 0) (at 3.81 1.27 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Value" "Buzzer" (id 1) (at 3.81 -1.27 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Footprint" "" (id 2) (at -0.635 2.54 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at -0.635 2.54 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "quartz resonator ceramic" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "Buzzer, polarized" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_fp_filters" "*Buzzer*" (id 6) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "Buzzer_0_1" + (arc (start 0 -3.175) (mid 3.175 0) (end 0 3.175) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -1.651 1.905) + (xy -1.143 1.905) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -1.397 2.159) + (xy -1.397 1.651) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 0 3.175) + (xy 0 -3.175) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + ) + (symbol "Buzzer_1_1" + (pin passive line (at -2.54 2.54 0) (length 2.54) + (name "-" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + (pin passive line (at -2.54 -2.54 0) (length 2.54) + (name "+" (effects (font (size 1.27 1.27)))) + (number "2" (effects (font (size 1.27 1.27)))) + ) + ) + ) + (symbol "Device:R" (pin_numbers hide) (pin_names (offset 0)) (in_bom yes) (on_board yes) + (property "Reference" "R" (id 0) (at 2.032 0 90) + (effects (font (size 1.27 1.27))) + ) + (property "Value" "R" (id 1) (at 0 0 90) + (effects (font (size 1.27 1.27))) + ) + (property "Footprint" "" (id 2) (at -1.778 0 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "R res resistor" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "Resistor" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_fp_filters" "R_*" (id 6) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "R_0_1" + (rectangle (start -1.016 -2.54) (end 1.016 2.54) + (stroke (width 0.254) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + ) + (symbol "R_1_1" + (pin passive line (at 0 3.81 270) (length 1.27) + (name "~" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + (pin passive line (at 0 -3.81 90) (length 1.27) + (name "~" (effects (font (size 1.27 1.27)))) + (number "2" (effects (font (size 1.27 1.27)))) + ) + ) + ) + (symbol "Interface_Optical:TSOP32S40F" (pin_names (offset 1.016)) (in_bom yes) (on_board yes) + (property "Reference" "U" (id 0) (at -10.16 7.62 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Value" "TSOP32S40F" (id 1) (at -10.16 -7.62 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Footprint" "OptoDevice:Vishay_MOLD-3Pin" (id 2) (at -1.27 -9.525 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "http://www.vishay.com/docs/82669/tsop32s40f.pdf" (id 3) (at 16.51 7.62 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "opto IR receiver" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "IR Receiver Modules for Remote Control Systems" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_fp_filters" "Vishay*MOLD*" (id 6) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "TSOP32S40F_0_0" + (arc (start -10.287 1.397) (mid -11.0899 -0.1852) (end -10.287 -1.778) + (stroke (width 0.254) (type default) (color 0 0 0 0)) + (fill (type background)) + ) + (polyline + (pts + (xy 1.905 -5.08) + (xy 0.127 -5.08) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.905 5.08) + (xy 0.127 5.08) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (text "DEMOD" (at -3.175 0.254 900) + (effects (font (size 1.524 1.524))) + ) + ) + (symbol "TSOP32S40F_0_1" + (rectangle (start -6.096 5.588) (end 0.127 -5.588) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -8.763 0.381) + (xy -9.652 1.27) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -8.763 0.381) + (xy -9.271 0.381) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -8.763 0.381) + (xy -8.763 0.889) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -8.636 -0.635) + (xy -9.525 0.254) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -8.636 -0.635) + (xy -9.144 -0.635) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -8.636 -0.635) + (xy -8.636 -0.127) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -8.382 -1.016) + (xy -6.731 -1.016) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.27 -2.921) + (xy 0.127 -2.921) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.27 -1.905) + (xy 1.27 -3.81) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.397 -3.556) + (xy 1.524 -3.556) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.651 -3.556) + (xy 1.524 -3.556) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.651 -3.556) + (xy 1.651 -3.302) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.905 0) + (xy 1.905 1.27) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.905 4.445) + (xy 1.905 5.08) + (xy 2.54 5.08) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -8.382 0.635) + (xy -6.731 0.635) + (xy -7.62 -1.016) + (xy -8.382 0.635) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type outline)) + ) + (polyline + (pts + (xy -6.096 1.397) + (xy -7.62 1.397) + (xy -7.62 -1.778) + (xy -6.096 -1.778) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.27 -3.175) + (xy 1.905 -3.81) + (xy 1.905 -5.08) + (xy 2.54 -5.08) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 1.27 -2.54) + (xy 1.905 -1.905) + (xy 1.905 0) + (xy 2.54 0) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (rectangle (start 2.54 1.27) (end 1.27 4.445) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (rectangle (start 7.62 6.35) (end -10.16 -6.35) + (stroke (width 0.254) (type default) (color 0 0 0 0)) + (fill (type background)) + ) + ) + (symbol "TSOP32S40F_1_1" + (pin output line (at 10.16 0 180) (length 2.54) + (name "OUT" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + (pin power_in line (at 10.16 5.08 180) (length 2.54) + (name "Vs" (effects (font (size 1.27 1.27)))) + (number "2" (effects (font (size 1.27 1.27)))) + ) + (pin power_in line (at 10.16 -5.08 180) (length 2.54) + (name "GND" (effects (font (size 1.27 1.27)))) + (number "3" (effects (font (size 1.27 1.27)))) + ) + ) + ) + (symbol "MCU_Module:Arduino_UNO_R3" (in_bom yes) (on_board yes) + (property "Reference" "A" (id 0) (at -10.16 23.495 0) + (effects (font (size 1.27 1.27)) (justify left bottom)) + ) + (property "Value" "Arduino_UNO_R3" (id 1) (at 5.08 -26.67 0) + (effects (font (size 1.27 1.27)) (justify left top)) + ) + (property "Footprint" "Module:Arduino_UNO_R3" (id 2) (at 0 0 0) + (effects (font (size 1.27 1.27) italic) hide) + ) + (property "Datasheet" "https://www.arduino.cc/en/Main/arduinoBoardUno" (id 3) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "Arduino UNO R3 Microcontroller Module Atmel AVR USB" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "Arduino UNO Microcontroller Module, release 3" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_fp_filters" "Arduino*UNO*R3*" (id 6) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "Arduino_UNO_R3_0_1" + (rectangle (start -10.16 22.86) (end 10.16 -25.4) + (stroke (width 0.254) (type default) (color 0 0 0 0)) + (fill (type background)) + ) + ) + (symbol "Arduino_UNO_R3_1_1" + (pin no_connect line (at -10.16 -20.32 0) (length 2.54) hide + (name "NC" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at 12.7 -2.54 180) (length 2.54) + (name "A1" (effects (font (size 1.27 1.27)))) + (number "10" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at 12.7 -5.08 180) (length 2.54) + (name "A2" (effects (font (size 1.27 1.27)))) + (number "11" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at 12.7 -7.62 180) (length 2.54) + (name "A3" (effects (font (size 1.27 1.27)))) + (number "12" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at 12.7 -10.16 180) (length 2.54) + (name "SDA/A4" (effects (font (size 1.27 1.27)))) + (number "13" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at 12.7 -12.7 180) (length 2.54) + (name "SCL/A5" (effects (font (size 1.27 1.27)))) + (number "14" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 15.24 0) (length 2.54) + (name "D0/RX" (effects (font (size 1.27 1.27)))) + (number "15" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 12.7 0) (length 2.54) + (name "D1/TX" (effects (font (size 1.27 1.27)))) + (number "16" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 10.16 0) (length 2.54) + (name "D2" (effects (font (size 1.27 1.27)))) + (number "17" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 7.62 0) (length 2.54) + (name "D3" (effects (font (size 1.27 1.27)))) + (number "18" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 5.08 0) (length 2.54) + (name "D4" (effects (font (size 1.27 1.27)))) + (number "19" (effects (font (size 1.27 1.27)))) + ) + (pin output line (at 12.7 10.16 180) (length 2.54) + (name "IOREF" (effects (font (size 1.27 1.27)))) + (number "2" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 2.54 0) (length 2.54) + (name "D5" (effects (font (size 1.27 1.27)))) + (number "20" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 0 0) (length 2.54) + (name "D6" (effects (font (size 1.27 1.27)))) + (number "21" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 -2.54 0) (length 2.54) + (name "D7" (effects (font (size 1.27 1.27)))) + (number "22" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 -5.08 0) (length 2.54) + (name "D8" (effects (font (size 1.27 1.27)))) + (number "23" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 -7.62 0) (length 2.54) + (name "D9" (effects (font (size 1.27 1.27)))) + (number "24" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 -10.16 0) (length 2.54) + (name "D10" (effects (font (size 1.27 1.27)))) + (number "25" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 -12.7 0) (length 2.54) + (name "D11" (effects (font (size 1.27 1.27)))) + (number "26" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 -15.24 0) (length 2.54) + (name "D12" (effects (font (size 1.27 1.27)))) + (number "27" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at -12.7 -17.78 0) (length 2.54) + (name "D13" (effects (font (size 1.27 1.27)))) + (number "28" (effects (font (size 1.27 1.27)))) + ) + (pin power_in line (at -2.54 -27.94 90) (length 2.54) + (name "GND" (effects (font (size 1.27 1.27)))) + (number "29" (effects (font (size 1.27 1.27)))) + ) + (pin input line (at 12.7 15.24 180) (length 2.54) + (name "~{RESET}" (effects (font (size 1.27 1.27)))) + (number "3" (effects (font (size 1.27 1.27)))) + ) + (pin input line (at 12.7 5.08 180) (length 2.54) + (name "AREF" (effects (font (size 1.27 1.27)))) + (number "30" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at 12.7 -17.78 180) (length 2.54) + (name "SDA/A4" (effects (font (size 1.27 1.27)))) + (number "31" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at 12.7 -20.32 180) (length 2.54) + (name "SCL/A5" (effects (font (size 1.27 1.27)))) + (number "32" (effects (font (size 1.27 1.27)))) + ) + (pin power_out line (at 2.54 25.4 270) (length 2.54) + (name "3V3" (effects (font (size 1.27 1.27)))) + (number "4" (effects (font (size 1.27 1.27)))) + ) + (pin power_out line (at 5.08 25.4 270) (length 2.54) + (name "+5V" (effects (font (size 1.27 1.27)))) + (number "5" (effects (font (size 1.27 1.27)))) + ) + (pin power_in line (at 0 -27.94 90) (length 2.54) + (name "GND" (effects (font (size 1.27 1.27)))) + (number "6" (effects (font (size 1.27 1.27)))) + ) + (pin power_in line (at 2.54 -27.94 90) (length 2.54) + (name "GND" (effects (font (size 1.27 1.27)))) + (number "7" (effects (font (size 1.27 1.27)))) + ) + (pin power_in line (at -2.54 25.4 270) (length 2.54) + (name "VIN" (effects (font (size 1.27 1.27)))) + (number "8" (effects (font (size 1.27 1.27)))) + ) + (pin bidirectional line (at 12.7 0 180) (length 2.54) + (name "A0" (effects (font (size 1.27 1.27)))) + (number "9" (effects (font (size 1.27 1.27)))) + ) + ) + ) + (symbol "Sensor_Optical:LDR07" (pin_numbers hide) (pin_names (offset 0)) (in_bom yes) (on_board yes) + (property "Reference" "R" (id 0) (at -5.08 0 90) + (effects (font (size 1.27 1.27))) + ) + (property "Value" "LDR07" (id 1) (at 1.905 0 90) + (effects (font (size 1.27 1.27)) (justify top)) + ) + (property "Footprint" "OptoDevice:R_LDR_5.1x4.3mm_P3.4mm_Vertical" (id 2) (at 4.445 0 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "http://www.tme.eu/de/Document/f2e3ad76a925811312d226c31da4cd7e/LDR07.pdf" (id 3) (at 0 -1.27 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "light dependent photo resistor LDR" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "light dependent resistor" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_fp_filters" "R*LDR*5.1x4.3mm*P3.4mm*" (id 6) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "LDR07_0_1" + (rectangle (start -1.016 2.54) (end 1.016 -2.54) + (stroke (width 0.254) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -1.524 -2.286) + (xy -4.064 0.254) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -1.524 -2.286) + (xy -2.286 -2.286) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -1.524 -2.286) + (xy -1.524 -1.524) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -1.524 -0.762) + (xy -4.064 1.778) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -1.524 -0.762) + (xy -2.286 -0.762) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy -1.524 -0.762) + (xy -1.524 0) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + ) + (symbol "LDR07_1_1" + (pin passive line (at 0 3.81 270) (length 1.27) + (name "~" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + (pin passive line (at 0 -3.81 90) (length 1.27) + (name "~" (effects (font (size 1.27 1.27)))) + (number "2" (effects (font (size 1.27 1.27)))) + ) + ) + ) + (symbol "Switch:SW_Push" (pin_numbers hide) (pin_names (offset 1.016) hide) (in_bom yes) (on_board yes) + (property "Reference" "SW" (id 0) (at 1.27 2.54 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Value" "SW_Push" (id 1) (at 0 -1.524 0) + (effects (font (size 1.27 1.27))) + ) + (property "Footprint" "" (id 2) (at 0 5.08 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 0 5.08 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "switch normally-open pushbutton push-button" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "Push button switch, generic, two pins" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "SW_Push_0_1" + (circle (center -2.032 0) (radius 0.508) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 0 1.27) + (xy 0 3.048) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 2.54 1.27) + (xy -2.54 1.27) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (circle (center 2.032 0) (radius 0.508) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (pin passive line (at -5.08 0 0) (length 2.54) + (name "1" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + (pin passive line (at 5.08 0 180) (length 2.54) + (name "2" (effects (font (size 1.27 1.27)))) + (number "2" (effects (font (size 1.27 1.27)))) + ) + ) + ) + (symbol "power:+5V" (power) (pin_names (offset 0)) (in_bom yes) (on_board yes) + (property "Reference" "#PWR" (id 0) (at 0 -3.81 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "+5V" (id 1) (at 0 3.556 0) + (effects (font (size 1.27 1.27))) + ) + (property "Footprint" "" (id 2) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "power-flag" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "Power symbol creates a global label with name \"+5V\"" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "+5V_0_1" + (polyline + (pts + (xy -0.762 1.27) + (xy 0 2.54) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 0 0) + (xy 0 2.54) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + (polyline + (pts + (xy 0 2.54) + (xy 0.762 1.27) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + ) + (symbol "+5V_1_1" + (pin power_in line (at 0 0 90) (length 0) hide + (name "+5V" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + ) + ) + (symbol "power:GND" (power) (pin_names (offset 0)) (in_bom yes) (on_board yes) + (property "Reference" "#PWR" (id 0) (at 0 -6.35 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 0 -3.81 0) + (effects (font (size 1.27 1.27))) + ) + (property "Footprint" "" (id 2) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_keywords" "power-flag" (id 4) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "ki_description" "Power symbol creates a global label with name \"GND\" , ground" (id 5) (at 0 0 0) + (effects (font (size 1.27 1.27)) hide) + ) + (symbol "GND_0_1" + (polyline + (pts + (xy 0 0) + (xy 0 -1.27) + (xy 1.27 -1.27) + (xy 0 -2.54) + (xy -1.27 -1.27) + (xy 0 -1.27) + ) + (stroke (width 0) (type default) (color 0 0 0 0)) + (fill (type none)) + ) + ) + (symbol "GND_1_1" + (pin power_in line (at 0 0 270) (length 0) hide + (name "GND" (effects (font (size 1.27 1.27)))) + (number "1" (effects (font (size 1.27 1.27)))) + ) + ) + ) + ) + + (junction (at 81.28 57.15) (diameter 0) (color 0 0 0 0) + (uuid 1253b181-e6bf-46ef-9ce0-0ebd7b09afc3) + ) + (junction (at 107.95 96.52) (diameter 0) (color 0 0 0 0) + (uuid 1be33e30-ecc6-43ae-8f26-d45550e4edeb) + ) + (junction (at 93.98 90.17) (diameter 0) (color 0 0 0 0) + (uuid 4ae13326-4ca7-415c-bcc2-1eac3539207a) + ) + (junction (at 81.28 96.52) (diameter 0) (color 0 0 0 0) + (uuid 82f9ca19-7f27-4546-8597-40a4871f604f) + ) + (junction (at 110.49 99.06) (diameter 0) (color 0 0 0 0) + (uuid ae022e79-4672-4103-afe8-459a29f9949e) + ) + (junction (at 176.53 96.52) (diameter 0) (color 0 0 0 0) + (uuid d532b373-8bef-483d-94ce-38f5ccfb39d7) + ) + (junction (at 95.25 129.54) (diameter 0) (color 0 0 0 0) + (uuid f1acfaba-792a-475b-9066-8e0a72a3bb05) + ) + + (wire (pts (xy 139.7 140.97) (xy 139.7 106.68)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 01720954-ebd0-4fe4-8ab9-e09bb6c4a6fd) + ) + (wire (pts (xy 93.98 69.85) (xy 93.98 57.15)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 0fe258fe-04e7-4d8c-98a7-53e1ac5d7856) + ) + (wire (pts (xy 95.25 109.22) (xy 95.25 96.52)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 13572b19-5360-41e4-9895-1b2435a9aea4) + ) + (wire (pts (xy 107.95 74.93) (xy 107.95 96.52)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 173ad493-5ce5-4a7c-9e85-c849dbfd0749) + ) + (wire (pts (xy 91.44 109.22) (xy 95.25 109.22)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 27deaa24-d5e1-46f4-93d6-9b974e798f3f) + ) + (wire (pts (xy 110.49 67.31) (xy 110.49 99.06)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 2e534c7e-a1e2-4014-879a-93cef3631b95) + ) + (wire (pts (xy 91.44 114.3) (xy 107.95 114.3)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 315b9383-0d5e-4ae6-9344-bfeece476e6b) + ) + (wire (pts (xy 91.44 116.84) (xy 95.25 116.84)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 31c0aa79-20af-4f92-a6e9-853980c15d29) + ) + (wire (pts (xy 135.89 134.62) (xy 135.89 135.89)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 32efbf43-074b-4b68-8ba0-078b16b86f82) + ) + (wire (pts (xy 93.98 77.47) (xy 93.98 90.17)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 386f5dfe-1117-4feb-9d4e-7473c6e7231c) + ) + (wire (pts (xy 81.28 129.54) (xy 95.25 129.54)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 38e91136-f0e3-4fbd-a048-8eb42b9ae94a) + ) + (wire (pts (xy 110.49 99.06) (xy 142.24 99.06)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 3c1e82c9-fea0-48a6-845c-322736992719) + ) + (wire (pts (xy 139.7 106.68) (xy 142.24 106.68)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 3d19638c-f994-4afd-9452-69496fc15ed5) + ) + (wire (pts (xy 119.38 101.6) (xy 142.24 101.6)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 4f96485b-79c9-4e23-ad0f-282e3d835b81) + ) + (wire (pts (xy 119.38 124.46) (xy 119.38 101.6)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 5a725437-1a79-4644-8f94-f36106378c55) + ) + (wire (pts (xy 91.44 67.31) (xy 110.49 67.31)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 5db1cc82-cede-4a46-a004-1347419de76f) + ) + (wire (pts (xy 105.41 93.98) (xy 142.24 93.98)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 5ed8222e-e54b-48f9-8b21-6489d05a2cae) + ) + (wire (pts (xy 91.44 77.47) (xy 93.98 77.47)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 6e36634f-cae9-4d73-afb1-0a3b14b7f072) + ) + (wire (pts (xy 91.44 101.6) (xy 105.41 101.6)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 73183147-78a4-4aac-b280-a1d8040f2556) + ) + (wire (pts (xy 167.64 96.52) (xy 176.53 96.52)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 74011baf-c7fb-49dc-8af7-81ca1e95cf58) + ) + (wire (pts (xy 110.49 106.68) (xy 110.49 99.06)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 75f9e204-ce7d-4b50-8827-c5d1cfbe834c) + ) + (wire (pts (xy 107.95 114.3) (xy 107.95 96.52)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 8344dbc9-9b1f-416c-bcbd-dec81bfc7d3a) + ) + (wire (pts (xy 95.25 116.84) (xy 95.25 129.54)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 8e7e07de-868e-45eb-a37e-38488a27d048) + ) + (wire (pts (xy 95.25 96.52) (xy 81.28 96.52)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 92ef4347-551d-4e63-ba76-1bc041c8c835) + ) + (wire (pts (xy 91.44 74.93) (xy 107.95 74.93)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 99907f80-05e8-4b74-bbeb-1789e8268128) + ) + (wire (pts (xy 46.99 124.46) (xy 71.12 124.46)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 9beafc4a-5476-47fe-a59d-6031f47164bc) + ) + (wire (pts (xy 96.52 49.53) (xy 46.99 49.53)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 9ca6d8e6-cfe3-4283-81ab-ea4926217b55) + ) + (wire (pts (xy 135.89 140.97) (xy 139.7 140.97)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid 9da2ba3f-5ff0-4eb1-a1e7-abe97b23bd52) + ) + (wire (pts (xy 134.62 88.9) (xy 142.24 88.9)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid a342cc1e-8d2b-4088-9007-a7f22abf5a85) + ) + (wire (pts (xy 91.44 62.23) (xy 96.52 62.23)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid a65f300d-524a-47e6-a976-bfad5ee10fc9) + ) + (wire (pts (xy 93.98 57.15) (xy 81.28 57.15)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid ac638f29-f19a-4987-9c89-220165746ffc) + ) + (wire (pts (xy 107.95 96.52) (xy 142.24 96.52)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid ad1a8737-d55f-44b5-bbb1-d1a51cda1388) + ) + (wire (pts (xy 46.99 49.53) (xy 46.99 124.46)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid ce21daba-68c6-4c5a-92a3-ce60fbe83bfa) + ) + (wire (pts (xy 91.44 69.85) (xy 93.98 69.85)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid eb4393ec-129b-4354-aac2-1a2a7201cfe1) + ) + (wire (pts (xy 93.98 90.17) (xy 81.28 90.17)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid f0a8952a-9288-4a87-a1c3-464b34210fe9) + ) + (wire (pts (xy 96.52 62.23) (xy 96.52 49.53)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid f525b1ed-0f0e-49eb-a7ed-1eac8bf0aa11) + ) + (wire (pts (xy 116.84 124.46) (xy 119.38 124.46)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid f5a04c40-1b7b-43b8-b9cf-7da9cbf65b8e) + ) + (wire (pts (xy 105.41 101.6) (xy 105.41 93.98)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid f82b5d62-ec47-4fef-acb0-d9bee638cb5c) + ) + (wire (pts (xy 91.44 106.68) (xy 110.49 106.68)) + (stroke (width 0) (type default) (color 0 0 0 0)) + (uuid fa3da842-eeb6-48be-b940-52926619a1cd) + ) + + (label "LED Matrix" (at 52.07 95.25 0) + (effects (font (size 1.27 1.27)) (justify left bottom)) + (uuid 2677a2ad-104a-4435-8abc-94b475c06d36) + ) + + (symbol (lib_id "Device:R") (at 113.03 124.46 270) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid 0d696145-2ec2-4bef-994b-9f1c8758cd4d) + (property "Reference" "R1" (id 0) (at 113.03 118.11 90)) + (property "Value" "161Ω" (id 1) (at 113.03 120.65 90)) + (property "Footprint" "" (id 2) (at 113.03 122.682 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 113.03 124.46 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 8a7575e3-608b-494f-a588-28cd13690535)) + (pin "2" (uuid 71fcda25-4b0d-41ed-ac73-b065872a22d5)) + ) + + (symbol (lib_id "power:+5V") (at 160.02 71.12 0) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid 141a79ea-d231-4dbf-9c06-a05c2ffa3c1d) + (property "Reference" "#PWR?" (id 0) (at 160.02 74.93 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "+5V" (id 1) (at 160.02 66.04 0)) + (property "Footprint" "" (id 2) (at 160.02 71.12 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 160.02 71.12 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid eb243f0b-1352-421f-bec7-8db4af5d0c2e)) + ) + + (symbol (lib_id "Device:R") (at 176.53 100.33 180) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid 1eb8f36d-7d0c-4e5e-9fe2-5070db5fd7e3) + (property "Reference" "R3" (id 0) (at 179.07 99.0599 0) + (effects (font (size 1.27 1.27)) (justify right)) + ) + (property "Value" "10kΩ" (id 1) (at 179.07 101.5999 0) + (effects (font (size 1.27 1.27)) (justify right)) + ) + (property "Footprint" "" (id 2) (at 178.308 100.33 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 176.53 100.33 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 134c348d-6d65-4204-867a-3f776c82577d)) + (pin "2" (uuid cd9f54d7-ecb6-4f6b-8393-8d47655c7dfa)) + ) + + (symbol (lib_id "Device:Buzzer") (at 106.68 127 0) (mirror y) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid 20e06040-d647-4f00-8cdf-985064ab739e) + (property "Reference" "BZ1" (id 0) (at 105.918 118.11 0)) + (property "Value" "Buzzer" (id 1) (at 105.918 120.65 0)) + (property "Footprint" "" (id 2) (at 107.315 124.46 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 107.315 124.46 90) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 64d506ab-e1f1-4fa6-af2f-d32fa7b7233a)) + (pin "2" (uuid bd650711-e39e-428e-8a6a-2863be2014e8)) + ) + + (symbol (lib_id "power:GND") (at 176.53 104.14 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid 2149f34b-2a09-42c6-a1a7-99baf49f5b8e) + (property "Reference" "#PWR?" (id 0) (at 176.53 110.49 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 176.53 107.95 0)) + (property "Footprint" "" (id 2) (at 176.53 104.14 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 176.53 104.14 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 6640eb2c-8d96-470c-94cd-56909fc8350b)) + ) + + (symbol (lib_id "power:+5V") (at 135.89 134.62 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid 301a8c1c-845a-4d25-a06f-7c09bae9ce79) + (property "Reference" "#PWR?" (id 0) (at 135.89 138.43 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "+5V" (id 1) (at 135.89 130.81 0)) + (property "Footprint" "" (id 2) (at 135.89 134.62 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 135.89 134.62 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 302551ac-c512-4dc5-be35-d3c29f4f30c6)) + ) + + (symbol (lib_id "MCU_Module:Arduino_UNO_R3") (at 154.94 96.52 0) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid 5cb8ee9f-73d1-4c0d-b255-8e874b857650) + (property "Reference" "A1" (id 0) (at 162.0394 68.58 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Value" "Arduino_UNO_R3" (id 1) (at 162.0394 71.12 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Footprint" "Module:Arduino_UNO_R3" (id 2) (at 154.94 96.52 0) + (effects (font (size 1.27 1.27) italic) hide) + ) + (property "Datasheet" "https://www.arduino.cc/en/Main/arduinoBoardUno" (id 3) (at 154.94 96.52 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 231f9b88-258f-4eae-b0de-709fbf717dbf)) + (pin "10" (uuid d267aecf-c5fd-4665-8830-fa845bbecc09)) + (pin "11" (uuid 13cab736-9e30-4c2c-b873-223cd16b67eb)) + (pin "12" (uuid bdf80067-ad32-46e8-ac5b-63bf8519d80c)) + (pin "13" (uuid 7107e33c-694f-4355-b8fe-ac7827deba78)) + (pin "14" (uuid c4c870a3-22e3-423c-933c-b0cc1a4a6bcf)) + (pin "15" (uuid b91c2a78-e9f0-499a-b945-e76cf466f295)) + (pin "16" (uuid adbbf2fc-4453-4d1d-a347-718256a9e445)) + (pin "17" (uuid 3ddc2159-ddde-4aae-8673-ee2995c86deb)) + (pin "18" (uuid 3833561e-1296-43c3-b3b6-6c9a6e25c922)) + (pin "19" (uuid 4f54a39c-0215-4fa3-a192-94629d104449)) + (pin "2" (uuid 089a6729-a3b9-45b8-9a19-4d833b966696)) + (pin "20" (uuid 0c3db89c-054f-4068-8302-f64047faaafd)) + (pin "21" (uuid e1cfddb4-a65e-4777-bbd9-f0cd139a190f)) + (pin "22" (uuid 70fe45da-8de8-4968-800e-c425f77679c6)) + (pin "23" (uuid dfd096d4-fcde-4c09-9247-229e19fb603d)) + (pin "24" (uuid 4c4d21ec-a1ee-4191-9b4b-4a18f2fbea0e)) + (pin "25" (uuid 69b7982d-71e9-4b86-b9ca-aac1e22daf32)) + (pin "26" (uuid 873fe5c1-eb91-4086-a9d3-4dda77002a2d)) + (pin "27" (uuid 23bd5e25-fcb3-4a2b-a61c-03ace3c922ed)) + (pin "28" (uuid f8aca652-015b-4036-a70b-97d9b75b1b6d)) + (pin "29" (uuid 6ed1e18f-935a-4e30-96ee-a044a124a877)) + (pin "3" (uuid 2579c382-b04f-4cfc-b2d2-68f5d7987fde)) + (pin "30" (uuid a491185a-6ab9-4bc6-a2e0-4b6a59fa9f7d)) + (pin "31" (uuid 8d2a15e9-b149-4e71-b7d4-7bbf5d0cf5cb)) + (pin "32" (uuid d8ca4a31-fe89-44cd-9fe1-58b6200861db)) + (pin "4" (uuid 8b04e630-5c93-41a1-8c09-596aea25dfca)) + (pin "5" (uuid 3d97cce6-e4c2-415e-b161-53e1c0dd9e81)) + (pin "6" (uuid bfa55a41-f9c0-4b59-afd5-e46362d4c97c)) + (pin "7" (uuid 74999fd3-5344-4076-8cce-8e873e8e928d)) + (pin "8" (uuid 28e5a82b-3a9a-4b45-96f2-2880597cb9b1)) + (pin "9" (uuid 0d02f8ab-e673-455f-9143-9564f40803a3)) + ) + + (symbol (lib_id "power:GND") (at 135.89 146.05 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid 7aefc256-28c5-4fca-b228-7eb3f739e209) + (property "Reference" "#PWR?" (id 0) (at 135.89 152.4 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 135.89 149.86 0)) + (property "Footprint" "" (id 2) (at 135.89 146.05 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 135.89 146.05 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 5386b8f9-cf77-4761-8b81-8251c98a3873)) + ) + + (symbol (lib_id "Interface_Optical:TSOP32S40F") (at 125.73 140.97 0) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid 7b556d3a-1886-4d11-a4ea-75d7ccf91a58) + (property "Reference" "U3" (id 0) (at 123.995 129.54 0)) + (property "Value" "TSOP32S40F" (id 1) (at 123.995 132.08 0)) + (property "Footprint" "OptoDevice:Vishay_MOLD-3Pin" (id 2) (at 124.46 150.495 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "http://www.vishay.com/docs/82669/tsop32s40f.pdf" (id 3) (at 142.24 133.35 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 4d0d5217-0ead-43ac-8f00-85bfc10124cd)) + (pin "2" (uuid 12a094c6-25b8-4545-bc73-e4594285558d)) + (pin "3" (uuid 8dc663e1-02ab-43a5-99f1-08b76b4da361)) + ) + + (symbol (lib_id "Device:R") (at 209.55 54.61 0) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid 9954329c-d0c0-4703-9a96-4426d37f78df) + (property "Reference" "R?" (id 0) (at 212.09 53.3399 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Value" "R" (id 1) (at 212.09 55.8799 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Footprint" "" (id 2) (at 207.772 54.61 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 209.55 54.61 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 2b71d0ae-5a56-4b71-b819-74c0849d6728)) + (pin "2" (uuid 8a88adb2-82cc-49ab-8bdb-5c1a57be05b7)) + ) + + (symbol (lib_id "power:+5V") (at 176.53 88.9 0) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid 9c41a0ab-d2cc-47f8-b12b-9acb54862052) + (property "Reference" "#PWR?" (id 0) (at 176.53 92.71 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "+5V" (id 1) (at 176.53 83.82 0)) + (property "Footprint" "" (id 2) (at 176.53 88.9 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 176.53 88.9 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 856457e8-069c-4e02-92b4-fc0e82a35eb5)) + ) + + (symbol (lib_id "power:GND") (at 95.25 129.54 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid a7ce1889-2073-4b99-8cf9-d7d05599b709) + (property "Reference" "#PWR?" (id 0) (at 95.25 135.89 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 95.25 133.35 0)) + (property "Footprint" "" (id 2) (at 95.25 129.54 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 95.25 129.54 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 39d0e4ed-44c8-46a8-bf5f-021e67df9cab)) + ) + + (symbol (lib_id "power:GND") (at 124.46 88.9 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid b026f555-902c-4e06-8246-0ad63d17f407) + (property "Reference" "#PWR?" (id 0) (at 124.46 95.25 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 124.46 92.71 0)) + (property "Footprint" "" (id 2) (at 124.46 88.9 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 124.46 88.9 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 6418e6d5-1d70-4e24-81f6-39d07f4edb38)) + ) + + (symbol (lib_id "74xx:74HC595") (at 81.28 72.39 0) (mirror y) (unit 1) + (in_bom yes) (on_board yes) + (uuid b25f44e0-8181-464f-9dc7-fd49f1f26994) + (property "Reference" "U2" (id 0) (at 62.23 66.04 0) + (effects (font (size 1.27 1.27)) (justify right)) + ) + (property "Value" "74HC595" (id 1) (at 59.69 71.12 0) + (effects (font (size 1.27 1.27)) (justify right)) + ) + (property "Footprint" "" (id 2) (at 81.28 72.39 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "http://www.ti.com/lit/ds/symlink/sn74hc595.pdf" (id 3) (at 81.28 72.39 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 622bcb9b-2cba-4a38-9a33-a6c41a23a6f5)) + (pin "10" (uuid 528000b0-2425-49b7-9dec-fcecddbb35de)) + (pin "11" (uuid 6393ab9c-ea85-4630-9189-20da23dfbdc3)) + (pin "12" (uuid 26a40cc3-c2fc-4533-beb8-8037593a97ec)) + (pin "13" (uuid c9d1030e-cc6f-4bd8-b75a-905f4a6f816c)) + (pin "14" (uuid cc98338b-2c92-4b22-a2bd-e6c937e84a02)) + (pin "15" (uuid abbaa369-8a3c-4727-9a77-bbdcd0da8cf6)) + (pin "16" (uuid becb9ca4-51ab-4e91-bba7-e330a41faad7)) + (pin "2" (uuid aecacf16-0b57-427d-956d-937b034a932c)) + (pin "3" (uuid d0f4cdf3-0b99-44fc-8888-dcd75db04c52)) + (pin "4" (uuid 519c089b-4f80-4f0a-ab8d-f4a272515f4b)) + (pin "5" (uuid 96cddcb1-31e3-4fe6-a327-d2a2abf39a49)) + (pin "6" (uuid 942c8804-9f47-491c-9f74-3684da59302b)) + (pin "7" (uuid 8fdd6819-dcf1-459a-b369-f801dcc6c2bd)) + (pin "8" (uuid a13ccb6b-01fa-4e21-bfb4-8f93d7f4db85)) + (pin "9" (uuid 8c6fd9d1-9190-4632-93bc-f8655686f38b)) + ) + + (symbol (lib_id "power:GND") (at 109.22 129.54 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid b7ec45b7-309e-49b5-84d7-3c2491b225fa) + (property "Reference" "#PWR?" (id 0) (at 109.22 135.89 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 109.22 133.35 0)) + (property "Footprint" "" (id 2) (at 109.22 129.54 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 109.22 129.54 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 56547516-be87-4c79-987f-2fc56540a1da)) + ) + + (symbol (lib_id "Switch:SW_Push") (at 129.54 88.9 0) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid c473d886-4ff1-480b-b845-981b3467af5b) + (property "Reference" "SW1" (id 0) (at 129.54 81.28 0)) + (property "Value" "SW_Push" (id 1) (at 129.54 83.82 0)) + (property "Footprint" "" (id 2) (at 129.54 83.82 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "~" (id 3) (at 129.54 83.82 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid f8c13bd8-ceee-4cbd-be1d-e75862a9af00)) + (pin "2" (uuid 2b791a90-19e5-4b05-aceb-2ccefb430ec2)) + ) + + (symbol (lib_id "power:+5V") (at 81.28 57.15 0) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid d6511d1d-e358-4c56-aef2-4b297ada6d1c) + (property "Reference" "#PWR?" (id 0) (at 81.28 60.96 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "+5V" (id 1) (at 81.28 52.07 0)) + (property "Footprint" "" (id 2) (at 81.28 57.15 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 81.28 57.15 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 67819a43-8a0e-4937-a682-9ee221f3bbc4)) + ) + + (symbol (lib_id "power:GND") (at 93.98 90.17 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid ef9c7fec-91ca-4276-9dc3-f182922c8ff6) + (property "Reference" "#PWR?" (id 0) (at 93.98 96.52 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 93.98 93.98 0)) + (property "Footprint" "" (id 2) (at 93.98 90.17 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 93.98 90.17 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid dc44d901-60d7-40e0-9a5a-12bca193ba04)) + ) + + (symbol (lib_id "74xx:74HC595") (at 81.28 111.76 0) (mirror y) (unit 1) + (in_bom yes) (on_board yes) + (uuid efc74e3b-0ed1-44ed-b04e-4c0fb66c0462) + (property "Reference" "U1" (id 0) (at 63.5 107.95 0) + (effects (font (size 1.27 1.27)) (justify right)) + ) + (property "Value" "74HC595" (id 1) (at 59.69 111.76 0) + (effects (font (size 1.27 1.27)) (justify right)) + ) + (property "Footprint" "" (id 2) (at 81.28 111.76 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "http://www.ti.com/lit/ds/symlink/sn74hc595.pdf" (id 3) (at 81.28 111.76 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 6ac9b379-7898-4e96-aa3d-bbd0e9dff99c)) + (pin "10" (uuid 3c9d35bc-b102-45fc-a2cc-0ba104ef1f55)) + (pin "11" (uuid 8db77c2a-4868-4d7a-a5a0-49dc17ea44aa)) + (pin "12" (uuid 8b9e0e4d-2d1a-405a-bba9-822c54568187)) + (pin "13" (uuid 9c0ae9e4-6109-4ffb-9185-db2b315c9ede)) + (pin "14" (uuid cd4d7956-e388-49bf-b45e-78e89c86a4ab)) + (pin "15" (uuid 639310a5-d6c6-4846-ac96-8b04648b19b5)) + (pin "16" (uuid 0a9b145a-ad99-4743-a27a-5f2723296b42)) + (pin "2" (uuid 2376e453-473f-4325-8394-ceecb92eae57)) + (pin "3" (uuid 16ddce74-4296-401f-b186-e68d31168016)) + (pin "4" (uuid c04e2b8a-3f2a-468e-9d92-f313ad7bcd77)) + (pin "5" (uuid 0948d14a-fa12-4825-a591-bd63fd1087fd)) + (pin "6" (uuid d294c6e3-4ed8-4097-9bab-6d6562e29775)) + (pin "7" (uuid 370966d8-2fac-4ddd-a079-77ca658e3aac)) + (pin "8" (uuid e730b25f-c96f-48ef-a606-f67b4c56b7b1)) + (pin "9" (uuid 2939070a-243b-4f6f-8953-8a568eacee32)) + ) + + (symbol (lib_id "Sensor_Optical:LDR07") (at 176.53 92.71 0) (unit 1) + (in_bom yes) (on_board yes) (fields_autoplaced) + (uuid f20a0d6f-d377-45a4-b121-f79bd50b9e38) + (property "Reference" "R2" (id 0) (at 179.07 91.4399 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Value" "LDR07" (id 1) (at 179.07 93.9799 0) + (effects (font (size 1.27 1.27)) (justify left)) + ) + (property "Footprint" "OptoDevice:R_LDR_5.1x4.3mm_P3.4mm_Vertical" (id 2) (at 180.975 92.71 90) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "http://www.tme.eu/de/Document/f2e3ad76a925811312d226c31da4cd7e/LDR07.pdf" (id 3) (at 176.53 93.98 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 17082467-f25e-4a5b-82ec-ffb20cb6c3d7)) + (pin "2" (uuid 7aecafab-919c-4b9e-803e-f5b0636420a2)) + ) + + (symbol (lib_id "power:+5V") (at 81.28 96.52 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid f615f992-b304-49f7-b744-952f42fc0886) + (property "Reference" "#PWR?" (id 0) (at 81.28 100.33 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "+5V" (id 1) (at 81.28 92.71 0)) + (property "Footprint" "" (id 2) (at 81.28 96.52 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 81.28 96.52 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid 9144ea53-bf57-47e7-8c4a-593655634e8a)) + ) + + (symbol (lib_id "power:GND") (at 154.94 124.46 0) (unit 1) + (in_bom yes) (on_board yes) + (uuid fad1c7e0-2820-482e-92c6-bd2d6fcfd26f) + (property "Reference" "#PWR?" (id 0) (at 154.94 130.81 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Value" "GND" (id 1) (at 154.94 128.27 0)) + (property "Footprint" "" (id 2) (at 154.94 124.46 0) + (effects (font (size 1.27 1.27)) hide) + ) + (property "Datasheet" "" (id 3) (at 154.94 124.46 0) + (effects (font (size 1.27 1.27)) hide) + ) + (pin "1" (uuid c0a75a50-5d6f-4f04-b9a6-c75a58c98c99)) + ) + + (sheet_instances + (path "/" (page "1")) + ) + + (symbol_instances + (path "/141a79ea-d231-4dbf-9c06-a05c2ffa3c1d" + (reference "#PWR?") (unit 1) (value "+5V") (footprint "") + ) + (path "/2149f34b-2a09-42c6-a1a7-99baf49f5b8e" + (reference "#PWR?") (unit 1) (value "GND") (footprint "") + ) + (path "/301a8c1c-845a-4d25-a06f-7c09bae9ce79" + (reference "#PWR?") (unit 1) (value "+5V") (footprint "") + ) + (path "/7aefc256-28c5-4fca-b228-7eb3f739e209" + (reference "#PWR?") (unit 1) (value "GND") (footprint "") + ) + (path "/9c41a0ab-d2cc-47f8-b12b-9acb54862052" + (reference "#PWR?") (unit 1) (value "+5V") (footprint "") + ) + (path "/a7ce1889-2073-4b99-8cf9-d7d05599b709" + (reference "#PWR?") (unit 1) (value "GND") (footprint "") + ) + (path "/b026f555-902c-4e06-8246-0ad63d17f407" + (reference "#PWR?") (unit 1) (value "GND") (footprint "") + ) + (path "/b7ec45b7-309e-49b5-84d7-3c2491b225fa" + (reference "#PWR?") (unit 1) (value "GND") (footprint "") + ) + (path "/d6511d1d-e358-4c56-aef2-4b297ada6d1c" + (reference "#PWR?") (unit 1) (value "+5V") (footprint "") + ) + (path "/ef9c7fec-91ca-4276-9dc3-f182922c8ff6" + (reference "#PWR?") (unit 1) (value "GND") (footprint "") + ) + (path "/f615f992-b304-49f7-b744-952f42fc0886" + (reference "#PWR?") (unit 1) (value "+5V") (footprint "") + ) + (path "/fad1c7e0-2820-482e-92c6-bd2d6fcfd26f" + (reference "#PWR?") (unit 1) (value "GND") (footprint "") + ) + (path "/5cb8ee9f-73d1-4c0d-b255-8e874b857650" + (reference "A1") (unit 1) (value "Arduino_UNO_R3") (footprint "Module:Arduino_UNO_R3") + ) + (path "/20e06040-d647-4f00-8cdf-985064ab739e" + (reference "BZ1") (unit 1) (value "Buzzer") (footprint "") + ) + (path "/0d696145-2ec2-4bef-994b-9f1c8758cd4d" + (reference "R1") (unit 1) (value "161Ω") (footprint "") + ) + (path "/f20a0d6f-d377-45a4-b121-f79bd50b9e38" + (reference "R2") (unit 1) (value "LDR07") (footprint "OptoDevice:R_LDR_5.1x4.3mm_P3.4mm_Vertical") + ) + (path "/1eb8f36d-7d0c-4e5e-9fe2-5070db5fd7e3" + (reference "R3") (unit 1) (value "10kΩ") (footprint "") + ) + (path "/9954329c-d0c0-4703-9a96-4426d37f78df" + (reference "R?") (unit 1) (value "R") (footprint "") + ) + (path "/c473d886-4ff1-480b-b845-981b3467af5b" + (reference "SW1") (unit 1) (value "SW_Push") (footprint "") + ) + (path "/efc74e3b-0ed1-44ed-b04e-4c0fb66c0462" + (reference "U1") (unit 1) (value "74HC595") (footprint "") + ) + (path "/b25f44e0-8181-464f-9dc7-fd49f1f26994" + (reference "U2") (unit 1) (value "74HC595") (footprint "") + ) + (path "/7b556d3a-1886-4d11-a4ea-75d7ccf91a58" + (reference "U3") (unit 1) (value "TSOP32S40F") (footprint "OptoDevice:Vishay_MOLD-3Pin") + ) + ) +) diff --git a/matrixclock/matrixclock.ino b/matrixclock/matrixclock.ino new file mode 100644 index 0000000..e182926 --- /dev/null +++ b/matrixclock/matrixclock.ino @@ -0,0 +1,233 @@ +#include + +#define SERIAL_DEBUG 0 + +// Remote controls +#define RC6_CHM 0xFFA25D// CHANNEL - +#define RC6_CH 0xFF629D// CHANNEL +#define RC6_CHP 0xFFE21D// CHANNEL + +#define RC6_PREV 0xFF22DD// |<< PREVIOUS +#define RC6_NEXT 0xFF02FD// >>| NEXT +#define RC6_PLAY 0xFFC23D// PLAY/PAUSE +#define RC6_VM 0xFFE01F// VOLUME - +#define RC6_VP 0xFFA857// VOLUME + +#define RC6_EQ 0xFF906F// EQ +#define RC6_0 0xFF6897// 0 +#define RC6_100 0xFF9867// 100+ +#define RC6_200 0xFFB04F// 200+ +#define RC6_1 0xFF30CF// 1 +#define RC6_2 0xFF18E7// 2 +#define RC6_3 0xFF7A85// 3 +#define RC6_4 0xFF10EF// 4 +#define RC6_5 0xFF38C7// 5 +#define RC6_6 0xFF5AA5// 6 +#define RC6_7 0xFF42BD// 7 +#define RC6_8 0xFF4AB5// 8 +#define RC6_9 0xFF52AD// 9 +#define AMP2540_VCDAUX 0x8FDBCE66 +#define AMP2540_TUNERCD 0xC375A98B +#define AMP2540_DVD 0xCC7372A6 +#define AMP2540_TAPE 0xE917A076 +#define AMP2540_SEARCH 0xE82D76B6 +#define AMP2540_RESET 0x04D1A486 +#define AMP2540_VM 0xAB95D276 +#define AMP2540_VP 0x0217C346 + +#define MODE_NORMAL 0 +#define MODE_SETTIME 1 +#define MODE_SETALARM 2 + +#define PIN_BUTTON 3 +#define PIN_BUZZER 8 +#define PIN_IR 10 +#define PIN_LED_DUTY A0 +#define PIN_REG_CLOCK 7 +#define PIN_REG_DATA 5 +#define PIN_REG_LATCH 6 + +IRrecv irrecv(PIN_IR); +decode_results ircode; +unsigned long last_ir = 0; + +// Matrix state +unsigned char matrix[8] = {0b10000001, 0, 0, 0, 0, 0, 0, 0b10000001}; +unsigned char matrix_row_on = 0; + +// Interface mode +unsigned char mode = MODE_NORMAL; + +// Selected number (0..4: None, Hour, Minute, Second) +unsigned char number_selection = 0; + +// Time added to internal clock, to fit real time +unsigned long time_offset = 0; + +unsigned char alarm = false; + +unsigned long alarm_time = 0; + +// Is alarm ringing +unsigned char alarm_ringing = false; + +unsigned int led_duty; +unsigned int led_duty_step = 3; + +// Bytewise reverse +unsigned char reverse(unsigned char b) { + b = (b & 0xF0) >> 4 | (b & 0x0F) << 4; + b = (b & 0xCC) >> 2 | (b & 0x33) << 2; + b = (b & 0xAA) >> 1 | (b & 0x55) << 1; + return b; +} + +unsigned char fix_pixels(unsigned char b) { + return (b << 1) | (b >> 7); +} + +void shift_matrix() { + if(led_duty_step == 0) { + digitalWrite(PIN_REG_LATCH, LOW); + shiftOut(PIN_REG_DATA, PIN_REG_CLOCK, MSBFIRST, ~(1 << matrix_row_on)); + shiftOut(PIN_REG_DATA, PIN_REG_CLOCK, MSBFIRST, fix_pixels(matrix[(matrix_row_on+7)%8])); + digitalWrite(PIN_REG_LATCH, HIGH); + matrix_row_on = (matrix_row_on + 1) % 8; + } else if(led_duty_step == 1) { + digitalWrite(PIN_REG_LATCH, LOW); + shiftOut(PIN_REG_DATA, PIN_REG_CLOCK, MSBFIRST, 255); + shiftOut(PIN_REG_DATA, PIN_REG_CLOCK, MSBFIRST, 0); + digitalWrite(PIN_REG_LATCH, HIGH); + } + led_duty_step ++; +} + +void draw_time(unsigned long t) { + unsigned char seconds = t/1000%60; + unsigned char minutes = t/60000%60; + unsigned char hours = t/3600000%24; + matrix[1] = reverse(seconds) >> 1; + matrix[2] = matrix[1]; + matrix[3] = reverse(minutes) >> 1; + matrix[4] = matrix[3]; + matrix[5] = reverse(hours) >> 1; + matrix[6] = matrix[5]; +} + +void draw_mode() { + switch(mode) { + case MODE_NORMAL: matrix[0] = 0b10000001; break; + case MODE_SETTIME: matrix[0] = 0b10011001; break; + case MODE_SETALARM: matrix[0] = 0b10111101; break; + } + if(alarm) matrix[0] |= 0b01000010; +} + +void draw_number_selection() { + switch(number_selection) { + case 1: matrix[1] |= 0b10000001; break; + case 2: matrix[3] |= 0b10000001; break; + case 3: matrix[5] |= 0b10000001; break; + } +} + +const unsigned char HEX_ALPHA[16] = {'0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F'}; +void send_hex(unsigned long val) { + Serial.write(HEX_ALPHA[(val >> 28) & 0xf]); + Serial.write(HEX_ALPHA[(val >> 24) & 0xf]); + Serial.write(HEX_ALPHA[(val >> 20) & 0xf]); + Serial.write(HEX_ALPHA[(val >> 16) & 0xf]); + Serial.write(HEX_ALPHA[(val >> 12) & 0xf]); + Serial.write(HEX_ALPHA[(val >> 8) & 0xf]); + Serial.write(HEX_ALPHA[(val >> 4) & 0xf]); + Serial.write(HEX_ALPHA[val & 0xf]); + Serial.write('\n'); +} + +void setup() { + pinMode(PIN_REG_DATA, OUTPUT); + pinMode(PIN_REG_CLOCK, OUTPUT); + pinMode(PIN_REG_LATCH, OUTPUT); + pinMode(PIN_BUZZER, OUTPUT); + pinMode(PIN_BUTTON, INPUT_PULLUP); + pinMode(PIN_LED_DUTY, INPUT); + irrecv.enableIRIn(); + + pinMode(13, OUTPUT); + digitalWrite(13, LOW); + + #if SERIAL_DEBUG + Serial.begin(9600); + #endif +} + +void loop() { + if(led_duty_step > led_duty) { + led_duty_step = 0; + led_duty = (1023-analogRead(PIN_LED_DUTY)) / 128; + } + + if(irrecv.decode(&ircode)) { + #if SERIAL_DEBUG + send_hex(ircode.value); + #endif + unsigned long val = ircode.value; + if(val == last_ir) { + alarm_ringing = false; + switch(val) { + case AMP2540_VCDAUX: mode = (mode+1) % 3; break; + case AMP2540_VP: change_selected_number(1); break; + case AMP2540_VM: change_selected_number(-1); break; + case AMP2540_SEARCH: number_selection = (number_selection+1) % 4; break; + case AMP2540_TUNERCD: alarm = !alarm; break; + } + last_ir = 0; + } else { + last_ir = val; + } + irrecv.resume(); + } + + if(alarm && !alarm_ringing) { + unsigned long t = ((millis() + time_offset) / 1000) % 86400; + if(alarm_time / 1000 == t) { + alarm_ringing = true; + } + } + + if(alarm_ringing) { + if(millis()%1000 < 100) { + matrix[7] = 0b11111111; + digitalWrite(PIN_BUZZER, HIGH); + } else { + matrix[7] = 0b10000001; + digitalWrite(PIN_BUZZER, LOW); + } + if(digitalRead(PIN_BUTTON) == LOW) { + digitalWrite(PIN_BUZZER, LOW); + alarm_ringing = false; + } + } + + draw_mode(); + if(mode == MODE_SETALARM) + draw_time(alarm_time); + else + draw_time(millis() + time_offset); + draw_number_selection(); + shift_matrix(); +} + +void change_selected_number(signed int nb) { + switch(mode) { + case MODE_SETTIME: change_time(&time_offset, nb); break; + case MODE_SETALARM: change_time(&alarm_time, nb); break; + } +} + +void change_time(unsigned long *t, signed int mul) { + switch(number_selection) { + case 1: *t += mul * 1000; break; + case 2: *t += mul * 60000; break; + case 3: *t += mul * 3600000; break; + } + *t %= 86400000; +}