diff --git a/hardware/Valve Node.kicad_pcb b/hardware/Valve Node.kicad_pcb index 6ae6fce..196f200 100644 --- a/hardware/Valve Node.kicad_pcb +++ b/hardware/Valve Node.kicad_pcb @@ -137,6 +137,7 @@ (net 56 "Net-(D301-K)") (net 57 "Net-(D303-A)") (net 58 "Net-(D303-K)") + (net 59 "unconnected-(U203-Vref-Pad5)") (footprint "Resistor_SMD:R_0402_1005Metric" (layer "F.Cu") (uuid "02c2bd61-5c31-428a-a6be-a2f5f37c158e") @@ -1537,537 +1538,6 @@ ) ) ) - (footprint "Package_SO:SOIC-8_3.9x4.9mm_P1.27mm" - (layer "F.Cu") - (uuid "26a003e5-1561-4704-a405-44556835a6f5") - (at 100 63 180) - (descr "SOIC, 8 Pin (JEDEC MS-012AA, https://www.analog.com/media/en/package-pcb-resources/package/pkg_pdf/soic_narrow-r/r_8.pdf), generated with kicad-footprint-generator ipc_gullwing_generator.py") - (tags "SOIC SO") - (property "Reference" "U202" - (at -2.362 -3.548 0) - (layer "F.SilkS") - (uuid "73a52ec7-f1dd-49c7-bc2a-19633b1c7713") - (effects - (font - (size 1 1) - (thickness 0.15) - ) - ) - ) - (property "Value" "TJA1042T-3" - (at 0 3.4 0) - (layer "F.Fab") - (uuid "d3cca8a0-b311-43e8-aa4b-b7b3d7667b77") - (effects - (font - (size 1 1) - (thickness 0.15) - ) - ) - ) - (property "Datasheet" "http://www.nxp.com/docs/en/data-sheet/TJA1042.pdf" - (at 0 0 0) - (layer "F.Fab") - (hide yes) - (uuid "dd16bf9e-9bd1-470b-8fef-1c7d763817ff") - (effects - (font - (size 1.27 1.27) - (thickness 0.15) - ) - ) - ) - (property "Description" "High-Speed CAN Transceiver, separate VIO, standby mode, SOIC-8" - (at 0 0 0) - (layer "F.Fab") - (hide yes) - (uuid "d196aeab-cba6-4441-a035-84a91fb92109") - (effects - (font - (size 1.27 1.27) - (thickness 0.15) - ) - ) - ) - (property "LCSC" "C132227" - (at 0 0 180) - (unlocked yes) - (layer "F.Fab") - (hide yes) - (uuid "99542f58-64e7-4773-b98c-bc4ead0dcaa3") - (effects - (font - (size 1 1) - (thickness 0.15) - ) - ) - ) - (property ki_fp_filters "SOIC*3.9x4.9mm*P1.27mm*") - (path "/5c46d7fe-34fa-4f56-9c85-0d1525266e94/f4fe0140-b1e8-4854-a46e-c8601fd5154e") - (sheetname "/MCU/") - (sheetfile "mcu.kicad_sch") - (attr smd) - (fp_line - (start 0 2.56) - (end 1.95 2.56) - (stroke - (width 0.12) - (type solid) - ) - (layer "F.SilkS") - (uuid "0d055936-e50d-45e8-b721-5a5f6bc456a7") - ) - (fp_line - (start 0 2.56) - (end -1.95 2.56) - (stroke - (width 0.12) - (type solid) - ) - (layer "F.SilkS") - (uuid "6a28c3c8-89e8-4c2d-9472-7fb17be64a88") - ) - (fp_line - (start 0 -2.56) - (end 1.95 -2.56) - (stroke - (width 0.12) - (type solid) - ) - (layer "F.SilkS") - (uuid "ea4c4db6-5c26-4a30-9c90-e195b808f21c") - ) - (fp_line - (start 0 -2.56) - (end -1.95 -2.56) - (stroke - (width 0.12) - (type solid) - ) - (layer "F.SilkS") - (uuid "17006a7d-fcfa-4ecd-bd0d-e5e25d5746df") - ) - (fp_poly - (pts - (xy -2.7 -2.465) (xy -2.94 -2.795) (xy -2.46 -2.795) (xy -2.7 -2.465) - ) - (stroke - (width 0.12) - (type solid) - ) - (fill yes) - (layer "F.SilkS") - (uuid "9559bdf9-43f8-45ee-a4b2-d11c59533bc3") - ) - (fp_line - (start 3.7 2.7) - (end 3.7 -2.7) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "bef94992-4d86-4988-b588-a153d34385e5") - ) - (fp_line - (start 3.7 -2.7) - (end -3.7 -2.7) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "d9f04f8b-2e93-43c7-8712-b567c970607f") - ) - (fp_line - (start -3.7 2.7) - (end 3.7 2.7) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "6b14fa3e-f632-4e45-ad4e-6420b10dc117") - ) - (fp_line - (start -3.7 -2.7) - (end -3.7 2.7) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "d45b9fa4-871c-44d5-9430-12785763e897") - ) - (fp_line - (start 1.95 2.45) - (end -1.95 2.45) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "80fdbc32-e0a5-4086-aedb-1315c7b8ee9e") - ) - (fp_line - (start 1.95 -2.45) - (end 1.95 2.45) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "8a5f2a49-b20f-4b68-af5b-2c72cddfecdb") - ) - (fp_line - (start -0.975 -2.45) - (end 1.95 -2.45) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "1ba135da-e892-488f-a2d9-5fc2763bac81") - ) - (fp_line - (start -1.95 2.45) - (end -1.95 -1.475) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "304e6f2f-2da0-43f7-918c-4747618f10b8") - ) - (fp_line - (start -1.95 -1.475) - (end -0.975 -2.45) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "32415962-102f-4632-b187-1e955fb80ffc") - ) - (fp_text user "${REFERENCE}" - (at 0 0 0) - (layer "F.Fab") - (uuid "61c2040f-3d6b-41e1-b8f8-a1362dd4ac90") - (effects - (font - (size 0.98 0.98) - (thickness 0.15) - ) - ) - ) - (pad "1" smd roundrect - (at -2.475 -1.905 180) - (size 1.95 0.6) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 13 "/MCU/CANTXD") - (pinfunction "TXD") - (pintype "input") - (uuid "48837ada-b50e-4200-acab-69838eb01507") - ) - (pad "2" smd roundrect - (at -2.475 -0.635 180) - (size 1.95 0.6) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 2 "GND") - (pinfunction "GND") - (pintype "power_in") - (uuid "f00d1ba2-8a66-478d-9380-388d64b8cb34") - ) - (pad "3" smd roundrect - (at -2.475 0.635 180) - (size 1.95 0.6) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 3 "5V0") - (pinfunction "VCC") - (pintype "power_in") - (uuid "1d3608ef-67f9-4bf1-925b-443b261f9b4d") - ) - (pad "4" smd roundrect - (at -2.475 1.905 180) - (size 1.95 0.6) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 12 "/MCU/CANRXD") - (pinfunction "RXD") - (pintype "output") - (uuid "eae6ccfe-1c14-4d6d-88a0-6ce4c1fce81c") - ) - (pad "5" smd roundrect - (at 2.475 1.905 180) - (size 1.95 0.6) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 1 "3V3") - (pinfunction "VIO") - (pintype "power_in") - (uuid "a71102f0-75b7-4e80-b6b8-658a1fead66e") - ) - (pad "6" smd roundrect - (at 2.475 0.635 180) - (size 1.95 0.6) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 10 "/MCU/CAN HIGH") - (pinfunction "CANL") - (pintype "bidirectional") - (uuid "e89223bf-305c-4bd9-902b-9b15284dafb1") - ) - (pad "7" smd roundrect - (at 2.475 -0.635 180) - (size 1.95 0.6) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 11 "/MCU/CAN LOW") - (pinfunction "CANH") - (pintype "bidirectional") - (uuid "df5d34aa-68ae-43d1-b30c-a6da529450ed") - ) - (pad "8" smd roundrect - (at 2.475 -1.905 180) - (size 1.95 0.6) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 2 "GND") - (pinfunction "STB") - (pintype "input") - (uuid "c93dea7c-b4dd-4b80-b043-06d05c32ead4") - ) - (embedded_fonts no) - (model "${KICAD9_3DMODEL_DIR}/Package_SO.3dshapes/SOIC-8_3.9x4.9mm_P1.27mm.wrl" - (offset - (xyz 0 0 0) - ) - (scale - (xyz 1 1 1) - ) - (rotate - (xyz 0 0 0) - ) - ) - ) - (footprint "Capacitor_SMD:C_0402_1005Metric" - (layer "F.Cu") - (uuid "270ba536-7a4a-4ae0-a54f-802734007032") - (at 95.278 61.214 180) - (descr "Capacitor SMD 0402 (1005 Metric), square (rectangular) end terminal, IPC_7351 nominal, (Body size source: IPC-SM-782 page 76, https://www.pcb-3d.com/wordpress/wp-content/uploads/ipc-sm-782a_amendment_1_and_2.pdf), generated with kicad-footprint-generator") - (tags "capacitor") - (property "Reference" "C208" - (at 0 -1.16 0) - (layer "F.SilkS") - (hide yes) - (uuid "80ca5d39-c768-42b1-920b-9a5721fb5a04") - (effects - (font - (size 1 1) - (thickness 0.15) - ) - ) - ) - (property "Value" "100nF" - (at 0 1.16 0) - (layer "F.Fab") - (uuid "d5200809-a913-4ab6-a800-c05384ebe49a") - (effects - (font - (size 1 1) - (thickness 0.15) - ) - ) - ) - (property "Datasheet" "" - (at 0 0 180) - (unlocked yes) - (layer "F.Fab") - (hide yes) - (uuid "dee87d63-419d-4a91-94b8-747a6d2ac086") - (effects - (font - (size 1.27 1.27) - (thickness 0.15) - ) - ) - ) - (property "Description" "Unpolarized capacitor" - (at 0 0 180) - (unlocked yes) - (layer "F.Fab") - (hide yes) - (uuid "269d3f6c-1809-4d1e-9690-f5849e43e824") - (effects - (font - (size 1.27 1.27) - (thickness 0.15) - ) - ) - ) - (property "LCSC" "C1525" - (at 0 0 180) - (unlocked yes) - (layer "F.Fab") - (hide yes) - (uuid "1b432fba-c068-4bfc-8051-33c8ef6db1d7") - (effects - (font - (size 1 1) - (thickness 0.15) - ) - ) - ) - (property ki_fp_filters "C_*") - (path "/5c46d7fe-34fa-4f56-9c85-0d1525266e94/b951972a-e60b-40a5-b0ac-20a8a2d0a69d") - (sheetname "/MCU/") - (sheetfile "mcu.kicad_sch") - (attr smd) - (fp_line - (start -0.107836 0.36) - (end 0.107836 0.36) - (stroke - (width 0.12) - (type solid) - ) - (layer "F.SilkS") - (uuid "de8df60a-4263-47d4-adf3-98da416d8d3a") - ) - (fp_line - (start -0.107836 -0.36) - (end 0.107836 -0.36) - (stroke - (width 0.12) - (type solid) - ) - (layer "F.SilkS") - (uuid "c08c23d2-c562-493f-8562-7255bb940f4f") - ) - (fp_line - (start 0.91 0.46) - (end -0.91 0.46) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "9be9d73c-38b2-4106-aed8-d79076d688d8") - ) - (fp_line - (start 0.91 -0.46) - (end 0.91 0.46) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "9440f4e3-9662-4a72-9c0c-e9d5dfb0e764") - ) - (fp_line - (start -0.91 0.46) - (end -0.91 -0.46) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "0a300ea6-101f-498b-b4cb-d6017f9d5bfb") - ) - (fp_line - (start -0.91 -0.46) - (end 0.91 -0.46) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "657f046f-7962-4a8c-b592-65235a31408b") - ) - (fp_line - (start 0.5 0.25) - (end -0.5 0.25) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "6636375f-5128-4d87-a6b7-84f8909c8d9d") - ) - (fp_line - (start 0.5 -0.25) - (end 0.5 0.25) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "3ff51412-538d-4df0-b0bc-0bcb66aeba18") - ) - (fp_line - (start -0.5 0.25) - (end -0.5 -0.25) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "d3a873b7-fec6-45f3-9d39-3e24cac218f5") - ) - (fp_line - (start -0.5 -0.25) - (end 0.5 -0.25) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "ab780553-9873-479d-a7fc-946b8f2299a6") - ) - (fp_text user "${REFERENCE}" - (at 0 0 0) - (layer "F.Fab") - (uuid "18781bd5-f601-4c4b-90bf-205b2361cc18") - (effects - (font - (size 0.25 0.25) - (thickness 0.04) - ) - ) - ) - (pad "1" smd roundrect - (at -0.48 0 180) - (size 0.56 0.62) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 1 "3V3") - (pintype "passive") - (uuid "72846cb2-3a90-4de5-ae9d-7cd5a2e6d9f0") - ) - (pad "2" smd roundrect - (at 0.48 0 180) - (size 0.56 0.62) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 2 "GND") - (pintype "passive") - (uuid "e645413e-49c3-4f67-8ab1-10267da04241") - ) - (embedded_fonts no) - (model "${KICAD9_3DMODEL_DIR}/Capacitor_SMD.3dshapes/C_0402_1005Metric.wrl" - (offset - (xyz 0 0 0) - ) - (scale - (xyz 1 1 1) - ) - (rotate - (xyz 0 0 0) - ) - ) - ) (footprint "Package_QFP:LQFP-48_7x7mm_P0.5mm" (layer "F.Cu") (uuid "281f5fe7-4ad0-43ca-8365-ea73ecc30513") @@ -3579,7 +3049,7 @@ (footprint "Package_TO_SOT_SMD:SOT-223-3_TabPin2" (layer "F.Cu") (uuid "4b30fc8e-489d-40bb-bf45-9a5fd275734c") - (at 105.537 102.743 180) + (at 103.124 114.554 180) (descr "module CMS SOT223 4 pins") (tags "CMS SOT") (property "Reference" "U302" @@ -3864,7 +3334,7 @@ (at 0 -1.68 0) (layer "F.SilkS") (hide yes) - (uuid "f7e8bae4-0a36-4b0e-83ce-33fd3a393e6d") + (uuid "497ac347-b9d0-4339-a862-5ae3e08bf385") (effects (font (size 1 1) @@ -3875,7 +3345,7 @@ (property "Value" "22uF" (at 0 1.68 0) (layer "F.Fab") - (uuid "58e500e3-92fd-439c-b2d1-4760197bca85") + (uuid "74692032-cb9d-4ab9-8eef-ebb8010cc0b6") (effects (font (size 1 1) @@ -3888,7 +3358,7 @@ (unlocked yes) (layer "F.Fab") (hide yes) - (uuid "63e3e8a5-8aaf-47be-b1f5-a624ec1f7787") + (uuid "f54660eb-b7b5-4159-a0d6-af311dd2f9cd") (effects (font (size 1.27 1.27) @@ -3901,7 +3371,7 @@ (unlocked yes) (layer "F.Fab") (hide yes) - (uuid "f2f6fd5c-8d7d-4341-a3d3-ebacaa0a7182") + (uuid "4651d4d2-1a44-4e07-9842-c1236947c9cb") (effects (font (size 1.27 1.27) @@ -5352,7 +4822,7 @@ (drill 0.9144) (layers "*.Cu" "*.Mask") (remove_unused_layers no) - (net 4 "Vin") + (net 2 "GND") (pintype "passive") (uuid "584ddaa3-67e6-4c1c-97b4-991f84d32f93") ) @@ -5372,7 +4842,7 @@ (drill 0.9144) (layers "*.Cu" "*.Mask") (remove_unused_layers no) - (net 4 "Vin") + (net 2 "GND") (pintype "passive") (uuid "94a59f35-f5e6-43fe-a4e2-a51b4d5a44f1") ) @@ -5382,7 +4852,7 @@ (drill 0.9144) (layers "*.Cu" "*.Mask") (remove_unused_layers no) - (net 2 "GND") + (net 4 "Vin") (pintype "passive") (uuid "47f0ac34-841c-462a-88e3-beab46b993c1") ) @@ -5402,7 +4872,7 @@ (drill 0.9144) (layers "*.Cu" "*.Mask") (remove_unused_layers no) - (net 2 "GND") + (net 4 "Vin") (pintype "passive") (uuid "329d07d3-4b22-42b7-a8a7-a57baac05db8") ) @@ -5866,7 +5336,7 @@ (at 0 -1.68 0) (layer "F.SilkS") (hide yes) - (uuid "23908cf6-7d06-4dc4-ad75-ec219fc4df87") + (uuid "bb0a060e-5133-4912-800f-ab798e42c4ca") (effects (font (size 1 1) @@ -5877,7 +5347,7 @@ (property "Value" "22uF" (at 0 1.68 0) (layer "F.Fab") - (uuid "566c416c-4f02-41dd-b6f0-8f3ab09f478c") + (uuid "4594db2d-1b47-4d35-855a-6f41bf8088e5") (effects (font (size 1 1) @@ -5890,7 +5360,7 @@ (unlocked yes) (layer "F.Fab") (hide yes) - (uuid "95220285-c2e6-442e-bc20-aac0b876ede5") + (uuid "0f70b0ba-9823-4945-8408-37d19d0e711d") (effects (font (size 1.27 1.27) @@ -5903,7 +5373,7 @@ (unlocked yes) (layer "F.Fab") (hide yes) - (uuid "0fab2403-ed6b-4c1c-9eae-855ebcdda3b3") + (uuid "d6d73340-2e68-4de1-bf5f-76748b864b0d") (effects (font (size 1.27 1.27) @@ -7206,6 +6676,309 @@ ) ) ) + (footprint "Package_SO:SOIC-8_3.9x4.9mm_P1.27mm" + (layer "F.Cu") + (uuid "889ebe10-f655-42df-8f9f-bdc7d0fdfc59") + (at 104.14 83.247 -90) + (descr "SOIC, 8 Pin (JEDEC MS-012AA, https://www.analog.com/media/en/package-pcb-resources/package/pkg_pdf/soic_narrow-r/r_8.pdf), generated with kicad-footprint-generator ipc_gullwing_generator.py") + (tags "SOIC SO") + (property "Reference" "U203" + (at 0 -3.4 90) + (layer "F.SilkS") + (uuid "ca865f76-44d8-4686-ae4e-5f3466629cd2") + (effects + (font + (size 1 1) + (thickness 0.15) + ) + ) + ) + (property "Value" "SN65HVD230" + (at 0 3.4 90) + (layer "F.Fab") + (uuid "ebcfd664-ec42-482c-a82b-8009fb50732e") + (effects + (font + (size 1 1) + (thickness 0.15) + ) + ) + ) + (property "Datasheet" "http://www.ti.com/lit/ds/symlink/sn65hvd230.pdf" + (at 0 0 90) + (layer "F.Fab") + (hide yes) + (uuid "13e205be-e30d-43a5-9720-f4d950498e45") + (effects + (font + (size 1.27 1.27) + (thickness 0.15) + ) + ) + ) + (property "Description" "CAN Bus Transceivers, 3.3V, 1Mbps, Low-Power capabilities, SOIC-8" + (at 0 0 90) + (layer "F.Fab") + (hide yes) + (uuid "c5a49003-44a9-4505-952e-2b1eeafbe3b0") + (effects + (font + (size 1.27 1.27) + (thickness 0.15) + ) + ) + ) + (property ki_fp_filters "SOIC*3.9x4.9mm*P1.27mm*") + (path "/5c46d7fe-34fa-4f56-9c85-0d1525266e94/96c1e221-1f32-4b6a-97b1-9166e2fa03db") + (sheetname "/MCU/") + (sheetfile "mcu.kicad_sch") + (attr smd) + (fp_line + (start 0 2.56) + (end -1.95 2.56) + (stroke + (width 0.12) + (type solid) + ) + (layer "F.SilkS") + (uuid "97f771d1-d98a-402d-9396-7109f47a0aa3") + ) + (fp_line + (start 0 2.56) + (end 1.95 2.56) + (stroke + (width 0.12) + (type solid) + ) + (layer "F.SilkS") + (uuid "bc93eaa0-bb65-4056-b82f-17a0492bb11d") + ) + (fp_line + (start 0 -2.56) + (end -1.95 -2.56) + (stroke + (width 0.12) + (type solid) + ) + (layer "F.SilkS") + (uuid "153d09d0-1147-4077-974d-ced9c4360f80") + ) + (fp_line + (start 0 -2.56) + (end 1.95 -2.56) + (stroke + (width 0.12) + (type solid) + ) + (layer "F.SilkS") + (uuid "272c039e-4c8c-4cb1-8009-205317dc95eb") + ) + (fp_poly + (pts + (xy -2.7 -2.465) (xy -2.94 -2.795) (xy -2.46 -2.795) (xy -2.7 -2.465) + ) + (stroke + (width 0.12) + (type solid) + ) + (fill yes) + (layer "F.SilkS") + (uuid "a21fd8f1-a8d1-485b-938b-94d600778100") + ) + (fp_line + (start -3.7 2.7) + (end 3.7 2.7) + (stroke + (width 0.05) + (type solid) + ) + (layer "F.CrtYd") + (uuid "b45d601a-da10-47ba-a484-5aea6f495721") + ) + (fp_line + (start 3.7 2.7) + (end 3.7 -2.7) + (stroke + (width 0.05) + (type solid) + ) + (layer "F.CrtYd") + (uuid "4e35e419-235c-4b13-bbb6-0db103d2007a") + ) + (fp_line + (start -3.7 -2.7) + (end -3.7 2.7) + (stroke + (width 0.05) + (type solid) + ) + (layer "F.CrtYd") + (uuid "427fe77f-bead-41de-ad6a-8efcebdcf0e9") + ) + (fp_line + (start 3.7 -2.7) + (end -3.7 -2.7) + (stroke + (width 0.05) + (type solid) + ) + (layer "F.CrtYd") + (uuid "26021c20-0f82-40b2-a5ad-6a2f0a2fde04") + ) + (fp_line + (start -1.95 2.45) + (end -1.95 -1.475) + (stroke + (width 0.1) + (type solid) + ) + (layer "F.Fab") + (uuid "b16bb282-1fe2-4160-94fb-588fbed9b432") + ) + (fp_line + (start 1.95 2.45) + (end -1.95 2.45) + (stroke + (width 0.1) + (type solid) + ) + (layer "F.Fab") + (uuid "c319c3ea-7c2a-4729-8d14-e77b7d3a218a") + ) + (fp_line + (start -1.95 -1.475) + (end -0.975 -2.45) + (stroke + (width 0.1) + (type solid) + ) + (layer "F.Fab") + (uuid "f30ef444-2f53-4658-ba58-9b2398d774c4") + ) + (fp_line + (start -0.975 -2.45) + (end 1.95 -2.45) + (stroke + (width 0.1) + (type solid) + ) + (layer "F.Fab") + (uuid "33e234bc-fc90-42d8-9744-667caf3f6c33") + ) + (fp_line + (start 1.95 -2.45) + (end 1.95 2.45) + (stroke + (width 0.1) + (type solid) + ) + (layer "F.Fab") + (uuid "05d56024-796b-490a-976c-8cc956342fef") + ) + (fp_text user "${REFERENCE}" + (at 0 0 90) + (layer "F.Fab") + (uuid "05e5d05d-af63-4e93-b1f3-6fa53194e0b5") + (effects + (font + (size 0.98 0.98) + (thickness 0.15) + ) + ) + ) + (pad "1" smd roundrect + (at -2.475 -1.905 270) + (size 1.95 0.6) + (layers "F.Cu" "F.Mask" "F.Paste") + (roundrect_rratio 0.25) + (net 13 "/MCU/CANTXD") + (pinfunction "D") + (pintype "input") + (uuid "1ad0810e-bb2e-48d9-b20b-da0b069e8690") + ) + (pad "2" smd roundrect + (at -2.475 -0.635 270) + (size 1.95 0.6) + (layers "F.Cu" "F.Mask" "F.Paste") + (roundrect_rratio 0.25) + (net 2 "GND") + (pinfunction "GND") + (pintype "power_in") + (uuid "a190a0c7-0375-45d5-a0a2-1024da0f8994") + ) + (pad "3" smd roundrect + (at -2.475 0.635 270) + (size 1.95 0.6) + (layers "F.Cu" "F.Mask" "F.Paste") + (roundrect_rratio 0.25) + (net 1 "3V3") + (pinfunction "VCC") + (pintype "power_in") + (uuid "8bbb8b77-8af6-4ed4-942b-379636ecc880") + ) + (pad "4" smd roundrect + (at -2.475 1.905 270) + (size 1.95 0.6) + (layers "F.Cu" "F.Mask" "F.Paste") + (roundrect_rratio 0.25) + (net 12 "/MCU/CANRXD") + (pinfunction "R") + (pintype "output") + (uuid "55c10e06-c15c-4a24-a0f0-a2df445b8647") + ) + (pad "5" smd roundrect + (at 2.475 1.905 270) + (size 1.95 0.6) + (layers "F.Cu" "F.Mask" "F.Paste") + (roundrect_rratio 0.25) + (net 59 "unconnected-(U203-Vref-Pad5)") + (pinfunction "Vref") + (pintype "output") + (uuid "cb9905d4-c237-4d77-bc71-81401eeedc8b") + ) + (pad "6" smd roundrect + (at 2.475 0.635 270) + (size 1.95 0.6) + (layers "F.Cu" "F.Mask" "F.Paste") + (roundrect_rratio 0.25) + (net 10 "/MCU/CAN HIGH") + (pinfunction "CANL") + (pintype "bidirectional") + (uuid "e4334db5-23be-4d34-a334-96dbf076d82e") + ) + (pad "7" smd roundrect + (at 2.475 -0.635 270) + (size 1.95 0.6) + (layers "F.Cu" "F.Mask" "F.Paste") + (roundrect_rratio 0.25) + (net 11 "/MCU/CAN LOW") + (pinfunction "CANH") + (pintype "bidirectional") + (uuid "78cfb995-1848-482f-aa4d-ddb660da43ce") + ) + (pad "8" smd roundrect + (at 2.475 -1.905 270) + (size 1.95 0.6) + (layers "F.Cu" "F.Mask" "F.Paste") + (roundrect_rratio 0.25) + (net 2 "GND") + (pinfunction "Rs") + (pintype "input") + (uuid "c73ae567-2f2d-403c-a7bf-ca1fe405045b") + ) + (embedded_fonts no) + (model "${KICAD9_3DMODEL_DIR}/Package_SO.3dshapes/SOIC-8_3.9x4.9mm_P1.27mm.wrl" + (offset + (xyz 0 0 0) + ) + (scale + (xyz 1 1 1) + ) + (rotate + (xyz 0 0 0) + ) + ) + ) (footprint "Connector_JST:JST_PH_B4B-PH-K_1x04_P2.00mm_Vertical" (layer "F.Cu") (uuid "892d3ef3-c17f-49bc-aa91-ecfb14fa6672") @@ -7764,221 +7537,6 @@ ) ) ) - (footprint "Capacitor_SMD:C_0402_1005Metric" - (layer "F.Cu") - (uuid "8ae94773-d698-4824-9093-d6553878f754") - (at 104.521 62.258 90) - (descr "Capacitor SMD 0402 (1005 Metric), square (rectangular) end terminal, IPC_7351 nominal, (Body size source: IPC-SM-782 page 76, https://www.pcb-3d.com/wordpress/wp-content/uploads/ipc-sm-782a_amendment_1_and_2.pdf), generated with kicad-footprint-generator") - (tags "capacitor") - (property "Reference" "C211" - (at 0 -1.16 90) - (layer "F.SilkS") - (hide yes) - (uuid "14b19268-5a5b-47b7-ac65-16defafe418a") - (effects - (font - (size 1 1) - (thickness 0.15) - ) - ) - ) - (property "Value" "100nF" - (at 0 1.16 90) - (layer "F.Fab") - (uuid "b0cf834e-6345-4bdc-a3a6-c7353d642025") - (effects - (font - (size 1 1) - (thickness 0.15) - ) - ) - ) - (property "Datasheet" "" - (at 0 0 90) - (unlocked yes) - (layer "F.Fab") - (hide yes) - (uuid "1237d4e3-3d96-43a5-8f33-81c07362b982") - (effects - (font - (size 1.27 1.27) - (thickness 0.15) - ) - ) - ) - (property "Description" "Unpolarized capacitor" - (at 0 0 90) - (unlocked yes) - (layer "F.Fab") - (hide yes) - (uuid "08e66cf7-9589-4d17-9192-3a8ec7110157") - (effects - (font - (size 1.27 1.27) - (thickness 0.15) - ) - ) - ) - (property "LCSC" "C1525" - (at 0 0 90) - (unlocked yes) - (layer "F.Fab") - (hide yes) - (uuid "09dd6138-829f-494a-9efc-756d269db186") - (effects - (font - (size 1 1) - (thickness 0.15) - ) - ) - ) - (property ki_fp_filters "C_*") - (path "/5c46d7fe-34fa-4f56-9c85-0d1525266e94/ad3a5b6b-340e-40a7-bce4-8141e5f3c6be") - (sheetname "/MCU/") - (sheetfile "mcu.kicad_sch") - (attr smd) - (fp_line - (start -0.107836 -0.36) - (end 0.107836 -0.36) - (stroke - (width 0.12) - (type solid) - ) - (layer "F.SilkS") - (uuid "bea06c22-8c5f-4786-9134-76bb29485a87") - ) - (fp_line - (start -0.107836 0.36) - (end 0.107836 0.36) - (stroke - (width 0.12) - (type solid) - ) - (layer "F.SilkS") - (uuid "c53607bd-ea9e-4c11-bf1b-6c5f7dbeb18a") - ) - (fp_line - (start 0.91 -0.46) - (end 0.91 0.46) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "99563eab-52e0-4d69-8afb-8d0e6d386a2c") - ) - (fp_line - (start -0.91 -0.46) - (end 0.91 -0.46) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "75fd32e3-60f3-4bf6-aac4-d8f223bf8b12") - ) - (fp_line - (start 0.91 0.46) - (end -0.91 0.46) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "c441daa5-b362-45b7-be9b-009bee744bd7") - ) - (fp_line - (start -0.91 0.46) - (end -0.91 -0.46) - (stroke - (width 0.05) - (type solid) - ) - (layer "F.CrtYd") - (uuid "33ed3671-f008-44dd-a8bb-e24c1522341b") - ) - (fp_line - (start 0.5 -0.25) - (end 0.5 0.25) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "aefd6ea7-780b-4aee-a7f9-c14c5438e47c") - ) - (fp_line - (start -0.5 -0.25) - (end 0.5 -0.25) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "d382c3df-3e69-49bd-965f-dedb0932079b") - ) - (fp_line - (start 0.5 0.25) - (end -0.5 0.25) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "4454fe3c-71a1-48c6-922f-3627daba4eb0") - ) - (fp_line - (start -0.5 0.25) - (end -0.5 -0.25) - (stroke - (width 0.1) - (type solid) - ) - (layer "F.Fab") - (uuid "84955b45-677b-4f3b-817d-c6990a3aae82") - ) - (fp_text user "${REFERENCE}" - (at 0 0 90) - (layer "F.Fab") - (uuid "b6927c6e-7307-4aca-9172-ce1e459b794e") - (effects - (font - (size 0.25 0.25) - (thickness 0.04) - ) - ) - ) - (pad "1" smd roundrect - (at -0.48 0 90) - (size 0.56 0.62) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 3 "5V0") - (pintype "passive") - (uuid "1cfb59c7-1e77-4bae-b019-a2820e8ab508") - ) - (pad "2" smd roundrect - (at 0.48 0 90) - (size 0.56 0.62) - (layers "F.Cu" "F.Mask" "F.Paste") - (roundrect_rratio 0.25) - (net 2 "GND") - (pintype "passive") - (uuid "18f8946c-8e64-40ff-9061-26692e8e536a") - ) - (embedded_fonts no) - (model "${KICAD9_3DMODEL_DIR}/Capacitor_SMD.3dshapes/C_0402_1005Metric.wrl" - (offset - (xyz 0 0 0) - ) - (scale - (xyz 1 1 1) - ) - (rotate - (xyz 0 0 0) - ) - ) - ) (footprint "Capacitor_SMD:C_0402_1005Metric" (layer "F.Cu") (uuid "8c841a17-08e3-4645-a2ff-32b246e3e9b1") @@ -8450,7 +8008,7 @@ (footprint "Capacitor_SMD:C_0805_2012Metric" (layer "F.Cu") (uuid "9da8a78d-4f8a-4e40-bcc2-15c7a7fb8928") - (at 106.24 66.04 90) + (at 109.474 61.595 90) (descr "Capacitor SMD 0805 (2012 Metric), square (rectangular) end terminal, IPC_7351 nominal, (Body size source: IPC-SM-782 page 76, https://www.pcb-3d.com/wordpress/wp-content/uploads/ipc-sm-782a_amendment_1_and_2.pdf, https://docs.google.com/spreadsheets/d/1BsfQQcO9C6DZCsRaXUlFlo91Tg2WpOkGARC1WS5S8t0/edit?usp=sharing), generated with kicad-footprint-generator") (tags "capacitor") (property "Reference" "C301" @@ -8846,7 +8404,7 @@ (drill 0.9144) (layers "*.Cu" "*.Mask") (remove_unused_layers no) - (net 4 "Vin") + (net 2 "GND") (pintype "passive") (uuid "2206aa8d-71bd-4f4f-ac9e-21abf3618d42") ) @@ -8866,7 +8424,7 @@ (drill 0.9144) (layers "*.Cu" "*.Mask") (remove_unused_layers no) - (net 4 "Vin") + (net 2 "GND") (pintype "passive") (uuid "904e08a6-a7f0-45a2-818c-a156a7e3c22c") ) @@ -8876,7 +8434,7 @@ (drill 0.9144) (layers "*.Cu" "*.Mask") (remove_unused_layers no) - (net 2 "GND") + (net 4 "Vin") (pintype "passive") (uuid "53d48fee-0843-46c2-8e5e-8905d774d893") ) @@ -8896,7 +8454,7 @@ (drill 0.9144) (layers "*.Cu" "*.Mask") (remove_unused_layers no) - (net 2 "GND") + (net 4 "Vin") (pintype "passive") (uuid "08701f0b-5c0e-4923-b60c-338d97d1437a") ) @@ -10529,7 +10087,7 @@ (footprint "Capacitor_SMD:C_0805_2012Metric" (layer "F.Cu") (uuid "b698cc84-437a-4f56-a393-dc599327d580") - (at 111.125 100.965 -90) + (at 108.712 112.776 -90) (descr "Capacitor SMD 0805 (2012 Metric), square (rectangular) end terminal, IPC_7351 nominal, (Body size source: IPC-SM-782 page 76, https://www.pcb-3d.com/wordpress/wp-content/uploads/ipc-sm-782a_amendment_1_and_2.pdf, https://docs.google.com/spreadsheets/d/1BsfQQcO9C6DZCsRaXUlFlo91Tg2WpOkGARC1WS5S8t0/edit?usp=sharing), generated with kicad-footprint-generator") (tags "capacitor") (property "Reference" "C302" @@ -10942,7 +10500,7 @@ (footprint "Capacitor_SMD:C_0805_2012Metric" (layer "F.Cu") (uuid "c7210011-d004-4055-b20a-48120aca07c5") - (at 106.24 62.484 90) + (at 109.474 58.039 90) (descr "Capacitor SMD 0805 (2012 Metric), square (rectangular) end terminal, IPC_7351 nominal, (Body size source: IPC-SM-782 page 76, https://www.pcb-3d.com/wordpress/wp-content/uploads/ipc-sm-782a_amendment_1_and_2.pdf, https://docs.google.com/spreadsheets/d/1BsfQQcO9C6DZCsRaXUlFlo91Tg2WpOkGARC1WS5S8t0/edit?usp=sharing), generated with kicad-footprint-generator") (tags "capacitor") (property "Reference" "C303" @@ -11373,7 +10931,7 @@ (footprint "Capacitor_SMD:C_0805_2012Metric" (layer "F.Cu") (uuid "cc25fe47-5c51-4063-8eb0-15adc5268186") - (at 111.125 104.521 -90) + (at 108.712 116.332 -90) (descr "Capacitor SMD 0805 (2012 Metric), square (rectangular) end terminal, IPC_7351 nominal, (Body size source: IPC-SM-782 page 76, https://www.pcb-3d.com/wordpress/wp-content/uploads/ipc-sm-782a_amendment_1_and_2.pdf, https://docs.google.com/spreadsheets/d/1BsfQQcO9C6DZCsRaXUlFlo91Tg2WpOkGARC1WS5S8t0/edit?usp=sharing), generated with kicad-footprint-generator") (tags "capacitor") (property "Reference" "C304" @@ -11588,7 +11146,7 @@ (footprint "Package_TO_SOT_SMD:SOT-223-3_TabPin2" (layer "F.Cu") (uuid "cf0cb135-e55b-484d-9f54-94e3e1a74db8") - (at 111.76 64.262) + (at 114.994 59.817) (descr "module CMS SOT223 4 pins") (tags "CMS SOT") (property "Reference" "U301" @@ -12701,168 +12259,8 @@ ) ) ) - (segment - (start 101.721 80.2) - (end 101.149 80.772) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "0836fc3f-61ac-423e-9425-85083d59dcec") - ) - (segment - (start 116.6745 80.7) - (end 116.049 80.7) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "0a72fad9-12c0-4665-838e-e59585c844b8") - ) - (segment - (start 101.149 96.831) - (end 107.061 102.743) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "0bbc4312-162a-45c3-a1f0-865286fdf637") - ) - (segment - (start 113.65 89.929) - (end 113.792 90.071) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "111f7c2e-b6b9-442c-9a2b-e44be7fcbc97") - ) - (segment - (start 113.65 88.5625) - (end 113.65 89.929) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "20c0657d-700c-4bcd-a1c0-82da07846b99") - ) - (segment - (start 107.061 102.743) - (end 108.687 102.743) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "2b392aae-e5ef-4d5d-82f0-fceb9ba0f236") - ) - (segment - (start 101.149 80.772) - (end 101.149 90.043) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "377e02e5-8277-4400-aae1-9d1294c80cba") - ) - (segment - (start 95.758 61.214) - (end 97.406 61.214) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "5aacc330-59c4-4499-a012-485e65437f0b") - ) - (segment - (start 116.049 80.7) - (end 115.85 80.899) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "8329d63c-2d89-49a9-a0ad-768a95202df7") - ) - (segment - (start 97.525 61.095) - (end 98.499999 61.095) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "8ce8457a-ee33-4e0e-9ceb-7ac43018d5fb") - ) - (segment - (start 98.499999 61.095) - (end 101.149 63.744001) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "8d664503-ddcd-42f8-b123-b21376200a88") - ) - (segment - (start 108.1545 88.409999) - (end 106.521499 90.043) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "990bef96-30b6-4396-a606-baf367bc5da5") - ) - (segment - (start 101.149 90.043) - (end 101.149 96.831) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "a565b3e8-c7a6-4eae-b118-5d91bb9fb85e") - ) - (segment - (start 108.077 80.2) - (end 101.721 80.2) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "ae08701e-e7c8-4e55-8a8a-50fb77802052") - ) - (segment - (start 108.1545 88.1) - (end 108.1545 88.409999) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "c9671937-7861-4e3b-9ac5-45fbd7c602e7") - ) - (segment - (start 108.7745 80.2) - (end 108.077 80.2) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "d1852136-5d8b-42f0-8714-4fc2b827649d") - ) - (segment - (start 106.521499 90.043) - (end 101.149 90.043) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "e3b3d81c-21eb-4272-b724-c83d10d2fda0") - ) - (segment - (start 101.149 63.744001) - (end 101.149 80.772) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "eede7474-2379-4955-9731-9962fccf2171") - ) - (segment - (start 97.406 61.214) - (end 97.525 61.095) - (width 0.4) - (layer "F.Cu") - (net 1) - (uuid "f00f1bc6-9ad7-4741-8e4e-05ba8a40dbd1") - ) (via - (at 106.521499 90.043) - (size 0.8) - (drill 0.4) - (layers "F.Cu" "B.Cu") - (net 1) - (uuid "09a4dda5-690a-4443-853a-25a090d82c5b") - ) - (via - (at 101.346 103.759) + (at 98.933 115.57) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12871,7 +12269,7 @@ (uuid "2aa50c87-60d4-4523-b4a1-30cceb8a5fc4") ) (via - (at 101.346 102.743) + (at 98.933 114.554) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12880,7 +12278,7 @@ (uuid "42150aec-efb8-4d86-8f18-952cf14cb944") ) (via - (at 101.346 104.775) + (at 98.933 116.586) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12889,7 +12287,7 @@ (uuid "42c4c8a3-589b-46e7-a10c-0df570ca5e6f") ) (via - (at 101.346 100.711) + (at 98.933 112.522) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12898,7 +12296,7 @@ (uuid "6c7beb96-a5aa-46d4-bd83-2dfda9b5db76") ) (via - (at 103.505 101.727) + (at 101.092 113.538) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12907,7 +12305,7 @@ (uuid "7f0ef9bb-8bd0-4a62-8df6-666d441b3e0c") ) (via - (at 103.505 103.759) + (at 101.092 115.57) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12916,7 +12314,7 @@ (uuid "832eb1e3-ce33-48b7-9790-47ddf71bb281") ) (via - (at 102.489 104.775) + (at 100.076 116.586) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12925,7 +12323,7 @@ (uuid "9663c46e-6c60-4ac4-8da2-0a3d6d7bce80") ) (via - (at 102.489 100.711) + (at 100.076 112.522) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12934,15 +12332,7 @@ (uuid "a43d3d39-0b08-45c2-a2f8-7e33d1d6c9dd") ) (via - (at 108.077 80.2) - (size 0.8) - (drill 0.4) - (layers "F.Cu" "B.Cu") - (net 1) - (uuid "a7707d7c-0ddf-474f-8136-ef9c514d2275") - ) - (via - (at 103.505 100.711) + (at 101.092 112.522) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12951,7 +12341,7 @@ (uuid "b8994269-df90-4d88-a4f3-8999aecdc3e8") ) (via - (at 101.346 101.727) + (at 98.933 113.538) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12960,7 +12350,7 @@ (uuid "c2bf0401-f1ad-4d16-b2b2-c49eae772225") ) (via - (at 103.505 102.743) + (at 101.092 114.554) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12969,23 +12359,7 @@ (uuid "d0b3372d-8a85-40e9-855a-de3110286482") ) (via - (at 114.3 90.043) - (size 0.8) - (drill 0.4) - (layers "F.Cu" "B.Cu") - (net 1) - (uuid "e39da303-a06b-42ec-b148-2028249bafe5") - ) - (via - (at 115.85 80.899) - (size 0.8) - (drill 0.4) - (layers "F.Cu" "B.Cu") - (net 1) - (uuid "e575947e-e658-4aee-a7b1-9fb80dc8d2e3") - ) - (via - (at 103.505 104.775) + (at 101.092 116.586) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -12993,64 +12367,8 @@ (net 1) (uuid "f4c38f4b-bf42-450b-88cd-a2f1f7034426") ) - (segment - (start 106.521499 90.043) - (end 114.3 90.043) - (width 0.4) - (layer "B.Cu") - (net 1) - (uuid "1c74f5cd-283c-40ca-a347-3fd42cceedc1") - ) - (segment - (start 108.776 80.899) - (end 108.077 80.2) - (width 0.4) - (layer "B.Cu") - (net 1) - (uuid "9e4dcc95-40eb-41f6-88aa-2a5cd30cd660") - ) - (segment - (start 115.85 80.899) - (end 108.776 80.899) - (width 0.4) - (layer "B.Cu") - (net 1) - (uuid "f26da1b5-5d42-406f-8a25-0373a4a31b0b") - ) - (segment - (start 105.544 62.738) - (end 106.24 63.434) - (width 0.4) - (layer "F.Cu") - (net 3) - (uuid "53e8ca04-d036-487e-b606-ac25e958ddf6") - ) - (segment - (start 102.475 62.365) - (end 102.848 62.738) - (width 0.4) - (layer "F.Cu") - (net 3) - (uuid "807fb4e7-38e0-4cc9-8547-305e3feb9aca") - ) - (segment - (start 104.521 62.738) - (end 105.544 62.738) - (width 0.4) - (layer "F.Cu") - (net 3) - (uuid "86d35a8c-532b-498f-81a6-4d20ad6a04b6") - ) - (segment - (start 102.848 62.738) - (end 104.521 62.738) - (width 0.4) - (layer "F.Cu") - (net 3) - (uuid "a6dcf572-9cc9-484f-8ad6-d28ab06cc5ce") - ) (via - (at 113.86 65.278) + (at 117.094 60.833) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13059,7 +12377,7 @@ (uuid "1dc6327a-899c-4a07-9539-b0e5f98d4c4b") ) (via - (at 116.019 62.23) + (at 119.253 57.785) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13068,7 +12386,7 @@ (uuid "25a08817-dbd2-48ee-bdfd-25240c472eed") ) (via - (at 113.86 64.262) + (at 117.094 59.817) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13077,7 +12395,7 @@ (uuid "363dfdc6-7eaf-4f9a-addb-888171ba75d8") ) (via - (at 113.86 63.246) + (at 117.094 58.801) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13086,7 +12404,7 @@ (uuid "4c9f9375-b03e-4ffe-9dc8-999cc768cfcf") ) (via - (at 116.019 65.278) + (at 119.253 60.833) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13095,7 +12413,7 @@ (uuid "6069e9a6-8b5c-415d-84e6-2ecea4f61ad6") ) (via - (at 114.876 66.294) + (at 118.11 61.849) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13104,7 +12422,7 @@ (uuid "725f11ff-ccb8-44c3-b45a-0c8917de93ed") ) (via - (at 116.019 63.246) + (at 119.253 58.801) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13113,7 +12431,7 @@ (uuid "bd042c9e-aef1-42b7-94d0-58babfa5611a") ) (via - (at 113.86 62.23) + (at 117.094 57.785) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13122,7 +12440,7 @@ (uuid "bff4086b-e89d-4101-a8a5-3387c92e3e89") ) (via - (at 116.019 66.294) + (at 119.253 61.849) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13131,7 +12449,7 @@ (uuid "ceaa1e55-9398-42cc-a3ca-3112f32fddbf") ) (via - (at 116.019 64.262) + (at 119.253 59.817) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13140,7 +12458,7 @@ (uuid "de6f4437-a6f2-42ca-9abe-3a8cda6c5cf1") ) (via - (at 113.86 66.294) + (at 117.094 61.849) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13149,7 +12467,7 @@ (uuid "e2f0acb5-2b8a-4d1b-888d-0c35b809e192") ) (via - (at 114.876 62.23) + (at 118.11 57.785) (size 0.6) (drill 0.2) (layers "F.Cu" "B.Cu") @@ -13157,469 +12475,21 @@ (net 3) (uuid "f4cd99af-9e75-4f17-bf07-9c6426d47166") ) - (segment - (start 109.158 76.962) - (end 114.108 76.962) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "462f96bb-c031-416f-a19b-1cff7eb04100") - ) - (segment - (start 107.188 69.596) - (end 108.904 69.596) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "55ae8f4b-436b-4370-a8ef-958584c9b9c7") - ) - (segment - (start 107.188 69.215) - (end 106.299 68.326) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "5b014b16-9316-4156-a320-bc489ff814c6") - ) - (segment - (start 108.904 76.708) - (end 109.158 76.962) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "5c39494c-c79c-42ae-9ee5-7712fab6b9b8") - ) - (segment - (start 106.299 67.049) - (end 106.24 66.99) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "7bbe4695-8490-45e1-9a7a-e5a3778fc185") - ) - (segment - (start 107.188 69.596) - (end 107.188 69.215) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "8a27f77b-7b1d-4e3f-aab4-911259915c87") - ) - (segment - (start 107.188 69.596) - (end 107.188 76.708) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "8b3d6fb4-c7f8-4aaa-8898-9df5568cc5a5") - ) - (segment - (start 106.299 68.326) - (end 106.299 67.049) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "99e9aab9-fd0e-4840-8164-37bcd3d67a52") - ) - (segment - (start 109.158 69.342) - (end 114.108 69.342) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "9dbff0c9-6d51-42be-b577-e2e673de0d68") - ) - (segment - (start 108.904 69.596) - (end 109.158 69.342) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "a7597d01-78f8-4efa-bbc1-86cfbef36e26") - ) - (segment - (start 107.188 76.708) - (end 108.904 76.708) - (width 0.6) - (layer "F.Cu") - (net 4) - (uuid "c416354f-b616-4d16-bfed-277c85a94c32") - ) (via - (at 108.687 100.443) - (size 0.8) - (drill 0.4) + (at 96.232 86.483037) + (size 0.7) + (drill 0.3) (layers "F.Cu" "B.Cu") - (net 4) - (uuid "22caa0ff-de46-4ada-b356-155aaabf4b69") + (net 10) + (uuid "223c9771-6bfa-4621-a5cd-e52207034ad7") ) (via - (at 106.299 68.326) - (size 0.8) - (drill 0.4) - (layers "F.Cu" "B.Cu") - (net 4) - (uuid "79584238-b4e1-4639-a268-e8beb149818c") - ) - (segment - (start 92.54 70.37237) - (end 94.58637 68.326) - (width 0.6) - (layer "B.Cu") - (net 4) - (uuid "4cca43e8-5d98-429b-b41e-e59ed65d30dd") - ) - (segment - (start 91.247 98.130382) - (end 93.005618 99.889) - (width 0.6) - (layer "B.Cu") - (net 4) - (uuid "4e84e861-1c51-4b2d-adf4-f2a24ad2ed84") - ) - (segment - (start 94.58637 68.326) - (end 106.299 68.326) - (width 0.6) - (layer "B.Cu") - (net 4) - (uuid "628dda04-344b-45d6-ba11-d953a27e1912") - ) - (segment - (start 92.54 71.45) - (end 92.54 70.37237) - (width 0.6) - (layer "B.Cu") - (net 4) - (uuid "9ecb947e-6c4c-4e18-9c9f-c3b73d562a76") - ) - (segment - (start 93.005618 99.889) - (end 108.133 99.889) - (width 0.6) - (layer "B.Cu") - (net 4) - (uuid "b245ad60-e5f3-41f3-bf3d-726ee04609b2") - ) - (segment - (start 91.247 96.303) - (end 91.247 98.130382) - (width 0.6) - (layer "B.Cu") - (net 4) - (uuid "cdd2bb9e-79e4-426f-a2c7-4516fe78d5de") - ) - (segment - (start 92.51 95.04) - (end 91.247 96.303) - (width 0.6) - (layer "B.Cu") - (net 4) - (uuid "e06431aa-97df-40d8-a6db-c00f6573a4ee") - ) - (segment - (start 108.133 99.889) - (end 108.687 100.443) - (width 0.6) - (layer "B.Cu") - (net 4) - (uuid "f516632c-5206-4238-a13b-8e24216d5680") - ) - (segment - (start 94.732599 77.57) - (end 92.54 77.57) - (width 0.2) - (layer "F.Cu") - (net 10) - (uuid "0f684d73-ee56-475d-b782-22a4a1589b3f") - ) - (segment - (start 95.303 80.333) - (end 95.303 96.479599) - (width 0.2) - (layer "F.Cu") - (net 10) - (uuid "67478638-937a-4a2a-be6e-5e5fc5139b92") - ) - (segment - (start 97.801256 62.365) - (end 99.102 63.665744) - (width 0.2) - (layer "F.Cu") - (net 10) - (uuid "678ba6e2-8693-4929-b719-786e727bceac") - ) - (segment - (start 95.303 96.479599) - (end 94.702599 97.08) - (width 0.2) - (layer "F.Cu") - (net 10) - (uuid "6e78e415-850b-4ae3-9412-9d217472a6bd") - ) - (segment - (start 92.54 77.57) - (end 95.303 80.333) - (width 0.2) - (layer "F.Cu") - (net 10) - (uuid "74390219-472b-4a9c-bf5c-4791026d8dc5") - ) - (segment - (start 99.102 63.665744) - (end 99.102 73.200599) - (width 0.2) - (layer "F.Cu") - (net 10) - (uuid "81ddfd84-d833-40cc-9128-74f3a6881ff4") - ) - (segment - (start 99.102 73.200599) - (end 94.732599 77.57) - (width 0.2) - (layer "F.Cu") - (net 10) - (uuid "88975d57-ac6e-4205-a22e-f99417a471b6") - ) - (segment - (start 97.525 62.365) - (end 97.801256 62.365) - (width 0.2) - (layer "F.Cu") - (net 10) - (uuid "a9c75834-1eed-4fae-b43f-f25d368bcbcb") - ) - (segment - (start 94.702599 97.08) - (end 92.51 97.08) - (width 0.2) - (layer "F.Cu") - (net 10) - (uuid "adf81a02-4e5a-4682-9e54-639dfe35d44e") - ) - (segment - (start 98.751 72.119) - (end 94.32 76.55) - (width 0.2) - (layer "F.Cu") - (net 11) - (uuid "2bae5f49-abc6-49e8-9a0a-8f90cd701e21") - ) - (segment - (start 98.751 64.584744) - (end 98.751 72.119) - (width 0.2) - (layer "F.Cu") - (net 11) - (uuid "6c7d70eb-3208-4743-bc0d-20465d2074e0") - ) - (segment - (start 97.801256 63.635) - (end 98.751 64.584744) - (width 0.2) - (layer "F.Cu") - (net 11) - (uuid "d888d8da-c3b6-4878-bad3-3f33df905f5f") - ) - (segment - (start 97.525 63.635) - (end 97.801256 63.635) - (width 0.2) - (layer "F.Cu") - (net 11) - (uuid "d9fb5406-7325-45f4-bcec-9116d43b79ba") - ) - (segment - (start 95.885 95.994) - (end 95.903 96.012) - (width 0.2) - (layer "F.Cu") - (net 11) - (uuid "dc818346-b76f-4d51-af1a-3d4eae820275") - ) - (segment - (start 95.885 77.978) - (end 95.885 95.994) - (width 0.2) - (layer "F.Cu") - (net 11) - (uuid "fae5658e-8ad8-4c4b-a627-b5c79efeaec7") - ) - (via - (at 95.885 77.978) + (at 96.232 84.836) (size 0.7) (drill 0.3) (layers "F.Cu" "B.Cu") (net 11) - (uuid "512909b1-213d-4e2f-80ba-6a4fdf4a1960") - ) - (via - (at 95.903 96.012) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 11) - (uuid "7a25badd-daac-49d1-92cc-9c2855548cc0") - ) - (segment - (start 94.338 96.012) - (end 94.29 96.06) - (width 0.2) - (layer "B.Cu") - (net 11) - (uuid "4ff01180-1fc8-4607-9d71-f85c12bc6694") - ) - (segment - (start 95.903 96.012) - (end 94.338 96.012) - (width 0.2) - (layer "B.Cu") - (net 11) - (uuid "85e5c6dc-0c40-4112-b92b-f7ba47bbf1c8") - ) - (segment - (start 95.885 77.978) - (end 94.457 76.55) - (width 0.2) - (layer "B.Cu") - (net 11) - (uuid "8dbbd5a4-217d-441b-9a51-213119406de3") - ) - (segment - (start 94.457 76.55) - (end 94.32 76.55) - (width 0.2) - (layer "B.Cu") - (net 11) - (uuid "f5e8829c-0211-4b58-b256-5c6266c24351") - ) - (segment - (start 111.65 80.2375) - (end 111.65 79.536888) - (width 0.2) - (layer "F.Cu") - (net 12) - (uuid "0724ff26-cdda-4745-b489-8b9a044ff8a4") - ) - (segment - (start 111.65 79.536888) - (end 109.847112 77.734) - (width 0.2) - (layer "F.Cu") - (net 12) - (uuid "6a580d71-6894-428e-adfa-21486558a80e") - ) - (segment - (start 109.847112 77.734) - (end 104.785 77.734) - (width 0.2) - (layer "F.Cu") - (net 12) - (uuid "c3ac7e92-6f3a-4afe-8392-9fd8bd816302") - ) - (segment - (start 104.013 76.962) - (end 104.013 63.541433) - (width 0.2) - (layer "F.Cu") - (net 12) - (uuid "c8b9d3d8-feaf-40c6-8fdd-8f5cc6aa7d6f") - ) - (segment - (start 104.013 63.541433) - (end 103.95 63.478433) - (width 0.2) - (layer "F.Cu") - (net 12) - (uuid "cd3b8dbc-06bc-4769-93e3-7f2f5d5b79f7") - ) - (segment - (start 104.785 77.734) - (end 104.013 76.962) - (width 0.2) - (layer "F.Cu") - (net 12) - (uuid "d4fe3926-7a64-478f-a9ba-f00b0b6bde60") - ) - (via - (at 102.475 61.095) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 12) - (uuid "3658994b-6f83-4875-a2bf-065f39eba985") - ) - (via - (at 103.95 63.478433) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 12) - (uuid "aebac1e6-c214-4f5e-9bb5-d58d80a19cf9") - ) - (segment - (start 103.95 63.478433) - (end 103.95 62.57) - (width 0.2) - (layer "B.Cu") - (net 12) - (uuid "8dc69632-d6a7-4a97-81d5-5eff6d2f6a42") - ) - (segment - (start 103.95 62.57) - (end 102.475 61.095) - (width 0.2) - (layer "B.Cu") - (net 12) - (uuid "ea759492-1ab8-44ca-9b88-9d6bc5eadc32") - ) - (segment - (start 109.701724 78.085) - (end 104.247 78.085) - (width 0.2) - (layer "F.Cu") - (net 13) - (uuid "1f45b6e1-3348-4197-bbde-7ff50d073a45") - ) - (segment - (start 111.15 80.2375) - (end 111.15 79.533276) - (width 0.2) - (layer "F.Cu") - (net 13) - (uuid "290bc199-311b-4e26-b751-b5c875cf5e96") - ) - (segment - (start 102.475 76.313) - (end 102.475 64.905) - (width 0.2) - (layer "F.Cu") - (net 13) - (uuid "441ba821-fecf-48b9-bb11-a2cbf8f00312") - ) - (segment - (start 104.247 78.085) - (end 102.475 76.313) - (width 0.2) - (layer "F.Cu") - (net 13) - (uuid "5eb27827-807f-415a-be75-088156934952") - ) - (segment - (start 111.15 79.533276) - (end 109.701724 78.085) - (width 0.2) - (layer "F.Cu") - (net 13) - (uuid "d907b153-3a19-4d2b-af12-67134e0f0c10") - ) - (segment - (start 110.89 92.2) - (end 111.65 91.44) - (width 0.2) - (layer "F.Cu") - (net 14) - (uuid "48639557-3025-4f33-bb4c-43bd48799605") + (uuid "81851763-a0e6-4497-bd80-a5b64910ba21") ) (segment (start 109.98 92.2) @@ -13637,14 +12507,6 @@ (net 14) (uuid "a910e94a-0166-4ce0-99fe-7fde2cdfc79d") ) - (segment - (start 111.65 91.44) - (end 111.65 88.5625) - (width 0.2) - (layer "F.Cu") - (net 14) - (uuid "f0150630-0057-48bf-b372-097d24b7a12c") - ) (segment (start 109.55 94.6) (end 109.55 92.63) @@ -13669,14 +12531,6 @@ (net 15) (uuid "535a75ed-8217-4142-9804-2a6d030827a7") ) - (segment - (start 112.15 88.5625) - (end 112.15 91.96) - (width 0.2) - (layer "F.Cu") - (net 15) - (uuid "80bc5d6d-8800-4242-aa8c-66acaa19407d") - ) (segment (start 112.82 92.2) (end 111.91 92.2) @@ -13685,445 +12539,46 @@ (net 15) (uuid "9b757304-5218-44b5-a354-47c398917cd8") ) - (segment - (start 112.15 91.96) - (end 111.91 92.2) - (width 0.2) - (layer "F.Cu") - (net 15) - (uuid "b272adcb-c002-4a24-8368-51dab35d8764") - ) - (segment - (start 113.65 80.2375) - (end 113.65 79.444959) - (width 0.2) - (layer "F.Cu") - (net 33) - (uuid "59a8fd07-5e73-43a7-8ad6-e4855ddc7920") - ) - (segment - (start 113.65 79.444959) - (end 112.47718 78.272139) - (width 0.2) - (layer "F.Cu") - (net 33) - (uuid "a72a10ab-0bfe-45cf-b80f-bcaff5c3999e") - ) - (via - (at 112.47718 78.272139) - (size 0.7) - (drill 0.3) + (zone + (net 4) + (net_name "Vin") (layers "F.Cu" "B.Cu") - (net 33) - (uuid "17bd8b3a-cd47-4222-a514-4d3a93d7d8a9") - ) - (via - (at 109.158 74.422) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 33) - (uuid "2005366c-6a12-44ed-a079-1e255fb6541d") - ) - (segment - (start 112.47718 77.74118) - (end 109.158 74.422) - (width 0.2) - (layer "B.Cu") - (net 33) - (uuid "2a3b6f5e-324f-435b-bf80-6115825ce8a2") - ) - (segment - (start 112.47718 78.272139) - (end 112.47718 77.74118) - (width 0.2) - (layer "B.Cu") - (net 33) - (uuid "f9eb9700-dcbb-4290-ab21-8b73bbd05b5f") - ) - (segment - (start 114.65 78.697804) - (end 114.180808 78.228612) - (width 0.2) - (layer "F.Cu") - (net 34) - (uuid "a26167d1-aa8f-464c-9297-64ccaac95167") - ) - (segment - (start 114.65 80.2375) - (end 114.65 78.697804) - (width 0.2) - (layer "F.Cu") - (net 34) - (uuid "a7f66e82-be39-4fff-abb0-9584ea16aca3") - ) - (via - (at 114.180808 78.228612) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 34) - (uuid "1e5d9fa2-d6de-4068-853f-01db7fe6e5a1") - ) - (via - (at 109.158 71.882) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 34) - (uuid "88e98735-dc22-48ce-a1a6-f130c1b66884") - ) - (segment - (start 114.180808 78.228612) - (end 114.180808 76.904808) - (width 0.2) - (layer "B.Cu") - (net 34) - (uuid "1d8bc6cb-2881-4637-88f7-e608cf97c87a") - ) - (segment - (start 114.180808 76.904808) - (end 109.158 71.882) - (width 0.2) - (layer "B.Cu") - (net 34) - (uuid "fc255585-7393-458c-86f5-c80702445ca7") - ) - (segment - (start 113.15 80.2375) - (end 113.15 79.500001) - (width 0.2) - (layer "F.Cu") - (net 36) - (uuid "8964a710-fba0-4894-8301-1424f6540738") - ) - (segment - (start 113.15 79.500001) - (end 112.587558 78.937559) - (width 0.2) - (layer "F.Cu") - (net 36) - (uuid "af696aee-512d-47db-a36f-a14f348d873c") - ) - (segment - (start 112.587558 78.937559) - (end 111.899201 78.937559) - (width 0.2) - (layer "F.Cu") - (net 36) - (uuid "cb87a770-4b58-4b45-9370-a4d77a022dd8") - ) - (via - (at 109.158 75.692) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 36) - (uuid "0ce0d10b-a85e-49ad-b064-557f79eaa7eb") - ) - (via - (at 111.899201 78.937559) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 36) - (uuid "c14c3e87-ce22-4715-88b2-91e7fe236d73") - ) - (segment - (start 111.899201 78.937559) - (end 111.899201 78.433201) - (width 0.2) - (layer "B.Cu") - (net 36) - (uuid "de4b770e-3dc3-4a47-952d-1294fe91cf9f") - ) - (segment - (start 111.899201 78.433201) - (end 109.158 75.692) - (width 0.2) - (layer "B.Cu") - (net 36) - (uuid "f0de4fa0-0ed6-4959-adf5-1870d76d06ae") - ) - (segment - (start 114.15 79.046334) - (end 113.325705 78.222039) - (width 0.2) - (layer "F.Cu") - (net 37) - (uuid "38134ec6-043a-49bd-b076-d00f92fded10") - ) - (segment - (start 114.15 80.2375) - (end 114.15 79.046334) - (width 0.2) - (layer "F.Cu") - (net 37) - (uuid "c2a36eeb-d923-46f6-add2-df90274b72b2") - ) - (via - (at 113.325705 78.222039) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 37) - (uuid "2e1c8e34-40dd-457b-b966-f5875de2dc17") - ) - (via - (at 109.158 73.152) - (size 0.7) - (drill 0.3) - (layers "F.Cu" "B.Cu") - (net 37) - (uuid "7e82f55d-6dfc-4775-a2b4-64e20f3cdad0") - ) - (segment - (start 113.325705 77.319705) - (end 109.158 73.152) - (width 0.2) - (layer "B.Cu") - (net 37) - (uuid "d093bae2-a841-4269-9367-3d0bb176158a") - ) - (segment - (start 113.325705 78.222039) - (end 113.325705 77.319705) - (width 0.2) - (layer "B.Cu") - (net 37) - (uuid "ef3ede1b-6fa9-4bc2-8459-e1398c285f8e") - ) - (segment - (start 114.108 74.422) - (end 114.108 75.692) - (width 0.6) - (layer "F.Cu") - (net 41) - (uuid "6e3440c7-49b8-406c-8f8b-f9274c86b846") - ) - (segment - (start 114.108 75.692) - (end 119.253 75.692) - (width 0.6) - (layer "F.Cu") - (net 41) - (uuid "6f4747ca-e341-4322-b1a1-b27c4bb156ac") - ) - (segment - (start 119.253 75.692) - (end 119.634 76.073) - (width 0.6) - (layer "F.Cu") - (net 41) - (uuid "8c69ff70-de08-4687-84ff-a65d5a34d7a2") - ) - (segment - (start 114.108 71.882) - (end 114.108 70.612) - (width 0.6) - (layer "F.Cu") - (net 42) - (uuid "e673f014-b862-45dc-b160-21422c3b4d1a") - ) - (segment - (start 114.108 70.612) - (end 119.095 70.612) - (width 0.6) - (layer "F.Cu") - (net 42) - (uuid "eb899980-90de-496d-a77a-f021faceaac8") - ) - (segment - (start 119.095 70.612) - (end 119.634 70.073) - (width 0.6) - (layer "F.Cu") - (net 42) - (uuid "ed2d046c-48de-41b0-aac3-3428f5fe64ea") - ) - (segment - (start 133.35 71.632) - (end 133.35 72.517) - (width 0.2) - (layer "F.Cu") - (net 43) - (uuid "51852501-11df-4860-90ba-348757953578") - ) - (segment - (start 132.912 72.07) - (end 133.35 71.632) - (width 0.2) - (layer "F.Cu") - (net 43) - (uuid "9a7bd084-49d5-4837-8a20-c4be300d69f0") - ) - (segment - (start 131.796 72.07) - (end 132.912 72.07) - (width 0.2) - (layer "F.Cu") - (net 43) - (uuid "dc585574-1ee0-4b61-9afb-27878c964d18") - ) - (segment - (start 133.35 75.569) - (end 133.35 76.454) - (width 0.2) - (layer "F.Cu") - (net 46) - (uuid "582631b2-276c-4567-b3ee-8e873c260d35") - ) - (segment - (start 131.796 75.88) - (end 133.039 75.88) - (width 0.2) - (layer "F.Cu") - (net 46) - (uuid "5d6142c5-c835-4218-8cc7-68f3a5fb5c7d") - ) - (segment - (start 133.039 75.88) - (end 133.35 75.569) - (width 0.2) - (layer "F.Cu") - (net 46) - (uuid "8be28ea0-e981-42a9-804f-f973795c3e3c") - ) - (segment - (start 129.064 74.073) - (end 129.921 74.93) - (width 0.4) - (layer "F.Cu") - (net 47) - (uuid "5a066f8f-09a7-41a9-b6b6-0ea4df36a287") - ) - (segment - (start 126.619 74.073) - (end 129.064 74.073) - (width 0.4) - (layer "F.Cu") - (net 47) - (uuid "8d600de3-44c4-43da-b04a-55de7fa4c5f9") - ) - (segment - (start 126.619 72.073) - (end 128.968 72.073) - (width 0.4) - (layer "F.Cu") - (net 48) - (uuid "6676a840-20db-495a-aaa3-42f76f85e3cc") - ) - (segment - (start 128.968 72.073) - (end 129.921 71.12) - (width 0.4) - (layer "F.Cu") - (net 48) - (uuid "ad83ca9a-ecba-4515-a9ec-2420d8a27f3c") - ) - (segment - (start 133.35 73.679372) - (end 132.788186 74.241186) - (width 0.2) - (layer "F.Cu") - (net 49) - (uuid "15e198e0-7666-40da-9ca5-9e0f5b7c092f") - ) - (segment - (start 129.244244 77.123) - (end 118.2645 77.123) - (width 0.2) - (layer "F.Cu") - (net 49) - (uuid "192de94f-e08b-46e4-93f8-0c343658813c") - ) - (segment - (start 132.788186 74.241186) - (end 132.788186 74.29657) - (width 0.2) - (layer "F.Cu") - (net 49) - (uuid "1ab4fc9a-c541-47fb-a5c7-f5124b9e5769") - ) - (segment - (start 132.788186 74.29657) - (end 132.535756 74.549) - (width 0.2) - (layer "F.Cu") - (net 49) - (uuid "30622889-b6ee-4d86-b76a-abd9e19b0f4e") - ) - (segment - (start 118.2645 77.123) - (end 115.15 80.2375) - (width 0.2) - (layer "F.Cu") - (net 49) - (uuid "4d0a6fd2-7eeb-486b-8a6b-2eb2426f4e18") - ) - (segment - (start 132.788186 74.241186) - (end 132.779 74.250372) - (width 0.2) - (layer "F.Cu") - (net 49) - (uuid "7985b6d7-1933-411b-aaef-c998494c53d5") - ) - (segment - (start 132.535756 74.549) - (end 131.818244 74.549) - (width 0.2) - (layer "F.Cu") - (net 49) - (uuid "8fa3f0cc-1fe7-4e73-9b64-b005dabd7e49") - ) - (segment - (start 133.35 73.537) - (end 133.35 73.679372) - (width 0.2) - (layer "F.Cu") - (net 49) - (uuid "d59e2d5d-899a-49ef-9eb1-59a7554c3d86") - ) - (segment - (start 131.818244 74.549) - (end 129.244244 77.123) - (width 0.2) - (layer "F.Cu") - (net 49) - (uuid "eb44e63e-fe58-4e4b-87c0-c28bd839ed31") - ) - (segment - (start 122.475999 77.474) - (end 117.299999 82.65) - (width 0.2) - (layer "F.Cu") - (net 50) - (uuid "0e50d7fa-0ad9-4f6e-8b96-10722811f8bb") - ) - (segment - (start 117.299999 82.65) - (end 116.5625 82.65) - (width 0.2) - (layer "F.Cu") - (net 50) - (uuid "1dee794d-d7bb-4c7b-ad75-d61d6af60c2d") - ) - (segment - (start 133.35 77.474) - (end 122.475999 77.474) - (width 0.2) - (layer "F.Cu") - (net 50) - (uuid "dfc78572-2e53-4292-9a94-7ce7f6f2cb4a") - ) - (segment - (start 124.613 87.63) - (end 124.756 87.487) - (width 0.2) - (layer "F.Cu") - (net 51) - (uuid "f5f73482-c2cd-42b9-9f31-8a3dc7ea511e") + (uuid "65cc02cd-3998-4787-b107-d7fefa94e1a7") + (hatch edge 0.5) + (connect_pads yes + (clearance 0.25) + ) + (min_thickness 0.25) + (filled_areas_thickness no) + (fill yes + (thermal_gap 0.5) + (thermal_bridge_width 0.5) + ) + (polygon + (pts + (xy 94.107 73.152) (xy 92.329 72.136) (xy 92.329 70.739) (xy 94.107 69.723) (xy 94.996 70.358) (xy 94.996 72.136) + ) + ) + (filled_polygon + (layer "F.Cu") + (pts + (xy 94.171632 69.769166) (xy 94.944074 70.32091) (xy 94.987184 70.375894) (xy 94.996 70.421813) + (xy 94.996 72.089407) (xy 94.976315 72.156446) (xy 94.965319 72.171062) (xy 94.173783 73.075674) + (xy 94.114824 73.113164) (xy 94.044955 73.112826) (xy 94.018943 73.101681) (xy 92.391479 72.171702) + (xy 92.343039 72.12135) (xy 92.329 72.06404) (xy 92.329 70.810959) (xy 92.348685 70.74392) (xy 92.391477 70.703298) + (xy 94.038038 69.762406) (xy 94.10601 69.746237) + ) + ) + (filled_polygon + (layer "B.Cu") + (pts + (xy 94.171632 69.769166) (xy 94.944074 70.32091) (xy 94.987184 70.375894) (xy 94.996 70.421813) + (xy 94.996 72.089407) (xy 94.976315 72.156446) (xy 94.965319 72.171062) (xy 94.173783 73.075674) + (xy 94.114824 73.113164) (xy 94.044955 73.112826) (xy 94.018943 73.101681) (xy 92.391479 72.171702) + (xy 92.343039 72.12135) (xy 92.329 72.06404) (xy 92.329 70.810959) (xy 92.348685 70.74392) (xy 92.391477 70.703298) + (xy 94.038038 69.762406) (xy 94.10601 69.746237) + ) + ) ) (zone (net 1) @@ -14143,57 +12598,96 @@ ) (polygon (pts - (xy 107.569 101.727) (xy 110.109 101.727) (xy 110.109 101.981) (xy 110.871 102.743) (xy 111.887 102.743) - (xy 111.887 104.267) (xy 110.363 104.267) (xy 109.855 103.759) (xy 107.569 103.759) (xy 107.569 106.299) - (xy 101.092 106.299) (xy 101.092 99.187) (xy 107.569 99.187) + (xy 105.156 113.538) (xy 107.696 113.538) (xy 107.696 113.792) (xy 108.458 114.554) (xy 109.474 114.554) + (xy 109.474 116.078) (xy 107.95 116.078) (xy 107.442 115.57) (xy 105.156 115.57) (xy 105.156 118.11) + (xy 98.679 118.11) (xy 98.679 110.998) (xy 105.156 110.998) ) ) (filled_polygon (layer "F.Cu") (pts - (xy 107.256539 99.206685) (xy 107.302294 99.259489) (xy 107.3135 99.311) (xy 107.3135 101.603002) - (xy 107.319338 101.657312) (xy 107.330543 101.708818) (xy 107.330546 101.708827) (xy 107.337779 101.735192) - (xy 107.337783 101.735203) (xy 107.387105 101.821818) (xy 107.38711 101.821825) (xy 107.387112 101.821828) - (xy 107.41358 101.852374) (xy 107.432863 101.874628) (xy 107.432866 101.874631) (xy 107.432867 101.874632) - (xy 107.465641 101.906257) (xy 107.553976 101.952465) (xy 107.553977 101.952465) (xy 107.553977 101.952466) - (xy 107.604105 101.967184) (xy 107.621015 101.97215) (xy 107.621019 101.97215) (xy 107.621021 101.972151) - (xy 107.632652 101.973823) (xy 107.693 101.9825) (xy 107.693001 101.9825) (xy 109.985 101.9825) - (xy 109.985011 101.982499) (xy 109.995141 101.981409) (xy 110.012243 101.979571) (xy 110.081001 101.991975) - (xy 110.13214 102.039584) (xy 110.1495 102.102859) (xy 110.1495 102.212869) (xy 110.149501 102.212876) - (xy 110.155908 102.272483) (xy 110.206202 102.407328) (xy 110.206206 102.407335) (xy 110.292452 102.522544) - (xy 110.292455 102.522547) (xy 110.407664 102.608793) (xy 110.407671 102.608797) (xy 110.452618 102.625561) - (xy 110.542517 102.659091) (xy 110.602127 102.6655) (xy 110.742138 102.665499) (xy 110.809176 102.685183) - (xy 110.829818 102.701818) (xy 110.871 102.743) (xy 111.763 102.743) (xy 111.830039 102.762685) - (xy 111.875794 102.815489) (xy 111.887 102.867) (xy 111.887 104.143) (xy 111.867315 104.210039) - (xy 111.814511 104.255794) (xy 111.763 104.267) (xy 110.414362 104.267) (xy 110.347323 104.247315) - (xy 110.326681 104.230681) (xy 109.855 103.759) (xy 107.569 103.759) (xy 107.569 104.238915) (xy 107.551732 104.302036) - (xy 107.483382 104.417609) (xy 107.48338 104.417614) (xy 107.439292 104.569366) (xy 107.43929 104.569379) - (xy 107.4365 104.604829) (xy 107.4365 105.48115) (xy 107.436501 105.481175) (xy 107.439291 105.516627) - (xy 107.48338 105.668385) (xy 107.483382 105.66839) (xy 107.551732 105.783963) (xy 107.569 105.847084) - (xy 107.569 106.175) (xy 107.549315 106.242039) (xy 107.496511 106.287794) (xy 107.445 106.299) - (xy 101.216 106.299) (xy 101.148961 106.279315) (xy 101.103206 106.226511) (xy 101.092 106.175) - (xy 101.092 99.311) (xy 101.111685 99.243961) (xy 101.164489 99.198206) (xy 101.216 99.187) (xy 107.1895 99.187) + (xy 104.843539 111.017685) (xy 104.889294 111.070489) (xy 104.9005 111.122) (xy 104.9005 113.414002) + (xy 104.906338 113.468312) (xy 104.917543 113.519818) (xy 104.917546 113.519827) (xy 104.924779 113.546192) + (xy 104.924783 113.546203) (xy 104.974105 113.632818) (xy 104.97411 113.632825) (xy 104.974112 113.632828) + (xy 105.00058 113.663374) (xy 105.019863 113.685628) (xy 105.019866 113.685631) (xy 105.019867 113.685632) + (xy 105.052641 113.717257) (xy 105.140976 113.763465) (xy 105.140977 113.763465) (xy 105.140977 113.763466) + (xy 105.191105 113.778184) (xy 105.208015 113.78315) (xy 105.208019 113.78315) (xy 105.208021 113.783151) + (xy 105.219652 113.784823) (xy 105.28 113.7935) (xy 105.280001 113.7935) (xy 107.572 113.7935) (xy 107.572011 113.793499) + (xy 107.582141 113.792409) (xy 107.599243 113.790571) (xy 107.668001 113.802975) (xy 107.71914 113.850584) + (xy 107.7365 113.913859) (xy 107.7365 114.023869) (xy 107.736501 114.023876) (xy 107.742908 114.083483) + (xy 107.793202 114.218328) (xy 107.793206 114.218335) (xy 107.879452 114.333544) (xy 107.879455 114.333547) + (xy 107.994664 114.419793) (xy 107.994671 114.419797) (xy 108.039618 114.436561) (xy 108.129517 114.470091) + (xy 108.189127 114.4765) (xy 108.329138 114.476499) (xy 108.396176 114.496183) (xy 108.416818 114.512818) + (xy 108.458 114.554) (xy 109.35 114.554) (xy 109.417039 114.573685) (xy 109.462794 114.626489) (xy 109.474 114.678) + (xy 109.474 115.954) (xy 109.454315 116.021039) (xy 109.401511 116.066794) (xy 109.35 116.078) (xy 108.001362 116.078) + (xy 107.934323 116.058315) (xy 107.913681 116.041681) (xy 107.442 115.57) (xy 105.156 115.57) (xy 105.156 116.049915) + (xy 105.138732 116.113036) (xy 105.070382 116.228609) (xy 105.07038 116.228614) (xy 105.026292 116.380366) + (xy 105.02629 116.380379) (xy 105.0235 116.415829) (xy 105.0235 117.29215) (xy 105.023501 117.292175) + (xy 105.026291 117.327627) (xy 105.07038 117.479385) (xy 105.070382 117.47939) (xy 105.138732 117.594963) + (xy 105.156 117.658084) (xy 105.156 117.986) (xy 105.136315 118.053039) (xy 105.083511 118.098794) + (xy 105.032 118.11) (xy 98.803 118.11) (xy 98.735961 118.090315) (xy 98.690206 118.037511) (xy 98.679 117.986) + (xy 98.679 111.122) (xy 98.698685 111.054961) (xy 98.751489 111.009206) (xy 98.803 110.998) (xy 104.7765 110.998) ) ) (filled_polygon (layer "B.Cu") (pts - (xy 107.256539 99.206685) (xy 107.302294 99.259489) (xy 107.3135 99.311) (xy 107.3135 101.603002) - (xy 107.319338 101.657312) (xy 107.330543 101.708818) (xy 107.330546 101.708827) (xy 107.337779 101.735192) - (xy 107.337783 101.735203) (xy 107.387105 101.821818) (xy 107.38711 101.821825) (xy 107.387112 101.821828) - (xy 107.41358 101.852374) (xy 107.432863 101.874628) (xy 107.432866 101.874631) (xy 107.432867 101.874632) - (xy 107.465641 101.906257) (xy 107.553976 101.952465) (xy 107.553977 101.952465) (xy 107.553977 101.952466) - (xy 107.604105 101.967184) (xy 107.621015 101.97215) (xy 107.621019 101.97215) (xy 107.621021 101.972151) - (xy 107.632652 101.973823) (xy 107.693 101.9825) (xy 107.693001 101.9825) (xy 109.985 101.9825) - (xy 109.985013 101.982499) (xy 110.016888 101.979071) (xy 110.039313 101.976661) (xy 110.039315 101.97666) - (xy 110.039329 101.976659) (xy 110.108089 101.989063) (xy 110.140267 102.012267) (xy 110.871 102.743) - (xy 111.763 102.743) (xy 111.830039 102.762685) (xy 111.875794 102.815489) (xy 111.887 102.867) - (xy 111.887 104.143) (xy 111.867315 104.210039) (xy 111.814511 104.255794) (xy 111.763 104.267) - (xy 110.414362 104.267) (xy 110.347323 104.247315) (xy 110.326681 104.230681) (xy 109.855 103.759) - (xy 107.569 103.759) (xy 107.569 106.175) (xy 107.549315 106.242039) (xy 107.496511 106.287794) - (xy 107.445 106.299) (xy 101.216 106.299) (xy 101.148961 106.279315) (xy 101.103206 106.226511) - (xy 101.092 106.175) (xy 101.092 99.311) (xy 101.111685 99.243961) (xy 101.164489 99.198206) (xy 101.216 99.187) - (xy 107.1895 99.187) + (xy 104.843539 112.270185) (xy 104.889294 112.322989) (xy 104.9005 112.3745) (xy 104.9005 113.414002) + (xy 104.906338 113.468312) (xy 104.917543 113.519818) (xy 104.917546 113.519827) (xy 104.924779 113.546192) + (xy 104.924783 113.546203) (xy 104.974105 113.632818) (xy 104.97411 113.632825) (xy 104.974112 113.632828) + (xy 105.00058 113.663374) (xy 105.019863 113.685628) (xy 105.019866 113.685631) (xy 105.019867 113.685632) + (xy 105.052641 113.717257) (xy 105.140976 113.763465) (xy 105.140977 113.763465) (xy 105.140977 113.763466) + (xy 105.191105 113.778184) (xy 105.208015 113.78315) (xy 105.208019 113.78315) (xy 105.208021 113.783151) + (xy 105.219652 113.784823) (xy 105.28 113.7935) (xy 105.280001 113.7935) (xy 107.572 113.7935) (xy 107.572013 113.793499) + (xy 107.603888 113.790071) (xy 107.626313 113.787661) (xy 107.626315 113.78766) (xy 107.626329 113.787659) + (xy 107.695089 113.800063) (xy 107.727267 113.823267) (xy 108.458 114.554) (xy 109.35 114.554) (xy 109.417039 114.573685) + (xy 109.462794 114.626489) (xy 109.474 114.678) (xy 109.474 115.954) (xy 109.454315 116.021039) + (xy 109.401511 116.066794) (xy 109.35 116.078) (xy 108.001362 116.078) (xy 107.934323 116.058315) + (xy 107.913681 116.041681) (xy 107.442 115.57) (xy 105.156 115.57) (xy 105.156 117.986) (xy 105.136315 118.053039) + (xy 105.083511 118.098794) (xy 105.032 118.11) (xy 98.803 118.11) (xy 98.735961 118.090315) (xy 98.690206 118.037511) + (xy 98.679 117.986) (xy 98.679 112.3745) (xy 98.698685 112.307461) (xy 98.751489 112.261706) (xy 98.803 112.2505) + (xy 104.7765 112.2505) + ) + ) + ) + (zone + (net 4) + (net_name "Vin") + (layers "F.Cu" "B.Cu") + (uuid "7559dbe5-b2f6-4d0f-90f9-8da99f3119d4") + (hatch edge 0.5) + (connect_pads yes + (clearance 0.25) + ) + (min_thickness 0.25) + (filled_areas_thickness no) + (fill yes + (thermal_gap 0.5) + (thermal_bridge_width 0.5) + ) + (polygon + (pts + (xy 94.107 92.71) (xy 92.329 91.694) (xy 92.329 90.297) (xy 94.107 89.281) (xy 94.996 89.916) (xy 94.996 91.694) + ) + ) + (filled_polygon + (layer "F.Cu") + (pts + (xy 94.171629 89.327163) (xy 94.900576 89.84784) (xy 94.943684 89.902821) (xy 94.9525 89.94874) + (xy 94.9525 91.697121) (xy 94.932815 91.76416) (xy 94.921819 91.778776) (xy 94.173783 92.633674) + (xy 94.114824 92.671164) (xy 94.044955 92.670826) (xy 94.018943 92.659681) (xy 92.391479 91.729702) + (xy 92.343039 91.67935) (xy 92.329 91.62204) (xy 92.329 90.368959) (xy 92.348685 90.30192) (xy 92.391477 90.261298) + (xy 94.03804 89.320405) (xy 94.106011 89.304236) + ) + ) + (filled_polygon + (layer "B.Cu") + (pts + (xy 94.171632 89.327166) (xy 94.944074 89.87891) (xy 94.987184 89.933894) (xy 94.996 89.979813) + (xy 94.996 91.647407) (xy 94.976315 91.714446) (xy 94.965319 91.729062) (xy 94.173783 92.633674) + (xy 94.114824 92.671164) (xy 94.044955 92.670826) (xy 94.018943 92.659681) (xy 92.391479 91.729702) + (xy 92.343039 91.67935) (xy 92.329 91.62204) (xy 92.329 90.368959) (xy 92.348685 90.30192) (xy 92.391477 90.261298) + (xy 94.038038 89.320406) (xy 94.10601 89.304237) ) ) ) @@ -14215,52 +12709,52 @@ ) (polygon (pts - (xy 109.796 65.278) (xy 107.256 65.278) (xy 107.256 65.024) (xy 106.494 64.262) (xy 105.478 64.262) - (xy 105.478 62.738) (xy 107.002 62.738) (xy 107.51 63.246) (xy 109.796 63.246) (xy 109.796 60.706) - (xy 116.273 60.706) (xy 116.273 67.818) (xy 109.796 67.818) + (xy 113.03 60.833) (xy 110.49 60.833) (xy 110.49 60.579) (xy 109.728 59.817) (xy 108.712 59.817) + (xy 108.712 58.293) (xy 110.236 58.293) (xy 110.744 58.801) (xy 113.03 58.801) (xy 113.03 56.261) + (xy 119.507 56.261) (xy 119.507 63.373) (xy 113.03 63.373) ) ) (filled_polygon (layer "F.Cu") (pts - (xy 116.216039 60.725685) (xy 116.261794 60.778489) (xy 116.273 60.83) (xy 116.273 67.694) (xy 116.253315 67.761039) - (xy 116.200511 67.806794) (xy 116.149 67.818) (xy 110.1755 67.818) (xy 110.108461 67.798315) (xy 110.062706 67.745511) - (xy 110.0515 67.694) (xy 110.0515 65.402) (xy 110.045661 65.347687) (xy 110.034455 65.296176) (xy 110.027219 65.269802) - (xy 110.027216 65.269796) (xy 109.977894 65.183181) (xy 109.97789 65.183176) (xy 109.977888 65.183172) - (xy 109.932133 65.130368) (xy 109.899359 65.098743) (xy 109.811024 65.052535) (xy 109.811023 65.052534) - (xy 109.811022 65.052534) (xy 109.811022 65.052533) (xy 109.74399 65.032851) (xy 109.743978 65.032848) - (xy 109.672001 65.0225) (xy 109.672 65.0225) (xy 107.38 65.0225) (xy 107.379997 65.0225) (xy 107.352753 65.025429) - (xy 107.283994 65.013022) (xy 107.232857 64.965412) (xy 107.215499 64.902139) (xy 107.215499 64.792129) - (xy 107.215498 64.792123) (xy 107.209091 64.732516) (xy 107.158797 64.597671) (xy 107.158793 64.597664) - (xy 107.072547 64.482455) (xy 107.072544 64.482452) (xy 106.957335 64.396206) (xy 106.957328 64.396202) - (xy 106.822482 64.345908) (xy 106.822483 64.345908) (xy 106.762883 64.339501) (xy 106.762881 64.3395) - (xy 106.762873 64.3395) (xy 106.762865 64.3395) (xy 106.622862 64.3395) (xy 106.555823 64.319815) - (xy 106.535181 64.303181) (xy 106.494 64.262) (xy 105.602 64.262) (xy 105.534961 64.242315) (xy 105.489206 64.189511) - (xy 105.478 64.138) (xy 105.478 62.862) (xy 105.497685 62.794961) (xy 105.550489 62.749206) (xy 105.602 62.738) - (xy 106.950638 62.738) (xy 107.017677 62.757685) (xy 107.038319 62.774319) (xy 107.51 63.246) (xy 109.796 63.246) - (xy 109.796 62.651103) (xy 109.811371 62.594917) (xy 109.81052 62.594549) (xy 109.813109 62.588564) - (xy 109.81327 62.587979) (xy 109.813617 62.587391) (xy 109.813618 62.58739) (xy 109.857709 62.435627) - (xy 109.8605 62.400163) (xy 109.860499 61.523838) (xy 109.857709 61.488373) (xy 109.813618 61.33661) - (xy 109.813615 61.336605) (xy 109.813613 61.3366) (xy 109.813265 61.336011) (xy 109.813104 61.335423) - (xy 109.810519 61.329449) (xy 109.811369 61.329081) (xy 109.796 61.272896) (xy 109.796 60.83) (xy 109.815685 60.762961) - (xy 109.868489 60.717206) (xy 109.92 60.706) (xy 116.149 60.706) + (xy 119.450039 56.280685) (xy 119.495794 56.333489) (xy 119.507 56.385) (xy 119.507 63.249) (xy 119.487315 63.316039) + (xy 119.434511 63.361794) (xy 119.383 63.373) (xy 113.4095 63.373) (xy 113.342461 63.353315) (xy 113.296706 63.300511) + (xy 113.2855 63.249) (xy 113.2855 60.957) (xy 113.279661 60.902687) (xy 113.268455 60.851176) (xy 113.261219 60.824802) + (xy 113.261216 60.824796) (xy 113.211894 60.738181) (xy 113.21189 60.738176) (xy 113.211888 60.738172) + (xy 113.166133 60.685368) (xy 113.133359 60.653743) (xy 113.045024 60.607535) (xy 113.045023 60.607534) + (xy 113.045022 60.607534) (xy 113.045022 60.607533) (xy 112.97799 60.587851) (xy 112.977978 60.587848) + (xy 112.906001 60.5775) (xy 112.906 60.5775) (xy 110.614 60.5775) (xy 110.613997 60.5775) (xy 110.586753 60.580429) + (xy 110.517994 60.568022) (xy 110.466857 60.520412) (xy 110.449499 60.457139) (xy 110.449499 60.347129) + (xy 110.449498 60.347123) (xy 110.443091 60.287516) (xy 110.392797 60.152671) (xy 110.392793 60.152664) + (xy 110.306547 60.037455) (xy 110.306544 60.037452) (xy 110.191335 59.951206) (xy 110.191328 59.951202) + (xy 110.056482 59.900908) (xy 110.056483 59.900908) (xy 109.996883 59.894501) (xy 109.996881 59.8945) + (xy 109.996873 59.8945) (xy 109.996865 59.8945) (xy 109.856862 59.8945) (xy 109.789823 59.874815) + (xy 109.769181 59.858181) (xy 109.728 59.817) (xy 108.836 59.817) (xy 108.768961 59.797315) (xy 108.723206 59.744511) + (xy 108.712 59.693) (xy 108.712 58.417) (xy 108.731685 58.349961) (xy 108.784489 58.304206) (xy 108.836 58.293) + (xy 110.184638 58.293) (xy 110.251677 58.312685) (xy 110.272319 58.329319) (xy 110.744 58.801) (xy 113.03 58.801) + (xy 113.03 58.206103) (xy 113.045371 58.149917) (xy 113.04452 58.149549) (xy 113.047109 58.143564) + (xy 113.04727 58.142979) (xy 113.047617 58.142391) (xy 113.047618 58.14239) (xy 113.091709 57.990627) + (xy 113.0945 57.955163) (xy 113.094499 57.078838) (xy 113.091709 57.043373) (xy 113.047618 56.89161) + (xy 113.047615 56.891605) (xy 113.047613 56.8916) (xy 113.047265 56.891011) (xy 113.047104 56.890423) + (xy 113.044519 56.884449) (xy 113.045369 56.884081) (xy 113.03 56.827896) (xy 113.03 56.385) (xy 113.049685 56.317961) + (xy 113.102489 56.272206) (xy 113.154 56.261) (xy 119.383 56.261) ) ) (filled_polygon (layer "B.Cu") (pts - (xy 116.216039 60.725685) (xy 116.261794 60.778489) (xy 116.273 60.83) (xy 116.273 67.694) (xy 116.253315 67.761039) - (xy 116.200511 67.806794) (xy 116.149 67.818) (xy 110.1755 67.818) (xy 110.108461 67.798315) (xy 110.062706 67.745511) - (xy 110.0515 67.694) (xy 110.0515 65.402) (xy 110.045661 65.347687) (xy 110.034455 65.296176) (xy 110.027219 65.269802) - (xy 110.023332 65.262976) (xy 109.977894 65.183181) (xy 109.97789 65.183176) (xy 109.977888 65.183172) - (xy 109.932133 65.130368) (xy 109.899359 65.098743) (xy 109.811024 65.052535) (xy 109.811023 65.052534) - (xy 109.811022 65.052534) (xy 109.811022 65.052533) (xy 109.74399 65.032851) (xy 109.743978 65.032848) - (xy 109.672001 65.0225) (xy 109.672 65.0225) (xy 107.38 65.0225) (xy 107.379997 65.0225) (xy 107.325667 65.028341) - (xy 107.256908 65.015935) (xy 107.224732 64.992732) (xy 106.494 64.262) (xy 105.602 64.262) (xy 105.534961 64.242315) - (xy 105.489206 64.189511) (xy 105.478 64.138) (xy 105.478 62.862) (xy 105.497685 62.794961) (xy 105.550489 62.749206) - (xy 105.602 62.738) (xy 106.950638 62.738) (xy 107.017677 62.757685) (xy 107.038319 62.774319) (xy 107.51 63.246) - (xy 109.796 63.246) (xy 109.796 60.83) (xy 109.815685 60.762961) (xy 109.868489 60.717206) (xy 109.92 60.706) - (xy 116.149 60.706) + (xy 119.450039 56.280685) (xy 119.495794 56.333489) (xy 119.507 56.385) (xy 119.507 63.249) (xy 119.487315 63.316039) + (xy 119.434511 63.361794) (xy 119.383 63.373) (xy 113.4095 63.373) (xy 113.342461 63.353315) (xy 113.296706 63.300511) + (xy 113.2855 63.249) (xy 113.2855 60.957) (xy 113.279661 60.902687) (xy 113.268455 60.851176) (xy 113.261219 60.824802) + (xy 113.257332 60.817976) (xy 113.211894 60.738181) (xy 113.21189 60.738176) (xy 113.211888 60.738172) + (xy 113.166133 60.685368) (xy 113.133359 60.653743) (xy 113.045024 60.607535) (xy 113.045023 60.607534) + (xy 113.045022 60.607534) (xy 113.045022 60.607533) (xy 112.97799 60.587851) (xy 112.977978 60.587848) + (xy 112.906001 60.5775) (xy 112.906 60.5775) (xy 110.614 60.5775) (xy 110.613997 60.5775) (xy 110.559667 60.583341) + (xy 110.490908 60.570935) (xy 110.458732 60.547732) (xy 109.728 59.817) (xy 108.836 59.817) (xy 108.768961 59.797315) + (xy 108.723206 59.744511) (xy 108.712 59.693) (xy 108.712 58.417) (xy 108.731685 58.349961) (xy 108.784489 58.304206) + (xy 108.836 58.293) (xy 110.184638 58.293) (xy 110.251677 58.312685) (xy 110.272319 58.329319) (xy 110.744 58.801) + (xy 113.03 58.801) (xy 113.03 56.385) (xy 113.049685 56.317961) (xy 113.102489 56.272206) (xy 113.154 56.261) + (xy 119.383 56.261) ) ) ) @@ -14282,18 +12776,18 @@ ) (polygon (pts - (xy 105.224 67.818) (xy 109.796 67.818) (xy 109.796 65.278) (xy 107.256 65.278) (xy 107.256 66.04) - (xy 105.224 66.04) + (xy 108.458 63.373) (xy 113.03 63.373) (xy 113.03 60.833) (xy 110.49 60.833) (xy 110.49 61.595) + (xy 108.458 61.595) ) ) (filled_polygon (layer "F.Cu") (pts - (xy 109.739039 65.297685) (xy 109.784794 65.350489) (xy 109.796 65.402) (xy 109.796 67.694) (xy 109.776315 67.761039) - (xy 109.723511 67.806794) (xy 109.672 67.818) (xy 105.348 67.818) (xy 105.280961 67.798315) (xy 105.235206 67.745511) - (xy 105.224 67.694) (xy 105.224 66.164) (xy 105.243685 66.096961) (xy 105.296489 66.051206) (xy 105.348 66.04) - (xy 107.256 66.04) (xy 107.256 65.402) (xy 107.275685 65.334961) (xy 107.328489 65.289206) (xy 107.38 65.278) - (xy 109.672 65.278) + (xy 112.973039 60.852685) (xy 113.018794 60.905489) (xy 113.03 60.957) (xy 113.03 63.249) (xy 113.010315 63.316039) + (xy 112.957511 63.361794) (xy 112.906 63.373) (xy 108.582 63.373) (xy 108.514961 63.353315) (xy 108.469206 63.300511) + (xy 108.458 63.249) (xy 108.458 61.719) (xy 108.477685 61.651961) (xy 108.530489 61.606206) (xy 108.582 61.595) + (xy 110.49 61.595) (xy 110.49 60.957) (xy 110.509685 60.889961) (xy 110.562489 60.844206) (xy 110.614 60.833) + (xy 112.906 60.833) ) ) ) @@ -14315,271 +12809,28 @@ ) (polygon (pts - (xy 112.141 99.187) (xy 107.569 99.187) (xy 107.569 101.727) (xy 110.109 101.727) (xy 110.109 100.965) - (xy 112.141 100.965) + (xy 109.728 110.998) (xy 105.156 110.998) (xy 105.156 113.538) (xy 107.696 113.538) (xy 107.696 112.776) + (xy 109.728 112.776) ) ) (filled_polygon (layer "F.Cu") (pts - (xy 112.084039 99.206685) (xy 112.129794 99.259489) (xy 112.141 99.311) (xy 112.141 100.841) (xy 112.121315 100.908039) - (xy 112.068511 100.953794) (xy 112.017 100.965) (xy 110.109 100.965) (xy 110.109 101.603) (xy 110.089315 101.670039) - (xy 110.036511 101.715794) (xy 109.985 101.727) (xy 107.693 101.727) (xy 107.625961 101.707315) - (xy 107.580206 101.654511) (xy 107.569 101.603) (xy 107.569 99.311) (xy 107.588685 99.243961) (xy 107.641489 99.198206) - (xy 107.693 99.187) (xy 112.017 99.187) - ) - ) - ) - (zone - (net 4) - (net_name "Vin") - (layers "F.Cu" "B.Cu") - (uuid "fe399f64-4f08-4afc-991b-540578fa7f7b") - (hatch edge 0.5) - (connect_pads yes - (clearance 0.25) - ) - (min_thickness 0.25) - (filled_areas_thickness no) - (fill yes - (thermal_gap 0.5) - (thermal_bridge_width 0.5) - ) - (polygon - (pts - (xy 86.741 70.358) (xy 93.345 70.358) (xy 93.345 96.012) (xy 86.741 96.012) - ) - ) - (filled_polygon - (layer "F.Cu") - (pts - (xy 93.250539 70.377685) (xy 93.296294 70.430489) (xy 93.3075 70.482) (xy 93.3075 70.529723) (xy 93.3075 70.529725) - (xy 93.307499 70.529725) (xy 93.342617 70.706265) (xy 93.345 70.730457) (xy 93.345 72.169541) (xy 93.342617 72.193733) - (xy 93.3075 72.370274) (xy 93.3075 72.370277) (xy 93.3075 72.569723) (xy 93.3075 72.569725) (xy 93.307499 72.569725) - (xy 93.342617 72.746265) (xy 93.345 72.770457) (xy 93.345 74.209541) (xy 93.342617 74.233733) (xy 93.3075 74.410274) - (xy 93.3075 74.410277) (xy 93.3075 74.609723) (xy 93.3075 74.609725) (xy 93.307499 74.609725) (xy 93.342617 74.786265) - (xy 93.345 74.810457) (xy 93.345 76.249541) (xy 93.342617 76.273733) (xy 93.3075 76.450274) (xy 93.3075 76.633115) - (xy 93.287815 76.700154) (xy 93.235011 76.745909) (xy 93.165853 76.755853) (xy 93.114609 76.736217) - (xy 93.019605 76.672737) (xy 93.019592 76.67273) (xy 92.835339 76.596411) (xy 92.835329 76.596408) - (xy 92.639725 76.5575) (xy 92.639723 76.5575) (xy 92.440277 76.5575) (xy 92.440275 76.5575) (xy 92.24467 76.596408) - (xy 92.24466 76.596411) (xy 92.060407 76.67273) (xy 92.060394 76.672737) (xy 91.894569 76.783539) - (xy 91.894565 76.783542) (xy 91.753542 76.924565) (xy 91.753539 76.924569) (xy 91.642737 77.090394) - (xy 91.64273 77.090407) (xy 91.566411 77.27466) (xy 91.566408 77.27467) (xy 91.5275 77.470274) (xy 91.5275 77.470277) - (xy 91.5275 77.669723) (xy 91.5275 77.669725) (xy 91.527499 77.669725) (xy 91.566408 77.865329) - (xy 91.566411 77.865339) (xy 91.64273 78.049592) (xy 91.642737 78.049605) (xy 91.753539 78.21543) - (xy 91.753542 78.215434) (xy 91.894565 78.356457) (xy 91.894569 78.35646) (xy 92.060394 78.467262) - (xy 92.060407 78.467269) (xy 92.24466 78.543588) (xy 92.244665 78.54359) (xy 92.244669 78.54359) - (xy 92.24467 78.543591) (xy 92.440274 78.5825) (xy 92.440277 78.5825) (xy 92.639725 78.5825) (xy 92.771324 78.556322) - (xy 92.835335 78.54359) (xy 92.887887 78.521821) (xy 92.957355 78.514353) (xy 93.019834 78.545627) - (xy 93.02302 78.548702) (xy 93.308681 78.834363) (xy 93.342166 78.895686) (xy 93.345 78.922044) - (xy 93.345 80.538942) (xy 93.325315 80.605981) (xy 93.272511 80.651736) (xy 93.2404 80.661415) (xy 93.208633 80.666446) - (xy 92.984005 80.739433) (xy 92.773566 80.846657) (xy 92.66455 80.925862) (xy 92.58249 80.985483) - (xy 92.582488 80.985485) (xy 92.582487 80.985485) (xy 92.415485 81.152487) (xy 92.415485 81.152488) - (xy 92.415483 81.15249) (xy 92.355862 81.23455) (xy 92.276657 81.343566) (xy 92.169433 81.554003) - (xy 92.096446 81.778631) (xy 92.0595 82.011902) (xy 92.0595 82.248097) (xy 92.096446 82.481368) - (xy 92.169433 82.705996) (xy 92.276657 82.916433) (xy 92.415483 83.10751) (xy 92.58249 83.274517) - (xy 92.773567 83.413343) (xy 92.872991 83.464002) (xy 92.984003 83.520566) (xy 92.984005 83.520566) - (xy 92.984008 83.520568) (xy 93.113761 83.562727) (xy 93.208625 83.593551) (xy 93.208626 83.593551) - (xy 93.208632 83.593553) (xy 93.2404 83.598584) (xy 93.271219 83.613194) (xy 93.302203 83.627344) - (xy 93.3027 83.628117) (xy 93.303532 83.628512) (xy 93.321564 83.657472) (xy 93.339977 83.686122) - (xy 93.340148 83.687316) (xy 93.340464 83.687823) (xy 93.345 83.721057) (xy 93.345 83.784191) (xy 93.325315 83.85123) - (xy 93.272511 83.896985) (xy 93.240398 83.906664) (xy 93.178631 83.916446) (xy 92.954003 83.989433) - (xy 92.743566 84.096657) (xy 92.63455 84.175862) (xy 92.55249 84.235483) (xy 92.552488 84.235485) - (xy 92.552487 84.235485) (xy 92.385485 84.402487) (xy 92.385485 84.402488) (xy 92.385483 84.40249) - (xy 92.325862 84.48455) (xy 92.246657 84.593566) (xy 92.139433 84.804003) (xy 92.066446 85.028631) - (xy 92.0295 85.261902) (xy 92.0295 85.498097) (xy 92.066446 85.731368) (xy 92.139433 85.955996) - (xy 92.235038 86.14363) (xy 92.246657 86.166433) (xy 92.385483 86.35751) (xy 92.55249 86.524517) - (xy 92.743567 86.663343) (xy 92.842991 86.714002) (xy 92.954003 86.770566) (xy 92.954005 86.770566) - (xy 92.954008 86.770568) (xy 93.178632 86.843553) (xy 93.240401 86.853336) (xy 93.303532 86.883263) - (xy 93.340463 86.942574) (xy 93.345 86.975808) (xy 93.345 89.550978) (xy 93.335561 89.59843) (xy 93.31641 89.644663) - (xy 93.316408 89.644671) (xy 93.2775 89.840274) (xy 93.2775 89.840277) (xy 93.2775 90.039723) (xy 93.2775 90.039725) - (xy 93.277499 90.039725) (xy 93.316408 90.235329) (xy 93.31641 90.235335) (xy 93.335561 90.281569) - (xy 93.345 90.329022) (xy 93.345 91.590978) (xy 93.335561 91.63843) (xy 93.31641 91.684663) (xy 93.316408 91.684671) - (xy 93.2775 91.880274) (xy 93.2775 91.880277) (xy 93.2775 92.079723) (xy 93.2775 92.079725) (xy 93.277499 92.079725) - (xy 93.316408 92.275329) (xy 93.31641 92.275335) (xy 93.335561 92.321569) (xy 93.345 92.369022) - (xy 93.345 93.630978) (xy 93.335561 93.67843) (xy 93.31641 93.724663) (xy 93.316408 93.724671) (xy 93.2775 93.920274) - (xy 93.2775 93.920277) (xy 93.2775 94.119723) (xy 93.2775 94.119725) (xy 93.277499 94.119725) (xy 93.316408 94.315329) - (xy 93.31641 94.315335) (xy 93.335561 94.361569) (xy 93.345 94.409022) (xy 93.345 95.670978) (xy 93.341127 95.701728) - (xy 93.338939 95.710273) (xy 93.31641 95.764665) (xy 93.286409 95.915485) (xy 93.285574 95.91875) - (xy 93.269376 95.946005) (xy 93.254679 95.974103) (xy 93.251655 95.975824) (xy 93.249879 95.978814) - (xy 93.221524 95.992982) (xy 93.193963 96.008677) (xy 93.188945 96.009261) (xy 93.187378 96.010045) - (xy 93.184705 96.009755) (xy 93.165447 96.012) (xy 87.6245 96.012) (xy 87.557461 95.992315) (xy 87.511706 95.939511) - (xy 87.5005 95.888) (xy 87.5005 87.040356) (xy 88.1445 87.040356) (xy 88.1445 87.279643) (xy 88.144501 87.279659) - (xy 88.175734 87.5169) (xy 88.237669 87.748045) (xy 88.329243 87.969123) (xy 88.329251 87.96914) - (xy 88.448891 88.176365) (xy 88.448892 88.176367) (xy 88.594569 88.366216) (xy 88.594575 88.366223) - (xy 88.763776 88.535424) (xy 88.763783 88.53543) (xy 88.953632 88.681107) (xy 88.953634 88.681108) - (xy 89.160859 88.800748) (xy 89.160862 88.800749) (xy 89.16087 88.800754) (xy 89.381953 88.89233) - (xy 89.613098 88.954265) (xy 89.85035 88.9855) (xy 89.850357 88.9855) (xy 90.089643 88.9855) (xy 90.08965 88.9855) - (xy 90.326902 88.954265) (xy 90.558047 88.89233) (xy 90.77913 88.800754) (xy 90.98637 88.681105) - (xy 91.176218 88.535429) (xy 91.345429 88.366218) (xy 91.491105 88.17637) (xy 91.610754 87.96913) - (xy 91.70233 87.748047) (xy 91.764265 87.516902) (xy 91.7955 87.27965) (xy 91.7955 87.04035) (xy 91.764265 86.803098) - (xy 91.70233 86.571953) (xy 91.610754 86.35087) (xy 91.610748 86.350859) (xy 91.491108 86.143634) - (xy 91.491107 86.143632) (xy 91.34543 85.953783) (xy 91.345424 85.953776) (xy 91.176223 85.784575) - (xy 91.176216 85.784569) (xy 90.986367 85.638892) (xy 90.986365 85.638891) (xy 90.77914 85.519251) - (xy 90.779132 85.519247) (xy 90.77913 85.519246) (xy 90.558047 85.42767) (xy 90.558048 85.42767) - (xy 90.558045 85.427669) (xy 90.3269 85.365734) (xy 90.089659 85.334501) (xy 90.089656 85.3345) - (xy 90.08965 85.3345) (xy 89.85035 85.3345) (xy 89.850344 85.3345) (xy 89.85034 85.334501) (xy 89.613099 85.365734) - (xy 89.381954 85.427669) (xy 89.160876 85.519243) (xy 89.160859 85.519251) (xy 88.953634 85.638891) - (xy 88.953632 85.638892) (xy 88.763783 85.784569) (xy 88.763776 85.784575) (xy 88.594575 85.953776) - (xy 88.594569 85.953783) (xy 88.448892 86.143632) (xy 88.448891 86.143634) (xy 88.329251 86.350859) - (xy 88.329243 86.350876) (xy 88.237669 86.571954) (xy 88.175734 86.803099) (xy 88.144501 87.04034) - (xy 88.1445 87.040356) (xy 87.5005 87.040356) (xy 87.5005 80.230356) (xy 88.1745 80.230356) (xy 88.1745 80.469643) - (xy 88.174501 80.469659) (xy 88.205734 80.7069) (xy 88.267669 80.938045) (xy 88.359243 81.159123) - (xy 88.359251 81.15914) (xy 88.478891 81.366365) (xy 88.478892 81.366367) (xy 88.624569 81.556216) - (xy 88.624575 81.556223) (xy 88.793776 81.725424) (xy 88.793783 81.72543) (xy 88.983632 81.871107) - (xy 88.983634 81.871108) (xy 89.190859 81.990748) (xy 89.190862 81.990749) (xy 89.19087 81.990754) - (xy 89.411953 82.08233) (xy 89.643098 82.144265) (xy 89.88035 82.1755) (xy 89.880357 82.1755) (xy 90.119643 82.1755) - (xy 90.11965 82.1755) (xy 90.356902 82.144265) (xy 90.588047 82.08233) (xy 90.80913 81.990754) (xy 91.01637 81.871105) - (xy 91.206218 81.725429) (xy 91.375429 81.556218) (xy 91.521105 81.36637) (xy 91.640754 81.15913) - (xy 91.73233 80.938047) (xy 91.794265 80.706902) (xy 91.8255 80.46965) (xy 91.8255 80.23035) (xy 91.794265 79.993098) - (xy 91.73233 79.761953) (xy 91.640754 79.54087) (xy 91.640748 79.540859) (xy 91.521108 79.333634) - (xy 91.521107 79.333632) (xy 91.37543 79.143783) (xy 91.375424 79.143776) (xy 91.206223 78.974575) - (xy 91.206216 78.974569) (xy 91.016367 78.828892) (xy 91.016365 78.828891) (xy 90.80914 78.709251) - (xy 90.809132 78.709247) (xy 90.80913 78.709246) (xy 90.588047 78.61767) (xy 90.588048 78.61767) - (xy 90.588045 78.617669) (xy 90.3569 78.555734) (xy 90.119659 78.524501) (xy 90.119656 78.5245) - (xy 90.11965 78.5245) (xy 89.88035 78.5245) (xy 89.880344 78.5245) (xy 89.88034 78.524501) (xy 89.643099 78.555734) - (xy 89.411954 78.617669) (xy 89.190876 78.709243) (xy 89.190859 78.709251) (xy 88.983634 78.828891) - (xy 88.983632 78.828892) (xy 88.793783 78.974569) (xy 88.793776 78.974575) (xy 88.624575 79.143776) - (xy 88.624569 79.143783) (xy 88.478892 79.333632) (xy 88.478891 79.333634) (xy 88.359251 79.540859) - (xy 88.359243 79.540876) (xy 88.267669 79.761954) (xy 88.205734 79.993099) (xy 88.174501 80.23034) - (xy 88.1745 80.230356) (xy 87.5005 80.230356) (xy 87.5005 70.482) (xy 87.520185 70.414961) (xy 87.572989 70.369206) - (xy 87.6245 70.358) (xy 93.1835 70.358) + (xy 109.671039 111.017685) (xy 109.716794 111.070489) (xy 109.728 111.122) (xy 109.728 112.652) + (xy 109.708315 112.719039) (xy 109.655511 112.764794) (xy 109.604 112.776) (xy 107.696 112.776) + (xy 107.696 113.414) (xy 107.676315 113.481039) (xy 107.623511 113.526794) (xy 107.572 113.538) + (xy 105.28 113.538) (xy 105.212961 113.518315) (xy 105.167206 113.465511) (xy 105.156 113.414) (xy 105.156 111.122) + (xy 105.175685 111.054961) (xy 105.228489 111.009206) (xy 105.28 110.998) (xy 109.604 110.998) ) ) (filled_polygon (layer "B.Cu") (pts - (xy 93.250539 70.377685) (xy 93.296294 70.430489) (xy 93.3075 70.482) (xy 93.3075 70.529723) (xy 93.3075 70.529725) - (xy 93.307499 70.529725) (xy 93.342617 70.706265) (xy 93.345 70.730457) (xy 93.345 72.169541) (xy 93.342617 72.193733) - (xy 93.3075 72.370274) (xy 93.3075 72.370277) (xy 93.3075 72.569723) (xy 93.3075 72.569725) (xy 93.307499 72.569725) - (xy 93.342617 72.746265) (xy 93.345 72.770457) (xy 93.345 74.209541) (xy 93.342617 74.233733) (xy 93.3075 74.410274) - (xy 93.3075 74.410277) (xy 93.3075 74.609723) (xy 93.3075 74.609725) (xy 93.307499 74.609725) (xy 93.342617 74.786265) - (xy 93.345 74.810457) (xy 93.345 76.249541) (xy 93.342617 76.273733) (xy 93.3075 76.450274) (xy 93.3075 76.633115) - (xy 93.287815 76.700154) (xy 93.235011 76.745909) (xy 93.165853 76.755853) (xy 93.114609 76.736217) - (xy 93.019605 76.672737) (xy 93.019592 76.67273) (xy 92.835339 76.596411) (xy 92.835329 76.596408) - (xy 92.639725 76.5575) (xy 92.639723 76.5575) (xy 92.440277 76.5575) (xy 92.440275 76.5575) (xy 92.24467 76.596408) - (xy 92.24466 76.596411) (xy 92.060407 76.67273) (xy 92.060394 76.672737) (xy 91.894569 76.783539) - (xy 91.894565 76.783542) (xy 91.753542 76.924565) (xy 91.753539 76.924569) (xy 91.642737 77.090394) - (xy 91.64273 77.090407) (xy 91.566411 77.27466) (xy 91.566408 77.27467) (xy 91.5275 77.470274) (xy 91.5275 77.470277) - (xy 91.5275 77.669723) (xy 91.5275 77.669725) (xy 91.527499 77.669725) (xy 91.566408 77.865329) - (xy 91.566411 77.865339) (xy 91.64273 78.049592) (xy 91.642737 78.049605) (xy 91.753539 78.21543) - (xy 91.753542 78.215434) (xy 91.894565 78.356457) (xy 91.894569 78.35646) (xy 92.060394 78.467262) - (xy 92.060407 78.467269) (xy 92.24466 78.543588) (xy 92.244665 78.54359) (xy 92.244669 78.54359) - (xy 92.24467 78.543591) (xy 92.440274 78.5825) (xy 92.440277 78.5825) (xy 92.639725 78.5825) (xy 92.771324 78.556322) - (xy 92.835335 78.54359) (xy 93.019599 78.467266) (xy 93.152109 78.378724) (xy 93.218786 78.357847) - (xy 93.286166 78.376331) (xy 93.332857 78.42831) (xy 93.345 78.481827) (xy 93.345 80.644847) (xy 93.208631 80.666446) - (xy 92.984003 80.739433) (xy 92.773566 80.846657) (xy 92.66455 80.925862) (xy 92.58249 80.985483) - (xy 92.582488 80.985485) (xy 92.582487 80.985485) (xy 92.415485 81.152487) (xy 92.415485 81.152488) - (xy 92.415483 81.15249) (xy 92.355862 81.23455) (xy 92.276657 81.343566) (xy 92.169433 81.554003) - (xy 92.096446 81.778631) (xy 92.0595 82.011902) (xy 92.0595 82.248097) (xy 92.096446 82.481368) - (xy 92.169433 82.705996) (xy 92.276657 82.916433) (xy 92.415483 83.10751) (xy 92.58249 83.274517) - (xy 92.773567 83.413343) (xy 92.872991 83.464002) (xy 92.984003 83.520566) (xy 92.984005 83.520566) - (xy 92.984008 83.520568) (xy 93.104412 83.559689) (xy 93.208631 83.593553) (xy 93.24727 83.599672) - (xy 93.345 83.615151) (xy 93.345 83.890096) (xy 93.178631 83.916446) (xy 92.954003 83.989433) (xy 92.743566 84.096657) - (xy 92.63455 84.175862) (xy 92.55249 84.235483) (xy 92.552488 84.235485) (xy 92.552487 84.235485) - (xy 92.385485 84.402487) (xy 92.385485 84.402488) (xy 92.385483 84.40249) (xy 92.325862 84.48455) - (xy 92.246657 84.593566) (xy 92.139433 84.804003) (xy 92.066446 85.028631) (xy 92.0295 85.261902) - (xy 92.0295 85.498097) (xy 92.066446 85.731368) (xy 92.139433 85.955996) (xy 92.235038 86.14363) - (xy 92.246657 86.166433) (xy 92.385483 86.35751) (xy 92.55249 86.524517) (xy 92.743567 86.663343) - (xy 92.842991 86.714002) (xy 92.954003 86.770566) (xy 92.954005 86.770566) (xy 92.954008 86.770568) - (xy 93.054125 86.803098) (xy 93.178631 86.843553) (xy 93.345 86.869903) (xy 93.345 88.773) (xy 93.345 89.550978) - (xy 93.335561 89.59843) (xy 93.31641 89.644663) (xy 93.316408 89.644671) (xy 93.2775 89.840274) - (xy 93.2775 89.840277) (xy 93.2775 90.039723) (xy 93.2775 90.039725) (xy 93.277499 90.039725) (xy 93.316408 90.235329) - (xy 93.31641 90.235335) (xy 93.335561 90.281569) (xy 93.345 90.329022) (xy 93.345 91.590978) (xy 93.335561 91.63843) - (xy 93.31641 91.684663) (xy 93.316408 91.684671) (xy 93.2775 91.880274) (xy 93.2775 91.880277) (xy 93.2775 92.079723) - (xy 93.2775 92.079725) (xy 93.277499 92.079725) (xy 93.316408 92.275329) (xy 93.31641 92.275335) - (xy 93.335561 92.321569) (xy 93.345 92.369022) (xy 93.345 93.630978) (xy 93.335561 93.67843) (xy 93.31641 93.724663) - (xy 93.316408 93.724671) (xy 93.2775 93.920274) (xy 93.2775 93.920277) (xy 93.2775 94.119723) (xy 93.2775 94.119725) - (xy 93.277499 94.119725) (xy 93.316408 94.315329) (xy 93.31641 94.315335) (xy 93.335561 94.361569) - (xy 93.345 94.409022) (xy 93.345 95.670978) (xy 93.341127 95.701728) (xy 93.338939 95.710273) (xy 93.31641 95.764665) - (xy 93.286409 95.915485) (xy 93.285574 95.91875) (xy 93.269376 95.946005) (xy 93.254679 95.974103) - (xy 93.251655 95.975824) (xy 93.249879 95.978814) (xy 93.221524 95.992982) (xy 93.193963 96.008677) - (xy 93.188945 96.009261) (xy 93.187378 96.010045) (xy 93.184705 96.009755) (xy 93.165447 96.012) - (xy 87.6245 96.012) (xy 87.557461 95.992315) (xy 87.511706 95.939511) (xy 87.5005 95.888) (xy 87.5005 87.040356) - (xy 88.1445 87.040356) (xy 88.1445 87.279643) (xy 88.144501 87.279659) (xy 88.175734 87.5169) (xy 88.237669 87.748045) - (xy 88.329243 87.969123) (xy 88.329251 87.96914) (xy 88.448891 88.176365) (xy 88.448892 88.176367) - (xy 88.594569 88.366216) (xy 88.594575 88.366223) (xy 88.763776 88.535424) (xy 88.763783 88.53543) - (xy 88.953632 88.681107) (xy 88.953634 88.681108) (xy 89.160859 88.800748) (xy 89.160862 88.800749) - (xy 89.16087 88.800754) (xy 89.381953 88.89233) (xy 89.613098 88.954265) (xy 89.85035 88.9855) (xy 89.850357 88.9855) - (xy 90.089643 88.9855) (xy 90.08965 88.9855) (xy 90.326902 88.954265) (xy 90.558047 88.89233) (xy 90.77913 88.800754) - (xy 90.98637 88.681105) (xy 91.176218 88.535429) (xy 91.345429 88.366218) (xy 91.491105 88.17637) - (xy 91.610754 87.96913) (xy 91.70233 87.748047) (xy 91.764265 87.516902) (xy 91.7955 87.27965) (xy 91.7955 87.04035) - (xy 91.764265 86.803098) (xy 91.70233 86.571953) (xy 91.610754 86.35087) (xy 91.610748 86.350859) - (xy 91.491108 86.143634) (xy 91.491107 86.143632) (xy 91.34543 85.953783) (xy 91.345424 85.953776) - (xy 91.176223 85.784575) (xy 91.176216 85.784569) (xy 90.986367 85.638892) (xy 90.986365 85.638891) - (xy 90.77914 85.519251) (xy 90.779132 85.519247) (xy 90.77913 85.519246) (xy 90.558047 85.42767) - (xy 90.558048 85.42767) (xy 90.558045 85.427669) (xy 90.3269 85.365734) (xy 90.089659 85.334501) - (xy 90.089656 85.3345) (xy 90.08965 85.3345) (xy 89.85035 85.3345) (xy 89.850344 85.3345) (xy 89.85034 85.334501) - (xy 89.613099 85.365734) (xy 89.381954 85.427669) (xy 89.160876 85.519243) (xy 89.160859 85.519251) - (xy 88.953634 85.638891) (xy 88.953632 85.638892) (xy 88.763783 85.784569) (xy 88.763776 85.784575) - (xy 88.594575 85.953776) (xy 88.594569 85.953783) (xy 88.448892 86.143632) (xy 88.448891 86.143634) - (xy 88.329251 86.350859) (xy 88.329243 86.350876) (xy 88.237669 86.571954) (xy 88.175734 86.803099) - (xy 88.144501 87.04034) (xy 88.1445 87.040356) (xy 87.5005 87.040356) (xy 87.5005 80.230356) (xy 88.1745 80.230356) - (xy 88.1745 80.469643) (xy 88.174501 80.469659) (xy 88.205734 80.7069) (xy 88.267669 80.938045) - (xy 88.359243 81.159123) (xy 88.359251 81.15914) (xy 88.478891 81.366365) (xy 88.478892 81.366367) - (xy 88.624569 81.556216) (xy 88.624575 81.556223) (xy 88.793776 81.725424) (xy 88.793783 81.72543) - (xy 88.983632 81.871107) (xy 88.983634 81.871108) (xy 89.190859 81.990748) (xy 89.190862 81.990749) - (xy 89.19087 81.990754) (xy 89.411953 82.08233) (xy 89.643098 82.144265) (xy 89.88035 82.1755) (xy 89.880357 82.1755) - (xy 90.119643 82.1755) (xy 90.11965 82.1755) (xy 90.356902 82.144265) (xy 90.588047 82.08233) (xy 90.80913 81.990754) - (xy 91.01637 81.871105) (xy 91.206218 81.725429) (xy 91.375429 81.556218) (xy 91.521105 81.36637) - (xy 91.640754 81.15913) (xy 91.73233 80.938047) (xy 91.794265 80.706902) (xy 91.8255 80.46965) (xy 91.8255 80.23035) - (xy 91.794265 79.993098) (xy 91.73233 79.761953) (xy 91.640754 79.54087) (xy 91.640748 79.540859) - (xy 91.521108 79.333634) (xy 91.521107 79.333632) (xy 91.37543 79.143783) (xy 91.375424 79.143776) - (xy 91.206223 78.974575) (xy 91.206216 78.974569) (xy 91.016367 78.828892) (xy 91.016365 78.828891) - (xy 90.80914 78.709251) (xy 90.809132 78.709247) (xy 90.80913 78.709246) (xy 90.588047 78.61767) - (xy 90.588048 78.61767) (xy 90.588045 78.617669) (xy 90.3569 78.555734) (xy 90.119659 78.524501) - (xy 90.119656 78.5245) (xy 90.11965 78.5245) (xy 89.88035 78.5245) (xy 89.880344 78.5245) (xy 89.88034 78.524501) - (xy 89.643099 78.555734) (xy 89.411954 78.617669) (xy 89.190876 78.709243) (xy 89.190859 78.709251) - (xy 88.983634 78.828891) (xy 88.983632 78.828892) (xy 88.793783 78.974569) (xy 88.793776 78.974575) - (xy 88.624575 79.143776) (xy 88.624569 79.143783) (xy 88.478892 79.333632) (xy 88.478891 79.333634) - (xy 88.359251 79.540859) (xy 88.359243 79.540876) (xy 88.267669 79.761954) (xy 88.205734 79.993099) - (xy 88.174501 80.23034) (xy 88.1745 80.230356) (xy 87.5005 80.230356) (xy 87.5005 70.482) (xy 87.520185 70.414961) - (xy 87.572989 70.369206) (xy 87.6245 70.358) (xy 93.1835 70.358) - ) - ) - ) - (zone - (net 4) - (net_name "Vin") - (layer "B.Cu") - (uuid "3ee0d734-5a0e-45eb-8814-a932b8f04dc1") - (hatch edge 0.5) - (priority 5) - (connect_pads yes - (clearance 0.25) - ) - (min_thickness 0.25) - (filled_areas_thickness no) - (fill yes - (thermal_gap 0.5) - (thermal_bridge_width 0.5) - ) - (polygon - (pts - (xy 93.345 78.486) (xy 96.774 78.486) (xy 96.774 88.773) (xy 93.345 88.773) - ) - ) - (filled_polygon - (layer "B.Cu") - (pts - (xy 95.592655 78.502612) (xy 95.653216 78.537577) (xy 95.805943 78.5785) (xy 95.805945 78.5785) - (xy 95.964055 78.5785) (xy 95.964057 78.5785) (xy 96.116784 78.537577) (xy 96.177344 78.502612) - (xy 96.239343 78.486) (xy 96.65 78.486) (xy 96.717039 78.505685) (xy 96.762794 78.558489) (xy 96.774 78.61) - (xy 96.774 88.649) (xy 96.754315 88.716039) (xy 96.701511 88.761794) (xy 96.65 88.773) (xy 93.345 88.773) - (xy 93.345 86.869903) (xy 93.411903 86.8805) (xy 93.411908 86.8805) (xy 93.648097 86.8805) (xy 93.881368 86.843553) - (xy 94.105992 86.770568) (xy 94.316433 86.663343) (xy 94.50751 86.524517) (xy 94.674517 86.35751) - (xy 94.813343 86.166433) (xy 94.920568 85.955992) (xy 94.993553 85.731368) (xy 95.0305 85.498097) - (xy 95.0305 85.261902) (xy 94.993553 85.028631) (xy 94.920566 84.804003) (xy 94.813342 84.593566) - (xy 94.674517 84.40249) (xy 94.50751 84.235483) (xy 94.316433 84.096657) (xy 94.105996 83.989433) - (xy 93.881368 83.916446) (xy 93.648097 83.8795) (xy 93.648092 83.8795) (xy 93.411908 83.8795) (xy 93.411903 83.8795) - (xy 93.345 83.890096) (xy 93.345 83.615151) (xy 93.377551 83.620307) (xy 93.441903 83.6305) (xy 93.441908 83.6305) - (xy 93.678097 83.6305) (xy 93.911368 83.593553) (xy 94.135992 83.520568) (xy 94.346433 83.413343) - (xy 94.53751 83.274517) (xy 94.704517 83.10751) (xy 94.843343 82.916433) (xy 94.950568 82.705992) - (xy 95.023553 82.481368) (xy 95.0605 82.248097) (xy 95.0605 82.011902) (xy 95.023553 81.778631) - (xy 94.950566 81.554003) (xy 94.843342 81.343566) (xy 94.704517 81.15249) (xy 94.53751 80.985483) - (xy 94.346433 80.846657) (xy 94.135996 80.739433) (xy 93.911368 80.666446) (xy 93.678097 80.6295) - (xy 93.678092 80.6295) (xy 93.441908 80.6295) (xy 93.441903 80.6295) (xy 93.345 80.644847) (xy 93.345 78.486) - (xy 95.530657 78.486) + (xy 109.671039 111.017685) (xy 109.716794 111.070489) (xy 109.728 111.122) (xy 109.728 112.652) + (xy 109.708315 112.719039) (xy 109.655511 112.764794) (xy 109.604 112.776) (xy 107.696 112.776) + (xy 107.696 113.414) (xy 107.676315 113.481039) (xy 107.623511 113.526794) (xy 107.572 113.538) + (xy 105.28 113.538) (xy 105.212961 113.518315) (xy 105.167206 113.465511) (xy 105.156 113.414) (xy 105.156 111.122) + (xy 105.175685 111.054961) (xy 105.228489 111.009206) (xy 105.28 110.998) (xy 109.604 110.998) ) ) ) diff --git a/hardware/mcu.kicad_sch b/hardware/mcu.kicad_sch index e649b4f..d16e18c 100644 --- a/hardware/mcu.kicad_sch +++ b/hardware/mcu.kicad_sch @@ -1441,26 +1441,29 @@ ) (embedded_fonts no) ) - (symbol "Interface_CAN_LIN:TJA1042T-3" + (symbol "Interface_CAN_LIN:SN65HVD230" + (pin_names + (offset 1.016) + ) (exclude_from_sim no) (in_bom yes) (on_board yes) (property "Reference" "U" - (at -10.16 8.89 0) + (at -2.54 10.16 0) (effects (font (size 1.27 1.27) ) - (justify left) + (justify right) ) ) - (property "Value" "TJA1042T-3" - (at 1.27 8.89 0) + (property "Value" "SN65HVD230" + (at -2.54 7.62 0) (effects (font (size 1.27 1.27) ) - (justify left) + (justify right) ) ) (property "Footprint" "Package_SO:SOIC-8_3.9x4.9mm_P1.27mm" @@ -1468,12 +1471,20 @@ (effects (font (size 1.27 1.27) - (italic yes) ) (hide yes) ) ) - (property "Datasheet" "http://www.nxp.com/docs/en/data-sheet/TJA1042.pdf" + (property "Datasheet" "http://www.ti.com/lit/ds/symlink/sn65hvd230.pdf" + (at -2.54 10.16 0) + (effects + (font + (size 1.27 1.27) + ) + (hide yes) + ) + ) + (property "Description" "CAN Bus Transceivers, 3.3V, 1Mbps, Low-Power capabilities, SOIC-8" (at 0 0 0) (effects (font @@ -1482,16 +1493,7 @@ (hide yes) ) ) - (property "Description" "High-Speed CAN Transceiver, separate VIO, standby mode, SOIC-8" - (at 0 0 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "ki_keywords" "High-Speed CAN Transceiver" + (property "ki_keywords" "can transeiver ti low-power" (at 0 0 0) (effects (font @@ -1509,10 +1511,10 @@ (hide yes) ) ) - (symbol "TJA1042T-3_0_1" + (symbol "SN65HVD230_0_1" (rectangle - (start -10.16 7.62) - (end 10.16 -7.62) + (start -7.62 5.08) + (end 7.62 -7.62) (stroke (width 0.254) (type default) @@ -1522,11 +1524,11 @@ ) ) ) - (symbol "TJA1042T-3_1_1" + (symbol "SN65HVD230_1_1" (pin input line - (at -12.7 5.08 0) + (at -10.16 2.54 0) (length 2.54) - (name "TXD" + (name "D" (effects (font (size 1.27 1.27) @@ -1542,9 +1544,9 @@ ) ) (pin output line - (at -12.7 2.54 0) + (at -10.16 0 0) (length 2.54) - (name "RXD" + (name "R" (effects (font (size 1.27 1.27) @@ -1559,10 +1561,10 @@ ) ) ) - (pin power_in line - (at -12.7 -2.54 0) + (pin output line + (at -10.16 -2.54 0) (length 2.54) - (name "VIO" + (name "Vref" (effects (font (size 1.27 1.27) @@ -1578,9 +1580,9 @@ ) ) (pin input line - (at -12.7 -5.08 0) + (at -10.16 -5.08 0) (length 2.54) - (name "STB" + (name "Rs" (effects (font (size 1.27 1.27) @@ -1596,7 +1598,7 @@ ) ) (pin power_in line - (at 0 10.16 270) + (at 0 7.62 270) (length 2.54) (name "VCC" (effects @@ -1632,7 +1634,7 @@ ) ) (pin bidirectional line - (at 12.7 2.54 180) + (at 10.16 0 180) (length 2.54) (name "CANH" (effects @@ -1650,7 +1652,7 @@ ) ) (pin bidirectional line - (at 12.7 -2.54 180) + (at 10.16 -2.54 180) (length 2.54) (name "CANL" (effects @@ -2876,131 +2878,6 @@ ) (embedded_fonts no) ) - (symbol "power:+5C" - (power) - (pin_numbers - (hide yes) - ) - (pin_names - (offset 0) - (hide yes) - ) - (exclude_from_sim no) - (in_bom yes) - (on_board yes) - (property "Reference" "#PWR" - (at 0 -3.81 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Value" "+5C" - (at 0 3.556 0) - (effects - (font - (size 1.27 1.27) - ) - ) - ) - (property "Footprint" "" - (at 0 0 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Datasheet" "" - (at 0 0 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Description" "Power symbol creates a global label with name \"+5C\"" - (at 0 0 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "ki_keywords" "global power" - (at 0 0 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (symbol "+5C_0_1" - (polyline - (pts - (xy -0.762 1.27) (xy 0 2.54) - ) - (stroke - (width 0) - (type default) - ) - (fill - (type none) - ) - ) - (polyline - (pts - (xy 0 2.54) (xy 0.762 1.27) - ) - (stroke - (width 0) - (type default) - ) - (fill - (type none) - ) - ) - (polyline - (pts - (xy 0 0) (xy 0 2.54) - ) - (stroke - (width 0) - (type default) - ) - (fill - (type none) - ) - ) - ) - (symbol "+5C_1_1" - (pin power_in line - (at 0 0 90) - (length 0) - (name "~" - (effects - (font - (size 1.27 1.27) - ) - ) - ) - (number "1" - (effects - (font - (size 1.27 1.27) - ) - ) - ) - ) - ) - (embedded_fonts no) - ) (symbol "power:GND" (power) (pin_numbers @@ -3229,10 +3106,10 @@ ) ) (junction - (at 254 82.55) + (at 251.46 90.17) (diameter 0) (color 0 0 0 0) - (uuid "01f880ff-65ea-48c8-9121-007f03634e82") + (uuid "023b79cf-8fdd-4340-b5d9-16960f286d62") ) (junction (at 180.34 45.72) @@ -3240,6 +3117,12 @@ (color 0 0 0 0) (uuid "09357d01-f544-440f-b2f9-46136a870f6d") ) + (junction + (at 254 114.3) + (diameter 0) + (color 0 0 0 0) + (uuid "0958c26b-975b-4f15-919d-04a2c556c391") + ) (junction (at 189.23 93.98) (diameter 0) @@ -3264,12 +3147,6 @@ (color 0 0 0 0) (uuid "13dbaa24-6a28-461b-8613-60a6acc70d1b") ) - (junction - (at 254 87.63) - (diameter 0) - (color 0 0 0 0) - (uuid "181cac62-ac4d-40cb-936a-5e5ff25e7bb1") - ) (junction (at 59.69 69.85) (diameter 0) @@ -3282,18 +3159,18 @@ (color 0 0 0 0) (uuid "221555ed-b498-4038-9d37-8ce39b65a4bd") ) - (junction - (at 251.46 114.3) - (diameter 0) - (color 0 0 0 0) - (uuid "3a67126f-05a5-498e-a4a1-cba6c0ced987") - ) (junction (at 82.55 113.03) (diameter 0) (color 0 0 0 0) (uuid "3cf3e85a-e9f4-45f0-aff7-25c80ff76714") ) + (junction + (at 254 116.84) + (diameter 0) + (color 0 0 0 0) + (uuid "3e38b72a-4887-4ece-8bfe-9f405f7ffbe7") + ) (junction (at 36.83 63.5) (diameter 0) @@ -3307,10 +3184,10 @@ (uuid "3fa1dbf6-775d-4a47-81d2-0d6bb367c79f") ) (junction - (at 251.46 119.38) + (at 254 85.09) (diameter 0) (color 0 0 0 0) - (uuid "40e81b64-f9d9-45fb-86d9-6871c9d79653") + (uuid "43f4f90f-fd7f-49a0-bc13-5c1ff4b39af9") ) (junction (at 102.87 48.26) @@ -3324,18 +3201,18 @@ (color 0 0 0 0) (uuid "55e47a7f-af73-448a-9706-09d1afe89a34") ) + (junction + (at 251.46 92.71) + (diameter 0) + (color 0 0 0 0) + (uuid "5aab71a1-e416-430f-a142-36795b3961ca") + ) (junction (at 59.69 57.15) (diameter 0) (color 0 0 0 0) (uuid "5f3c402f-1c14-44f1-a67f-76c32aa34283") ) - (junction - (at 254 92.71) - (diameter 0) - (color 0 0 0 0) - (uuid "5f74bee3-e4f1-473d-9495-fc956fc69fdb") - ) (junction (at 135.89 50.8) (diameter 0) @@ -3348,6 +3225,12 @@ (color 0 0 0 0) (uuid "64dbab03-9c9c-44e3-b5f8-d24d6b697668") ) + (junction + (at 254 82.55) + (diameter 0) + (color 0 0 0 0) + (uuid "76aa01f5-130d-4299-868c-1e72a7282ec7") + ) (junction (at 166.37 33.02) (diameter 0) @@ -3360,12 +3243,6 @@ (color 0 0 0 0) (uuid "81537b42-a383-4c76-88ba-e00fac1e7426") ) - (junction - (at 254 121.92) - (diameter 0) - (color 0 0 0 0) - (uuid "8a947cf2-6759-4669-b245-9b06364051a2") - ) (junction (at 248.92 132.08) (diameter 0) @@ -3379,16 +3256,10 @@ (uuid "8f60c940-dc18-4257-a42d-3d4d7387b08b") ) (junction - (at 254 116.84) + (at 251.46 124.46) (diameter 0) (color 0 0 0 0) - (uuid "8f646df4-eda4-4ed2-aefa-6e12d8cf304b") - ) - (junction - (at 251.46 90.17) - (diameter 0) - (color 0 0 0 0) - (uuid "9470f718-be4f-4682-8e4c-f89b6c790c5b") + (uuid "a0d5a6f3-20b5-4990-b813-42f68fe6e6bc") ) (junction (at 251.46 138.43) @@ -3414,24 +3285,6 @@ (color 0 0 0 0) (uuid "b1f2c6bc-c6f4-40a7-bcc6-742dfc099ff4") ) - (junction - (at 181.61 132.08) - (diameter 0) - (color 0 0 0 0) - (uuid "b2e3adaf-0895-425a-afd0-8ecd3f2dac1e") - ) - (junction - (at 251.46 124.46) - (diameter 0) - (color 0 0 0 0) - (uuid "bb5b341c-382d-49e5-a091-7a677750bfa4") - ) - (junction - (at 251.46 85.09) - (diameter 0) - (color 0 0 0 0) - (uuid "c301f8f0-e43e-4a83-ac52-df08f5676307") - ) (junction (at 91.44 60.96) (diameter 0) @@ -3439,10 +3292,16 @@ (uuid "c41a19d1-5d57-402d-b10d-7b48495c6fee") ) (junction - (at 170.18 144.78) + (at 251.46 121.92) (diameter 0) (color 0 0 0 0) - (uuid "c877bbff-29ae-480a-9bf4-01aa33a3734c") + (uuid "c5dedc30-d104-4c82-803d-ab3f49b06a1d") + ) + (junction + (at 251.46 127) + (diameter 0) + (color 0 0 0 0) + (uuid "d4cf2686-aa67-4a87-bdb1-85590e334e39") ) (junction (at 82.55 105.41) @@ -3450,12 +3309,6 @@ (color 0 0 0 0) (uuid "db21d2fc-44cb-49ad-bc2f-36be69145b98") ) - (junction - (at 196.85 115.57) - (diameter 0) - (color 0 0 0 0) - (uuid "e49b645c-4580-46c4-a9d5-2f8e36a76d64") - ) (junction (at 196.85 144.78) (diameter 0) @@ -3480,6 +3333,12 @@ (color 0 0 0 0) (uuid "f2adbe8e-0b08-42da-b86d-ff417228f3e7") ) + (junction + (at 254 80.01) + (diameter 0) + (color 0 0 0 0) + (uuid "f8c29a3b-9efe-4060-88eb-db67e69acd54") + ) (no_connect (at 128.27 53.34) (uuid "6d887f29-1005-4468-ae0f-5ecbca81580b") @@ -3618,16 +3477,6 @@ ) (uuid "100caf50-6fe7-47d9-9a5d-5e92df7de965") ) - (wire - (pts - (xy 170.18 134.62) (xy 170.18 132.08) - ) - (stroke - (width 0) - (type default) - ) - (uuid "10249341-239c-4736-9ed3-32e3f838bbce") - ) (wire (pts (xy 138.43 50.8) (xy 135.89 50.8) @@ -3658,6 +3507,16 @@ ) (uuid "172ff6f0-7885-4f80-892e-12e481a0c55c") ) + (wire + (pts + (xy 256.54 119.38) (xy 254 119.38) + ) + (stroke + (width 0) + (type default) + ) + (uuid "1750052f-c680-484c-b9bc-5f216e73b8e7") + ) (wire (pts (xy 135.89 134.62) (xy 135.89 137.16) @@ -3758,16 +3617,6 @@ ) (uuid "253e49fd-0047-4e1c-88eb-edc46ac69f10") ) - (wire - (pts - (xy 170.18 142.24) (xy 170.18 144.78) - ) - (stroke - (width 0) - (type default) - ) - (uuid "27531bb5-9857-46d0-b61d-0df9a4c7e85b") - ) (wire (pts (xy 115.57 71.12) (xy 73.66 71.12) @@ -3788,16 +3637,6 @@ ) (uuid "2c8e7b0f-8871-47dc-9615-52c725384ab1") ) - (wire - (pts - (xy 215.9 125.73) (xy 215.9 144.78) - ) - (stroke - (width 0) - (type default) - ) - (uuid "2d31484f-728c-427b-8d81-5c2c777457f1") - ) (wire (pts (xy 115.57 73.66) (xy 71.12 73.66) @@ -3818,6 +3657,16 @@ ) (uuid "3005852e-5062-42b5-9146-853348ed1361") ) + (wire + (pts + (xy 254 119.38) (xy 254 116.84) + ) + (stroke + (width 0) + (type default) + ) + (uuid "3272295a-c900-43a5-98a2-358eebdc3f91") + ) (wire (pts (xy 130.81 30.48) (xy 130.81 33.02) @@ -3838,6 +3687,16 @@ ) (uuid "34da68da-b8cd-4a36-a871-17057786fc36") ) + (wire + (pts + (xy 251.46 92.71) (xy 251.46 90.17) + ) + (stroke + (width 0) + (type default) + ) + (uuid "35867608-3cec-446d-9356-ecc08b5e8caf") + ) (wire (pts (xy 180.34 43.18) (xy 180.34 45.72) @@ -3900,13 +3759,13 @@ ) (wire (pts - (xy 254 127) (xy 254 121.92) + (xy 254 85.09) (xy 254 82.55) ) (stroke (width 0) (type default) ) - (uuid "3b9da5d6-5cf2-42f7-8f37-21576cd1855a") + (uuid "3c6780f9-344f-4e90-a9d6-4105266d14ae") ) (wire (pts @@ -3928,6 +3787,16 @@ ) (uuid "3f35188b-6c6e-4e20-9422-77d028680843") ) + (wire + (pts + (xy 207.01 129.54) (xy 246.38 129.54) + ) + (stroke + (width 0) + (type default) + ) + (uuid "3f44de36-ea27-42ad-bc98-331666f3632f") + ) (wire (pts (xy 115.57 104.14) (xy 88.9 104.14) @@ -4000,13 +3869,23 @@ ) (wire (pts - (xy 254 116.84) (xy 254 92.71) + (xy 207.01 132.08) (xy 248.92 132.08) ) (stroke (width 0) (type default) ) - (uuid "4de39e4f-1053-4234-8515-d72d7a09e3e7") + (uuid "4e08cc4e-fc82-4aea-b8c6-21882b0a36cd") + ) + (wire + (pts + (xy 251.46 121.92) (xy 256.54 121.92) + ) + (stroke + (width 0) + (type default) + ) + (uuid "5101871f-79a0-43d5-9262-9c9d0acfb8d5") ) (wire (pts @@ -4048,26 +3927,6 @@ ) (uuid "5a04eb72-c5c6-4be6-ac1a-c83dcaf8da96") ) - (wire - (pts - (xy 254 92.71) (xy 256.54 92.71) - ) - (stroke - (width 0) - (type default) - ) - (uuid "5a74c1e7-3665-4b86-bfa1-1e4a22f98902") - ) - (wire - (pts - (xy 212.09 129.54) (xy 246.38 129.54) - ) - (stroke - (width 0) - (type default) - ) - (uuid "5a7afc84-de6f-430e-a477-f63ad7036d39") - ) (wire (pts (xy 48.26 57.15) (xy 48.26 59.69) @@ -4078,6 +3937,16 @@ ) (uuid "5c02a850-2228-4e1c-b9cf-febf7400c991") ) + (wire + (pts + (xy 175.26 127) (xy 186.69 127) + ) + (stroke + (width 0) + (type default) + ) + (uuid "5de1084c-69ca-4cf2-a56c-0a6eed704c1b") + ) (wire (pts (xy 246.38 95.25) (xy 256.54 95.25) @@ -4098,16 +3967,6 @@ ) (uuid "62176738-6b41-4948-bed2-41dab2905b43") ) - (wire - (pts - (xy 196.85 111.76) (xy 196.85 115.57) - ) - (stroke - (width 0) - (type default) - ) - (uuid "644d7f0e-c162-4cfe-a405-40fe210099ae") - ) (wire (pts (xy 113.03 116.84) (xy 115.57 116.84) @@ -4118,16 +3977,6 @@ ) (uuid "64aa2464-9be3-423f-85f5-e2c7343b3f39") ) - (wire - (pts - (xy 254 92.71) (xy 254 87.63) - ) - (stroke - (width 0) - (type default) - ) - (uuid "6778750d-e847-4f20-ab83-d03400de8d87") - ) (wire (pts (xy 36.83 63.5) (xy 36.83 57.15) @@ -4138,6 +3987,16 @@ ) (uuid "67fbd166-05aa-4805-b116-96c0df4b914d") ) + (wire + (pts + (xy 254 114.3) (xy 254 116.84) + ) + (stroke + (width 0) + (type default) + ) + (uuid "681017d5-c08f-4635-b4f9-f8fbbe093041") + ) (wire (pts (xy 266.7 138.43) (xy 266.7 137.16) @@ -4160,7 +4019,7 @@ ) (wire (pts - (xy 175.26 91.44) (xy 175.26 124.46) + (xy 175.26 91.44) (xy 175.26 127) ) (stroke (width 0) @@ -4170,17 +4029,7 @@ ) (wire (pts - (xy 215.9 144.78) (xy 196.85 144.78) - ) - (stroke - (width 0) - (type default) - ) - (uuid "6fc85fc5-1cf7-4be2-816e-ce027595ec3b") - ) - (wire - (pts - (xy 181.61 134.62) (xy 184.15 134.62) + (xy 181.61 134.62) (xy 186.69 134.62) ) (stroke (width 0) @@ -4218,26 +4067,6 @@ ) (uuid "718eaa15-5837-4e6b-af12-efb507a1a86e") ) - (wire - (pts - (xy 133.35 144.78) (xy 170.18 144.78) - ) - (stroke - (width 0) - (type default) - ) - (uuid "728a828d-50ac-4e21-bd4c-b3a078d0be19") - ) - (wire - (pts - (xy 251.46 124.46) (xy 251.46 119.38) - ) - (stroke - (width 0) - (type default) - ) - (uuid "72e1ad6e-c94e-485a-ad93-4e5cd259b5c6") - ) (wire (pts (xy 102.87 60.96) (xy 91.44 60.96) @@ -4258,26 +4087,6 @@ ) (uuid "74f048a3-aa6e-46a5-b428-6dfa42c2c5a8") ) - (wire - (pts - (xy 181.61 132.08) (xy 181.61 120.65) - ) - (stroke - (width 0) - (type default) - ) - (uuid "77017c33-0602-4bb3-a5c6-c85f8b70d315") - ) - (wire - (pts - (xy 254 87.63) (xy 254 82.55) - ) - (stroke - (width 0) - (type default) - ) - (uuid "77cc6cad-4088-46a0-8910-c4a1cfdee625") - ) (wire (pts (xy 48.26 69.85) (xy 48.26 67.31) @@ -4300,7 +4109,7 @@ ) (wire (pts - (xy 170.18 144.78) (xy 181.61 144.78) + (xy 133.35 144.78) (xy 181.61 144.78) ) (stroke (width 0) @@ -4328,16 +4137,6 @@ ) (uuid "8094d635-3956-46e0-b967-217b094afd89") ) - (wire - (pts - (xy 251.46 80.01) (xy 251.46 85.09) - ) - (stroke - (width 0) - (type default) - ) - (uuid "83b1d694-48b6-4683-906f-7a789ef8ecde") - ) (wire (pts (xy 130.81 53.34) (xy 130.81 50.8) @@ -4348,16 +4147,6 @@ ) (uuid "88319bc5-bf0d-4b8f-801b-ac638b0f75f0") ) - (wire - (pts - (xy 177.8 88.9) (xy 177.8 127) - ) - (stroke - (width 0) - (type default) - ) - (uuid "8982efa2-995e-4e60-9da0-bbfbcd3abea5") - ) (wire (pts (xy 91.44 46.99) (xy 91.44 48.26) @@ -4398,6 +4187,16 @@ ) (uuid "8b154531-bc02-4a13-9b70-00cd8055bf0d") ) + (wire + (pts + (xy 256.54 85.09) (xy 254 85.09) + ) + (stroke + (width 0) + (type default) + ) + (uuid "8c5c7bcf-7b94-4f29-80c7-d29f33948a62") + ) (wire (pts (xy 138.43 53.34) (xy 138.43 50.8) @@ -4408,16 +4207,6 @@ ) (uuid "8ca851ff-35eb-4dc0-ab6b-bea3a8312d74") ) - (wire - (pts - (xy 254 121.92) (xy 256.54 121.92) - ) - (stroke - (width 0) - (type default) - ) - (uuid "8ce0f501-5401-469f-91cf-3a675a20bd37") - ) (wire (pts (xy 71.12 73.66) (xy 71.12 69.85) @@ -4438,26 +4227,6 @@ ) (uuid "930d4bd1-2a7c-482a-8691-97c4621d0792") ) - (wire - (pts - (xy 196.85 115.57) (xy 196.85 119.38) - ) - (stroke - (width 0) - (type default) - ) - (uuid "942399a7-090e-4a4f-8fc0-8f55ec61cb98") - ) - (wire - (pts - (xy 254 87.63) (xy 256.54 87.63) - ) - (stroke - (width 0) - (type default) - ) - (uuid "94e96b72-4f79-49c3-afea-cda7b2b5c86c") - ) (wire (pts (xy 185.42 83.82) (xy 185.42 88.9) @@ -4470,7 +4239,7 @@ ) (wire (pts - (xy 251.46 124.46) (xy 251.46 138.43) + (xy 251.46 124.46) (xy 251.46 127) ) (stroke (width 0) @@ -4478,26 +4247,6 @@ ) (uuid "9725fd02-3a2c-4573-b04a-e4fe56b39a57") ) - (wire - (pts - (xy 209.55 127) (xy 212.09 127) - ) - (stroke - (width 0) - (type default) - ) - (uuid "984638c3-befc-4ffb-9c9a-559e2aeccb42") - ) - (wire - (pts - (xy 209.55 132.08) (xy 248.92 132.08) - ) - (stroke - (width 0) - (type default) - ) - (uuid "992afab9-cf8b-43ef-abe4-d94d65d512a5") - ) (wire (pts (xy 181.61 144.78) (xy 196.85 144.78) @@ -4508,16 +4257,6 @@ ) (uuid "999a105a-a70b-47df-bd7e-dd9f2a2ee330") ) - (wire - (pts - (xy 256.54 119.38) (xy 251.46 119.38) - ) - (stroke - (width 0) - (type default) - ) - (uuid "9d48a7b7-97dc-4aa3-b7af-2e79a5f8aa9f") - ) (wire (pts (xy 113.03 121.92) (xy 115.57 121.92) @@ -4548,6 +4287,16 @@ ) (uuid "a1804555-1a92-4fbc-80dc-5648848f3011") ) + (wire + (pts + (xy 196.85 111.76) (xy 196.85 121.92) + ) + (stroke + (width 0) + (type default) + ) + (uuid "a1bcc7a1-6aac-4d5f-9c68-5e91708e280f") + ) (wire (pts (xy 38.1 69.85) (xy 36.83 69.85) @@ -4578,26 +4327,6 @@ ) (uuid "a80cd283-c3d6-4ac9-9561-9ffcc9b1850c") ) - (wire - (pts - (xy 251.46 85.09) (xy 256.54 85.09) - ) - (stroke - (width 0) - (type default) - ) - (uuid "a8b3f147-a62c-4910-97fd-dbb80c4bfbd0") - ) - (wire - (pts - (xy 175.26 124.46) (xy 184.15 124.46) - ) - (stroke - (width 0) - (type default) - ) - (uuid "a8ef18c4-f69d-4dc9-ac9b-22c0bc980f7e") - ) (wire (pts (xy 246.38 129.54) (xy 246.38 95.25) @@ -4608,16 +4337,6 @@ ) (uuid "a91ecc47-e1dc-4ed6-a6d6-a69f51bc5d10") ) - (wire - (pts - (xy 254 116.84) (xy 254 121.92) - ) - (stroke - (width 0) - (type default) - ) - (uuid "a924a1ff-ed84-4dcd-9054-b00c11f2bddb") - ) (wire (pts (xy 187.96 86.36) (xy 189.23 86.36) @@ -4630,13 +4349,13 @@ ) (wire (pts - (xy 251.46 114.3) (xy 251.46 90.17) + (xy 254 85.09) (xy 254 114.3) ) (stroke (width 0) (type default) ) - (uuid "b178c2e4-0247-4718-a943-ed6bf030315a") + (uuid "b126ef4a-8850-41ad-be56-46890e673a33") ) (wire (pts @@ -4650,7 +4369,17 @@ ) (wire (pts - (xy 254 77.47) (xy 254 82.55) + (xy 256.54 87.63) (xy 251.46 87.63) + ) + (stroke + (width 0) + (type default) + ) + (uuid "b430b8b4-5043-45c5-b81f-bcb285930bb3") + ) + (wire + (pts + (xy 254 77.47) (xy 254 80.01) ) (stroke (width 0) @@ -4668,6 +4397,16 @@ ) (uuid "b4f8aff7-7d71-493f-b1e3-28c513473c2a") ) + (wire + (pts + (xy 251.46 92.71) (xy 256.54 92.71) + ) + (stroke + (width 0) + (type default) + ) + (uuid "b607df17-a925-4179-8db9-b6537b3ac1f7") + ) (wire (pts (xy 82.55 87.63) (xy 82.55 95.25) @@ -4728,16 +4467,6 @@ ) (uuid "bcd83d3c-565a-4019-aa99-4f98a217e998") ) - (wire - (pts - (xy 251.46 90.17) (xy 251.46 85.09) - ) - (stroke - (width 0) - (type default) - ) - (uuid "bd55dd22-e530-443b-9098-ba9106e4100a") - ) (wire (pts (xy 166.37 35.56) (xy 166.37 33.02) @@ -4748,6 +4477,16 @@ ) (uuid "bd8e6286-3f4a-4e33-8ea7-439e05fad560") ) + (wire + (pts + (xy 177.8 88.9) (xy 177.8 129.54) + ) + (stroke + (width 0) + (type default) + ) + (uuid "be2de2d9-d2b1-4c1b-9267-f49cb7bea18b") + ) (wire (pts (xy 133.35 53.34) (xy 133.35 50.8) @@ -4758,16 +4497,6 @@ ) (uuid "bf3504de-215b-435a-975d-682ff8c6d5a6") ) - (wire - (pts - (xy 256.54 80.01) (xy 251.46 80.01) - ) - (stroke - (width 0) - (type default) - ) - (uuid "bffaf06c-e4fa-46f9-bea4-88758790ad55") - ) (wire (pts (xy 151.13 83.82) (xy 185.42 83.82) @@ -4778,6 +4507,16 @@ ) (uuid "c1d7b845-7225-48ce-a1a3-7f0183feb32b") ) + (wire + (pts + (xy 251.46 87.63) (xy 251.46 90.17) + ) + (stroke + (width 0) + (type default) + ) + (uuid "c1db6903-0cc2-4e18-a8b3-01384fd09f50") + ) (wire (pts (xy 113.03 124.46) (xy 115.57 124.46) @@ -4810,13 +4549,13 @@ ) (wire (pts - (xy 215.9 118.11) (xy 215.9 115.57) + (xy 251.46 127) (xy 251.46 138.43) ) (stroke (width 0) (type default) ) - (uuid "c58038c0-78e1-4e5d-8de7-734e1d3a9b86") + (uuid "c3d36420-d618-46da-a6b7-1b3e079dc2cf") ) (wire (pts @@ -4840,13 +4579,13 @@ ) (wire (pts - (xy 170.18 132.08) (xy 181.61 132.08) + (xy 251.46 127) (xy 256.54 127) ) (stroke (width 0) (type default) ) - (uuid "cbc29a29-24ed-4cd4-93c7-db20f56d248d") + (uuid "cb4c4417-4adf-4e24-a701-a3cbfd42d753") ) (wire (pts @@ -4868,16 +4607,6 @@ ) (uuid "cdefebce-387c-4b2f-9b6d-5ef12cf976fb") ) - (wire - (pts - (xy 215.9 115.57) (xy 196.85 115.57) - ) - (stroke - (width 0) - (type default) - ) - (uuid "cf09b86b-bf81-4020-a4b6-c2f993e76b41") - ) (wire (pts (xy 45.72 69.85) (xy 48.26 69.85) @@ -4888,16 +4617,6 @@ ) (uuid "d0be6f8c-3036-49da-91c2-770c39d1ddd9") ) - (wire - (pts - (xy 184.15 132.08) (xy 181.61 132.08) - ) - (stroke - (width 0) - (type default) - ) - (uuid "d0cc9827-d199-4c47-8eff-287bb68b1cb0") - ) (wire (pts (xy 135.89 50.8) (xy 133.35 50.8) @@ -4918,6 +4637,16 @@ ) (uuid "d38f9ed5-b177-475b-88bb-dd0756137a6a") ) + (wire + (pts + (xy 251.46 92.71) (xy 251.46 121.92) + ) + (stroke + (width 0) + (type default) + ) + (uuid "d63a096a-89eb-4a04-beab-220143ff633d") + ) (wire (pts (xy 248.92 97.79) (xy 256.54 97.79) @@ -4928,36 +4657,6 @@ ) (uuid "d6e821f1-79b7-4c01-aaa2-f0702e9f6151") ) - (wire - (pts - (xy 177.8 127) (xy 184.15 127) - ) - (stroke - (width 0) - (type default) - ) - (uuid "d6f3c763-aa24-4855-9210-4d3e1784fdfb") - ) - (wire - (pts - (xy 256.54 114.3) (xy 251.46 114.3) - ) - (stroke - (width 0) - (type default) - ) - (uuid "dab91b86-8c32-4467-b25b-c3d3469e91ae") - ) - (wire - (pts - (xy 256.54 127) (xy 254 127) - ) - (stroke - (width 0) - (type default) - ) - (uuid "dac06e01-bc5c-4c3d-8935-f6bdaaa37fb5") - ) (wire (pts (xy 114.3 48.26) (xy 102.87 48.26) @@ -4990,13 +4689,13 @@ ) (wire (pts - (xy 212.09 127) (xy 212.09 129.54) + (xy 186.69 129.54) (xy 177.8 129.54) ) (stroke (width 0) (type default) ) - (uuid "e1ae87aa-c0ba-457f-9a04-cb3bd3417797") + (uuid "e306d7ba-c60c-4576-a567-f57f29c7333e") ) (wire (pts @@ -5018,6 +4717,16 @@ ) (uuid "e788fa01-b6da-4d67-84fa-f2b01dcf8adb") ) + (wire + (pts + (xy 254 80.01) (xy 254 82.55) + ) + (stroke + (width 0) + (type default) + ) + (uuid "e7d1dbbe-3cf8-430f-9116-36d25f68934c") + ) (wire (pts (xy 115.57 101.6) (xy 86.36 101.6) @@ -5058,6 +4767,16 @@ ) (uuid "eee63fe1-2640-40f7-b72c-be33c097b79b") ) + (wire + (pts + (xy 256.54 114.3) (xy 254 114.3) + ) + (stroke + (width 0) + (type default) + ) + (uuid "ef4485da-3744-4c21-8246-c58b8d772506") + ) (wire (pts (xy 102.87 48.26) (xy 102.87 50.8) @@ -5088,16 +4807,6 @@ ) (uuid "f2c0d18a-e75c-43a7-a89f-6010a201d4f0") ) - (wire - (pts - (xy 251.46 119.38) (xy 251.46 114.3) - ) - (stroke - (width 0) - (type default) - ) - (uuid "f372c17a-6f21-43c7-80f8-010c081c9b81") - ) (wire (pts (xy 256.54 90.17) (xy 251.46 90.17) @@ -5128,6 +4837,26 @@ ) (uuid "f930f6f6-fe6a-4af7-8985-f7ce9c7e013a") ) + (wire + (pts + (xy 251.46 121.92) (xy 251.46 124.46) + ) + (stroke + (width 0) + (type default) + ) + (uuid "f9d6f8e5-718a-4160-a479-247debf8d680") + ) + (wire + (pts + (xy 254 80.01) (xy 256.54 80.01) + ) + (stroke + (width 0) + (type default) + ) + (uuid "fa756c89-b6e1-4333-aff4-6531d1f12d99") + ) (wire (pts (xy 80.01 113.03) (xy 82.55 113.03) @@ -5863,7 +5592,7 @@ ) (symbol (lib_id "power:VDD") - (at 181.61 120.65 0) + (at 196.85 111.76 0) (unit 1) (exclude_from_sim no) (in_bom yes) @@ -5872,7 +5601,7 @@ (fields_autoplaced yes) (uuid "5c42b1af-c645-4cdd-9846-b4c48326bc8c") (property "Reference" "#PWR0207" - (at 181.61 124.46 0) + (at 196.85 115.57 0) (effects (font (size 1.27 1.27) @@ -5881,7 +5610,7 @@ ) ) (property "Value" "3V3" - (at 181.61 115.57 0) + (at 196.85 106.68 0) (effects (font (size 1.27 1.27) @@ -5889,7 +5618,7 @@ ) ) (property "Footprint" "" - (at 181.61 120.65 0) + (at 196.85 111.76 0) (effects (font (size 1.27 1.27) @@ -5898,7 +5627,7 @@ ) ) (property "Datasheet" "" - (at 181.61 120.65 0) + (at 196.85 111.76 0) (effects (font (size 1.27 1.27) @@ -5907,7 +5636,7 @@ ) ) (property "Description" "Power symbol creates a global label with name \"VDD\"" - (at 181.61 120.65 0) + (at 196.85 111.76 0) (effects (font (size 1.27 1.27) @@ -6594,6 +6323,94 @@ ) ) ) + (symbol + (lib_id "Interface_CAN_LIN:SN65HVD230") + (at 196.85 129.54 0) + (unit 1) + (exclude_from_sim no) + (in_bom yes) + (on_board yes) + (dnp no) + (fields_autoplaced yes) + (uuid "96c1e221-1f32-4b6a-97b1-9166e2fa03db") + (property "Reference" "U203" + (at 198.9933 119.38 0) + (effects + (font + (size 1.27 1.27) + ) + (justify left) + ) + ) + (property "Value" "SN65HVD230" + (at 198.9933 121.92 0) + (effects + (font + (size 1.27 1.27) + ) + (justify left) + ) + ) + (property "Footprint" "Package_SO:SOIC-8_3.9x4.9mm_P1.27mm" + (at 196.85 142.24 0) + (effects + (font + (size 1.27 1.27) + ) + (hide yes) + ) + ) + (property "Datasheet" "http://www.ti.com/lit/ds/symlink/sn65hvd230.pdf" + (at 194.31 119.38 0) + (effects + (font + (size 1.27 1.27) + ) + (hide yes) + ) + ) + (property "Description" "CAN Bus Transceivers, 3.3V, 1Mbps, Low-Power capabilities, SOIC-8" + (at 196.85 129.54 0) + (effects + (font + (size 1.27 1.27) + ) + (hide yes) + ) + ) + (pin "2" + (uuid "46e0088e-afe5-4f4b-bd91-f658e66dc0e5") + ) + (pin "6" + (uuid "260060e7-294a-4bb6-9fbc-fcc0e8dd9f95") + ) + (pin "5" + (uuid "293b4972-1e3e-49d1-90ab-73e9d9a0655e") + ) + (pin "1" + (uuid "ede4b242-4529-4d07-8839-22ac861f51ac") + ) + (pin "7" + (uuid "d9316cd5-d322-4af5-8fb8-072822471ef8") + ) + (pin "4" + (uuid "72abf7ea-bd15-405e-bc37-2541e8347a60") + ) + (pin "3" + (uuid "b293fe27-d209-4ee7-9bca-1cae67946f82") + ) + (pin "8" + (uuid "1e8976aa-e715-4f71-b016-878c113ba453") + ) + (instances + (project "" + (path "/161a9599-9ba4-4610-99d7-67cfc29e63e3/5c46d7fe-34fa-4f56-9c85-0d1525266e94" + (reference "U203") + (unit 1) + ) + ) + ) + ) (symbol (lib_id "power:VDD") (at 187.96 82.55 0) @@ -6660,72 +6477,6 @@ ) ) ) - (symbol - (lib_id "power:+5C") - (at 196.85 111.76 0) - (unit 1) - (exclude_from_sim no) - (in_bom yes) - (on_board yes) - (dnp no) - (fields_autoplaced yes) - (uuid "a30a297b-9cc9-4a0c-a7f1-aab062f12ec7") - (property "Reference" "#PWR0209" - (at 196.85 115.57 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Value" "5V0" - (at 196.85 106.68 0) - (effects - (font - (size 1.27 1.27) - ) - ) - ) - (property "Footprint" "" - (at 196.85 111.76 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Datasheet" "" - (at 196.85 111.76 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Description" "Power symbol creates a global label with name \"+5C\"" - (at 196.85 111.76 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (pin "1" - (uuid "1a9af7cc-5683-4f79-a954-11be9055ae7b") - ) - (instances - (project "Valve Node" - (path "/161a9599-9ba4-4610-99d7-67cfc29e63e3/5c46d7fe-34fa-4f56-9c85-0d1525266e94" - (reference "#PWR0209") - (unit 1) - ) - ) - ) - ) (symbol (lib_id "power:GND") (at 187.96 100.33 0) @@ -6866,85 +6617,6 @@ ) ) ) - (symbol - (lib_id "Device:C") - (at 215.9 121.92 0) - (unit 1) - (exclude_from_sim no) - (in_bom yes) - (on_board yes) - (dnp no) - (fields_autoplaced yes) - (uuid "ad3a5b6b-340e-40a7-bce4-8141e5f3c6be") - (property "Reference" "C211" - (at 219.71 120.6499 0) - (effects - (font - (size 1.27 1.27) - ) - (justify left) - ) - ) - (property "Value" "100nF" - (at 219.71 123.1899 0) - (effects - (font - (size 1.27 1.27) - ) - (justify left) - ) - ) - (property "Footprint" "Capacitor_SMD:C_0402_1005Metric" - (at 216.8652 125.73 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Datasheet" "~" - (at 215.9 121.92 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Description" "Unpolarized capacitor" - (at 215.9 121.92 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "LCSC" "C1525" - (at 215.9 121.92 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (pin "1" - (uuid "7760e158-2b9d-417d-bc2a-52c106a4b282") - ) - (pin "2" - (uuid "8497ac40-7530-4179-b10c-63164d4f85ae") - ) - (instances - (project "Valve Node" - (path "/161a9599-9ba4-4610-99d7-67cfc29e63e3/5c46d7fe-34fa-4f56-9c85-0d1525266e94" - (reference "C211") - (unit 1) - ) - ) - ) - ) (symbol (lib_id "Device:R") (at 167.64 66.04 270) @@ -7101,84 +6773,6 @@ ) ) ) - (symbol - (lib_id "Device:C") - (at 170.18 138.43 0) - (unit 1) - (exclude_from_sim no) - (in_bom yes) - (on_board yes) - (dnp no) - (uuid "b951972a-e60b-40a5-b0ac-20a8a2d0a69d") - (property "Reference" "C208" - (at 173.99 137.1599 0) - (effects - (font - (size 1.27 1.27) - ) - (justify left) - ) - ) - (property "Value" "100nF" - (at 173.99 143.5099 0) - (effects - (font - (size 1.27 1.27) - ) - (justify left) - ) - ) - (property "Footprint" "Capacitor_SMD:C_0402_1005Metric" - (at 171.1452 142.24 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Datasheet" "~" - (at 170.18 138.43 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Description" "Unpolarized capacitor" - (at 170.18 138.43 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "LCSC" "C1525" - (at 170.18 138.43 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (pin "1" - (uuid "8c5c16ce-97f0-4c97-b869-6859dbabfd8c") - ) - (pin "2" - (uuid "6934328e-192a-485d-b0fa-46efb86c22e2") - ) - (instances - (project "Valve Node" - (path "/161a9599-9ba4-4610-99d7-67cfc29e63e3/5c46d7fe-34fa-4f56-9c85-0d1525266e94" - (reference "C208") - (unit 1) - ) - ) - ) - ) (symbol (lib_id "power:GND") (at 194.31 48.26 0) @@ -7832,103 +7426,6 @@ ) ) ) - (symbol - (lib_id "Interface_CAN_LIN:TJA1042T-3") - (at 196.85 129.54 0) - (unit 1) - (exclude_from_sim no) - (in_bom yes) - (on_board yes) - (dnp no) - (uuid "f4fe0140-b1e8-4854-a46e-c8601fd5154e") - (property "Reference" "U202" - (at 197.866 120.142 0) - (effects - (font - (size 1.27 1.27) - ) - (justify left) - ) - ) - (property "Value" "TJA1042T-3" - (at 198.12 142.748 0) - (effects - (font - (size 1.27 1.27) - ) - (justify left) - ) - ) - (property "Footprint" "Package_SO:SOIC-8_3.9x4.9mm_P1.27mm" - (at 196.85 142.24 0) - (effects - (font - (size 1.27 1.27) - (italic yes) - ) - (hide yes) - ) - ) - (property "Datasheet" "http://www.nxp.com/docs/en/data-sheet/TJA1042.pdf" - (at 196.85 129.54 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "Description" "High-Speed CAN Transceiver, separate VIO, standby mode, SOIC-8" - (at 196.85 129.54 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (property "LCSC" "C132227" - (at 196.85 129.54 0) - (effects - (font - (size 1.27 1.27) - ) - (hide yes) - ) - ) - (pin "7" - (uuid "f8ca2462-5130-43e9-823e-aa07ff43b60d") - ) - (pin "4" - (uuid "7cb9452f-7feb-4412-bd85-e8a80e09837c") - ) - (pin "6" - (uuid "24f1b9b6-fdc6-4fbb-9467-75ea535a0f24") - ) - (pin "1" - (uuid "e0038046-6f49-4a46-bf6f-525c6fc41dab") - ) - (pin "3" - (uuid "fb442efe-c494-4f81-81af-ece65acaa38f") - ) - (pin "8" - (uuid "842b1e86-95c4-4c28-a05b-1e07d6ebc1bb") - ) - (pin "5" - (uuid "9d52e6bf-7f32-45a9-bd19-ba0f5d4a9a15") - ) - (pin "2" - (uuid "ca3d785b-ddc0-4178-aa79-815e23f56edb") - ) - (instances - (project "Valve Node" - (path "/161a9599-9ba4-4610-99d7-67cfc29e63e3/5c46d7fe-34fa-4f56-9c85-0d1525266e94" - (reference "U202") - (unit 1) - ) - ) - ) - ) (symbol (lib_id "Device:C") (at 194.31 39.37 0) diff --git a/software/.vscode/extensions.json b/software/.vscode/extensions.json new file mode 100644 index 0000000..2b32164 --- /dev/null +++ b/software/.vscode/extensions.json @@ -0,0 +1,10 @@ +{ + "recommendations": [ + "ms-vscode.cpptools-extension-pack", + "ms-python.python", + "ms-vscode.vscode-embedded-tools", + "ms-vscode.vscode-serial-monitor", + "marus25.cortex-debug", + "donjayamanne.python-environment-manager" + ] +} \ No newline at end of file diff --git a/software/.vscode/launch.json b/software/.vscode/launch.json new file mode 100644 index 0000000..a386ed2 --- /dev/null +++ b/software/.vscode/launch.json @@ -0,0 +1,28 @@ +{ + "version": "0.2.0", + "configurations": [ + { + "name": "Launch", + "device": "STM32F103RB", + "cwd": "${workspaceFolder}", + "executable": "build/zephyr/zephyr.elf", + "request": "launch", + "type": "cortex-debug", + //"runToEntryPoint": "main", + "servertype": "jlink", + "gdbPath": "${userHome}/zephyr-sdk-0.17.1/arm-zephyr-eabi/bin/arm-zephyr-eabi-gdb", + "preLaunchTask": "West Build" + }, + { + "name": "Attach", + "device": "nRF52840_xxAA", + "cwd": "${workspaceFolder}", + "executable": "build/zephyr/zephyr.elf", + "request": "attach", + "type": "cortex-debug", + // "runToEntryPoint": "main", + "servertype": "jlink", + "gdbPath": "${userHome}/zephyr-sdk-0.17.1/arm-zephyr-eabi/bin/arm-zephyr-eabi-gdb" + }, + ] +} \ No newline at end of file diff --git a/software/.vscode/settings.json b/software/.vscode/settings.json index 15b66f3..4f59a24 100644 --- a/software/.vscode/settings.json +++ b/software/.vscode/settings.json @@ -1,15 +1,12 @@ { - "nrf-connect.applications": [ - "${workspaceFolder}\\modbus_test" - ], - "files.associations": { - "log.h": "c", - "modbus.h": "c", - "array": "c", - "string": "c", - "string_view": "c", - "canbus.h": "c", - "kernel.h": "c", - "settings.h": "c" - } + // Hush CMake + "cmake.configureOnOpen": false, + + // IntelliSense + "C_Cpp.default.compilerPath": "${userHome}/zephyr-sdk-0.17.1/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc.exe", + "C_Cpp.default.compileCommands": "${workspaceFolder}/build/compile_commands.json", + + // File Associations + "files.associations": { + } } \ No newline at end of file diff --git a/software/.vscode/tasks.json b/software/.vscode/tasks.json new file mode 100644 index 0000000..89ed6b2 --- /dev/null +++ b/software/.vscode/tasks.json @@ -0,0 +1,96 @@ +{ + "version": "2.0.0", + "tasks": [ + { + "label": "West Build", + "type": "shell", + "group": { + "kind": "build", + "isDefault": true + }, + "linux": { + "command": "${userHome}/zephyrproject/.venv/bin/west" + }, + "windows": { + "command": "${userHome}/zephyrproject/.venv/Scripts/west.exe" + }, + "osx": { + "command": "${userHome}/zephyrproject/.venv/bin/west" + }, + "args": [ + "build", + "-p", + "auto", + "-b", + "valve_node" + ], + "problemMatcher": [ + "$gcc" + ] + }, + { + "label": "West Configurable Build", + "type": "shell", + "group": { + "kind": "build", + }, + "linux": { + "command": "${userHome}/zephyrproject/.venv/bin/west" + }, + "windows": { + "command": "${userHome}/zephyrproject/.venv/Scripts/west.exe" + }, + "osx": { + "command": "${userHome}/zephyrproject/.venv/bin/west" + }, + "args": [ + "build", + "-p", + "${input:pristine}", + "-b", + "${input:board}" + ], + "problemMatcher": [ + "$gcc" + ] + }, + { + "label": "West Flash", + "type": "shell", + "linux": { + "command": "${userHome}/zephyrproject/.venv/bin/west" + }, + "windows": { + "command": "${userHome}/zephyrproject/.venv/Scripts/west.exe" + }, + "osx": { + "command": "${userHome}/zephyrproject/.venv/bin/west" + }, + "args": [ + "flash" + ], + "problemMatcher": [ + "$gcc" + ] + } + ], + "inputs": [ + { + "id": "board", + "type": "promptString", + "default": "valve-node", + "description": "See https://docs.zephyrproject.org/latest/boards/index.html" + }, + { + "id": "pristine", + "type": "pickString", + "description": "Choose when to run a pristine build", + "default": "auto", + "options": [ + "auto", + "always", + "never" + ] + } + ] +} \ No newline at end of file diff --git a/software/CMakeLists.txt b/software/CMakeLists.txt new file mode 100644 index 0000000..5472451 --- /dev/null +++ b/software/CMakeLists.txt @@ -0,0 +1,25 @@ +# SPDX-License-Identifier: Apache-2.0 + +cmake_minimum_required(VERSION 3.20.0) + +list(APPEND BOARD_ROOT ${CMAKE_CURRENT_SOURCE_DIR}) + +find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE}) +project(valve_node) + +target_sources(app PRIVATE src/main.c) +target_sources(app PRIVATE lib/canbus.c) + +# source files for modbus waterlevel sensor +zephyr_library_sources_ifdef(CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR + lib/waterlevel_sensor.c +) + +#source files for valve +zephyr_library_sources_ifdef(CONFIG_HAS_VALVE + lib/valve.c +) + +zephyr_include_directories( + lib +) diff --git a/software/boards/iten/valve_node/Kconfig.valve_node b/software/boards/iten/valve_node/Kconfig.valve_node index a52f9b8..1525006 100644 --- a/software/boards/iten/valve_node/Kconfig.valve_node +++ b/software/boards/iten/valve_node/Kconfig.valve_node @@ -1,7 +1,7 @@ config BOARD_VALVE_NODE select SOC_STM32F103XB -mainmenu "Controller Area Network sample application" +mainmenu "APP CAN Settings" config LOOPBACK_MODE bool "Loopback LOOPBACK_MODE" default n @@ -9,10 +9,50 @@ config LOOPBACK_MODE Set the can controller to loopback mode. This allows testing without a second board. +mainmenu "APP Logging Settings" config LOG_CAN_LEVEL int "Log level for CAN" default 3 range 0 7 help Set the log level for CAN messages. - 0 = None, 1 = Error, 2 = Warning, 3 = Info, 4 = Debug, 5 = Trace, 6 = Debug2, 7 = Debug3 \ No newline at end of file + 0 = None, 1 = Error, 2 = Warning, 3 = Info, 4 = Debug, 5 = Trace, 6 = Debug2, 7 = Debug3 + +config LOG_SETTINGS_LEVEL + int "Log level for settings" + default 3 + range 0 7 + help + Set the log level for CAN messages. + 0 = None, 1 = Error, 2 = Warning, 3 = Info, 4 = Debug, 5 = Trace, 6 = Debug2, 7 = Debug3 + +config LOG_WATERLEVELSENSOR_LEVEL + int "Log level for waterlevel sensor" + default 3 + range 0 7 + help + Set the log level for CAN messages. + 0 = None, 1 = Error, 2 = Warning, 3 = Info, 4 = Debug, 5 = Trace, 6 = Debug2, 7 = Debug3 + +config LOG_VALVE_LEVEL + int "Log level for valve control" + default 3 + range 0 7 + help + Set the log level for valve control messages. + 0 = None, 1 = Error, 2 = Warning, 3 = Info, 4 = Debug, 5 = Trace, 6 = Debug2, 7 = Debug3 + +mainmenu "Irrigation controller node configuration" +config HAS_MODBUS_WATERLEVEL_SENSOR + bool "Has modbus water level sensor" + default n + help + Enable modbus water level sensor support. + This allows reading the water level from a modbus device. + +config HAS_VALVE + bool "Has valve control" + default n + help + Enable valve control support. + This allows controlling valves via CAN messages. \ No newline at end of file diff --git a/software/boards/iten/valve_node/board.cmake b/software/boards/iten/valve_node/board.cmake index 9b122cd..ebd92d6 100644 --- a/software/boards/iten/valve_node/board.cmake +++ b/software/boards/iten/valve_node/board.cmake @@ -8,3 +8,4 @@ board_runner_args(jlink "--device=STM32F103RB" "--speed=4000") include(${ZEPHYR_BASE}/boards/common/stm32cubeprogrammer.board.cmake) include(${ZEPHYR_BASE}/boards/common/openocd-stm32.board.cmake) include(${ZEPHYR_BASE}/boards/common/jlink.board.cmake) +include(${ZEPHYR_BASE}/boards/common/blackmagicprobe.board.cmake) diff --git a/software/boards/iten/valve_node/valve_node.dts b/software/boards/iten/valve_node/valve_node.dts index bd39f4a..f1f38ab 100644 --- a/software/boards/iten/valve_node/valve_node.dts +++ b/software/boards/iten/valve_node/valve_node.dts @@ -13,12 +13,18 @@ model = "Iten engineering Valve Node"; compatible = "iten,valve-node", "st,stm32f103rb"; + can_loopback0: can_loopback0 { + status = "disabled"; + compatible = "zephyr,can-loopback"; + }; + chosen { zephyr,console = &usart1; zephyr,shell-uart = &usart1; zephyr,sram = &sram0; zephyr,flash = &flash0; zephyr,canbus = &can1; + //zephyr,canbus = &can_loopback0; }; leds: leds { @@ -73,6 +79,10 @@ gpios = <&gpiob 13 0>; label = "Motor Open"; }; + fake: fake { + gpios = <&gpiob 11 GPIO_PULL_UP>; + label = "CAN RX pullup"; + }; }; }; @@ -174,7 +184,7 @@ pinctrl-0 = <&can_rx_pa11 &can_tx_pa12>; pinctrl-names = "default"; status= "okay"; - bus-speed = < 125000 >; + bus-speed = <125000>; }; &exti { diff --git a/software/boards/iten/valve_node/valve_node_defconfig b/software/boards/iten/valve_node/valve_node_defconfig index 8eb026e..5e3d242 100644 --- a/software/boards/iten/valve_node/valve_node_defconfig +++ b/software/boards/iten/valve_node/valve_node_defconfig @@ -18,6 +18,7 @@ CONFIG_MODBUS_ROLE_CLIENT=y CONFIG_CAN=y CONFIG_CAN_INIT_PRIORITY=80 #CONFIG_CAN_MAX_FILTER=5 +CONFIG_CAN_ACCEPT_RTR=y # settings CONFIG_FLASH=y diff --git a/software/lib/canbus.c b/software/lib/canbus.c index bac6b69..e2f78ab 100644 --- a/software/lib/canbus.c +++ b/software/lib/canbus.c @@ -1,81 +1,152 @@ #include "canbus.h" #include #include -#include "settings.h" +#include +#include +#include + +#ifdef CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR +#include "waterlevel_sensor.h" +#endif // CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR + +#ifdef CONFIG_HAS_VALVE +#include "valve.h" +#endif // CONFIG_HAS_VALVE const struct device *const can_dev = DEVICE_DT_GET(DT_CHOSEN(zephyr_canbus)); -K_THREAD_STACK_DEFINE(rx_thread_stack, RX_THREAD_STACK_SIZE); - -static uint8_t node_id = 12; // Default node ID - LOG_MODULE_REGISTER(canbus, CONFIG_LOG_CAN_LEVEL); -static int canbus_set(const char *key, size_t len, settings_read_cb read_cb, void *cb_arg) +K_MSGQ_DEFINE(canbus_msgq, sizeof(struct can_frame), CANBUS_RX_MSGQ_SIZE, 4); +K_THREAD_STACK_DEFINE(canbus_rx_stack, CANBUS_RX_THREAD_STACK_SIZE); + +uint8_t node_id = 0; // Default node ID, can be set later +uint8_t can_msg_id = 0; + +k_tid_t canbus_rx_thread_id; +struct k_thread canbus_rx_thread_data; + +int canbus_rx_filter_id = -1; + +void canbus_rx_callback(const struct device *dev, struct can_frame *frame, void *user_data) { - const char *next; int rc; + ARG_UNUSED(dev); + ARG_UNUSED(user_data); - // Handle setting values for CAN bus configuration - LOG_DBG("Setting CAN bus configuration: key=%s, len=%zu", key, len); - if (settings_name_steq(key, "node_id", &next) && next != NULL) + if (frame->id >> 8 != node_id) // Check if the frame ID matches the node ID { - if (len != sizeof(node_id)) - { - LOG_ERR("Invalid length for node_id setting: %zu", len); - return -EINVAL; // Invalid argument - } - - rc = read_cb(cb_arg, &node_id, sizeof(node_id)); - if (rc < 0) - { - LOG_ERR("Failed to read node_id setting: %d", rc); - return rc; // Read error - } - LOG_DBG("Set CAN bus node ID to: %d", node_id); + LOG_DBG("Received CAN frame with ID %d, but it does not match node ID %d", frame->id >> 8, node_id); + return; // Ignore frames that do not match the node ID + } + + // Process the received CAN frame + rc = k_msgq_put(&canbus_msgq, frame, K_NO_WAIT); + if (rc != 0) + { + LOG_ERR("Failed to put CAN frame into message queue: %d", rc); } - return 0; // Return 0 on success } -struct settings_handler canbus_settings_handler = { - .name = "canbus", - .h_set = canbus_set, // No settings set handler -}; +void canbus_thread(void *arg1, void *arg2, void *arg3) +{ + ARG_UNUSED(arg1); + ARG_UNUSED(arg2); + ARG_UNUSED(arg3); + + LOG_INF("CAN bus thread started"); + + // Main loop for CAN bus operations + while (1) + { + int rc; + struct can_frame frame; + k_msgq_get(&canbus_msgq, &frame, K_FOREVER); // Wait for a message from the queue + LOG_DBG("Received CAN frame with ID: 0x%02x, DLC: %d, RTR: %d", + frame.id, frame.dlc, (uint8_t)(frame.flags & CAN_FRAME_RTR)); + LOG_HEXDUMP_DBG(frame.data, frame.dlc, "CAN frame data"); + uint8_t reg = frame.id & 0xFF; // Extract register from the frame ID + bool is_rtr = (frame.flags & CAN_FRAME_RTR) != 0; // Check if it's a remote transmission request + switch (reg) + { +#ifdef CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR + case CANBUS_REG_WATERLEVEL_LEVEL: + case CANBUS_REG_WATERLEVEL_ZERO_POINT: + case CANBUS_REG_WATERLEVEL_MAX_POINT: + waterlevel_command_t command; + command.cmd = is_rtr ? WATERLEVEL_CMD_GET : WATERLEVEL_CMD_SET; // Determine command type based on RTR + command.reg = reg; // Set the register ID + int16_t value = 0; // Initialize value to 0 + if (!is_rtr) // If it's not a remote request, extract the value from the frame data + { + if (frame.dlc < sizeof(command.data)) + { LOG_ERR("Received frame with insufficient data length: %d", frame.dlc); + continue; // Skip processing if data length is insufficient + } + value = sys_be16_to_cpu(*(uint16_t *)frame.data); // Convert data from big-endian to host byte order + command.data = value; // Set the data field + LOG_DBG("Setting command data to: %d", value); + } + extern struct k_msgq waterlevel_sensor_msgq; // Declare the water level sensor message queue + k_msgq_put(&waterlevel_sensor_msgq, &command, K_NO_WAIT); + break; +#endif // CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR +#ifdef CONFIG_HAS_VALVE + case CANBUS_REG_VALVE_STATUS: + case CANBUS_REG_VALVE_OPERATION: + if (is_rtr) + { + LOG_DBG("Received remote request for valve status or operation"); + if (reg == CANBUS_REG_VALVE_STATUS) + { + valve_send_status(); // Send the current valve status + } + else if (reg == CANBUS_REG_VALVE_OPERATION) + { + valve_send_operation(); // Send the current valve operation state + } else { + LOG_ERR("Unknown valve register: 0x%02x", reg); + continue; // Skip processing if the register is unknown + } + } + else + { + LOG_ERR("Received CAN frame with data for valve status or operation, but RTR is not set"); + continue; // Skip processing if RTR is not set for valve status or operation + } + break; + case CANBUS_REG_VALVE_COMMAND: + { + if (is_rtr) { + LOG_ERR("Received remote request for valve command, but this is not supported"); + continue; // Skip processing if RTR is set for valve command + } else { + // Extract the command from the frame data + if (frame.dlc < sizeof(uint8_t)) { + LOG_ERR("Received frame with insufficient data length for valve command: %d", frame.dlc); + continue; // Skip processing if data length is insufficient + } + uint8_t command = frame.data[0]; // Get the command from the first byte of data + LOG_DBG("Received valve command: 0x%02x", command); + rc = valve_cmd(command); // Send the command to the valve + if (rc < 0) { + LOG_ERR("Failed to send valve command: %d", rc); + continue; // Skip processing if sending the command failed + } + } + break; + } + default: + LOG_DBG("Received CAN frame with unknown register: 0x%02x", reg); + break; + } + #endif // CONFIG_HAS_VALVE + } +} int canbus_init(void) { - int rc; - settings_subsys_init(); - settings_register(&canbus_settings_handler); - settings_load(); - - rc = settings_get_val_len("canbus/node_id"); - if (rc < 0) - { - LOG_ERR("Failed to check CAN bus settings: %d", rc); - return rc; - } - - else if (rc == 0) - { - LOG_WRN("No CAN bus node id found in settings, using default default (%d)", node_id); - settings_save_one("canbus/node_id", &node_id, sizeof(node_id)); - if (rc < 0) - { - LOG_ERR("Failed to save default CAN bus node id: %d", rc); - return rc; - } - } - else - { - rc = settings_load_one("canbus/node_id", &node_id, sizeof(node_id)); - if (rc < 0) - { - LOG_ERR("Failed to load CAN bus node id from settings: %d", rc); - return rc; - } - LOG_DBG("Loaded CAN bus node id: %d", node_id); - } + int rc = 0; if (!device_is_ready(can_dev)) { @@ -91,5 +162,125 @@ int canbus_init(void) return rc; } #endif + + rc = can_start(can_dev); + if (rc != 0) + { + printf("Error starting CAN controller [%d]", rc); + return 0; + } + LOG_DBG("CAN device %s is ready", can_dev->name); + // Initialize the CAN RX thread + canbus_rx_thread_id = k_thread_create(&canbus_rx_thread_data, canbus_rx_stack, + K_THREAD_STACK_SIZEOF(canbus_rx_stack), canbus_thread, + NULL, NULL, NULL, + CANBUS_RX_THREAD_PRIORITY, 0, K_NO_WAIT); + k_thread_name_set(canbus_rx_thread_id, "canbus_rx"); + + const struct can_filter filter = { + .id = node_id << 8, // Standard ID with node ID in the first byte + .mask = 0x700, // Mask to match the first byte of the ID + .flags = 0, // No special flags + }; + canbus_rx_filter_id = can_add_rx_filter(can_dev, canbus_rx_callback, NULL, &filter); + LOG_DBG("CAN RX filter added for node ID %d", canbus_rx_filter_id); + return 0; +} + +void canbus_tx8_callback(const struct device *dev, int error, void *user_data) +{ + ARG_UNUSED(dev); + uint8_t frame_id = *(uint8_t *)user_data; // Retrieve the frame ID from user data + + if (error != 0) + { + LOG_ERR("CAN transmission error. Error code: %d, Frame ID: %d", error, frame_id); + } + else + { + LOG_DBG("CAN message with Frame ID %d sent successfully", frame_id); + } + free(user_data); // Free the allocated memory for frame ID +} + +int canbus_send8(uint16_t reg, uint8_t value) +{ + int rc = 0; + struct can_frame frame = { + .id = (node_id << 8) | reg, // Standard ID with node ID in the first byte + .dlc = sizeof(value), // Data Length Code (DLC) + }; + frame.data[0] = value; // Set the value in the first byte of the data + uint8_t *frame_id = malloc(sizeof(uint8_t)); // Allocate memory for frame ID + LOG_DBG("Preparing to send 8-bit value 0x%02x to register 0x%02x on node %d", value, reg, node_id); + if (frame_id == NULL) + { + LOG_ERR("Failed to allocate memory for frame ID"); + return -ENOMEM; // Not enough memory + } + *frame_id = can_msg_id++; // Increment message ID for uniqueness + LOG_DBG("Using frame ID: %d", *frame_id); + rc = can_send(can_dev, &frame, CANBUS_TX_TIMEOUT, canbus_tx8_callback, frame_id); + // Send the CAN frame with a timeout and callback + if (rc != 0) + { + LOG_ERR("Failed to queue CAN frame: %d", rc); + free(frame_id); // Free the allocated memory for frame ID + return rc; + } + return 0; +} + +void canbus_tx16_callback(const struct device *dev, int error, void *user_data) +{ + ARG_UNUSED(dev); + uint8_t frame_id = *(uint8_t *)user_data; // Retrieve the frame ID from user data + + if (error != 0) + { + LOG_ERR("CAN transmission error. Error code: %d, Frame ID: %d", error, frame_id); + } + else + { + LOG_DBG("CAN message with Frame ID %d sent successfully", frame_id); + } + free(user_data); // Free the allocated memory for frame ID +} + +int canbus_send16(uint16_t reg, uint16_t value) +{ + int rc = 0; + union data_type + { + int16_t value; + uint8_t bytes[2]; + } data; + data.value = sys_cpu_to_be16(value); // Convert value to big-endian format + + struct can_frame frame = { + .id = (node_id << 8) | reg, // Standard ID with node ID in the first byte + .dlc = sizeof(data), // Data Length Code (DLC) + }; + memcpy(frame.data, data.bytes, sizeof(data)); // Copy data into the frame + uint8_t *frame_id = malloc(sizeof(uint8_t)); // Allocate memory for frame ID + LOG_DBG("Preparing to send 16-bit value 0x%04x to register 0x%02x on node %d", value, reg, node_id); + if (frame_id == NULL) + { + LOG_ERR("Failed to allocate memory for frame ID"); + return -ENOMEM; // Not enough memory + } + *frame_id = can_msg_id++; // Increment message ID for uniqueness + LOG_DBG("Using frame ID: %d", *frame_id); + rc = can_send(can_dev, &frame, CANBUS_TX_TIMEOUT, canbus_tx16_callback, frame_id); + // Send the CAN frame with a timeout and callback + if (rc != 0) + { + LOG_ERR("Failed to queue CAN frame: %d", rc); + free(frame_id); // Free the allocated memory for frame ID + return rc; + } + + LOG_DBG("Queued 16-bit value 0x%04x to register 0x%02x on node %d, frame ID: %d", + value, reg, node_id, *frame_id); return 0; } \ No newline at end of file diff --git a/software/lib/canbus.h b/software/lib/canbus.h index c58a404..51e6ea2 100644 --- a/software/lib/canbus.h +++ b/software/lib/canbus.h @@ -1,13 +1,16 @@ #ifndef __CANBUS_H__ #define __CANBUS_H__ -#include -#include +#include +#include "canbus_registers.h" -#define RX_THREAD_STACK_SIZE 512 -#define RX_THREAD_PRIORITY 2 +#define CANBUS_RX_THREAD_STACK_SIZE (512) // Stack size for the CAN RX thread +#define CANBUS_RX_THREAD_PRIORITY (5) // Priority for the CAN RX thread +#define CANBUS_RX_MSGQ_SIZE (5) // Size of the message queue for CAN RX thread +#define CANBUS_TX_TIMEOUT K_MSEC(100) // Timeout for sending CAN messages in milliseconds int canbus_init(void); -int canbus_send_message(const struct can_frame *frame); +int canbus_send8(uint16_t reg, uint8_t value); +int canbus_send16(uint16_t reg, uint16_t value); #endif // __CANBUS_H__ \ No newline at end of file diff --git a/software/lib/canbus_registers.h b/software/lib/canbus_registers.h new file mode 100644 index 0000000..5463b53 --- /dev/null +++ b/software/lib/canbus_registers.h @@ -0,0 +1,42 @@ +#ifndef __CANBUS_REGISTERS_H__ +#define __CANBUS_REGISTERS_H__ + +enum canbus_registers { + CANBUS_REG_REBOOT = 0x00, + CANBUS_REG_STATE = 0x01, + CANBUS_REG_ERROR = 0x02, + + CANBUS_REG_VALVE_STATUS = 0x10, + CANBUS_REG_VALVE_OPERATION = 0x11, + CANBUS_REG_VALVE_COMMAND = 0x12, + + CANBUS_REG_WATERLEVEL_STATE = 0x20, + CANBUS_REG_WATERLEVEL_LEVEL = 0x21, + CANBUS_REG_WATERLEVEL_ZERO_POINT = 0x22, + CANBUS_REG_WATERLEVEL_MAX_POINT = 0x23, +}; + +enum valve_status { + VALVE_STATE_CLOSED = 0x00, + VALVE_STATE_OPEN = 0x01, + VALVE_STATE_ERROR = 0x02, + VALVE_STATE_UNKNOWN = 0x03, +}; + +enum valve_operation_state { + VALVE_OPERATION_IDLE = 0x00, + VALVE_OPERATION_OPENING = 0x01, + VALVE_OPERATION_CLOSING = 0x02, +}; + +enum valve_command { + VALVE_COMMAND_STOP = 0x00, + VALVE_COMMAND_OPEN = 0x01, + VALVE_COMMAND_CLOSE = 0x02, +}; + +enum waterlevel_state { + WATERLEVEL_STATE_OK = 0x00, + WATERLEVEL_STATE_MODBUS_ERROR = 0x02, +}; +#endif // __CANBUS_REGISTERS_H__ \ No newline at end of file diff --git a/software/lib/modbus.c b/software/lib/modbus.c deleted file mode 100644 index ed118cf..0000000 --- a/software/lib/modbus.c +++ /dev/null @@ -1,163 +0,0 @@ -#include "modbus.h" -#include -#include -#include -#include - -LOG_MODULE_REGISTER(mbc, CONFIG_LOG_DEFAULT_LEVEL); - -#define MODBUS_NODE DT_COMPAT_GET_ANY_STATUS_OKAY(zephyr_modbus_serial) - -static int client_iface; - -static struct -{ - int level; // Water level value - int minimum; // Minimum value - int maximum; // Maximum value - int factor; // Factor for unit conversion -} measurement; - -int mb_init_client(void) -{ - const char iface_name[] = {DEVICE_DT_NAME(MODBUS_NODE)}; - client_iface = modbus_iface_get_by_name(iface_name); - LOG_DBG("Modbus client interface: %d", client_iface); - if (client_iface < 0) - { - LOG_ERR("Failed to get Modbus interface by name: %s", iface_name); - return client_iface; - } - return modbus_init_client(client_iface, client_param); -} - -int mb_read_holding_registers(int node, uint16_t reg_addr, uint16_t *data, size_t len) -{ - return modbus_read_holding_regs(client_iface, node, reg_addr, data, len); -} - -int mb_read() -{ - int rc; - int16_t data[5] = {0}; - rc = mb_read_holding_registers(1, 0x0002, data, sizeof(data) / sizeof(data[0])); - if (rc < 0) - { - LOG_ERR("Failed to read holding registers: %d", rc); - return rc; - } - LOG_HEXDUMP_DBG(data, sizeof(data), "Holding Registers Data"); - - int unit, decimals; - unit = data[0]; - decimals = data[1]; - int factor; - switch (unit) - { - case 1: // cm - factor = 10; - break; - case 2: // mm - factor = 1; - break; - default: - LOG_ERR("Unknown unit: %d", unit); - return -EINVAL; - } - switch(decimals) - { - case 0: // no decimals - factor /= 1; - break; - case 1: // one decimal - factor /= 10; - break; - case 2: // two decimals - factor /= 100; - break; - default: - LOG_ERR("Unknown decimals: %d", decimals); - return -EINVAL; - } - measurement.factor = factor; - measurement.level = data[2] * factor; - measurement.minimum = data[3] * factor; - measurement.maximum = data[4] * factor; - LOG_DBG("Water level: %dmm, Minimum: %dmm, Maximum: %dmm", - measurement.level, measurement.minimum, measurement.maximum); - return 0; -} - -int mb_read_water_level(double *mb_read_water_level) -{ - int rc = mb_read(); - if (rc < 0) - { - LOG_ERR("Failed to read water level: %d", rc); - return rc; - } - *mb_read_water_level = (double)measurement.level / 1000.0; // Convert to meters - - return 0; -} - -int mb_read_water_level_mm(int *mb_read_water_level) -{ - int rc = mb_read(); - if (rc < 0) - { - LOG_ERR("Failed to read water level: %d", rc); - return rc; - } - *mb_read_water_level = measurement.level; - - return 0; -} - -int mb_read_minimum_mm(int *mb_read_minimum) -{ - int rc = mb_read(); - if (rc < 0) - { - LOG_ERR("Failed to read water level: %d", rc); - return rc; - } - *mb_read_minimum = measurement.minimum; - return 0; -} - -int mb_read_maximum_mm(int *mb_read_maximum) -{ - int rc = mb_read(); - if (rc < 0) - { - LOG_ERR("Failed to read water level: %d", rc); - return rc; - } - *mb_read_maximum = measurement.maximum; - return 0; -} - -int mb_write_minimum_mm(int minimum) -{ - int rc = mb_read(); - if (rc < 0) - { - LOG_ERR("Failed to read water level: %d", rc); - return rc; - } - modbus_write_holding_reg(client_iface, 1, 0x0005, minimum / measurement.factor); - return 0; -} - -int mb_write_maximum_mm(int maximum) -{ - int rc = mb_read(); - if (rc < 0) - { - LOG_ERR("Failed to read water level: %d", rc); - return rc; - } - modbus_write_holding_reg(client_iface, 1, 0x0006, maximum / measurement.factor); - return 0; -} diff --git a/software/lib/modbus.h b/software/lib/modbus.h deleted file mode 100644 index 3d43bac..0000000 --- a/software/lib/modbus.h +++ /dev/null @@ -1,24 +0,0 @@ -#ifndef __waterlevel_h -#define __waterlevel_h - -#include - -const static struct modbus_iface_param client_param = { - .mode = MODBUS_MODE_RTU, - .rx_timeout = 50000, - .serial = { - .baud = 9600, - .parity = UART_CFG_PARITY_NONE, - }, -}; - -int mb_init_client(void); -int mb_read_holding_registers(int node, uint16_t reg_addr, uint16_t *data, size_t len); -int mb_read_water_level(double *mb_read_water_level); -int mb_read_water_level_mm(int *mb_read_water_level_mm); -int mb_read_minimum_mm(int *mb_read_minimum); -int mb_read_maximum_mm(int *mb_read_maximum); -int mb_write_minimum_mm(int minimum); -int mb_write_maximum_mm(int maximum); - -#endif \ No newline at end of file diff --git a/software/lib/settings.h b/software/lib/settings.h deleted file mode 100644 index 523df6f..0000000 --- a/software/lib/settings.h +++ /dev/null @@ -1,17 +0,0 @@ -#ifndef __SETTINGS_H__ -#define __SETTINGS_H__ - -#include - -#include -#include - -#if defined(CONFIG_SETTINGS_FILE) -#include -#include -#endif - -#define STORAGE_PARTITION storage_partition -#define STORAGE_PARTITION_ID FIXED_PARTITION_ID(STORAGE_PARTITION) - -#endif // __SETTINGS_H__ \ No newline at end of file diff --git a/software/lib/valve.c b/software/lib/valve.c new file mode 100644 index 0000000..4966540 --- /dev/null +++ b/software/lib/valve.c @@ -0,0 +1,163 @@ +#include +#include + +#include "canbus.h" +#include "canbus_registers.h" +#include "valve.h" + +LOG_MODULE_REGISTER(valve, CONFIG_LOG_VALVE_LEVEL); + +K_THREAD_STACK_DEFINE(valve_thread_stack, VALVE_THREAD_STACK_SIZE); +K_MSGQ_DEFINE(valve_msgq, sizeof(int), VALVE_MSGQ_SIZE, 4); + +k_tid_t valve_thread_id; +struct k_thread valve_thread_data; + +valve_status_t valve_status_data = { + .valve_state = VALVE_STATE_UNKNOWN, + .valve_operation = VALVE_OPERATION_IDLE, +}; + +int valve_start_thread(void) +{ + int rc; + + // Initialize the valve + rc = valve_init(); + if (rc < 0) + { + LOG_ERR("Failed to initialize valve: %d", rc); + return rc; + } + + // Create the valve thread + valve_thread_id = k_thread_create(&valve_thread_data, valve_thread_stack, + K_THREAD_STACK_SIZEOF(valve_thread_stack), + (k_thread_entry_t)valve_cmd, NULL, NULL, NULL, + VALVE_THREAD_PRIORITY, 0, K_NO_WAIT); + k_thread_name_set(valve_thread_id, "valve"); + + LOG_INF("Valve thread started successfully"); +while (1) + { + // Wait for commands from the message queue + int cmd; + rc = k_msgq_get(&valve_msgq, &cmd, VALVE_STATE_INTERVAL); + if (rc == 0) + { + // Process the command + rc = valve_cmd(cmd); + if (rc < 0) + { + LOG_ERR("Failed to process valve command: %d", rc); + } + } + else + { + valve_send_status(); // Send current valve status periodically + } + } + return 0; +} +int valve_init(void) +{ + return 0; +} + +int valve_cmd(int cmd) +{ + switch (cmd) + { + case VALVE_COMMAND_OPEN: + if (valve_status_data.valve_state != VALVE_STATE_OPEN) + { + valve_status_data.valve_state = VALVE_STATE_OPEN; + valve_status_data.valve_operation = VALVE_OPERATION_OPENING; + valve_send_status(); // Send updated status before opening + valve_send_operation(); // Send updated operation state before opening + k_sleep(VALVE_OPENING_TIME); // Simulate opening time + valve_status_data.valve_operation = VALVE_OPERATION_IDLE; // Set operation to idle after opening + valve_send_status(); // Send updated status after opening + valve_send_operation(); // Send updated operation state after opening + } + break; + case VALVE_COMMAND_CLOSE: + if (valve_status_data.valve_state != VALVE_STATE_CLOSED) + { + valve_status_data.valve_operation = VALVE_OPERATION_CLOSING; + valve_send_operation(); // Send updated operation state before closing + k_sleep(VALVE_CLOSING_TIME); // Simulate closing time + valve_status_data.valve_state = VALVE_STATE_CLOSED; // Set valve state to closed after closing + valve_status_data.valve_operation = VALVE_OPERATION_IDLE; // Set operation to idle after closing + valve_send_status(); // Send updated status after closing + valve_send_operation(); // Send updated operation state after closing + } + break; + case VALVE_COMMAND_STOP: + valve_status_data.valve_operation = VALVE_OPERATION_IDLE; + break; + default: + LOG_ERR("Unknown valve command: %d", cmd); + return -EINVAL; // Invalid command + } + return 0; +} + +int valve_send_status(void) +{ + int rc = canbus_send8(CANBUS_REG_VALVE_STATUS, valve_status_data.valve_state); + if (rc != 0) + { + LOG_ERR("Failed to send valve status: %d", rc); + return rc; + } + char *state_str; + switch (valve_status_data.valve_state) + { + case VALVE_STATE_CLOSED: + state_str = "CLOSED"; + break; + case VALVE_STATE_OPEN: + state_str = "OPEN"; + break; + case VALVE_STATE_ERROR: + state_str = "ERROR"; + break; + case VALVE_STATE_UNKNOWN: + state_str = "UNKNOWN"; + break; + default: + state_str = "INVALID"; + break; + } + LOG_INF("Valve status sent: %s", state_str); + return 0; +} + +int valve_send_operation(void) +{ + int rc = canbus_send8(CANBUS_REG_VALVE_OPERATION, valve_status_data.valve_operation); + if (rc != 0) + { + LOG_ERR("Failed to send valve operation: %d", rc); + return rc; + } + char *operation_str; + switch (valve_status_data.valve_operation) + { + case VALVE_OPERATION_IDLE: + operation_str = "IDLE"; + break; + case VALVE_OPERATION_OPENING: + operation_str = "OPENING"; + break; + case VALVE_OPERATION_CLOSING: + operation_str = "CLOSING"; + break; + default: + operation_str = "UNKNOWN"; + break; + } + LOG_INF("Valve operation sent: %s", operation_str); + return 0; +} \ No newline at end of file diff --git a/software/lib/valve.h b/software/lib/valve.h new file mode 100644 index 0000000..94f4538 --- /dev/null +++ b/software/lib/valve.h @@ -0,0 +1,27 @@ +#ifndef __VALVE_H__ +#define __VALVE_H__ + +#define VALVE_OPENING_TIME K_MSEC(4500) // Time to open the valve +#define VALVE_CLOSING_TIME K_MSEC(4500) // Time to close the valve +#define VALVE_MAX_OPENING_TIME K_MSEC(5000) // Maximum time to open the valve +#define VALVE_MAX_CLOSING_TIME K_MSEC(5000) // Maximum time to close the valve +#define VALVE_STATE_INTERVAL K_SECONDS(5 * 60) // Interval to check the valve state +#define VALVE_THREAD_STACK_SIZE (512) // Stack size for the valve thread +#define VALVE_THREAD_PRIORITY (2) // Priority for the valve thread +#define VALVE_MSGQ_SIZE (5) // Size of the message queue for valve operations + +#include +#include "canbus_registers.h" + +typedef struct { + uint8_t valve_state; + uint8_t valve_operation; +} valve_status_t; + +int valve_init(void); +int valve_cmd(int cmd); +int valve_send_status(void); +int valve_send_operation(void); + + +#endif // __VALVE_H__ \ No newline at end of file diff --git a/software/lib/waterlevel_sensor.c b/software/lib/waterlevel_sensor.c new file mode 100644 index 0000000..3d441f8 --- /dev/null +++ b/software/lib/waterlevel_sensor.c @@ -0,0 +1,384 @@ +#include "waterlevel_sensor.h" +#include +#include +#include +#include +#include "canbus.h" + +LOG_MODULE_REGISTER(wls, CONFIG_LOG_WATERLEVELSENSOR_LEVEL); + +#define MODBUS_NODE DT_COMPAT_GET_ANY_STATUS_OKAY(zephyr_modbus_serial) + +struct k_thread waterlevel_sensor_thread_data; +K_THREAD_STACK_DEFINE(waterlevel_sensor_stack, WATERLEVEL_SENSOR_STACK_SIZE); +K_MSGQ_DEFINE(waterlevel_sensor_msgq, sizeof(waterlevel_command_t), WATERLEVEL_MESSAGE_QUEUE_SIZE, 4); + +static int modbus_client_iface; + +volatile static struct +{ + int level; // Water level value + int zeropoint; // Minimum value + int maxpoint; // Maximum value + int factor; // Factor for unit conversion + bool factor_set; // Flag to indicate if factor is set +} waterlevel_measurement = { + .factor_set = false, +}; + +struct modbus_iface_param client_param = { + .mode = MODBUS_MODE_RTU, + .rx_timeout = 50000, // Timeout for receiving data in milliseconds + .serial = { + .baud = 9600, + .parity = UART_CFG_PARITY_NONE, + .stop_bits_client = UART_CFG_STOP_BITS_1, // 1 stop bit for Modbus RTU + }, +}; + +static int waterlevel_modbus_init() { + const char iface_name[] = {DEVICE_DT_NAME(MODBUS_NODE)}; + modbus_client_iface = modbus_iface_get_by_name(iface_name); + if (modbus_client_iface < 0) + { + LOG_ERR("Failed to get Modbus interface by name: %s", iface_name); + return modbus_client_iface; + } + LOG_DBG("Initializing modbus client interface: %s", iface_name); + return modbus_init_client(modbus_client_iface, client_param); +} + +static int waterlevel_modbus_read(void) { + int rc; + union + { + struct + { + int16_t unit; // Unit of measurement (e.g., cm, mm) + int16_t decimals; // Number of decimal places for the measurement + int16_t level; // Water level value + int16_t zeropoint; // Zero point for the measurement + int16_t maxpoint; // Maximum point for the measurement + }; + int16_t data[5]; // Data array for holding registers + } waterlevel_modbus_data; + rc = modbus_read_holding_regs(modbus_client_iface, WATERLEVEL_SENSOR_MODBUS_NODE_ID, 0x0002, waterlevel_modbus_data.data, sizeof(waterlevel_modbus_data.data) / sizeof(waterlevel_modbus_data.data[0])); + if (rc < 0) + { + LOG_ERR("Failed to read holding registers, node <%d>, returncode: %d", WATERLEVEL_SENSOR_MODBUS_NODE_ID, rc); + return rc; + } + + LOG_DBG("Got values. Unit: %d, Decimals: %d, Level: %d, Zero Point: %d, Max Point: %d", + waterlevel_modbus_data.unit, + waterlevel_modbus_data.decimals, + waterlevel_modbus_data.level, + waterlevel_modbus_data.zeropoint, + waterlevel_modbus_data.maxpoint); + + LOG_HEXDUMP_DBG(waterlevel_modbus_data.data, sizeof(waterlevel_modbus_data.data), "Waterlevel Sensor Holding Registers Data"); + + switch (waterlevel_modbus_data.unit) + { + case 1: // cm + waterlevel_measurement.factor = 10; + break; + case 2: // mm + waterlevel_measurement.factor = 1; + break; + default: + LOG_ERR("Unknown unit: %d", waterlevel_modbus_data.unit); + waterlevel_measurement.factor_set = false; + return -EINVAL; + } + switch (waterlevel_modbus_data.decimals) + { + case 0: // no decimals + waterlevel_measurement.factor /= 1; + break; + case 1: // one decimal + waterlevel_measurement.factor /= 10; + break; + case 2: // two decimals + waterlevel_measurement.factor /= 100; + break; + default: + LOG_ERR("Unknown decimals: %d", waterlevel_modbus_data.decimals); + waterlevel_measurement.factor_set = false; + return -EINVAL; + } + waterlevel_measurement.factor_set = true; + waterlevel_measurement.level = waterlevel_modbus_data.level * waterlevel_measurement.factor; + waterlevel_measurement.zeropoint = waterlevel_modbus_data.zeropoint * waterlevel_measurement.factor; + waterlevel_measurement.maxpoint = waterlevel_modbus_data.maxpoint * waterlevel_measurement.factor; + + LOG_DBG("Water level: %dmm, zero point: %dmm, maximum point: %dmm", + waterlevel_measurement.level, + waterlevel_measurement.zeropoint, + waterlevel_measurement.maxpoint); + LOG_HEXDUMP_DBG(waterlevel_modbus_data.data, sizeof(waterlevel_modbus_data.data), "Waterlevel Sensor Holding Registers Data"); + return 0; +} + +static int waterlevel_send_level(void) { + if (!waterlevel_measurement.factor_set) { + LOG_ERR("Factor not set, cannot send water level"); + return -EINVAL; + } + + LOG_INF("Sending water level: %dmm", waterlevel_measurement.level); + canbus_send16(CANBUS_REG_WATERLEVEL_LEVEL, waterlevel_measurement.level); + return 0; +} + +static int waterlevel_send_zero_point(void) { + if (!waterlevel_measurement.factor_set) { + LOG_ERR("Factor not set, cannot send zero point"); + return -EINVAL; + } + + LOG_INF("Sending water zero point: %dmm", waterlevel_measurement.zeropoint); + canbus_send16(CANBUS_REG_WATERLEVEL_ZERO_POINT, waterlevel_measurement.zeropoint); + return 0; +} + +static int waterlevel_send_max_point(void) { + if (!waterlevel_measurement.factor_set) { + LOG_ERR("Factor not set, cannot send maximum point"); + return -EINVAL; + } + + LOG_INF("Sending water maximum point: %dmm", waterlevel_measurement.maxpoint); + canbus_send16(CANBUS_REG_WATERLEVEL_MAX_POINT, waterlevel_measurement.maxpoint); + return 0; +} + +static int waterlevel_set_zero_point(int zeropoint) { + if (!waterlevel_measurement.factor_set) { + LOG_ERR("Factor not set, cannot set zero point"); + return -EINVAL; + } + + int16_t zeropoint_modbus = zeropoint / waterlevel_measurement.factor; + int rc = modbus_write_holding_regs(modbus_client_iface, WATERLEVEL_SENSOR_MODBUS_NODE_ID, 0x0005, &zeropoint_modbus, 1); + if (rc < 0) { + LOG_ERR("Failed to write zero point: %d", rc); + return rc; + } + + waterlevel_measurement.zeropoint = zeropoint; // Update the local measurement structure + LOG_INF("Zero point set to: %dmm", waterlevel_measurement.zeropoint); + rc = waterlevel_send_zero_point(); + if (rc < 0) { + LOG_ERR("Failed to send zero point: %d", rc); + return rc; + } + return 0; +} + +static int waterlevel_set_max_point(int maxpoint) { + if (!waterlevel_measurement.factor_set) { + LOG_ERR("Factor not set, cannot set maximum point"); + return -EINVAL; + } + + int16_t maxpoint_modbus = maxpoint / waterlevel_measurement.factor; + int rc = modbus_write_holding_regs(modbus_client_iface, WATERLEVEL_SENSOR_MODBUS_NODE_ID, 0x0006, &maxpoint_modbus, 1); + if (rc < 0) { + LOG_ERR("Failed to write maximum point: %d", rc); + return rc; + } + + waterlevel_measurement.maxpoint = maxpoint; // Update the local measurement structure + LOG_INF("Maximum point set to: %dmm", waterlevel_measurement.maxpoint); + rc = waterlevel_send_max_point(); + if (rc < 0) { + LOG_ERR("Failed to send maximum point: %d", rc); + return rc; + } + return 0; +} + +void waterlevel_sensor_thread(void *arg1, void *arg2, void *arg3) +{ + ARG_UNUSED(arg1); + ARG_UNUSED(arg2); + ARG_UNUSED(arg3); + + // Initialize the Modbus client + int rc = waterlevel_modbus_init(); + if (rc < 0) + { + LOG_ERR("Failed to initialize Modbus client: %d", rc); + return; + } + + rc = waterlevel_modbus_read(); + if (rc < 0) { + LOG_ERR("Failed to read initial water level: %d", rc); + return; + } + waterlevel_send_level(); + waterlevel_send_zero_point(); + waterlevel_send_max_point(); + + // Initialize the last transmission time and level + // Use k_uptime_get_32() to get the current uptime in milliseconds + // and store the initial water level measurement. + // This will be used to determine when to send updates. + + uint32_t last_transmission_time_ms = k_uptime_get_32(); + int32_t last_transmission_level = waterlevel_measurement.level; + + while (1) + { + uint32_t current_time_ms = k_uptime_get_32(); + uint32_t delta_time = current_time_ms-last_transmission_time_ms; + waterlevel_command_t command; + + rc = waterlevel_modbus_read(); + if (rc < 0) + { + LOG_ERR("Failed to read water level: %d", rc); + continue; + } + + if (delta_time >= WATERLEVEL_SENSOR_MAX_UPDATE_INTERVAL_MS || + abs(waterlevel_measurement.level - last_transmission_level) >= WATERLEVEL_SENSOR_MIN_DELTA) { + rc = waterlevel_send_level(); + if (rc < 0) { + LOG_ERR("Failed to send water level: %d", rc); + } else { + last_transmission_time_ms = current_time_ms; + last_transmission_level = waterlevel_measurement.level; + } + } + + while (k_msgq_get(&waterlevel_sensor_msgq, &command, K_NO_WAIT) == 0) + { + switch(command.cmd) + { + case WATERLEVEL_CMD_SET: + switch (command.reg) + { + case CANBUS_REG_WATERLEVEL_ZERO_POINT: // Set zero point + rc = waterlevel_set_zero_point(command.data); + if (rc < 0) { + LOG_ERR("Failed to set zero point: %d", rc); + } + break; + case CANBUS_REG_WATERLEVEL_MAX_POINT: // Set maximum point + rc = waterlevel_set_max_point(command.data); + if (rc < 0) { + LOG_ERR("Failed to set maximum point: %d", rc); + } + break; + default: + LOG_ERR("Unknown register for SET command: 0x%02X", command.reg); + break; + } + break; + case WATERLEVEL_CMD_GET: + switch (command.reg) + { + case CANBUS_REG_WATERLEVEL_LEVEL: // Get water level + waterlevel_send_level(); + break; + case CANBUS_REG_WATERLEVEL_ZERO_POINT: // Get zero point + waterlevel_send_zero_point(); + break; + case CANBUS_REG_WATERLEVEL_MAX_POINT: // Get maximum point + waterlevel_send_max_point(); + break; + default: + LOG_ERR("Unknown register for GET command: 0x%02X", command.reg); + break; + } + break; + default: + LOG_ERR("Unknown command type: %d", command.cmd); + break; + } + } + } +} + +int waterlevel_sensor_start_thread(void) +{ + k_tid_t waterlevel_sensor_thread_id; + + // Start the thread + waterlevel_sensor_thread_id = k_thread_create(&waterlevel_sensor_thread_data, waterlevel_sensor_stack, + K_THREAD_STACK_SIZEOF(waterlevel_sensor_stack), waterlevel_sensor_thread, + NULL, NULL, NULL, + WATERLEVEL_SENSOR_THREAD_PRIORITY, 0, K_NO_WAIT); + + if (waterlevel_sensor_thread_id == NULL) + { + LOG_ERR("Failed to create water level sensor thread"); + return -ENOMEM; + } + k_thread_name_set(waterlevel_sensor_thread_id, "waterlevel_sensor"); + + LOG_INF("Water level sensor thread started successfully"); + return 0; +} + +#ifdef CONFIG_SHELL +#include + +void waterlevel_set_zero_point_shell(const struct shell *shell, size_t argc, char **argv) { + if (argc != 2) { + shell_error(shell, "Usage: waterlevel_sensor set_zero_point "); + return; + } + + int zeropoint = atoi(argv[1]); + int rc = waterlevel_set_zero_point(zeropoint); + if (rc < 0) { + shell_error(shell, "Failed to set zero point: %d", rc); + } else { + shell_print(shell, "Zero point set to: %dmm", zeropoint); + } +} + +void waterlevel_set_max_point_shell(const struct shell *shell, size_t argc, char **argv) { + if (argc != 2) { + shell_error(shell, "Usage: waterlevel_sensor set_max_point "); + return; + } + + int maxpoint = atoi(argv[1]); + int rc = waterlevel_set_max_point(maxpoint); + if (rc < 0) { + shell_error(shell, "Failed to set maximum point: %d", rc); + } else { + shell_print(shell, "Maximum point set to: %dmm", maxpoint); + } +} + +void waterlevel_sensor_print_shell(const struct shell *shell, size_t argc, char **argv) { + ARG_UNUSED(argc); + ARG_UNUSED(argv); + + waterlevel_modbus_read(); + if (!waterlevel_measurement.factor_set) { + shell_error(shell, "Factor not set, cannot print water level"); + return; + } + + shell_print(shell, "Current water level: %4dmm", waterlevel_measurement.level); + shell_print(shell, "Zero point: %4dmm", waterlevel_measurement.zeropoint); + shell_print(shell, "Maximum point: %4dmm", waterlevel_measurement.maxpoint); +} + +// Define the shell commands for the water level sensor +SHELL_STATIC_SUBCMD_SET_CREATE( + waterlevel_sensor_cmds, + SHELL_CMD(print, NULL, "Print the current water level, zero point, and maximum point", waterlevel_sensor_print_shell), + SHELL_CMD(setzero, NULL, "Set the zero point for the water level sensor", waterlevel_set_zero_point_shell), + SHELL_CMD(setmax, NULL, "Set the maximum point for the water level sensor", waterlevel_set_max_point_shell), + SHELL_SUBCMD_SET_END); + +SHELL_CMD_REGISTER(wls, &waterlevel_sensor_cmds, "Water level sensor commands", NULL); +#endif // CONFIG_SHELL diff --git a/software/lib/waterlevel_sensor.h b/software/lib/waterlevel_sensor.h new file mode 100644 index 0000000..e8ab7e5 --- /dev/null +++ b/software/lib/waterlevel_sensor.h @@ -0,0 +1,27 @@ +#ifndef __WATERLEVEL_SENSOR_H__ +#define __WATERLEVEL_SENSOR_H__ + +#define WATERLEVEL_SENSOR_STACK_SIZE (512) +#define WATERLEVEL_SENSOR_THREAD_PRIORITY (2) +#define WATERLEVEL_MESSAGE_QUEUE_SIZE (5) // Size of the message queue for water level sensor thread +#define WATERLEVEL_SENSOR_READ_INTERVAL_MS (5000) // Interval for reading the water level sensor in milliseconds +#define WATERLEVEL_SENSOR_MIN_DELTA (2) // Minimum change in water level to trigger an update +#define WATERLEVEL_SENSOR_MAX_UPDATE_INTERVAL_MS (600000) // Maximum interval for updating the water level in milliseconds + +#define WATERLEVEL_SENSOR_MODBUS_NODE_ID (0x01) // Modbus node ID for the water level sensor +#define WATERLEVEL_SENSOR_MODBUS_BAUD_RATE (9600) // Baud rate for Modbus communication + +#include + +int waterlevel_sensor_start_thread(void); + +typedef struct { + uint8_t reg; + enum { + WATERLEVEL_CMD_SET, + WATERLEVEL_CMD_GET, + } cmd; + int16_t data; // Data to be set +} waterlevel_command_t; + +#endif // __WATERLEVEL_SENSOR_H__ \ No newline at end of file diff --git a/software/prj.conf b/software/prj.conf new file mode 100644 index 0000000..f297171 --- /dev/null +++ b/software/prj.conf @@ -0,0 +1,17 @@ +CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR=y +CONFIG_HAS_VALVE=y + +CONFIG_LOG=y +CONFIG_LOG_DEFAULT_LEVEL=3 +# CONFIG_LOG_CAN_LEVEL=4 +# CONFIG_LOG_WATERLEVELSENSOR_LEVEL=4 +# CONFIG_LOG_VALVE_LEVEL=4 +CONFIG_CBPRINTF_FP_SUPPORT=y +CONFIG_UART_CONSOLE=y # Console on USART1 + +# CAN loopback mode for testing +#CONFIG_LOOPBACK_MODE=y +CONFIG_SHELL=y +CONFIG_CAN_SHELL=y +CONFIG_GPIO_SHELL=y +CONFIG_REBOOT=y \ No newline at end of file diff --git a/software/src/main.c b/software/src/main.c new file mode 100644 index 0000000..8cb48fb --- /dev/null +++ b/software/src/main.c @@ -0,0 +1,53 @@ +#include +#include +#include +#include +#include "canbus.h" +#include "canbus_registers.h" + +#ifdef CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR +// Include the water level sensor header file when the feature is enabled +#include "waterlevel_sensor.h" +#endif // CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR + +#ifdef CONFIG_HAS_VALVE +#include "valve.h" +#endif // CONFIG_HAS_VALVE + +LOG_MODULE_REGISTER(main, CONFIG_LOG_DEFAULT_LEVEL); + +int main(void) +{ + LOG_INF("Starting main application..."); + canbus_init(); + k_sleep(K_MSEC(3000)); // Allow some time for CAN initialization +#ifdef CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR + int rc = waterlevel_sensor_start_thread(); + if (rc < 0) + { + LOG_ERR("Failed to start water level sensor thread: %d", rc); + return rc; + } +#endif // CONFIG_HAS_MODBUS_WATERLEVEL_SENSOR + + valve_cmd(VALVE_COMMAND_CLOSE); // Ensure the valve is closed at startup + + LOG_INF("Main application started successfully."); + return 0; // Return 0 on success +} + +#ifdef CONFIG_SHELL +#include +#include + +static int reboot_shell_cmd(const struct shell *shell, size_t argc, char **argv) +{ + ARG_UNUSED(argc); + ARG_UNUSED(argv); + shell_print(shell, "Rebooting the node in 1 second..."); + k_sleep(K_SECONDS(1)); + sys_reboot(SYS_REBOOT_COLD); + return 0; +} +SHELL_CMD_REGISTER(reboot, NULL, "Reboot the node", reboot_shell_cmd); +#endif // CONFIG_SHELL diff --git a/software/test_canbus/.gitignore b/software/test_canbus/.gitignore deleted file mode 100644 index 378eac2..0000000 --- a/software/test_canbus/.gitignore +++ /dev/null @@ -1 +0,0 @@ -build diff --git a/software/test_canbus/.vscode/c_cpp_properties.json b/software/test_canbus/.vscode/c_cpp_properties.json deleted file mode 100644 index b1f27e8..0000000 --- a/software/test_canbus/.vscode/c_cpp_properties.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "configurations": [ - { - "name": "Win32", - "includePath": [ - "${workspaceFolder}/**" - ], - "defines": [ - "_DEBUG", - "UNICODE", - "_UNICODE" - ] - } - ], - "version": 4 -} \ No newline at end of file diff --git a/software/test_canbus/CMakeLists.txt b/software/test_canbus/CMakeLists.txt deleted file mode 100644 index 3989c64..0000000 --- a/software/test_canbus/CMakeLists.txt +++ /dev/null @@ -1,14 +0,0 @@ -# SPDX-License-Identifier: Apache-2.0 - -cmake_minimum_required(VERSION 3.20.0) - -list(APPEND BOARD_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/..) - -find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE}) -project(hello_world) - -target_sources(app PRIVATE src/main.c) -target_sources(app PRIVATE ../lib/canbus.c) -target_include_directories(app PRIVATE - ${CMAKE_CURRENT_SOURCE_DIR}/../lib -) diff --git a/software/test_canbus/boards/nucleo_f103rb.overlay b/software/test_canbus/boards/nucleo_f103rb.overlay deleted file mode 100644 index a3e38dc..0000000 --- a/software/test_canbus/boards/nucleo_f103rb.overlay +++ /dev/null @@ -1,9 +0,0 @@ -&usart1 { - status = "okay"; - current-speed = <9600>; - modbus0 { - compatible = "zephyr,modbus-serial"; - status = "okay"; - // de-gpios = <&arduino_header 15 GPIO_ACTIVE_LOW>; /* D9 */ - }; -}; \ No newline at end of file diff --git a/software/test_canbus/prj.conf b/software/test_canbus/prj.conf deleted file mode 100644 index b95fd27..0000000 --- a/software/test_canbus/prj.conf +++ /dev/null @@ -1,10 +0,0 @@ -CONFIG_LOG=y -CONFIG_LOG_DEFAULT_LEVEL=3 -CONFIG_CBPRINTF_FP_SUPPORT=y - -CONFIG_UART_CONSOLE=y # Console on USART1 -#CONFIG_RTT_CONSOLE=y -#CONFIG_USE_SEGGER_RTT=y - -CONFIG_LOOPBACK_MODE=y -CONFIG_LOG_CAN_LEVEL=4 \ No newline at end of file diff --git a/software/test_canbus/src/main.c b/software/test_canbus/src/main.c deleted file mode 100644 index eec6388..0000000 --- a/software/test_canbus/src/main.c +++ /dev/null @@ -1,26 +0,0 @@ -/* Testing MODBUS functionality - This code initializes a Modbus client, sets the zero point and the 2m point for water level, - and reads the water level in both meters and millimeters. - It uses the Zephyr RTOS and its Modbus library to communicate with a Modbus server. -*/ - -#include -#include -#include - -#include "canbus.h" - -LOG_MODULE_REGISTER(main, CONFIG_LOG_DEFAULT_LEVEL); - -int main(void) -{ - int rc; - rc = canbus_init(); - if (rc != 0) - { - LOG_ERR("Failed to initialize CAN bus: %d", rc); - return rc; - } - LOG_INF("CAN bus initialized successfully"); - return 0; -} diff --git a/software/test_modbus/.gitignore b/software/test_modbus/.gitignore deleted file mode 100644 index 378eac2..0000000 --- a/software/test_modbus/.gitignore +++ /dev/null @@ -1 +0,0 @@ -build diff --git a/software/test_modbus/.vscode/c_cpp_properties.json b/software/test_modbus/.vscode/c_cpp_properties.json deleted file mode 100644 index b1f27e8..0000000 --- a/software/test_modbus/.vscode/c_cpp_properties.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "configurations": [ - { - "name": "Win32", - "includePath": [ - "${workspaceFolder}/**" - ], - "defines": [ - "_DEBUG", - "UNICODE", - "_UNICODE" - ] - } - ], - "version": 4 -} \ No newline at end of file diff --git a/software/test_modbus/CMakeLists.txt b/software/test_modbus/CMakeLists.txt deleted file mode 100644 index 5d2c3bf..0000000 --- a/software/test_modbus/CMakeLists.txt +++ /dev/null @@ -1,14 +0,0 @@ -# SPDX-License-Identifier: Apache-2.0 - -cmake_minimum_required(VERSION 3.20.0) - -list(APPEND BOARD_ROOT ${CMAKE_CURRENT_SOURCE_DIR}/..) - -find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE}) -project(hello_world) - -target_sources(app PRIVATE src/main.c) -target_sources(app PRIVATE ../lib/modbus.c) -target_include_directories(app PRIVATE - ${CMAKE_CURRENT_SOURCE_DIR}/../lib -) diff --git a/software/test_modbus/boards/nucleo_f103rb.overlay b/software/test_modbus/boards/nucleo_f103rb.overlay deleted file mode 100644 index a3e38dc..0000000 --- a/software/test_modbus/boards/nucleo_f103rb.overlay +++ /dev/null @@ -1,9 +0,0 @@ -&usart1 { - status = "okay"; - current-speed = <9600>; - modbus0 { - compatible = "zephyr,modbus-serial"; - status = "okay"; - // de-gpios = <&arduino_header 15 GPIO_ACTIVE_LOW>; /* D9 */ - }; -}; \ No newline at end of file diff --git a/software/test_modbus/prj.conf b/software/test_modbus/prj.conf deleted file mode 100644 index 502f667..0000000 --- a/software/test_modbus/prj.conf +++ /dev/null @@ -1,7 +0,0 @@ -CONFIG_LOG=y -CONFIG_LOG_DEFAULT_LEVEL=3 -CONFIG_CBPRINTF_FP_SUPPORT=y - -CONFIG_UART_CONSOLE=y # Console on USART1 -#CONFIG_RTT_CONSOLE=y -#CONFIG_USE_SEGGER_RTT=y \ No newline at end of file diff --git a/software/test_modbus/src/main.c b/software/test_modbus/src/main.c deleted file mode 100644 index 7a79b40..0000000 --- a/software/test_modbus/src/main.c +++ /dev/null @@ -1,78 +0,0 @@ -/* Testing MODBUS functionality - This code initializes a Modbus client, sets the zero point and the 2m point for water level, - and reads the water level in both meters and millimeters. - It uses the Zephyr RTOS and its Modbus library to communicate with a Modbus server. -*/ - -#include -#include -#include - -#include "modbus.h" - -LOG_MODULE_REGISTER(main, CONFIG_LOG_DEFAULT_LEVEL); - -/* 1000 msec = 1 sec */ -#define SLEEP_TIME_MS 1000 - -int main(void) -{ - int rc; - - rc = mb_init_client(); - if (rc != 0) - { - LOG_ERR("Failed to initialize Modbus client: %d", rc); - return rc; - } - LOG_INF("Modbus client initialized successfully"); - - double water_level = 0.0; - int water_level_mm, water_level_min_mm, water_level_max_mm = 0; - - rc = mb_write_minimum_mm(42); // Set the zero point for water level - if (rc < 0) - { - LOG_ERR("Failed to write minimum water level: %d", rc); - return rc; - } - rc = mb_write_maximum_mm(2000); // Set the 2m point for water level - if (rc < 0) - { - LOG_ERR("Failed to write maximum water level: %d", rc); - return rc; - } - rc = mb_read_minimum_mm(&water_level_min_mm); - if (rc < 0) - { - LOG_ERR("Failed to read minimum water level: %d", rc); - return rc; - } - rc = mb_read_maximum_mm(&water_level_max_mm); - if (rc < 0) - { - LOG_ERR("Failed to read maximum water level: %d", rc); - return rc; - } - LOG_INF("Water zero point is set to: %dmm", water_level_min_mm); - LOG_INF("Water 2m point is set to: %dmm", water_level_max_mm); - - /* Read water level */ - rc = mb_read_water_level(&water_level); - if (rc < 0) - { - LOG_ERR("Failed to read water level: %d", rc); - return rc; - } - rc = mb_read_water_level_mm(&water_level_mm); - if (rc < 0) - { - LOG_ERR("Failed to read water level: %d", rc); - return rc; - } - LOG_INF("Water level: %.3fm", water_level); - LOG_INF("Water level: %dmm", water_level_mm); - LOG_INF("Modbus test completed successfully"); - - return 0; -} diff --git a/software/worspace.code-workspace b/software/worspace.code-workspace new file mode 100644 index 0000000..47b5bb9 --- /dev/null +++ b/software/worspace.code-workspace @@ -0,0 +1,132 @@ +{ + "folders": [ + { + "path": "." + } + ], + "settings": { + // Hush CMake + "cmake.configureOnOpen": false, + + // IntelliSense + "C_Cpp.default.compilerPath": "${userHome}/zephyr-sdk-0.17.1/arm-zephyr-eabi/bin/arm-zephyr-eabi-gcc", + "C_Cpp.default.compileCommands": "${workspaceFolder}/build/compile_commands.json", + + // File Associations + "files.associations": { + "waterlevel_sensor.h": "c", + "shell.h": "c", + "can.h": "c" + } + }, + "tasks": { + "version": "2.0.0", + "tasks": [ + { + "label": "West Build", + "type": "shell", + "group": { + "kind": "build", + "isDefault": true + }, + "command": "${userHome}/zephyrproject/.venv/bin/west", + "args": [ + "build", + "-p", + "auto", + "-b", + "valve_node" + ], + "problemMatcher": [ + "$gcc" + ], + }, + { + "label": "West Configurable Build", + "type": "shell", + "group": { + "kind": "build", + }, + "command": "${userHome}/zephyrproject/.venv/bin/west", + "args": [ + "build", + "-p", + "${input:pristine}", + "-b", + "${input:board}" + ], + "problemMatcher": [ + "$gcc" + ] + }, + { + "label": "West Flash", + "type": "shell", + "command": "${userHome}/zephyrproject/.venv/bin/west", + "args": [ + "flash" + ], + "problemMatcher": [ + "$gcc" + ] + } + ], + "inputs": [ + { + "id": "board", + "type": "promptString", + "default": "vave_node", + "description": "See https://docs.zephyrproject.org/latest/boards/index.html" + }, + { + "id": "pristine", + "type": "pickString", + "description": "Choose when to run a pristine build", + "default": "auto", + "options": [ + "auto", + "always", + "never" + ] + } + ] + }, + "launch": { + "version": "0.2.0", + "configurations": [ + { + "name": "Launch", + "device": "STM32F103RB", + "cwd": "${workspaceFolder}", + "executable": "build/zephyr/zephyr.elf", + "request": "launch", + "type": "cortex-debug", + //"runToEntryPoint": "main", + "servertype": "jlink", + "gdbPath": "${userHome}/zephyr-sdk-0.17.1/arm-zephyr-eabi/bin/arm-zephyr-eabi-gdb", + "preLaunchTask": "West Build" + }, + { + "name": "Attach", + "device": "STM32F103RB", + "cwd": "${workspaceFolder}", + "executable": "build/zephyr/zephyr.elf", + "request": "attach", + "type": "cortex-debug", + //"runToEntryPoint": "main", + "servertype": "jlink", + "gdbPath": "${userHome}/zephyr-sdk-0.17.1/arm-zephyr-eabi/bin/arm-zephyr-eabi-gdb" + }, + ] + }, + "extensions": { + "recommendations": [ + "ms-vscode.cpptools-extension-pack", + "ms-python.python", + "ms-vscode.vscode-embedded-tools", + "ms-vscode.vscode-serial-monitor", + "marus25.cortex-debug", + "donjayamanne.python-environment-manager" + ] + } +}