text:
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE eagle SYSTEM "eagle.dtd">
<eagle version="7.2.0">
<drawing>
<settings>
<setting alwaysvectorfont="no"/>
<setting verticaltext="up"/>
</settings>
<grid distance="0.05" unitdist="inch" unit="inch" style="lines" multiple="2" display="yes" altdistance="0.025" altunitdist="inch" altunit="inch"/>
<layers>
<layer number="1" name="Top" color="4" fill="1" visible="yes" active="yes"/>
<layer number="16" name="Bottom" color="1" fill="1" visible="yes" active="yes"/>
<layer number="17" name="Pads" color="2" fill="1" visible="yes" active="yes"/>
<layer number="18" name="Vias" color="2" fill="1" visible="yes" active="yes"/>
<layer number="19" name="Unrouted" color="6" fill="1" visible="yes" active="yes"/>
<layer number="20" name="Dimension" color="15" fill="1" visible="yes" active="yes"/>
<layer number="21" name="tPlace" color="7" fill="1" visible="yes" active="yes"/>
<layer number="22" name="bPlace" color="7" fill="1" visible="yes" active="yes"/>
<layer number="23" name="tOrigins" color="15" fill="1" visible="yes" active="yes"/>
<layer number="24" name="bOrigins" color="15" fill="1" visible="yes" active="yes"/>
<layer number="25" name="tNames" color="7" fill="1" visible="yes" active="yes"/>
<layer number="26" name="bNames" color="7" fill="1" visible="yes" active="yes"/>
<layer number="27" name="tValues" color="7" fill="1" visible="yes" active="yes"/>
<layer number="28" name="bValues" color="7" fill="1" visible="yes" active="yes"/>
<layer number="29" name="tStop" color="7" fill="3" visible="no" active="yes"/>
<layer number="30" name="bStop" color="7" fill="6" visible="no" active="yes"/>
<layer number="31" name="tCream" color="7" fill="4" visible="no" active="yes"/>
<layer number="32" name="bCream" color="7" fill="5" visible="no" active="yes"/>
<layer number="33" name="tFinish" color="6" fill="3" visible="no" active="yes"/>
<layer number="34" name="bFinish" color="6" fill="6" visible="no" active="yes"/>
<layer number="35" name="tGlue" color="7" fill="4" visible="no" active="yes"/>
<layer number="36" name="bGlue" color="7" fill="5" visible="no" active="yes"/>
<layer number="37" name="tTest" color="7" fill="1" visible="no" active="yes"/>
<layer number="38" name="bTest" color="7" fill="1" visible="no" active="yes"/>
<layer number="39" name="tKeepout" color="4" fill="11" visible="yes" active="yes"/>
<layer number="40" name="bKeepout" color="1" fill="11" visible="yes" active="yes"/>
<layer number="41" name="tRestrict" color="4" fill="10" visible="yes" active="yes"/>
<layer number="42" name="bRestrict" color="1" fill="10" visible="yes" active="yes"/>
<layer number="43" name="vRestrict" color="2" fill="10" visible="yes" active="yes"/>
<layer number="44" name="Drills" color="7" fill="1" visible="no" active="yes"/>
<layer number="45" name="Holes" color="7" fill="1" visible="no" active="yes"/>
<layer number="46" name="Milling" color="3" fill="1" visible="no" active="yes"/>
<layer number="47" name="Measures" color="7" fill="1" visible="no" active="yes"/>
<layer number="48" name="Document" color="7" fill="1" visible="yes" active="yes"/>
<layer number="49" name="Reference" color="7" fill="1" visible="yes" active="yes"/>
<layer number="50" name="dxf" color="7" fill="1" visible="no" active="no"/>
<layer number="51" name="tDocu" color="7" fill="1" visible="yes" active="yes"/>
<layer number="52" name="bDocu" color="7" fill="1" visible="yes" active="yes"/>
<layer number="53" name="tGND_GNDA" color="7" fill="9" visible="no" active="no"/>
<layer number="54" name="bGND_GNDA" color="1" fill="9" visible="no" active="no"/>
<layer number="56" name="wert" color="7" fill="1" visible="no" active="no"/>
<layer number="57" name="tCAD" color="7" fill="1" visible="no" active="no"/>
<layer number="90" name="Modules" color="5" fill="1" visible="no" active="no"/>
<layer number="91" name="Nets" color="2" fill="1" visible="no" active="no"/>
<layer number="92" name="Busses" color="1" fill="1" visible="no" active="no"/>
<layer number="93" name="Pins" color="2" fill="1" visible="no" active="no"/>
<layer number="94" name="Symbols" color="4" fill="1" visible="no" active="no"/>
<layer number="95" name="Names" color="7" fill="1" visible="no" active="no"/>
<layer number="96" name="Values" color="7" fill="1" visible="no" active="no"/>
<layer number="97" name="Info" color="7" fill="1" visible="no" active="no"/>
<layer number="98" name="Guide" color="6" fill="1" visible="no" active="no"/>
<layer number="99" name="SpiceOrder" color="7" fill="1" visible="no" active="no"/>
<layer number="100" name="Muster" color="7" fill="1" visible="no" active="no"/>
<layer number="101" name="Patch_Top" color="12" fill="4" visible="yes" active="yes"/>
<layer number="102" name="Vscore" color="7" fill="1" visible="yes" active="yes"/>
<layer number="103" name="tMap" color="7" fill="1" visible="yes" active="yes"/>
<layer number="104" name="Name" color="16" fill="1" visible="yes" active="yes"/>
<layer number="105" name="tPlate" color="7" fill="1" visible="yes" active="yes"/>
<layer number="106" name="bPlate" color="7" fill="1" visible="yes" active="yes"/>
<layer number="107" name="Crop" color="7" fill="1" visible="yes" active="yes"/>
<layer number="108" name="tplace-old" color="10" fill="1" visible="yes" active="yes"/>
<layer number="109" name="ref-old" color="11" fill="1" visible="yes" active="yes"/>
<layer number="110" name="fp0" color="7" fill="1" visible="yes" active="yes"/>
<layer number="111" name="LPC17xx" color="7" fill="1" visible="yes" active="yes"/>
<layer number="112" name="tSilk" color="7" fill="1" visible="yes" active="yes"/>
<layer number="113" name="IDFDebug" color="7" fill="1" visible="yes" active="yes"/>
<layer number="116" name="Patch_BOT" color="9" fill="4" visible="yes" active="yes"/>
<layer number="121" name="_tsilk" color="7" fill="1" visible="yes" active="yes"/>
<layer number="122" name="_bsilk" color="7" fill="1" visible="yes" active="yes"/>
<layer number="123" name="tTestmark" color="7" fill="1" visible="yes" active="yes"/>
<layer number="124" name="bTestmark" color="7" fill="1" visible="yes" active="yes"/>
<layer number="125" name="_tNames" color="7" fill="1" visible="yes" active="yes"/>
<layer number="126" name="_bNames" color="7" fill="1" visible="yes" active="yes"/>
<layer number="127" name="_tValues" color="7" fill="1" visible="yes" active="yes"/>
<layer number="128" name="_bValues" color="7" fill="1" visible="yes" active="yes"/>
<layer number="131" name="tAdjust" color="7" fill="1" visible="yes" active="yes"/>
<layer number="132" name="bAdjust" color="7" fill="1" visible="yes" active="yes"/>
<layer number="144" name="Drill_legend" color="7" fill="1" visible="yes" active="yes"/>
<layer number="150" name="Notes" color="7" fill="1" visible="yes" active="yes"/>
<layer number="151" name="HeatSink" color="7" fill="1" visible="yes" active="yes"/>
<layer number="152" name="_bDocu" color="7" fill="1" visible="yes" active="yes"/>
<layer number="153" name="FabDoc1" color="7" fill="1" visible="yes" active="yes"/>
<layer number="154" name="FabDoc2" color="7" fill="1" visible="yes" active="yes"/>
<layer number="155" name="FabDoc3" color="7" fill="1" visible="yes" active="yes"/>
<layer number="199" name="Contour" color="7" fill="1" visible="yes" active="yes"/>
<layer number="200" name="200bmp" color="1" fill="10" visible="yes" active="yes"/>
<layer number="201" name="201bmp" color="2" fill="10" visible="yes" active="yes"/>
<layer number="202" name="202bmp" color="3" fill="10" visible="yes" active="yes"/>
<layer number="203" name="203bmp" color="4" fill="10" visible="yes" active="yes"/>
<layer number="204" name="204bmp" color="5" fill="10" visible="yes" active="yes"/>
<layer number="205" name="205bmp" color="6" fill="10" visible="yes" active="yes"/>
<layer number="206" name="206bmp" color="7" fill="10" visible="yes" active="yes"/>
<layer number="207" name="207bmp" color="8" fill="10" visible="yes" active="yes"/>
<layer number="208" name="208bmp" color="9" fill="10" visible="yes" active="yes"/>
<layer number="209" name="209bmp" color="7" fill="1" visible="yes" active="yes"/>
<layer number="210" name="210bmp" color="7" fill="1" visible="yes" active="yes"/>
<layer number="211" name="211bmp" color="7" fill="1" visible="yes" active="yes"/>
<layer number="212" name="212bmp" color="7" fill="1" visible="yes" active="yes"/>
<layer number="213" name="213bmp" color="7" fill="1" visible="yes" active="yes"/>
<layer number="214" name="214bmp" color="7" fill="1" visible="yes" active="yes"/>
<layer number="215" name="215bmp" color="7" fill="1" visible="yes" active="yes"/>
<layer number="216" name="216bmp" color="7" fill="1" visible="yes" active="yes"/>
<layer number="217" name="217bmp" color="18" fill="1" visible="no" active="no"/>
<layer number="218" name="218bmp" color="19" fill="1" visible="no" active="no"/>
<layer number="219" name="219bmp" color="20" fill="1" visible="no" active="no"/>
<layer number="220" name="220bmp" color="21" fill="1" visible="no" active="no"/>
<layer number="221" name="221bmp" color="22" fill="1" visible="no" active="no"/>
<layer number="222" name="222bmp" color="23" fill="1" visible="no" active="no"/>
<layer number="223" name="223bmp" color="24" fill="1" visible="no" active="no"/>
<layer number="224" name="224bmp" color="25" fill="1" visible="no" active="no"/>
<layer number="225" name="FrontBMP" color="7" fill="1" visible="yes" active="yes"/>
<layer number="231" name="Eagle3D_PG1" color="7" fill="1" visible="yes" active="yes"/>
<layer number="232" name="Eagle3D_PG2" color="7" fill="1" visible="yes" active="yes"/>
<layer number="233" name="Eagle3D_PG3" color="7" fill="1" visible="yes" active="yes"/>
<layer number="248" name="Housing" color="7" fill="1" visible="yes" active="yes"/>
<layer number="249" name="Edge" color="7" fill="1" visible="yes" active="yes"/>
<layer number="250" name="Descript" color="3" fill="1" visible="no" active="no"/>
<layer number="251" name="SMDround" color="12" fill="11" visible="no" active="no"/>
<layer number="254" name="cooling" color="7" fill="1" visible="yes" active="yes"/>
<layer number="255" name="routoute" color="7" fill="1" visible="yes" active="yes"/>
</layers>
<board>
<plain>
<wire x1="0" y1="0" x2="100" y2="0" width="0" layer="20"/>
<wire x1="100" y1="0" x2="100" y2="78.73" width="0" layer="20"/>
<wire x1="100" y1="78.73" x2="0" y2="78.73" width="0" layer="20"/>
<wire x1="0" y1="78.73" x2="0" y2="0" width="0" layer="20"/>
</plain>
<libraries>
<library name="SparkFun-Capacitors">
<description>
SparkFun Electronics' preferred foot prints

In this library you'll find resistors, capacitors, inductors, test points, jumper pads, etc.

We've spent an enormous amount of time creating and checking these footprints and parts, but it is the end user's responsibility to ensure correctness and suitablity for a given componet or application. If you enjoy using this library, please buy one of our products at www.sparkfun.com.

Licensing: Creative Commons ShareAlike 4.0 International - https://creativecommons.org/licenses/by-sa/4.0/

You are welcome to use this library for commercial purposes. For attribution, we ask that when you begin to sell your device using our footprint, you email us with a link to the product being sold. We want bragging rights that we helped (in a very small part) to create your 8th world wonder. We would like the opportunity to feature your device on our homepage.</description>
<packages>
<package name="CAP-PTH-SMALL">
<wire x1="1.27" y1="0.635" x2="1.27" y2="-0.635" width="0.2032" layer="21"/>
<pad name="1" x="0" y="0" drill="0.7" diameter="1.651"/>
<pad name="2" x="2.54" y="0" drill="0.7" diameter="1.651"/>
<text x="0.508" y="1.27" size="0.4064" layer="25">>Name</text>
<text x="0.254" y="-1.524" size="0.4064" layer="27">>Value</text>
</package>
<package name="CAP-PTH-SMALL-KIT">
<description>
CAP-PTH-SMALL-KIT

Commonly used for small ceramic capacitors. Like our 0.1uF (http://www.sparkfun.com/products/8375) or 22pF caps (http://www.sparkfun.com/products/8571).

Warning: This is the KIT version of this package. This package has a smaller diameter top stop mask, which doesn't cover the diameter of the pad. This means only the bottom side of the pads' copper will be exposed. You'll only be able to solder to the bottom side.</description>
<wire x1="0" y1="0.635" x2="0" y2="-0.635" width="0.254" layer="21"/>
<wire x1="-2.667" y1="1.27" x2="2.667" y2="1.27" width="0.254" layer="21"/>
<wire x1="2.667" y1="1.27" x2="2.667" y2="-1.27" width="0.254" layer="21"/>
<wire x1="2.667" y1="-1.27" x2="-2.667" y2="-1.27" width="0.254" layer="21"/>
<wire x1="-2.667" y1="-1.27" x2="-2.667" y2="1.27" width="0.254" layer="21"/>
<pad name="1" x="-1.397" y="0" drill="1.016" diameter="2.032" stop="no"/>
<pad name="2" x="1.397" y="0" drill="1.016" diameter="2.032" stop="no"/>
<polygon width="0.127" layer="30">
<vertex x="-1.4021" y="-0.9475" curve="-90"/>
<vertex x="-2.357" y="-0.0178" curve="-90.011749"/>
<vertex x="-1.4046" y="0.9576" curve="-90"/>
<vertex x="-0.4546" y="-0.0204" curve="-90.024193"/>
</polygon>
<polygon width="0.127" layer="29">
<vertex x="-1.4046" y="-0.4395" curve="-90.012891"/>
<vertex x="-1.8491" y="-0.0153" curve="-90"/>
<vertex x="-1.4046" y="0.452" curve="-90"/>
<vertex x="-0.9627" y="-0.0051" curve="-90.012967"/>
</polygon>
<polygon width="0.127" layer="30">
<vertex x="1.397" y="-0.9475" curve="-90"/>
<vertex x="0.4421" y="-0.0178" curve="-90.011749"/>
<vertex x="1.3945" y="0.9576" curve="-90"/>
<vertex x="2.3445" y="-0.0204" curve="-90.024193"/>
</polygon>
<polygon width="0.127" layer="29">
<vertex x="1.3945" y="-0.4395" curve="-90.012891"/>
<vertex x="0.95" y="-0.0153" curve="-90"/>
<vertex x="1.3945" y="0.452" curve="-90"/>
<vertex x="1.8364" y="-0.0051" curve="-90.012967"/>
</polygon>
</package>
<package name="CPOL-RADIAL-10UF-25V">
<wire x1="-0.762" y1="1.397" x2="-1.778" y2="1.397" width="0.2032" layer="21"/>
<circle x="0" y="0" radius="2.5" width="0.2032" layer="21"/>
<pad name="1" x="1.27" y="0" drill="0.7" diameter="1.651" shape="square"/>
<pad name="2" x="-1.27" y="0" drill="0.7" diameter="1.651"/>
<text x="-0.889" y="1.524" size="0.4064" layer="25">>Name</text>
<text x="-1.905" y="-3.683" size="0.8128" layer="27">>Value</text>
</package>
</packages>
</library>
<library name="SparkFun-Connectors">
<description>
SparkFun Electronics' preferred foot prints

In this library you'll find connectors and sockets- basically anything that can be plugged into or onto.

We've spent an enormous amount of time creating and checking these footprints and parts, but it is the end user's responsibility to ensure correctness and suitablity for a given componet or application. If you enjoy using this library, please buy one of our products at www.sparkfun.com.

Licensing: Creative Commons ShareAlike 4.0 International - https://creativecommons.org/licenses/by-sa/4.0/

You are welcome to use this library for commercial purposes. For attribution, we ask that when you begin to sell your device using our footprint, you email us with a link to the product being sold. We want bragging rights that we helped (in a very small part) to create your 8th world wonder. We would like the opportunity to feature your device on our homepage.</description>
<packages>
<package name="2X3-SHROUDED">
<wire x1="-2.775" y1="3.175" x2="-2.775" y2="1.905" width="0.2032" layer="21"/>
<wire x1="4.5" y1="7.56" x2="4.5" y2="-7.56" width="0.2032" layer="21"/>
<wire x1="-4.5" y1="-7.56" x2="-4.5" y2="-2.2" width="0.2032" layer="21"/>
<wire x1="-4.5" y1="-2.2" x2="-4.5" y2="2.2" width="0.2032" layer="21"/>
<wire x1="-4.5" y1="2.2" x2="-4.5" y2="7.56" width="0.2032" layer="21"/>
<wire x1="-4.5" y1="7.56" x2="4.4" y2="7.56" width="0.2032" layer="21"/>
<wire x1="4.5" y1="-7.56" x2="-4.5" y2="-7.56" width="0.2032" layer="21"/>
<wire x1="-3.4" y1="6.46" x2="3.4" y2="6.46" width="0.2032" layer="51"/>
<wire x1="3.4" y1="6.46" x2="3.4" y2="-6.46" width="0.2032" layer="51"/>
<wire x1="-3.4" y1="-6.46" x2="3.4" y2="-6.46" width="0.2032" layer="51"/>
<wire x1="-4.5" y1="2.2" x2="-3" y2="2.2" width="0.2032" layer="21"/>
<wire x1="-3" y1="2.2" x2="-3" y2="-2.2" width="0.2032" layer="21"/>
<wire x1="-3" y1="-2.2" x2="-4.5" y2="-2.2" width="0.2032" layer="21"/>
<wire x1="-3.4" y1="6.46" x2="-3.4" y2="2.2" width="0.2032" layer="51"/>
<wire x1="-3.4" y1="-6.46" x2="-3.4" y2="-2.2" width="0.2032" layer="51"/>
<pad name="1" x="-1.27" y="2.54" drill="1.016" diameter="1.8796" shape="octagon" rot="R270"/>
<pad name="2" x="1.27" y="2.54" drill="1.016" diameter="1.8796" shape="octagon" rot="R270"/>
<pad name="3" x="-1.27" y="0" drill="1.016" diameter="1.8796" shape="octagon" rot="R270"/>
<pad name="4" x="1.27" y="0" drill="1.016" diameter="1.8796" shape="octagon" rot="R270"/>
<pad name="5" x="-1.27" y="-2.54" drill="1.016" diameter="1.8796" shape="octagon" rot="R270"/>
<pad name="6" x="1.27" y="-2.54" drill="1.016" diameter="1.8796" shape="octagon" rot="R270"/>
<text x="-2.921" y="7.874" size="0.4064" layer="27" font="vector">>VALUE</text>
<text x="-2.921" y="-8.382" size="0.4064" layer="25">>NAME</text>
<rectangle x1="1.016" y1="2.286" x2="1.524" y2="2.794" layer="51"/>
<rectangle x1="-1.524" y1="2.286" x2="-1.016" y2="2.794" layer="51"/>
<rectangle x1="1.016" y1="-0.254" x2="1.524" y2="0.254" layer="51"/>
<rectangle x1="-1.524" y1="-0.254" x2="-1.016" y2="0.254" layer="51"/>
<rectangle x1="1.016" y1="-2.794" x2="1.524" y2="-2.286" layer="51"/>
<rectangle x1="-1.524" y1="-2.794" x2="-1.016" y2="-2.286" layer="51"/>
<rectangle x1="-1.524" y1="-2.794" x2="-1.016" y2="-2.286" layer="51"/>
<rectangle x1="1.016" y1="-2.794" x2="1.524" y2="-2.286" layer="51"/>
</package>
<package name="1X06">
<wire x1="11.43" y1="0.635" x2="12.065" y2="1.27" width="0.2032" layer="21"/>
<wire x1="12.065" y1="1.27" x2="13.335" y2="1.27" width="0.2032" layer="21"/>
<wire x1="13.335" y1="1.27" x2="13.97" y2="0.635" width="0.2032" layer="21"/>
<wire x1="13.97" y1="-0.635" x2="13.335" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="13.335" y1="-1.27" x2="12.065" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="12.065" y1="-1.27" x2="11.43" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="6.985" y1="1.27" x2="8.255" y2="1.27" width="0.2032" layer="21"/>
<wire x1="8.255" y1="1.27" x2="8.89" y2="0.635" width="0.2032" layer="21"/>
<wire x1="8.89" y1="-0.635" x2="8.255" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="8.89" y1="0.635" x2="9.525" y2="1.27" width="0.2032" layer="21"/>
<wire x1="9.525" y1="1.27" x2="10.795" y2="1.27" width="0.2032" layer="21"/>
<wire x1="10.795" y1="1.27" x2="11.43" y2="0.635" width="0.2032" layer="21"/>
<wire x1="11.43" y1="-0.635" x2="10.795" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="10.795" y1="-1.27" x2="9.525" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="9.525" y1="-1.27" x2="8.89" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="3.81" y1="0.635" x2="4.445" y2="1.27" width="0.2032" layer="21"/>
<wire x1="4.445" y1="1.27" x2="5.715" y2="1.27" width="0.2032" layer="21"/>
<wire x1="5.715" y1="1.27" x2="6.35" y2="0.635" width="0.2032" layer="21"/>
<wire x1="6.35" y1="-0.635" x2="5.715" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="5.715" y1="-1.27" x2="4.445" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="4.445" y1="-1.27" x2="3.81" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="6.985" y1="1.27" x2="6.35" y2="0.635" width="0.2032" layer="21"/>
<wire x1="6.35" y1="-0.635" x2="6.985" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="8.255" y1="-1.27" x2="6.985" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="-0.635" y1="1.27" x2="0.635" y2="1.27" width="0.2032" layer="21"/>
<wire x1="0.635" y1="1.27" x2="1.27" y2="0.635" width="0.2032" layer="21"/>
<wire x1="1.27" y1="-0.635" x2="0.635" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="1.27" y1="0.635" x2="1.905" y2="1.27" width="0.2032" layer="21"/>
<wire x1="1.905" y1="1.27" x2="3.175" y2="1.27" width="0.2032" layer="21"/>
<wire x1="3.175" y1="1.27" x2="3.81" y2="0.635" width="0.2032" layer="21"/>
<wire x1="3.81" y1="-0.635" x2="3.175" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="3.175" y1="-1.27" x2="1.905" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="1.905" y1="-1.27" x2="1.27" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="-1.27" y1="0.635" x2="-1.27" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="-0.635" y1="1.27" x2="-1.27" y2="0.635" width="0.2032" layer="21"/>
<wire x1="-1.27" y1="-0.635" x2="-0.635" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="0.635" y1="-1.27" x2="-0.635" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="13.97" y1="0.635" x2="13.97" y2="-0.635" width="0.2032" layer="21"/>
<pad name="1" x="0" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="2" x="2.54" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="3" x="5.08" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="4" x="7.62" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="5" x="10.16" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="6" x="12.7" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<text x="-1.3462" y="1.8288" size="1.27" layer="25" ratio="10">>NAME</text>
<text x="-1.27" y="-3.175" size="1.27" layer="27">>VALUE</text>
<rectangle x1="12.446" y1="-0.254" x2="12.954" y2="0.254" layer="51"/>
<rectangle x1="9.906" y1="-0.254" x2="10.414" y2="0.254" layer="51"/>
<rectangle x1="7.366" y1="-0.254" x2="7.874" y2="0.254" layer="51"/>
<rectangle x1="4.826" y1="-0.254" x2="5.334" y2="0.254" layer="51"/>
<rectangle x1="2.286" y1="-0.254" x2="2.794" y2="0.254" layer="51"/>
<rectangle x1="-0.254" y1="-0.254" x2="0.254" y2="0.254" layer="51"/>
</package>
<package name="1X08">
<wire x1="14.605" y1="1.27" x2="15.875" y2="1.27" width="0.2032" layer="21"/>
<wire x1="15.875" y1="1.27" x2="16.51" y2="0.635" width="0.2032" layer="21"/>
<wire x1="16.51" y1="-0.635" x2="15.875" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="11.43" y1="0.635" x2="12.065" y2="1.27" width="0.2032" layer="21"/>
<wire x1="12.065" y1="1.27" x2="13.335" y2="1.27" width="0.2032" layer="21"/>
<wire x1="13.335" y1="1.27" x2="13.97" y2="0.635" width="0.2032" layer="21"/>
<wire x1="13.97" y1="-0.635" x2="13.335" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="13.335" y1="-1.27" x2="12.065" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="12.065" y1="-1.27" x2="11.43" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="14.605" y1="1.27" x2="13.97" y2="0.635" width="0.2032" layer="21"/>
<wire x1="13.97" y1="-0.635" x2="14.605" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="15.875" y1="-1.27" x2="14.605" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="6.985" y1="1.27" x2="8.255" y2="1.27" width="0.2032" layer="21"/>
<wire x1="8.255" y1="1.27" x2="8.89" y2="0.635" width="0.2032" layer="21"/>
<wire x1="8.89" y1="-0.635" x2="8.255" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="8.89" y1="0.635" x2="9.525" y2="1.27" width="0.2032" layer="21"/>
<wire x1="9.525" y1="1.27" x2="10.795" y2="1.27" width="0.2032" layer="21"/>
<wire x1="10.795" y1="1.27" x2="11.43" y2="0.635" width="0.2032" layer="21"/>
<wire x1="11.43" y1="-0.635" x2="10.795" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="10.795" y1="-1.27" x2="9.525" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="9.525" y1="-1.27" x2="8.89" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="3.81" y1="0.635" x2="4.445" y2="1.27" width="0.2032" layer="21"/>
<wire x1="4.445" y1="1.27" x2="5.715" y2="1.27" width="0.2032" layer="21"/>
<wire x1="5.715" y1="1.27" x2="6.35" y2="0.635" width="0.2032" layer="21"/>
<wire x1="6.35" y1="-0.635" x2="5.715" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="5.715" y1="-1.27" x2="4.445" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="4.445" y1="-1.27" x2="3.81" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="6.985" y1="1.27" x2="6.35" y2="0.635" width="0.2032" layer="21"/>
<wire x1="6.35" y1="-0.635" x2="6.985" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="8.255" y1="-1.27" x2="6.985" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="-0.635" y1="1.27" x2="0.635" y2="1.27" width="0.2032" layer="21"/>
<wire x1="0.635" y1="1.27" x2="1.27" y2="0.635" width="0.2032" layer="21"/>
<wire x1="1.27" y1="-0.635" x2="0.635" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="1.27" y1="0.635" x2="1.905" y2="1.27" width="0.2032" layer="21"/>
<wire x1="1.905" y1="1.27" x2="3.175" y2="1.27" width="0.2032" layer="21"/>
<wire x1="3.175" y1="1.27" x2="3.81" y2="0.635" width="0.2032" layer="21"/>
<wire x1="3.81" y1="-0.635" x2="3.175" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="3.175" y1="-1.27" x2="1.905" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="1.905" y1="-1.27" x2="1.27" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="-1.27" y1="0.635" x2="-1.27" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="-0.635" y1="1.27" x2="-1.27" y2="0.635" width="0.2032" layer="21"/>
<wire x1="-1.27" y1="-0.635" x2="-0.635" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="0.635" y1="-1.27" x2="-0.635" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="17.145" y1="1.27" x2="18.415" y2="1.27" width="0.2032" layer="21"/>
<wire x1="18.415" y1="1.27" x2="19.05" y2="0.635" width="0.2032" layer="21"/>
<wire x1="19.05" y1="0.635" x2="19.05" y2="-0.635" width="0.2032" layer="21"/>
<wire x1="19.05" y1="-0.635" x2="18.415" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="17.145" y1="1.27" x2="16.51" y2="0.635" width="0.2032" layer="21"/>
<wire x1="16.51" y1="-0.635" x2="17.145" y2="-1.27" width="0.2032" layer="21"/>
<wire x1="18.415" y1="-1.27" x2="17.145" y2="-1.27" width="0.2032" layer="21"/>
<pad name="1" x="0" y="0" drill="1.016" diameter="1.8796" shape="square" rot="R90"/>
<pad name="2" x="2.54" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="3" x="5.08" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="4" x="7.62" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="5" x="10.16" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="6" x="12.7" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="7" x="15.24" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<pad name="8" x="17.78" y="0" drill="1.016" diameter="1.8796" rot="R90"/>
<text x="-1.3462" y="1.8288" size="1.27" layer="25" ratio="10">>NAME</text>
<text x="-1.27" y="-3.175" size="1.27" layer="27">>VALUE</text>
<rectangle x1="14.986" y1="-0.254" x2="15.494" y2="0.254" layer="51"/>
<rectangle x1="12.446" y1="-0.254" x2="12.954" y2="0.254" layer="51"/>
<rectangle x1="9.906" y1="-0.254" x2="10.414" y2="0.254" layer="51"/>
<rectangle x1="7.366" y1="-0.254" x2="7.874" y2="0.254" layer="51"/>
<rectangle x1="4.826" y1="-0.254" x2="5.334" y2="0.254" layer="51"/>
<rectangle x1="2.286" y1="-0.254" x2="2.794" y2="0.254" layer="51"/>
<rectangle x1="-0.254" y1="-0.254" x2="0.254" y2="0.254" layer="51"/>
<rectangle x1="17.526" y1="-0.254" x2="18.034" y2="0.254" layer="51"/>
</package>
</packages>
</library>
<library name="SparkFun-Resistors">
<description>
SparkFun Electronics' preferred foot prints

In this library you'll find resistors, capacitors, inductors, test points, jumper pads, etc.

We've spent an enormous amount of time creating and checking these footprints and parts, but it is the end user's responsibility to ensure correctness and suitablity for a given componet or application. If you enjoy using this library, please buy one of our products at www.sparkfun.com.

Licensing: Creative Commons ShareAlike 4.0 International - https://creativecommons.org/licenses/by-sa/4.0/

You are welcome to use this library for commercial purposes. For attribution, we ask that when you begin to sell your device using our footprint, you email us with a link to the product being sold. We want bragging rights that we helped (in a very small part) to create your 8th world wonder. We would like the opportunity to feature your device on our homepage.</description>
<packages>
<package name="AXIAL-0.1EZ">
<wire x1="1.27" y1="-0.762" x2="1.27" y2="0" width="0.2032" layer="21"/>
<wire x1="1.27" y1="0" x2="1.27" y2="0.762" width="0.2032" layer="21"/>
<wire x1="1.524" y1="0" x2="1.27" y2="0" width="0.2032" layer="21"/>
<wire x1="1.27" y1="0" x2="1.016" y2="0" width="0.2032" layer="21"/>
<pad name="P$1" x="0" y="0" drill="0.9" diameter="1.8796" stop="no"/>
<pad name="P$2" x="2.54" y="0" drill="0.9" diameter="1.8796" stop="no"/>
<text x="0" y="1.27" size="1.016" layer="25" font="vector" ratio="15">>Name</text>
<text x="0" y="-2.159" size="1.016" layer="21" font="vector" ratio="15">>Value</text>
<circle x="0" y="0" radius="0.4572" width="0" layer="29"/>
<circle x="0" y="0" radius="1.016" width="0" layer="30"/>
<circle x="2.54" y="0" radius="1.016" width="0" layer="30"/>
<circle x="0" y="0" radius="0.4572" width="0" layer="29"/>
<circle x="2.54" y="0" radius="0.4572" width="0" layer="29"/>
</package>
</packages>
</library>
<library name="SparkFun-DigitalIC">
<description>
SparkFun Electronics' preferred foot prints

In this library you'll find all manner of digital ICs- microcontrollers, memory chips, logic chips, FPGAs, etc.

We've spent an enormous amount of time creating and checking these footprints and parts, but it is the end user's responsibility to ensure correctness and suitablity for a given componet or application. If you enjoy using this library, please buy one of our products at www.sparkfun.com.

Licensing: Creative Commons ShareAlike 4.0 International - https://creativecommons.org/licenses/by-sa/4.0/

You are welcome to use this library for commercial purposes. For attribution, we ask that when you begin to sell your device using our footprint, you email us with a link to the product being sold. We want bragging rights that we helped (in a very small part) to create your 8th world wonder. We would like the opportunity to feature your device on our homepage.</description>
<packages>
<package name="DIL28-3">
<description>Standard 28-pin DIP package.

IC needs to have legs bent before insertion.</description>
<wire x1="-17.78" y1="-1.27" x2="-17.78" y2="-3.048" width="0.2032" layer="21"/>
<wire x1="-17.78" y1="-1.27" x2="-17.78" y2="1.27" width="0.2032" layer="21" curve="180"/>
<wire x1="17.78" y1="-3.048" x2="17.78" y2="3.048" width="0.2032" layer="21"/>
<wire x1="-17.78" y1="3.048" x2="-17.78" y2="1.27" width="0.2032" layer="21"/>
<wire x1="-17.78" y1="3.048" x2="-17.526" y2="3.048" width="0.2032" layer="21"/>
<wire x1="-17.78" y1="-3.048" x2="-17.526" y2="-3.048" width="0.2032" layer="21"/>
<wire x1="17.78" y1="-3.048" x2="17.526" y2="-3.048" width="0.2032" layer="21"/>
<wire x1="17.78" y1="3.048" x2="17.526" y2="3.048" width="0.2032" layer="21"/>
<pad name="1" x="-16.51" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="2" x="-13.97" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="3" x="-11.43" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="4" x="-8.89" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="5" x="-6.35" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="6" x="-3.81" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="7" x="-1.27" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="8" x="1.27" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="9" x="3.81" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="10" x="6.35" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="11" x="8.89" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="12" x="11.43" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="13" x="13.97" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="14" x="16.51" y="-3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="15" x="16.51" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="16" x="13.97" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="17" x="11.43" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="18" x="8.89" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="19" x="6.35" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="20" x="3.81" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="21" x="1.27" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="22" x="-1.27" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="23" x="-3.81" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="24" x="-6.35" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="25" x="-8.89" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="26" x="-11.43" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="27" x="-13.97" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<pad name="28" x="-16.51" y="3.81" drill="0.8128" shape="long" rot="R90"/>
<text x="-15.24" y="0" size="0.6096" layer="25" ratio="10">>NAME</text>
<text x="-15.24" y="-1.27" size="0.6096" layer="27" ratio="10">>VALUE</text>
</package>
</packages>
</library>
<library name="SparkFun-FreqCtrl">
<description>
SparkFun Electronics' preferred foot prints

In this library you'll find crystals and oscillators and other things that go "tick".

We've spent an enormous amount of time creating and checking these footprints and parts, but it is the end user's responsibility to ensure correctness and suitablity for a given componet or application. If you enjoy using this library, please buy one of our products at www.sparkfun.com.

Licensing: Creative Commons ShareAlike 4.0 International - https://creativecommons.org/licenses/by-sa/4.0/

You are welcome to use this library for commercial purposes. For attribution, we ask that when you begin to sell your device using our footprint, you email us with a link to the product being sold. We want bragging rights that we helped (in a very small part) to create your 8th world wonder. We would like the opportunity to feature your device on our homepage.</description>
<packages>
<package name="HC49US">
<description>CRYSTAL</description>
<wire x1="-3.429" y1="-2.286" x2="3.429" y2="-2.286" width="0.2032" layer="21"/>
<wire x1="3.429" y1="2.286" x2="-3.429" y2="2.286" width="0.2032" layer="21"/>
<wire x1="3.429" y1="2.286" x2="3.429" y2="-2.286" width="0.2032" layer="21" curve="-180"/>
<wire x1="-3.429" y1="2.286" x2="-3.429" y2="-2.286" width="0.2032" layer="21" curve="180"/>
<pad name="1" x="-2.54" y="0" drill="0.7" diameter="1.651" rot="R90"/>
<pad name="2" x="2.54" y="0" drill="0.7" diameter="1.651" rot="R90"/>
<text x="-5.08" y="-3.937" size="1.27" layer="27" ratio="10">>VALUE</text>
<text x="-5.08" y="2.667" size="1.27" layer="25" ratio="10">>NAME</text>
</package>
</packages>
</library>
<library name="RBBB">
<description>Generated from ByteseekerMini.sch

by exp-project-lbr.ulp</description>
<packages>
<package name="L4931_REGULATOR">
<description>VOLTAGE REGULATOR</description>
<wire x1="4.826" y1="-4.318" x2="5.08" y2="-4.064" width="0.1524" layer="21"/>
<wire x1="4.826" y1="-4.318" x2="-4.826" y2="-4.318" width="0.1524" layer="21"/>
<wire x1="-5.08" y1="-4.064" x2="-4.826" y2="-4.318" width="0.1524" layer="21"/>
<wire x1="5.08" y1="-1.143" x2="5.08" y2="-4.064" width="0.1524" layer="21"/>
<wire x1="-5.08" y1="-4.064" x2="-5.08" y2="-1.143" width="0.1524" layer="21"/>
<circle x="-4.6228" y="-3.7084" radius="0.254" width="0" layer="21"/>
<pad name="IN" x="-2.54" y="-2.54" drill="1.016" shape="long" rot="R90"/>
<pad name="GND" x="0" y="-2.54" drill="1.016" shape="long" rot="R90"/>
<pad name="OUT" x="2.54" y="-2.54" drill="1.016" shape="long" rot="R90"/>
<text x="-5.08" y="-6.0452" size="1.27" layer="25" ratio="10">>NAME</text>
<text x="-5.08" y="-7.62" size="1.27" layer="27" ratio="10">>VALUE</text>
<text x="-0.635" y="-3.81" size="1.27" layer="51" ratio="10">-</text>
<text x="-3.175" y="-3.81" size="1.27" layer="51" ratio="10">I</text>
<text x="1.905" y="-3.81" size="1.27" layer="51" ratio="10">O</text>
<rectangle x1="-5.334" y1="-1.27" x2="-3.429" y2="0" layer="21"/>
<rectangle x1="-3.429" y1="-0.762" x2="-1.651" y2="0" layer="21"/>
<rectangle x1="-1.651" y1="-1.27" x2="-0.889" y2="0" layer="21"/>
<rectangle x1="-0.889" y1="-0.762" x2="0.889" y2="0" layer="21"/>
<rectangle x1="0.889" y1="-1.27" x2="1.651" y2="0" layer="21"/>
<rectangle x1="1.651" y1="-0.762" x2="3.429" y2="0" layer="21"/>
<rectangle x1="3.429" y1="-1.27" x2="5.334" y2="0" layer="21"/>
<rectangle x1="-3.429" y1="-1.27" x2="-1.651" y2="-0.762" layer="51"/>
<rectangle x1="-0.889" y1="-1.27" x2="0.889" y2="-0.762" layer="51"/>
<rectangle x1="1.651" y1="-1.27" x2="3.429" y2="-0.762" layer="51"/>
</package>
<package name="POWER_JACK">
<wire x1="4.5" y1="13.7" x2="1.765" y2="13.7" width="0.2032" layer="21"/>
<wire x1="-4.5" y1="3" x2="-4.5" y2="0.1" width="0.2032" layer="51"/>
<wire x1="4.5" y1="0.1" x2="4.5" y2="3" width="0.2032" layer="51"/>
<wire x1="4.5" y1="0.1" x2="-4.5" y2="0.1" width="0.2032" layer="51"/>
<wire x1="4.5" y1="0.206" x2="4.5" y2="9.062" width="0.2032" layer="21"/>
<wire x1="4.5" y1="13.7" x2="4.5" y2="12.238" width="0.2032" layer="21"/>
<wire x1="-4.5" y1="0.206" x2="-4.5" y2="13.7" width="0.2032" layer="21"/>
<wire x1="-4.5" y1="13.7" x2="-1.765" y2="13.7" width="0.2032" layer="21"/>
<wire x1="-4.5" y1="0.206" x2="4.5" y2="0.206" width="0.2032" layer="21"/>
<pad name="GND" x="0" y="7.7" drill="1.3208" diameter="2.794"/>
<pad name="GNDBREAK" x="4.7" y="10.7" drill="1.3208" diameter="2.794" rot="R90"/>
<pad name="PWR" x="0" y="13.7" drill="1.3208" diameter="2.794"/>
<text x="-3.81" y="5.08" size="0.4064" layer="25">>NAME</text>
<text x="-3.81" y="3.81" size="0.4064" layer="27">>VALUE</text>
</package>
</packages>
</library>
<library name="SparkFun-DiscreteSemi">
<description>
SparkFun Electronics' preferred foot prints

In this library you'll find discrete semiconductors- transistors, diodes, TRIACs, optoisolators, etc.

We've spent an enormous amount of time creating and checking these footprints and parts, but it is the end user's responsibility to ensure correctness and suitablity for a given componet or application. If you enjoy using this library, please buy one of our products at www.sparkfun.com.

Licensing: Creative Commons ShareAlike 4.0 International - https://creativecommons.org/licenses/by-sa/4.0/

You are welcome to use this library for commercial purposes. For attribution, we ask that when you begin to sell your device using our footprint, you email us with a link to the product being sold. We want bragging rights that we helped (in a very small part) to create your 8th world wonder. We would like the opportunity to feature your device on our homepage.</description>
<packages>
<package name="TO-92-AMMO">
<wire x1="-2.0946" y1="-1.651" x2="-0.7863" y2="2.5485" width="0.2032" layer="21" curve="-111.098957" cap="flat"/>
<wire x1="0.7863" y1="2.5484" x2="2.0945" y2="-1.651" width="0.2032" layer="21" curve="-111.09954" cap="flat"/>
<wire x1="-2.0945" y1="-1.651" x2="2.0945" y2="-1.651" width="0.2032" layer="21"/>
<wire x1="-0.635" y1="2.54" x2="0.635" y2="2.54" width="0.2032" layer="21" curve="-25.057615"/>
<wire x1="0.635" y1="2.54" x2="1.905" y2="1.905" width="0.2032" layer="21" curve="-28.072487"/>
<wire x1="-1.905" y1="1.905" x2="0.635" y2="2.54" width="0.2032" layer="21" curve="-53.130102"/>
<pad name="3" x="2.54" y="0" drill="0.8128" diameter="1.8796"/>
<pad name="2" x="0" y="0" drill="0.8128" diameter="1.8796"/>
<pad name="1" x="-2.54" y="0" drill="0.8128" diameter="1.8796"/>
<text x="3.175" y="1.905" size="0.4064" layer="25" ratio="10">>NAME</text>
<text x="3.175" y="-1.905" size="0.4064" layer="27" ratio="10">>VALUE</text>
</package>
</packages>
</library>
<library name="led">
<description>LEDs

<author>Created by librarian@cadsoft.de</author>

Extended by Federico Battaglin <author>&lt;federico.rd@fdpinternational.com&gt;</author> with DUOLED</description>
<packages>
<package name="SFH482">
<description>IR LED

infrared emitting diode, Infineon
TO-18, lead spacing 2.54 mm, cathode marking

Inifineon</description>
<wire x1="-2.159" y1="1.524" x2="-2.794" y2="2.159" width="0.1524" layer="21"/>
<wire x1="-2.794" y1="2.159" x2="-2.159" y2="2.794" width="0.1524" layer="21"/>
<wire x1="-1.524" y1="2.159" x2="-2.159" y2="2.794" width="0.1524" layer="21"/>
<wire x1="0" y1="1.778" x2="1.5358" y2="0.8959" width="0.1524" layer="21" curve="-59.743278"/>
<wire x1="-1.5358" y1="0.8959" x2="0" y2="1.778" width="0.1524" layer="21" curve="-59.743278"/>
<wire x1="-1.5358" y1="-0.8959" x2="0" y2="-1.778" width="0.1524" layer="21" curve="59.743278"/>
<wire x1="0" y1="-1.778" x2="1.5358" y2="-0.8959" width="0.1524" layer="21" curve="59.743278"/>
<wire x1="1.5142" y1="0.9318" x2="1.778" y2="0" width="0.1524" layer="51" curve="-31.606487"/>
<wire x1="1.5" y1="-0.9546" x2="1.778" y2="0" width="0.1524" layer="51" curve="32.472615"/>
<wire x1="-1.778" y1="0" x2="-1.5142" y2="-0.9318" width="0.1524" layer="51" curve="31.606487"/>
<wire x1="-1.778" y1="0" x2="-1.5" y2="0.9546" width="0.1524" layer="51" curve="-32.472615"/>
<wire x1="-0.635" y1="0" x2="0" y2="0.635" width="0.1524" layer="51" curve="-90"/>
<wire x1="-1.016" y1="0" x2="0" y2="1.016" width="0.1524" layer="51" curve="-90"/>
<wire x1="0" y1="-0.635" x2="0.635" y2="0" width="0.1524" layer="51" curve="90"/>
<wire x1="0.0539" y1="-1.0699" x2="1.0699" y2="-0.0539" width="0.1524" layer="51" curve="90"/>
<circle x="0" y="0" radius="2.667" width="0.1524" layer="21"/>
<circle x="0" y="0" radius="2.413" width="0.254" layer="21"/>
<pad name="K" x="1.27" y="0" drill="0.8128" shape="long" rot="R90"/>
<pad name="A" x="-1.27" y="0" drill="0.8128" shape="long" rot="R90"/>
<text x="-1.27" y="3.048" size="1.27" layer="25" ratio="10">>NAME</text>
<text x="-1.27" y="-4.318" size="1.27" layer="27" ratio="10">>VALUE</text>
</package>
<package name="LED5MM">
<description>LED

5 mm, round</description>
<wire x1="2.54" y1="-1.905" x2="2.54" y2="1.905" width="0.2032" layer="21"/>
<wire x1="2.54" y1="-1.905" x2="2.54" y2="1.905" width="0.254" layer="21" curve="-286.260205"/>
<wire x1="-1.143" y1="0" x2="0" y2="1.143" width="0.1524" layer="51" curve="-90"/>
<wire x1="0" y1="-1.143" x2="1.143" y2="0" width="0.1524" layer="51" curve="90"/>
<wire x1="-1.651" y1="0" x2="0" y2="1.651" width="0.1524" layer="51" curve="-90"/>
<wire x1="0" y1="-1.651" x2="1.651" y2="0" width="0.1524" layer="51" curve="90"/>
<wire x1="-2.159" y1="0" x2="0" y2="2.159" width="0.1524" layer="51" curve="-90"/>
<wire x1="0" y1="-2.159" x2="2.159" y2="0" width="0.1524" layer="51" curve="90"/>
<circle x="0" y="0" radius="2.54" width="0.1524" layer="21"/>
<pad name="A" x="-1.27" y="0" drill="0.8128" shape="octagon"/>
<pad name="K" x="1.27" y="0" drill="0.8128" shape="octagon"/>
<text x="3.175" y="0.5334" size="1.27" layer="25" ratio="10">>NAME</text>
<text x="3.2004" y="-1.8034" size="1.27" layer="27" ratio="10">>VALUE</text>
</package>
</packages>
</library>
</libraries>
<attributes>
</attributes>
<variantdefs>
</variantdefs>
<classes>
<class number="0" name="default" width="0" drill="0">
</class>
</classes>
<designrules name="default">
<description language="de">EAGLE Design Rules

Die Standard-Design-Rules sind so gewählt, dass sie für
die meisten Anwendungen passen. Sollte ihre Platine
besondere Anforderungen haben, treffen Sie die erforderlichen
Einstellungen hier und speichern die Design Rules unter
einem neuen Namen ab.</description>
<description language="en">EAGLE Design Rules

The default Design Rules have been set to cover
a wide range of applications. Your particular design
may have different requirements, so please make the
necessary adjustments and save your customized
design rules under a new name.</description>
<param name="layerSetup" value="(1*16)"/>
<param name="mtCopper" value="0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm 0.035mm"/>
<param name="mtIsolate" value="1.5mm 0.15mm 0.2mm 0.15mm 0.2mm 0.15mm 0.2mm 0.15mm 0.2mm 0.15mm 0.2mm 0.15mm 0.2mm 0.15mm 0.2mm"/>
<param name="mdWireWire" value="8mil"/>
<param name="mdWirePad" value="8mil"/>
<param name="mdWireVia" value="8mil"/>
<param name="mdPadPad" value="8mil"/>
<param name="mdPadVia" value="8mil"/>
<param name="mdViaVia" value="8mil"/>
<param name="mdSmdPad" value="8mil"/>
<param name="mdSmdVia" value="8mil"/>
<param name="mdSmdSmd" value="8mil"/>
<param name="mdViaViaSameLayer" value="8mil"/>
<param name="mnLayersViaInSmd" value="2"/>
<param name="mdCopperDimension" value="40mil"/>
<param name="mdDrill" value="8mil"/>
<param name="mdSmdStop" value="0mil"/>
<param name="msWidth" value="10mil"/>
<param name="msDrill" value="24mil"/>
<param name="msMicroVia" value="9.99mm"/>
<param name="msBlindViaRatio" value="0.5"/>
<param name="rvPadTop" value="0.25"/>
<param name="rvPadInner" value="0.25"/>
<param name="rvPadBottom" value="0.25"/>
<param name="rvViaOuter" value="0.25"/>
<param name="rvViaInner" value="0.25"/>
<param name="rvMicroViaOuter" value="0.25"/>
<param name="rvMicroViaInner" value="0.25"/>
<param name="rlMinPadTop" value="10mil"/>
<param name="rlMaxPadTop" value="20mil"/>
<param name="rlMinPadInner" value="10mil"/>
<param name="rlMaxPadInner" value="20mil"/>
<param name="rlMinPadBottom" value="10mil"/>
<param name="rlMaxPadBottom" value="20mil"/>
<param name="rlMinViaOuter" value="8mil"/>
<param name="rlMaxViaOuter" value="20mil"/>
<param name="rlMinViaInner" value="8mil"/>
<param name="rlMaxViaInner" value="20mil"/>
<param name="rlMinMicroViaOuter" value="4mil"/>
<param name="rlMaxMicroViaOuter" value="20mil"/>
<param name="rlMinMicroViaInner" value="4mil"/>
<param name="rlMaxMicroViaInner" value="20mil"/>
<param name="psTop" value="-1"/>
<param name="psBottom" value="-1"/>
<param name="psFirst" value="-1"/>
<param name="psElongationLong" value="100"/>
<param name="psElongationOffset" value="100"/>
<param name="mvStopFrame" value="1"/>
<param name="mvCreamFrame" value="0"/>
<param name="mlMinStopFrame" value="4mil"/>
<param name="mlMaxStopFrame" value="4mil"/>
<param name="mlMinCreamFrame" value="0mil"/>
<param name="mlMaxCreamFrame" value="0mil"/>
<param name="mlViaStopLimit" value="0mil"/>
<param name="srRoundness" value="0"/>
<param name="srMinRoundness" value="0mil"/>
<param name="srMaxRoundness" value="0mil"/>
<param name="slThermalIsolate" value="10mil"/>
<param name="slThermalsForVias" value="0"/>
<param name="dpMaxLengthDifference" value="10mm"/>
<param name="dpGapFactor" value="2.5"/>
<param name="checkGrid" value="0"/>
<param name="checkAngle" value="0"/>
<param name="checkFont" value="1"/>
<param name="checkRestrict" value="1"/>
<param name="useDiameter" value="13"/>
<param name="maxErrors" value="50"/>
</designrules>
<autorouter>
<pass name="Default">
<param name="RoutingGrid" value="50mil"/>
<param name="AutoGrid" value="1"/>
<param name="Efforts" value="1"/>
<param name="TopRouterVariant" value="1"/>
<param name="tpViaShape" value="round"/>
<param name="PrefDir.1" value="-"/>
<param name="PrefDir.2" value="0"/>
<param name="PrefDir.3" value="0"/>
<param name="PrefDir.4" value="0"/>
<param name="PrefDir.5" value="0"/>
<param name="PrefDir.6" value="0"/>
<param name="PrefDir.7" value="0"/>
<param name="PrefDir.8" value="0"/>
<param name="PrefDir.9" value="0"/>
<param name="PrefDir.10" value="0"/>
<param name="PrefDir.11" value="0"/>
<param name="PrefDir.12" value="0"/>
<param name="PrefDir.13" value="0"/>
<param name="PrefDir.14" value="0"/>
<param name="PrefDir.15" value="0"/>
<param name="PrefDir.16" value="|"/>
<param name="cfVia" value="8"/>
<param name="cfNonPref" value="5"/>
<param name="cfChangeDir" value="2"/>
<param name="cfOrthStep" value="2"/>
<param name="cfDiagStep" value="3"/>
<param name="cfExtdStep" value="0"/>
<param name="cfBonusStep" value="1"/>
<param name="cfMalusStep" value="1"/>
<param name="cfPadImpact" value="4"/>
<param name="cfSmdImpact" value="4"/>
<param name="cfBusImpact" value="0"/>
<param name="cfHugging" value="3"/>
<param name="cfAvoid" value="4"/>
<param name="cfPolygon" value="10"/>
<param name="cfBase.1" value="0"/>
<param name="cfBase.2" value="1"/>
<param name="cfBase.3" value="1"/>
<param name="cfBase.4" value="1"/>
<param name="cfBase.5" value="1"/>
<param name="cfBase.6" value="1"/>
<param name="cfBase.7" value="1"/>
<param name="cfBase.8" value="1"/>
<param name="cfBase.9" value="1"/>
<param name="cfBase.10" value="1"/>
<param name="cfBase.11" value="1"/>
<param name="cfBase.12" value="1"/>
<param name="cfBase.13" value="1"/>
<param name="cfBase.14" value="1"/>
<param name="cfBase.15" value="1"/>
<param name="cfBase.16" value="0"/>
<param name="mnVias" value="20"/>
<param name="mnSegments" value="9999"/>
<param name="mnExtdSteps" value="9999"/>
<param name="mnRipupLevel" value="10"/>
<param name="mnRipupSteps" value="100"/>
<param name="mnRipupTotal" value="100"/>
</pass>
<pass name="Follow-me" refer="Default" active="yes">
</pass>
<pass name="Busses" refer="Default" active="yes">
<param name="cfNonPref" value="4"/>
<param name="cfBusImpact" value="4"/>
<param name="cfHugging" value="0"/>
<param name="mnVias" value="0"/>
</pass>
<pass name="Route" refer="Default" active="yes">
</pass>
<pass name="Optimize1" refer="Default" active="yes">
<param name="cfVia" value="99"/>
<param name="cfExtdStep" value="10"/>
<param name="cfHugging" value="1"/>
<param name="mnExtdSteps" value="1"/>
<param name="mnRipupLevel" value="0"/>
</pass>
<pass name="Optimize2" refer="Optimize1" active="yes">
<param name="cfNonPref" value="0"/>
<param name="cfChangeDir" value="6"/>
<param name="cfExtdStep" value="0"/>
<param name="cfBonusStep" value="2"/>
<param name="cfMalusStep" value="2"/>
<param name="cfPadImpact" value="2"/>
<param name="cfSmdImpact" value="2"/>
<param name="cfHugging" value="0"/>
</pass>
<pass name="Optimize3" refer="Optimize2" active="yes">
<param name="cfChangeDir" value="8"/>
<param name="cfPadImpact" value="0"/>
<param name="cfSmdImpact" value="0"/>
</pass>
<pass name="Optimize4" refer="Optimize3" active="yes">
<param name="cfChangeDir" value="25"/>
</pass>
</autorouter>
<elements>
<element name="C1" library="SparkFun-Capacitors" package="CAP-PTH-SMALL" value="22p" x="43.18" y="20.32" rot="R90"/>
<element name="C2" library="SparkFun-Capacitors" package="CAP-PTH-SMALL" value="22p" x="43.18" y="17.78" rot="R270"/>
<element name="C3" library="SparkFun-Capacitors" package="CAP-PTH-SMALL-KIT" value="100n" x="46.99" y="48.26" rot="R180">
<attribute name="PROD_ID" value="CAP-08370" x="46.99" y="48.26" size="1.778" layer="27" rot="R180" display="off"/>
</element>
<element name="C4" library="SparkFun-Capacitors" package="CPOL-RADIAL-10UF-25V" value="10u" x="46.99" y="53.34"/>
<element name="JP1" library="SparkFun-Connectors" package="2X3-SHROUDED" value="FEMALE 2x3" x="73.66" y="21.59" rot="R270">
<attribute name="PROD_ID" value="CONN-10681" x="73.66" y="21.59" size="1.778" layer="27" rot="R270" display="off"/>
</element>
<element name="Q1" library="SparkFun-FreqCtrl" package="HC49US" value="16M" x="48.26" y="20.32" rot="R90"/>
<element name="U1" library="SparkFun-DigitalIC" package="DIL28-3" value="ATMEGA328P_PDIP" x="44.45" y="39.37"/>
<element name="IC1" library="RBBB" package="L4931_REGULATOR" value="LM4931" x="78.74" y="43.18" rot="R90"/>
<element name="J1" library="RBBB" package="POWER_JACK" value="POWER_JACK"" x="97.79" y="40.64" rot="R90"/>
<element name="R9" library="SparkFun-Resistors" package="AXIAL-0.1EZ" value="1K" x="27.94" y="30.48" rot="R90">
<attribute name="PROD_ID" value="RES-12182" x="27.94" y="30.48" size="1.778" layer="27" rot="R90" display="off"/>
</element>
<element name="JP3" library="SparkFun-Connectors" package="1X06" value="" x="35.56" y="48.26" rot="R180">
<attribute name="PROD_ID" value="CONN-08437" x="35.56" y="48.26" size="1.778" layer="27" rot="R180" display="off"/>
</element>
<element name="Q2" library="SparkFun-DiscreteSemi" package="TO-92-AMMO" value="2N2222" x="15.24" y="38.1" rot="R270"/>
<element name="R10" library="SparkFun-Resistors" package="AXIAL-0.1EZ" value="470" x="20.32" y="38.1" rot="R180">
<attribute name="PROD_ID" value="RES-12182" x="20.32" y="38.1" size="1.778" layer="27" rot="R180" display="off"/>
</element>
<element name="R11" library="SparkFun-Resistors" package="AXIAL-0.1EZ" value="22" x="20.32" y="30.48">
<attribute name="PROD_ID" value="RES-12182" x="20.32" y="30.48" size="1.778" layer="27" display="off"/>
</element>
<element name="D1" library="led" package="SFH482" value="SFH482" x="15.24" y="31.75" rot="R90"/>
<element name="R12" library="SparkFun-Resistors" package="AXIAL-0.1EZ" value="1K" x="60.96" y="25.4" rot="R90">
<attribute name="PROD_ID" value="RES-12183" x="60.96" y="25.4" size="1.778" layer="27" rot="R90" display="off"/>
</element>
<element name="LED1" library="led" package="LED5MM" value="IR" x="57.15" y="25.4" rot="R180"/>
<element name="JP4" library="SparkFun-Connectors" package="1X06" value="" x="35.56" y="17.78" rot="R180">
<attribute name="PROD_ID" value="CONN-08437" x="35.56" y="17.78" size="1.778" layer="27" rot="R180" display="off"/>
</element>
<element name="C6" library="SparkFun-Capacitors" package="CAP-PTH-SMALL-KIT" value="100n" x="25.4" y="24.13" rot="R270">
<attribute name="PROD_ID" value="CAP-08370" x="25.4" y="24.13" size="1.778" layer="27" rot="R270" display="off"/>
</element>
<element name="JP2" library="SparkFun-Connectors" package="1X08" value="" x="66.04" y="71.12" rot="R270">
<attribute name="PROD_ID" value="CONN-08438" x="66.04" y="71.12" size="1.778" layer="27" rot="R270" display="off"/>
</element>
<element name="C7" library="SparkFun-Capacitors" package="CAP-PTH-SMALL-KIT" value="100n" x="76.2" y="44.45" rot="R270">
<attribute name="PROD_ID" value="CAP-08370" x="76.2" y="44.45" size="1.778" layer="27" rot="R270" display="off"/>
</element>
<element name="C8" library="SparkFun-Capacitors" package="CPOL-RADIAL-10UF-25V" value="10u" x="71.12" y="44.45" rot="R90"/>
</elements>
<signals>
<signal name="GND">
<contactref element="JP1" pad="6"/>
<contactref element="C3" pad="2"/>
<contactref element="C4" pad="2"/>
<contactref element="U1" pad="8"/>
<contactref element="U1" pad="22"/>
<wire x1="45.72" y1="25.4" x2="45.72" y2="35.56" width="0.4064" layer="16"/>
<wire x1="45.72" y1="35.56" x2="45.72" y2="38.1" width="0.4064" layer="16"/>
<wire x1="45.72" y1="38.1" x2="43.18" y2="40.64" width="0.4064" layer="16"/>
<wire x1="43.18" y1="40.64" x2="43.18" y2="43.18" width="0.4064" layer="16"/>
<contactref element="IC1" pad="GND"/>
<contactref element="J1" pad="GND"/>
<contactref element="JP3" pad="2"/>
<contactref element="JP3" pad="6"/>
<contactref element="Q2" pad="1"/>
<contactref element="LED1" pad="K"/>
<wire x1="33.02" y1="48.26" x2="33.02" y2="50.8" width="0.4064" layer="16"/>
<wire x1="33.02" y1="50.8" x2="22.86" y2="50.8" width="0.4064" layer="16"/>
<wire x1="22.86" y1="50.8" x2="22.86" y2="48.26" width="0.4064" layer="16"/>
<wire x1="33.02" y1="48.26" x2="33.02" y2="45.72" width="0.4064" layer="16"/>
<wire x1="33.02" y1="45.72" x2="43.18" y2="45.72" width="0.4064" layer="16"/>
<wire x1="43.18" y1="45.72" x2="43.18" y2="43.18" width="0.4064" layer="16"/>
<wire x1="15.24" y1="40.64" x2="15.24" y2="48.26" width="0.4064" layer="16"/>
<wire x1="15.24" y1="48.26" x2="22.86" y2="48.26" width="0.4064" layer="16"/>
<wire x1="45.72" y1="48.26" x2="45.593" y2="48.26" width="0.4064" layer="16"/>
<wire x1="45.593" y1="48.26" x2="43.18" y2="48.26" width="0.4064" layer="16"/>
<wire x1="43.18" y1="48.26" x2="43.18" y2="45.72" width="0.4064" layer="16"/>
<contactref element="JP4" pad="6"/>
<via x="22.86" y="15.24" extent="1-16" drill="0.6" shape="square"/>
<wire x1="22.86" y1="15.24" x2="22.86" y2="17.78" width="0.4064" layer="16"/>
<contactref element="JP2" pad="8"/>
<wire x1="45.593" y1="48.26" x2="45.593" y2="53.213" width="0.4064" layer="16"/>
<wire x1="45.593" y1="53.213" x2="45.72" y2="53.34" width="0.4064" layer="16"/>
<wire x1="55.88" y1="25.4" x2="53.34" y2="25.4" width="0.4064" layer="16"/>
<via x="53.34" y="25.4" extent="1-16" drill="0.6" shape="square"/>
<via x="45.72" y="25.4" extent="1-16" drill="0.6" shape="square"/>
<wire x1="53.34" y1="25.4" x2="45.72" y2="25.4" width="0.4064" layer="1"/>
<wire x1="45.72" y1="25.4" x2="43.18" y2="25.4" width="0.4064" layer="16"/>
<via x="43.18" y="25.4" extent="1-16" drill="0.6" shape="square"/>
<wire x1="43.18" y1="25.4" x2="40.64" y2="22.86" width="0.4064" layer="1"/>
<wire x1="55.88" y1="25.4" x2="55.88" y2="30.48" width="0.4064" layer="16"/>
<via x="55.88" y="30.48" extent="1-16" drill="0.6" shape="square"/>
<wire x1="55.88" y1="30.48" x2="66.04" y2="30.48" width="0.4064" layer="1"/>
<wire x1="66.04" y1="30.48" x2="66.04" y2="43.18" width="0.4064" layer="1"/>
<via x="66.04" y="43.18" extent="1-16" drill="0.6" shape="square"/>
<wire x1="40.64" y1="15.24" x2="38.1" y2="15.24" width="0.4064" layer="16"/>
<via x="38.1" y="15.24" extent="1-16" drill="0.6" shape="square"/>
<wire x1="38.1" y1="15.24" x2="22.86" y2="15.24" width="0.4064" layer="1"/>
<wire x1="40.64" y1="15.24" x2="40.64" y2="17.78" width="0.4064" layer="16"/>
<via x="40.64" y="17.78" extent="1-16" drill="0.6" shape="square"/>
<wire x1="40.64" y1="22.86" x2="40.64" y2="17.78" width="0.4064" layer="1"/>
<wire x1="71.12" y1="20.32" x2="71.12" y2="15.24" width="0.4064" layer="16"/>
<wire x1="55.88" y1="22.86" x2="55.88" y2="25.4" width="0.4064" layer="16"/>
<via x="71.12" y="15.24" extent="1-16" drill="0.6" shape="square"/>
<wire x1="66.04" y1="53.34" x2="66.04" y2="43.18" width="0.4064" layer="16"/>
<contactref element="C8" pad="2"/>
<contactref element="C7" pad="2"/>
<wire x1="76.2" y1="43.053" x2="81.28" y2="43.053" width="0.4064" layer="16"/>
<wire x1="81.28" y1="43.053" x2="81.28" y2="43.18" width="0.4064" layer="16"/>
<wire x1="76.2" y1="43.053" x2="66.04" y2="43.053" width="0.4064" layer="16"/>
<wire x1="66.04" y1="43.053" x2="66.04" y2="43.18" width="0.4064" layer="16"/>
<wire x1="81.28" y1="43.053" x2="88.9" y2="43.053" width="0.4064" layer="16"/>
<wire x1="88.9" y1="43.053" x2="88.9" y2="40.64" width="0.4064" layer="16"/>
<wire x1="88.9" y1="40.64" x2="90.09" y2="40.64" width="0.4064" layer="16"/>
<via x="66.04" y="30.48" extent="1-16" drill="0.6" shape="square"/>
<wire x1="66.04" y1="30.48" x2="55.88" y2="30.48" width="0.4064" layer="16"/>
<wire x1="55.88" y1="30.48" x2="55.88" y2="22.86" width="0.4064" layer="16"/>
<via x="55.88" y="22.86" extent="1-16" drill="0.6" shape="square"/>
<wire x1="55.88" y1="22.86" x2="55.88" y2="15.24" width="0.4064" layer="1"/>
<wire x1="55.88" y1="15.24" x2="71.12" y2="15.24" width="0.4064" layer="1"/>
<contactref element="C1" pad="1"/>
<contactref element="C2" pad="1"/>
<wire x1="76.2" y1="43.053" x2="71.12" y2="43.18" width="0" layer="19" extent="1-1"/>
<wire x1="43.18" y1="17.78" x2="40.64" y2="17.78" width="0" layer="19" extent="1-1"/>
<wire x1="43.18" y1="20.32" x2="43.18" y2="17.78" width="0" layer="19" extent="1-1"/>
</signal>
<signal name="N$10">
<contactref element="U1" pad="9"/>
<contactref element="C1" pad="2"/>
<contactref element="Q1" pad="2"/>
<wire x1="48.26" y1="22.86" x2="48.26" y2="35.56" width="0" layer="19" extent="1-1"/>
<wire x1="43.18" y1="22.86" x2="48.26" y2="22.86" width="0" layer="19" extent="1-1"/>
</signal>
<signal name="N$11">
<contactref element="U1" pad="10"/>
<contactref element="Q1" pad="1"/>
<wire x1="50.8" y1="35.56" x2="50.8" y2="17.78" width="0.4064" layer="16"/>
<wire x1="50.8" y1="17.78" x2="48.26" y2="17.78" width="0.4064" layer="16"/>
<wire x1="48.26" y1="17.78" x2="48.26" y2="15.24" width="0.4064" layer="16"/>
<contactref element="C2" pad="2"/>
<wire x1="43.18" y1="15.24" x2="48.26" y2="15.24" width="0" layer="19" extent="16-16"/>
</signal>
<signal name="MISO">
<contactref element="U1" pad="18"/>
<contactref element="JP1" pad="1"/>
<contactref element="JP2" pad="6"/>
<wire x1="53.34" y1="43.18" x2="53.34" y2="38.1" width="0.4064" layer="16"/>
<wire x1="53.34" y1="38.1" x2="63.5" y2="38.1" width="0.4064" layer="16"/>
<wire x1="76.2" y1="27.94" x2="76.2" y2="22.86" width="0.4064" layer="16"/>
<via x="63.5" y="38.1" extent="1-16" drill="0.6" shape="square"/>
<via x="76.2" y="27.94" extent="1-16" drill="0.6" shape="square"/>
<wire x1="66.04" y1="58.42" x2="53.34" y2="58.42" width="0.4064" layer="16"/>
<via x="53.34" y="58.42" extent="1-16" drill="0.6" shape="square"/>
<wire x1="53.34" y1="58.42" x2="53.34" y2="45.72" width="0.4064" layer="1"/>
<via x="53.34" y="45.72" extent="1-16" drill="0.6" shape="square"/>
<wire x1="53.34" y1="45.72" x2="53.34" y2="43.18" width="0.4064" layer="16"/>
<wire x1="63.5" y1="38.1" x2="76.2" y2="27.94" width="0" layer="19" extent="1-1"/>
</signal>
<signal name="MOSI">
<contactref element="U1" pad="17"/>
<contactref element="JP1" pad="4"/>
<contactref element="JP2" pad="5"/>
<wire x1="55.88" y1="43.18" x2="55.88" y2="40.64" width="0.4064" layer="16"/>
<wire x1="55.88" y1="40.64" x2="63.5" y2="40.64" width="0.4064" layer="16"/>
<via x="63.5" y="40.64" extent="1-16" drill="0.6" shape="square"/>
<via x="73.66" y="15.24" extent="1-16" drill="0.6" shape="square"/>
<wire x1="73.66" y1="15.24" x2="73.66" y2="20.32" width="0.4064" layer="16"/>
<wire x1="66.04" y1="60.96" x2="55.88" y2="60.96" width="0.4064" layer="16"/>
<via x="55.88" y="60.96" extent="1-16" drill="0.6" shape="square"/>
<wire x1="55.88" y1="60.96" x2="55.88" y2="45.72" width="0.4064" layer="1"/>
<via x="55.88" y="45.72" extent="1-16" drill="0.6" shape="square"/>
<wire x1="55.88" y1="45.72" x2="55.88" y2="43.18" width="0.4064" layer="16"/>
<wire x1="73.66" y1="20.32" x2="63.5" y2="40.64" width="0" layer="19" extent="1-1"/>
</signal>
<signal name="SCK">
<contactref element="JP1" pad="3"/>
<contactref element="JP2" pad="4"/>
<contactref element="U1" pad="19"/>
<wire x1="73.66" y1="22.86" x2="73.66" y2="27.94" width="0.4064" layer="16"/>
<via x="73.66" y="27.94" extent="1-16" drill="0.6" shape="square"/>
<wire x1="66.04" y1="63.5" x2="50.8" y2="63.5" width="0.4064" layer="16"/>
<via x="50.8" y="63.5" extent="1-16" drill="0.6" shape="square"/>
<wire x1="50.8" y1="63.5" x2="50.8" y2="45.72" width="0.4064" layer="1"/>
<via x="50.8" y="45.72" extent="1-16" drill="0.6" shape="square"/>
<wire x1="50.8" y1="45.72" x2="50.8" y2="43.18" width="0.4064" layer="16"/>
<wire x1="50.8" y1="43.18" x2="73.66" y2="27.94" width="0" layer="19" extent="1-1"/>
</signal>
<signal name="RESET">
<contactref element="JP1" pad="5"/>
<contactref element="U1" pad="1"/>
<contactref element="R9" pad="P$2"/>
<wire x1="27.94" y1="35.56" x2="27.94" y2="33.02" width="0.4064" layer="16"/>
<contactref element="C6" pad="1"/>
<wire x1="25.4" y1="25.527" x2="25.4" y2="27.94" width="0.4064" layer="16"/>
<via x="25.4" y="27.94" extent="1-16" drill="0.6" shape="square"/>
<wire x1="25.4" y1="27.94" x2="25.4" y2="33.02" width="0.4064" layer="1"/>
<via x="25.4" y="33.02" extent="1-16" drill="0.6" shape="square"/>
<wire x1="25.4" y1="33.02" x2="27.94" y2="33.02" width="0.4064" layer="16"/>
<wire x1="27.94" y1="35.56" x2="25.4" y2="35.56" width="0.4064" layer="16"/>
<wire x1="25.4" y1="33.02" x2="25.4" y2="35.56" width="0.4064" layer="16"/>
<via x="25.4" y="35.56" extent="1-16" drill="0.6" shape="square"/>
<wire x1="27.94" y1="33.02" x2="22.86" y2="33.02" width="0.4064" layer="16"/>
<wire x1="71.12" y1="22.86" x2="71.12" y2="27.94" width="0.4064" layer="16"/>
<via x="22.86" y="33.02" extent="1-16" drill="0.6" shape="square"/>
<via x="71.12" y="27.94" extent="1-16" drill="0.6" shape="square"/>
<wire x1="27.94" y1="33.02" x2="71.12" y2="27.94" width="0" layer="19" extent="1-1"/>
</signal>
<signal name="5V">
<contactref element="JP1" pad="2"/>
<contactref element="U1" pad="20"/>
<contactref element="U1" pad="7"/>
<contactref element="IC1" pad="IN"/>
<contactref element="J1" pad="PWR"/>
<contactref element="R9" pad="P$1"/>
<contactref element="R11" pad="P$2"/>
<via x="43.18" y="27.94" extent="1-16" drill="0.6" shape="square"/>
<wire x1="43.18" y1="30.48" x2="43.18" y2="27.94" width="0.4064" layer="16"/>
<wire x1="43.18" y1="27.94" x2="27.94" y2="27.94" width="0.4064" layer="1"/>
<via x="27.94" y="27.94" extent="1-16" drill="0.6" shape="square"/>
<wire x1="27.94" y1="27.94" x2="27.94" y2="30.48" width="0.4064" layer="16"/>
<wire x1="22.86" y1="30.48" x2="27.94" y2="30.48" width="0.4064" layer="16"/>
<wire x1="48.26" y1="45.72" x2="48.26" y2="48.133" width="0.4064" layer="16"/>
<wire x1="43.18" y1="35.56" x2="43.18" y2="33.02" width="0.4064" layer="16"/>
<via x="43.18" y="33.02" extent="1-16" drill="0.6" shape="square"/>
<wire x1="43.18" y1="33.02" x2="44.45" y2="34.29" width="0.4064" layer="1"/>
<wire x1="44.45" y1="34.29" x2="44.45" y2="38.1" width="0.4064" layer="1"/>
<wire x1="44.45" y1="38.1" x2="49.53" y2="40.64" width="0.4064" layer="1"/>
<wire x1="49.53" y1="40.64" x2="49.53" y2="44.45" width="0.4064" layer="1"/>
<wire x1="49.53" y1="44.45" x2="48.26" y2="45.72" width="0.4064" layer="1"/>
<via x="48.26" y="45.72" extent="1-16" drill="0.6" shape="square"/>
<wire x1="48.26" y1="45.72" x2="48.26" y2="43.18" width="0.4064" layer="16"/>
<wire x1="84.09" y1="40.64" x2="81.28" y2="40.64" width="0.4064" layer="16"/>
<wire x1="68.58" y1="29.21" x2="44.45" y2="29.21" width="0.4064" layer="1"/>
<wire x1="44.45" y1="29.21" x2="43.18" y2="30.48" width="0.4064" layer="1"/>
<via x="43.18" y="30.48" extent="1-16" drill="0.6" shape="square"/>
<wire x1="43.18" y1="30.48" x2="43.18" y2="33.02" width="0.4064" layer="16"/>
<contactref element="JP2" pad="1"/>
<wire x1="76.2" y1="20.32" x2="76.2"

repository: fmeschia/web-ac-control

repo_name: fmeschia/web-ac-control


text:
y2="15.24" width="0.4064" layer="16"/>
<via x="76.2" y="15.24" extent="1-16" drill="0.6" shape="square"/>
<via x="68.58" y="35.56" extent="1-16" drill="0.6" shape="square"/>
<wire x1="68.58" y1="29.21" x2="68.58" y2="35.56" width="0.4064" layer="1"/>
<wire x1="48.26" y1="66.04" x2="53.34" y2="71.12" width="0.4064" layer="16"/>
<wire x1="53.34" y1="71.12" x2="66.04" y2="71.12" width="0.4064" layer="16"/>
<wire x1="81.28" y1="40.64" x2="68.58" y2="40.64" width="0.4064" layer="16"/>
<wire x1="68.58" y1="40.64" x2="68.58" y2="35.56" width="0.4064" layer="16"/>
<contactref element="C4" pad="1"/>
<contactref element="C3" pad="1"/>
<wire x1="48.26" y1="53.34" x2="48.26" y2="66.04" width="0" layer="19" extent="16-16"/>
<wire x1="48.387" y1="48.26" x2="48.26" y2="53.34" width="0" layer="19" extent="1-1"/>
<wire x1="48.26" y1="48.133" x2="48.387" y2="48.26" width="0" layer="19" extent="16-16"/>
<wire x1="76.2" y1="20.32" x2="68.58" y2="29.21" width="0" layer="19" extent="1-1"/>
</signal>
<signal name="3.3V">
<contactref element="JP3" pad="1"/>
<contactref element="IC1" pad="OUT"/>
<via x="68.58" y="45.72" extent="1-16" drill="0.6" shape="square"/>
<wire x1="68.58" y1="45.72" x2="66.04" y2="49.53" width="0.4064" layer="1"/>
<wire x1="66.04" y1="49.53" x2="39.37" y2="49.53" width="0.4064" layer="1"/>
<wire x1="39.37" y1="49.53" x2="38.1" y2="48.26" width="0.4064" layer="1"/>
<via x="38.1" y="48.26" extent="1-16" drill="0.6" shape="square"/>
<wire x1="38.1" y1="48.26" x2="35.56" y2="48.26" width="0.4064" layer="16"/>
<contactref element="C7" pad="1"/>
<contactref element="C8" pad="1"/>
<wire x1="76.2" y1="45.847" x2="68.58" y2="45.847" width="0.4064" layer="16"/>
<wire x1="68.58" y1="45.847" x2="68.58" y2="45.72" width="0.4064" layer="16"/>
<wire x1="76.2" y1="45.847" x2="81.28" y2="45.847" width="0.4064" layer="16"/>
<wire x1="81.28" y1="45.847" x2="81.28" y2="45.72" width="0.4064" layer="16"/>
<wire x1="68.58" y1="45.847" x2="71.12" y2="45.72" width="0" layer="19" extent="16-16"/>
</signal>
<signal name="N$12">
</signal>
<signal name="N$13">
<contactref element="U1" pad="27"/>
<contactref element="JP3" pad="3"/>
<wire x1="30.48" y1="43.18" x2="30.48" y2="48.26" width="0.4064" layer="16"/>
</signal>
<signal name="N$14">
<contactref element="U1" pad="28"/>
<contactref element="JP3" pad="4"/>
<wire x1="27.94" y1="48.26" x2="27.94" y2="43.18" width="0.4064" layer="16"/>
</signal>
<signal name="PD3">
<contactref element="U1" pad="5"/>
<contactref element="R10" pad="P$1"/>
<wire x1="20.32" y1="38.1" x2="38.1" y2="38.1" width="0.4064" layer="16"/>
<wire x1="38.1" y1="38.1" x2="38.1" y2="35.56" width="0.4064" layer="16"/>
</signal>
<signal name="N$15">
<contactref element="Q2" pad="2"/>
<contactref element="R10" pad="P$2"/>
<wire x1="15.24" y1="38.1" x2="17.78" y2="38.1" width="0.4064" layer="16"/>
</signal>
<signal name="N$16">
<contactref element="Q2" pad="3"/>
<contactref element="D1" pad="K"/>
<wire x1="15.24" y1="33.02" x2="15.24" y2="35.56" width="0.4064" layer="16"/>
</signal>
<signal name="N$17">
<contactref element="R11" pad="P$1"/>
<contactref element="D1" pad="A"/>
<wire x1="20.32" y1="30.48" x2="15.24" y2="30.48" width="0.4064" layer="16"/>
</signal>
<signal name="N$18">
<contactref element="R12" pad="P$1"/>
<contactref element="LED1" pad="A"/>
<wire x1="58.42" y1="25.4" x2="60.96" y2="25.4" width="0.4064" layer="16"/>
</signal>
<signal name="N$19">
</signal>
<signal name="N$20">
</signal>
<signal name="N$21">
</signal>
<signal name="N$22">
<contactref element="JP4" pad="1"/>
<contactref element="C6" pad="2"/>
<wire x1="35.56" y1="17.78" x2="35.56" y2="20.32" width="0.4064" layer="16"/>
<via x="35.56" y="20.32" extent="1-16" drill="0.6" shape="square"/>
<wire x1="35.56" y1="20.32" x2="25.4" y2="20.32" width="0.4064" layer="1"/>
<via x="25.4" y="20.32" extent="1-16" drill="0.6" shape="square"/>
<wire x1="25.4" y1="20.32" x2="25.4" y2="22.733" width="0.4064" layer="16"/>
</signal>
<signal name="N$23">
<contactref element="JP4" pad="2"/>
<contactref element="U1" pad="3"/>
<wire x1="33.02" y1="17.78" x2="33.02" y2="35.56" width="0.4064" layer="16"/>
</signal>
<signal name="N$24">
<contactref element="JP4" pad="3"/>
<contactref element="U1" pad="2"/>
<wire x1="30.48" y1="17.78" x2="30.48" y2="35.56" width="0.4064" layer="16"/>
</signal>
<signal name="N$1">
<contactref element="U1" pad="15"/>
<contactref element="JP2" pad="2"/>
<wire x1="66.04" y1="68.58" x2="60.96" y2="68.58" width="0.4064" layer="16"/>
<via x="60.96" y="68.58" extent="1-16" drill="0.6" shape="square"/>
<wire x1="60.96" y1="68.58" x2="60.96" y2="45.72" width="0.4064" layer="1"/>
<via x="60.96" y="45.72" extent="1-16" drill="0.6" shape="square"/>
<wire x1="60.96" y1="45.72" x2="60.96" y2="43.18" width="0.4064" layer="16"/>
</signal>
<signal name="N$2">
<contactref element="JP2" pad="3"/>
<contactref element="U1" pad="16"/>
<wire x1="66.04" y1="66.04" x2="58.42" y2="66.04" width="0.4064" layer="16"/>
<via x="58.42" y="66.04" extent="1-16" drill="0.6" shape="square"/>
<wire x1="58.42" y1="66.04" x2="58.42" y2="45.72" width="0.4064" layer="1"/>
<via x="58.42" y="45.72" extent="1-16" drill="0.6" shape="square"/>
<wire x1="58.42" y1="45.72" x2="58.42" y2="43.18" width="0.4064" layer="16"/>
</signal>
<signal name="N$3">
<contactref element="R12" pad="P$2"/>
<contactref element="U1" pad="14"/>
<wire x1="60.96" y1="35.56" x2="60.96" y2="27.94" width="0.4064" layer="16"/>
</signal>
<signal name="N$4">
<contactref element="JP2" pad="7"/>
<contactref element="U1" pad="4"/>
<wire x1="66.04" y1="55.88" x2="63.5" y2="55.88" width="0.4064" layer="16"/>
<wire x1="35.56" y1="35.56" x2="35.56" y2="33.02" width="0.4064" layer="16"/>
<wire x1="35.56" y1="33.02" x2="63.5" y2="55.88" width="0" layer="19" extent="1-16"/>
<via x="35.56" y="33.02" extent="1-16" drill="0.6" shape="square"/>
<via x="63.5" y="55.88" extent="1-16" drill="0.6" shape="square"/>
</signal>
</signals>
</board>
</drawing>
</eagle>

license_type: permissive

branch_name: refs/heads/master

extension: brd


text:
import debug, { Debugger } from 'debug';
import { EventEmitter } from 'events';
import { ZoneGroup } from './models/zone-group';
import { ZoneGroupTopologyService, ZoneGroupTopologyServiceEvent } from './services';
import SonosDevice from './sonos-device';
import SonosDeviceDiscovery from './sonos-device-discovery';
import { ServiceEvents, PlayNotificationOptions, PlayTtsOptions } from './models';
import IpHelper from './helpers/ip-helper';
import TtsHelper from './helpers/tts-helper';
/**
 * The SonosManager will manage the logical devices for you. It will also manage group updates so be sure to call .Close on exit to remove open listeners.
 *
 * @export
 * @class SonosManager
 */
export default class SonosManager {
  private readonly events: EventEmitter;

  private readonly debug: Debugger;

  private devices: SonosDevice[] = [];

  private zoneService: ZoneGroupTopologyService | undefined;

  constructor() {
    this.events = new EventEmitter();
    this.debug = debug('sonos:sonosmanager');
  }

  /**
   * Initialize the manager with one known device. Useful in special network environments.
   *
   * @param {string} host
   * @param {number} [port=1400]
   * @returns {Promise<boolean>}
   * @memberof SonosManager
   */
  public async InitializeFromDevice(host: string, port = 1400): Promise<boolean> {
    this.debug('InitializeFromDevice %s', host);
    const ip = IpHelper.IsIpv4(host) ? host : await IpHelper.ResolveHostname(host);
    this.zoneService = new ZoneGroupTopologyService(ip, port);
    return await this.Initialize();
  }

  /**
   * Initialize the manager by searching for one Sonos device in your network.
   *
   * @param {number} [timeoutInSeconds=10]
   * @returns {Promise<boolean>}
   * @memberof SonosManager
   */
  public async InitializeWithDiscovery(timeoutInSeconds = 10, discovery = new SonosDeviceDiscovery()): Promise<boolean> {
    this.debug('InitializeWithDiscovery timeout: %d', timeoutInSeconds);
    const player = await discovery.SearchOne(timeoutInSeconds);
    this.debug('Discovery found player with ip: %s', player.host);
    this.zoneService = new ZoneGroupTopologyService(player.host, player.port);
    return await this.Initialize();
  }

  private async Initialize(): Promise<boolean> {
    this.debug('Initialize()');
    const groups = await this.LoadAllGroups();
    const success = this.InitializeWithGroups(groups);
    return this.SubscribeForGroupEvents(success);
  }

  private async LoadAllGroups(): Promise<ZoneGroup[]> {
    if (this.zoneService === undefined) throw new Error('Manager is\'t initialized');
    return await this.zoneService.GetParsedZoneGroupState();
  }

  private InitializeWithGroups(groups: ZoneGroup[]): boolean {
    groups.forEach((g) => {
      const coordinator = new SonosDevice(g.coordinator.host, g.coordinator.port, g.coordinator.uuid, g.coordinator.name, { name: g.name, managerEvents: this.events });
      if (this.devices.findIndex((v) => v.Uuid === coordinator.Uuid) === -1) this.devices.push(coordinator);
      g.members.forEach((m) => {
        // Check if device exists
        if (this.devices.findIndex((v) => v.Uuid === m.uuid) === -1) {
          this.devices.push(new SonosDevice(m.host, m.port, m.uuid, m.name, { coordinator: m.uuid === g.coordinator.uuid ? undefined : coordinator, name: g.name, managerEvents: this.events }));
        }
      });
    });
    return true;
  }

  private SubscribeForGroupEvents(success: boolean): boolean {
    if (success && this.zoneService) {
      this.zoneService.Events.on(ServiceEvents.ServiceEvent, this.zoneEventSubscription);
    }
    return success;
  }

  private zoneEventSubscription = this.handleZoneEventData.bind(this);

  private handleZoneEventData(data: ZoneGroupTopologyServiceEvent): void {
    if (data.ZoneGroupState !== undefined && typeof data.ZoneGroupState !== 'string') {
      data.ZoneGroupState.forEach((g) => {
        let coordinator = this.devices.find((d) => d.Uuid === g.coordinator.uuid);
        if (coordinator === undefined) {
          coordinator = new SonosDevice(g.coordinator.host, g.coordinator.port, g.coordinator.uuid, g.coordinator.name, { coordinator: undefined, name: g.name, managerEvents: this.events });
          this.devices.push(coordinator);
          this.events.emit('NewDevice', coordinator);
        }

        // New members
        g.members
          .filter((m) => !this.devices.some((d) => d.Uuid === m.uuid))
          .forEach((m) => {
            const newDevice = new SonosDevice(m.host, m.port, m.uuid, m.name, { coordinator: m.uuid === g.coordinator.uuid ? undefined : coordinator, name: g.name, managerEvents: this.events });
            this.devices.push(newDevice);
            this.events.emit('NewDevice', newDevice);
          });

        g.members.forEach((m) => {
          this.events.emit(m.uuid, { coordinator: g.coordinator.uuid === m.uuid ? undefined : coordinator, name: g.name });
        });
      });
    }
  }

  /**
   * Cancel the subscription (this will unsubscribe for zone events)
   *
   * @memberof SonosManager
   */
  public CancelSubscription(): void {
    if (this.zoneService !== undefined) this.zoneService.Events.removeListener(ServiceEvents.ServiceEvent, this.zoneEventSubscription);
  }

  /**
   * Get all found devices, call InitializeWithDiscovery or InitializeFromDevice first.
   *
   * @readonly
   * @type {SonosDevice[]}
   * @memberof SonosManager
   */
  public get Devices(): SonosDevice[] {
    if (this.devices.length === 0) throw new Error('No Devices available!');
    return this.devices;
  }

  /**
   * Subscribe to receive new devices.
   *
   * @param {(device: SonosDevice) => void} listener
   * @memberof SonosManager
   */
  public OnNewDevice(listener: (device: SonosDevice) => void): void {
    this.events.on('NewDevice', listener);
  }

  /**
   * Play a notification on all groups, without changing the current groups (for now).
   *
   * @param {PlayNotificationOptions} options The options
   * @param {string} options.trackUri The uri of the sound to play as notification, can be every supported sonos uri.
   * @param {string|Track} [options.metadata] The metadata of the track to play, will be guesses if undefined.
   * @param {number} [options.delayMs] Delay in ms between commands, for better notification playback stability
   * @param {boolean} [options.onlyWhenPlaying] Only play a notification if currently playing music. You don't have to check if the user is home ;)
   * @param {number} [options.timeout] Number of seconds the notification should play, as a fallback if the event doesn't come through.
   * @param {number} [options.volume] Change the volume for the notication and revert afterwards.
   * @returns {Promise<boolean>} Returns true is notification was played (and the state is set back to original)
   * @memberof SonosManager
   */
  public async PlayNotification(options: PlayNotificationOptions): Promise<boolean> {
    this.debug('PlayNotification(%o)', options);

    const commands = this.Devices
      .filter((d) => d.Coordinator.Uuid === d.Uuid)
      .map((d) => d.PlayNotification(options));
    return Promise
      .all(commands)
      .then((values) => values.some((v) => v));
  }

  /**
   * Play text to speech message on all groups, without changing the current groups (for now).
   *
   * @param {PlayTtsOptions} options
   * @param {string} options.text Text to request a TTS file for.
   * @param {string} options.lang Language to request tts file for.
   * @param {string} [options.endpoint] TTS endpoint, see documentation, can also be set by environment variable 'SONOS_TTS_ENDPOINT'
   * @param {string} [options.gender] Supply gender, some languages support both genders.
   * @param {string} [options.name] Supply voice name, some services support several voices with different names.
   * @param {number} [options.delayMs] Delay in ms between commands, for better notification playback stability
   * @param {boolean} [options.onlyWhenPlaying] Only play a notification if currently playing music. You don't have to check if the user is home ;)
   * @param {number} [options.timeout] Number of seconds the notification should play, as a fallback if the event doesn't come through.
   * @param {number} [options.volume] Change the volume for the notication and revert afterwards.
   * @returns {Promise<boolean>} returns true if notification actually played
   * @memberof SonosDevice
   */
  public async PlayTTS(options: PlayTtsOptions): Promise<boolean> {
    this.debug('PlayTTS(%o)', options);
    const notificationOptions = await TtsHelper.TtsOptionsToNotification(options);
    if (typeof (notificationOptions) === 'undefined') {
      return false;
    }

    return await this.PlayNotification(notificationOptions);
  }

  /**
   * Check the event subscriptions for all known devices.
   *
   * @returns {Promise<void>}
   * @memberof SonosManager
   */
  public async CheckAllEventSubscriptions(): Promise<void> {
    await this.zoneService?.CheckEventListener();
    await Promise.all(this.devices.map((device) => device.RefreshEventSubscriptions()));
  }
}

license: MIT

repository: cheanrod/node-sonos-ts

repo_name: cheanrod/node-sonos-ts

extension: ts


text:
package logs

import "github.com/prometheus/common/log"

var Logger log.Logger

func InitLog(debug bool) {
	Logger = log.Base()
	err := Logger.SetFormat("logger:stdout?json=true")
	if err != nil{
		Logger.Fatalf("Set Log format error: %s", err.Error())
	}
	err = Logger.SetLevel("info")
	if err != nil {
		Logger.Fatal("Set Log level error.")
		return
	}
	if debug {
		err := Logger.SetLevel("debug")
		if err != nil {
			Logger.Fatal("Set Log level error.")
		}
	}
}

repository: huaweicloud/cloudeye-exporter

repo_name: huaweicloud/cloudeye-exporter

gha_language: Go

extension: go


text:
//Package list copy from datastruct.list
// what is more:
// 1、add a func NewElement() to support get a single Element whithout set prev and next and list
// 2、add a func PushElementFront() to insert the single element to first of the list which created by call NewElement()
package list

// Element is an element of a linked list.
type Element struct {
	// Next and previous pointers in the doubly-linked list of elements.
	// To simplify the implementation, internally a list l is implemented
	// as a ring, such that &l.root is both the next element of the last
	// list element (l.Back()) and the previous element of the first list
	// element (l.Front()).
	next, prev *Element

	// The list to which this element belongs.
	list *List

	// The value stored with this element.
	Value interface{}
}

// Next returns the next list element or nil.
func (e *Element) Next() *Element {
	if p := e.next; e.list != nil && p != &e.list.root {
		return p
	}
	return nil
}

// Prev returns the previous list element or nil.
func (e *Element) Prev() *Element {
	if p := e.prev; e.list != nil && p != &e.list.root {
		return p
	}
	return nil
}

// List represents a doubly linked list.
// The zero value for List is an empty list ready to use.
type List struct {
	root Element // sentinel list element, only &root, root.prev, and root.next are used
	len  int     // current list length excluding (this) sentinel element
}

// Init initializes or clears list l.
func (l *List) Init() *List {
	l.root.next = &l.root
	l.root.prev = &l.root
	l.len = 0
	return l
}

// New returns an initialized list.
func New() *List { return new(List).Init() }

// NewElement return a new single Element
func (l *List) NewElement(value interface{}) *Element {
	return &Element{Value: value}
}

// Len returns the number of elements of list l.
// The complexity is O(1).
func (l *List) Len() int { return l.len }

// Front returns the first element of list l or nil if the list is empty.
func (l *List) Front() *Element {
	if l.len == 0 {
		return nil
	}
	return l.root.next
}

// Back returns the last element of list l or nil if the list is empty.
func (l *List) Back() *Element {
	if l.len == 0 {
		return nil
	}
	return l.root.prev
}

// lazyInit lazily initializes a zero List value.
func (l *List) lazyInit() {
	if l.root.next == nil {
		l.Init()
	}
}

// insert inserts e after at, increments l.len, and returns e.
func (l *List) insert(e, at *Element) *Element {
	e.prev = at
	e.next = at.next
	e.prev.next = e
	e.next.prev = e
	e.list = l
	l.len++
	return e
}

// insertValue is a convenience wrapper for insert(&Element{Value: v}, at).
func (l *List) insertValue(v interface{}, at *Element) *Element {
	return l.insert(&Element{Value: v}, at)
}

// remove removes e from its list, decrements l.len, and returns e.
func (l *List) remove(e *Element) *Element {
	// if e is a single element without prev and next, set its list = nil and return
	// the list.len is not contains the e, so need not to do l.len--
	if e.prev == nil && e.next == nil {
		e.list = nil
		return e
	}
	e.prev.next = e.next
	e.next.prev = e.prev
	e.next = nil // avoid memory leaks
	e.prev = nil // avoid memory leaks
	e.list = nil
	l.len--
	return e
}

// move moves e to next to at and returns e.
func (l *List) move(e, at *Element) *Element {
	if e == at {
		return e
	}
	// add if nil so that we can add a single Element to the list
	if e.prev != nil {
		e.prev.next = e.next
	}
	if e.next != nil {
		e.next.prev = e.prev
	}

	e.prev = at
	e.next = at.next
	e.prev.next = e
	e.next.prev = e

	return e
}

// Remove removes e from l if e is an element of list l.
// It returns the element value e.Value.
// The element must not be nil.
func (l *List) Remove(e *Element) interface{} {
	if e.list == l {
		// if e.list == l, l must have been initialized when e was inserted
		// in l or l == nil (e is a zero Element) and l.remove will crash
		l.remove(e)
	}
	return e.Value
}

// PushFront inserts a new element e with value v at the front of list l and returns e.
func (l *List) PushFront(v interface{}) *Element {
	l.lazyInit()
	return l.insertValue(v, &l.root)
}

// PushBack inserts a new element e with value v at the back of list l and returns e.
func (l *List) PushBack(v interface{}) *Element {
	l.lazyInit()
	return l.insertValue(v, l.root.prev)
}

// PushElementFront insert a single element to list`s front
func (l *List) PushElementFront(e *Element) {
	// only single element can do this
	if e.list == nil && e.prev == nil && e.next == nil {
		e.list = l
		l.len++
		l.move(e, &l.root)
	}
}

// MoveToFront moves element e to the front of list l.
// If e is not an element of l, the list is not modified.
// The element must not be nil.
func (l *List) MoveToFront(e *Element) {
	if e.list != l || l.root.next == e {
		return
	}
	// see comment in List.Remove about initialization of l
	l.move(e, &l.root)
}

// MoveToBack moves element e to the back of list l.
// If e is not an element of l, the list is not modified.
// The element must not be nil.
func (l *List) MoveToBack(e *Element) {
	if e.list != l || l.root.prev == e {
		return
	}
	// see comment in List.Remove about initialization of l
	l.move(e, l.root.prev)
}

repository: MoeYang/go-localcache

repo_name: MoeYang/go-localcache

branch_name: refs/heads/main

gha_license_id: MIT


text:
/*
 ApproxMC

 Copyright (c) 2019, Mate Soos and Kuldeep S. Meel. All rights reserved
 Copyright (c) 2009-2018, Mate Soos. All rights reserved.
 Copyright (c) 2014, Supratik Chakraborty, Kuldeep S. Meel, Moshe Y. Vardi
 Copyright (c) 2015, Supratik Chakraborty, Daniel J. Fremont,
 Kuldeep S. Meel, Sanjit A. Seshia, Moshe Y. Vardi

 Permission is hereby granted, free of charge, to any person obtaining a copy
 of this software and associated documentation files (the "Software"), to deal
 in the Software without restriction, including without limitation the rights
 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
 copies of the Software, and to permit persons to whom the Software is
 furnished to do so, subject to the following conditions:

 The above copyright notice and this permission notice shall be included in
 all copies or substantial portions of the Software.

 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
 THE SOFTWARE.
 */

#ifndef APPMC_CONFIG_H__
#define APPMC_CONFIG_H__

#include <vector>
#include <cstdint>
#include <string>

struct Config {
    uint32_t start_iter = 0;
    double epsilon = 0.80;
    double delta = 0.2;
    int sparse = 0;
    unsigned verb = 0;
    unsigned verb_cls = 0;
    uint32_t seed = 1;
    int simplify = 1;
    double var_elim_ratio = 1.6;
    int reuse_models = 1;
    int force_sol_extension = 0;
    std::vector<uint32_t> sampling_set;
    std::string logfilename = "";
    int cms_detach_xor = 1;
};

#endif //APPMCCONFIG

repository: SoftVarE-Group/emse-evaluation-sharpsat

repo_name: SoftVarE-Group/emse-evaluation-sharpsat

extension: h


text:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Reflection;
using WampSharp.Logging;
using WampSharp.Core.Message;
using WampSharp.Core.Serialization;
using WampSharp.Core.Utilities;

namespace WampSharp.Core.Dispatch.Handler
{
    /// <summary>
    /// An implementation of <see cref="IMethodBuilder{TKey,TMethod}"/>.
    /// Builds efficient delegates using compiled expressions.
    /// </summary>
    /// <typeparam name="TMessage"></typeparam>
    /// <typeparam name="TClient"></typeparam>
    public class WampMethodBuilder<TMessage, TClient> : IMethodBuilder<WampMethodInfo, Action<TClient, WampMessage<TMessage>>>
    {
        #region Members

        private readonly ILog mLogger;

        private readonly object mInstance;
        private readonly IWampFormatter<TMessage> mFormatter;

        #endregion

        #region Constructor

        /// <summary>
        /// Creates a new instance of <see cref="WampMethodBuilder{TMessage,TClient}"/>.
        /// </summary>
        /// <param name="instance">The instance to call its methods.</param>
        /// <param name="formatter">The <see cref="IWampFormatter{TMessage}"/> used to convert the arguments.</param>
        public WampMethodBuilder(object instance, IWampFormatter<TMessage> formatter)
        {
            mInstance = instance;
            mLogger = LogProvider.GetLogger(this.GetType());
            mFormatter = formatter;
        }

        #endregion

        #region Public Methods

        public Action<TClient, WampMessage<TMessage>> BuildMethod(WampMethodInfo wampMethod)
        {
            Func<object, object[], object> action = BuildAction(wampMethod);

            return (client, message) =>
            {
                object[] arguments = GetArguments(client, message, wampMethod);
                object instance = GetInstance(client, message, wampMethod);
                action(instance, arguments);
            };
        }

        private Func<object, object[], object> BuildAction(WampMethodInfo wampMethod)
        {
            Func<object, object[], object> method =
                MethodInvokeGenerator.CreateInvokeMethod(wampMethod.Method);

            return method;
        }

        #endregion

        #region Protected Members

        // Maybe these should be in a seperated interface.
        protected virtual object GetInstance(TClient client, WampMessage<TMessage> message, WampMethodInfo method)
        {
            return mInstance;
        }

        protected virtual object[] GetArguments(TClient client, WampMessage<TMessage> message, WampMethodInfo method)
        {
            return InnerGetArguments(client, message, method);
        }

        #endregion

        #region Private Members

        private object[] InnerGetArguments(TClient client, WampMessage<TMessage> message, WampMethodInfo method)
        {
            List<object> methodArguments = new List<object>(method.TotalArgumentsCount);

            if (method.HasWampClientArgument)
            {
                methodArguments.Add(client);
            }

            if (method.IsRawMethod)
            {
                methodArguments.Add(message);
            }
            else
            {
                methodArguments.AddRange
                    (ConvertArguments(message, method));
            }

            return methodArguments.ToArray();
        }

        private object[] ConvertArguments(WampMessage<TMessage> message, WampMethodInfo method)
        {
            ParameterInfo[] parametersList = method.ParametersToConvert;

            TMessage[] arguments = message.Arguments;

            IEnumerable<TMessage> relevantArguments = arguments;

            if (method.HasParamsArgument)
            {
                relevantArguments = relevantArguments.Take(parametersList.Length - 1);
            }

            List<object> converted =
                parametersList.Zip(relevantArguments,
                                   (parameter, argument) =>
                                   DeserializeArgument(parameter, argument))
                              .ToList();

            if (method.HasParamsArgument)
            {
                IEnumerable<TMessage> otherArgumets =
                    arguments.Skip(parametersList.Length - 1);

                converted.Add(otherArgumets.ToArray());
            }

            return converted.ToArray();
        }

        private object DeserializeArgument(ParameterInfo parameter, TMessage argument)
        {
            try
            {
                return mFormatter.Deserialize(parameter.ParameterType, argument);
            }
            catch (Exception ex)
            {
                mLogger.ErrorFormat(ex, "Failed deserializing {ParameterName}", parameter.Name);
                throw;
            }
        }

        #endregion
    }
}

repository: Code-Sharp/WampSharp

repo_name: Code-Sharp/WampSharp

gha_license_id: NOASSERTION

gha_language: C#

extension: cs