text:
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE eagle SYSTEM "eagle.dtd">
<eagle version="6.4">
<drawing>
<settings>
<setting alwaysvectorfont="yes"/>
<setting verticaltext="up"/>
</settings>
<grid distance="5" unitdist="mil" unit="mil" style="lines" multiple="1" 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="2" name="Route2" color="1" fill="3" visible="no" active="no"/>
<layer number="3" name="Route3" color="4" fill="3" visible="no" active="no"/>
<layer number="4" name="Route4" color="1" fill="4" visible="no" active="no"/>
<layer number="5" name="Route5" color="4" fill="4" visible="no" active="no"/>
<layer number="6" name="Route6" color="1" fill="8" visible="no" active="no"/>
<layer number="7" name="Route7" color="4" fill="8" visible="no" active="no"/>
<layer number="8" name="Route8" color="1" fill="2" visible="no" active="no"/>
<layer number="9" name="Route9" color="4" fill="2" visible="no" active="no"/>
<layer number="10" name="Route10" color="1" fill="7" visible="no" active="no"/>
<layer number="11" name="Route11" color="4" fill="7" visible="no" active="no"/>
<layer number="12" name="Route12" color="1" fill="5" visible="no" active="no"/>
<layer number="13" name="Route13" color="4" fill="5" visible="no" active="no"/>
<layer number="14" name="Route14" color="1" fill="6" visible="no" active="no"/>
<layer number="15" name="Route15" color="4" fill="6" visible="no" active="no"/>
<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="14" 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="no" 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="yes" active="yes"/>
<layer number="30" name="bStop" color="7" fill="6" visible="yes" active="yes"/>
<layer number="31" name="tCream" color="7" fill="4" visible="yes" active="yes"/>
<layer number="32" name="bCream" color="7" fill="5" visible="yes" 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="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="100" name="Muster" color="7" fill="1" visible="no" active="no"/>
<layer number="101" name="Patch_Top" color="12" fill="4" visible="no" active="yes"/>
<layer number="102" name="Vscore" color="7" fill="1" visible="no" active="yes"/>
<layer number="103" name="tMap" color="7" fill="1" visible="no" active="yes"/>
<layer number="104" name="Name" color="16" fill="1" visible="no" active="yes"/>
<layer number="105" name="tPlate" color="7" fill="1" visible="no" active="yes"/>
<layer number="106" name="bPlate" color="7" fill="1" visible="no" active="yes"/>
<layer number="107" name="Crop" color="7" fill="1" visible="no" 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="116" name="Patch_BOT" color="9" fill="4" visible="no" active="yes"/>
<layer number="121" name="_tsilk" color="7" fill="1" visible="no" active="yes"/>
<layer number="122" name="_bsilk" color="7" fill="1" visible="no" active="yes"/>
<layer number="125" name="_tNames" color="7" fill="1" visible="no" active="yes"/>
<layer number="144" name="Drill_legend" color="7" fill="1" visible="no" active="yes"/>
<layer number="151" name="HeatSink" color="7" fill="1" visible="no" 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="no" active="yes"/>
<layer number="201" name="201bmp" color="2" fill="10" visible="no" active="yes"/>
<layer number="202" name="202bmp" color="3" fill="10" visible="no" active="yes"/>
<layer number="203" name="203bmp" color="4" fill="10" visible="no" active="yes"/>
<layer number="204" name="204bmp" color="5" fill="10" visible="no" active="yes"/>
<layer number="205" name="205bmp" color="6" fill="10" visible="no" active="yes"/>
<layer number="206" name="206bmp" color="7" fill="10" visible="no" active="yes"/>
<layer number="207" name="207bmp" color="8" fill="10" visible="no" active="yes"/>
<layer number="208" name="208bmp" color="9" fill="10" visible="no" active="yes"/>
<layer number="209" name="209bmp" color="7" fill="1" visible="no" active="yes"/>
<layer number="210" name="210bmp" color="7" fill="1" visible="no" active="yes"/>
<layer number="211" name="211bmp" color="7" fill="1" visible="no" active="yes"/>
<layer number="212" name="212bmp" color="7" fill="1" visible="no" active="yes"/>
<layer number="213" name="213bmp" color="7" fill="1" visible="no" active="yes"/>
<layer number="214" name="214bmp" color="7" fill="1" visible="no" active="yes"/>
<layer number="215" name="215bmp" color="7" fill="1" visible="no" active="yes"/>
<layer number="216" name="216bmp" color="7" fill="1" visible="no" 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="225bmp" color="26" fill="10" visible="yes" active="yes"/>
<layer number="226" name="226bmp" color="27" fill="10" visible="yes" active="yes"/>
<layer number="227" name="227bmp" color="28" fill="10" visible="yes" active="yes"/>
<layer number="228" name="228bmp" color="29" fill="10" visible="yes" active="yes"/>
<layer number="229" name="229bmp" color="30" fill="10" visible="yes" active="yes"/>
<layer number="230" name="230bmp" color="31" fill="10" visible="yes" active="yes"/>
<layer number="231" name="231bmp" color="32" fill="10" 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="no" active="yes"/>
</layers>
<board>
<plain>
<wire x1="0" y1="0" x2="19.05" y2="0" width="0" layer="20"/>
<wire x1="19.05" y1="0" x2="19.05" y2="25.4" width="0" layer="20"/>
<wire x1="19.05" y1="25.4" x2="0" y2="25.4" width="0" layer="20"/>
<wire x1="0" y1="25.4" x2="0" y2="0" width="0" layer="20"/>
</plain>
<libraries>
<library name="Microchip">
<packages>
<package name="TSSOP-16">
<smd name="1" x="-2.95" y="2.275" dx="0.45" dy="1.5" layer="1" rot="R90"/>
<smd name="2" x="-2.95" y="1.625" dx="0.45" dy="1.5" layer="1" rot="R90"/>
<smd name="3" x="-2.95" y="0.975" dx="0.45" dy="1.5" layer="1" rot="R90"/>
<smd name="4" x="-2.95" y="0.325" dx="0.45" dy="1.5" layer="1" rot="R90"/>
<smd name="5" x="-2.95" y="-0.325" dx="0.45" dy="1.5" layer="1" rot="R90"/>
<smd name="6" x="-2.95" y="-0.975" dx="0.45" dy="1.5" layer="1" rot="R90"/>
<smd name="7" x="-2.95" y="-1.625" dx="0.45" dy="1.5" layer="1" rot="R90"/>
<smd name="8" x="-2.95" y="-2.275" dx="0.45" dy="1.5" layer="1" rot="R90"/>
<smd name="9" x="2.95" y="-2.275" dx="0.45" dy="1.5" layer="1" rot="R270"/>
<smd name="10" x="2.95" y="-1.625" dx="0.45" dy="1.5" layer="1" rot="R270"/>
<smd name="11" x="2.95" y="-0.975" dx="0.45" dy="1.5" layer="1" rot="R270"/>
<smd name="12" x="2.95" y="-0.325" dx="0.45" dy="1.5" layer="1" rot="R270"/>
<smd name="13" x="2.95" y="0.325" dx="0.45" dy="1.5" layer="1" rot="R270"/>
<smd name="14" x="2.95" y="0.975" dx="0.45" dy="1.5" layer="1" rot="R270"/>
<smd name="15" x="2.95" y="1.625" dx="0.45" dy="1.5" layer="1" rot="R270"/>
<smd name="16" x="2.95" y="2.275" dx="0.45" dy="1.5" layer="1" rot="R270"/>
<wire x1="-2" y1="2.5" x2="2" y2="2.5" width="0.127" layer="21"/>
<wire x1="-2" y1="2.5" x2="-2" y2="-2.5" width="0.127" layer="21"/>
<wire x1="2" y1="2.5" x2="2" y2="-2.5" width="0.127" layer="21"/>
<wire x1="-2" y1="-2.5" x2="2" y2="-2.5" width="0.127" layer="21"/>
<circle x="-1.4" y="1.9" radius="0.282840625" width="0.127" layer="21"/>
<text x="-1.9" y="2.7" size="0.6096" layer="21" ratio="12">>NAME</text>
</package>
</packages>
</library>
<library name="SparkFun-Passives">
<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: CC v3.0 Share-Alike 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="0805-CAP_POL">
<wire x1="-0.3" y1="-0.9" x2="-1.45" y2="-0.9" width="0.2032" layer="21"/>
<wire x1="-1.45" y1="-0.9" x2="-1.45" y2="0.9" width="0.2032" layer="21"/>
<wire x1="-1.45" y1="0.9" x2="-0.3" y2="0.9" width="0.2032" layer="21"/>
<wire x1="0.4" y1="-0.9" x2="1.25" y2="-0.9" width="0.2032" layer="21"/>
<wire x1="1.25" y1="-0.9" x2="1.45" y2="-0.7" width="0.2032" layer="21"/>
<wire x1="1.45" y1="-0.7" x2="1.45" y2="0.7" width="0.2032" layer="21"/>
<wire x1="1.45" y1="0.7" x2="1.25" y2="0.9" width="0.2032" layer="21"/>
<wire x1="1.25" y1="0.9" x2="0.4" y2="0.9" width="0.2032" layer="21"/>
<wire x1="0.131" y1="0.716" x2="0.131" y2="-0.716" width="0.127" layer="21"/>
<text x="-1.44" y="1.131" size="0.4064" layer="25">>NAME</text>
<text x="-1.442" y="-1.518" size="0.4064" layer="27">>VALUE</text>
<smd name="A" x="0.75" y="0" dx="0.8" dy="1.2" layer="1"/>
<smd name="C" x="-0.75" y="0" dx="0.8" dy="1.2" layer="1"/>
<rectangle x1="-1" y1="-0.45" x2="-0.5" y2="0.45" layer="51"/>
<rectangle x1="0.5" y1="-0.45" x2="1" y2="0.45" layer="51"/>
</package>
<package name="0805">
<wire x1="-0.3" y1="0.6" x2="0.3" y2="0.6" width="0.1524" layer="21"/>
<wire x1="-0.3" y1="-0.6" x2="0.3" y2="-0.6" width="0.1524" layer="21"/>
<smd name="1" x="-0.9" y="0" dx="0.8" dy="1.2" layer="1"/>
<smd name="2" x="0.9" y="0" dx="0.8" dy="1.2" layer="1"/>
<text x="-0.762" y="0.8255" size="0.4064" layer="25">>NAME</text>
<text x="-1.016" y="-1.397" size="0.4064" 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: CC v3.0 Share-Alike 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="SMA-EDGE">
<description>SMA Antenna Connector

This is a footprint for an edge mount RF antenna. Works pretty well with SMA type connectors but may also work with other edge mount RF connectors. Keep in mind, these edge mount connectors assume you are using a 0.062" PCB thickness.</description>
<smd name="GND@0" x="0" y="0" dx="1.524" dy="4.064" layer="1" cream="no"/>
<smd name="SIG" x="2.54" y="0" dx="1.524" dy="4.064" layer="1" cream="no"/>
<smd name="GND@1" x="5.08" y="0" dx="1.524" dy="4.064" layer="1" cream="no"/>
<smd name="GND@2" x="0" y="0" dx="1.524" dy="4.064" layer="16"/>
<smd name="GND@3" x="5.08" y="0" dx="1.524" dy="4.064" layer="16"/>
</package>
<package name="1X07">
<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="16.51" y1="0.635" x2="16.51" 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"/>
<pad name="7" x="15.24" 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"/>
</package>
</packages>
</library>
<library name="Passives">
<packages>
<package name="0805">
<wire x1="-0.3" y1="0.6" x2="0.3" y2="0.6" width="0.1524" layer="21"/>
<wire x1="-0.3" y1="-0.6" x2="0.3" y2="-0.6" width="0.1524" layer="21"/>
<smd name="1" x="-0.9" y="0" dx="0.8" dy="1.2" layer="1"/>
<smd name="2" x="0.9" y="0" dx="0.8" dy="1.2" layer="1"/>
<text x="-1.2" y="0.816" size="0.6096" layer="21" ratio="12">>NAME</text>
</package>
<package name="FA-238">
<smd name="3" x="1.1" y="0.8" dx="1.2" dy="1.4" layer="1" rot="R90"/>
<smd name="4" x="-1.1" y="0.8" dx="1.2" dy="1.4" layer="1" rot="R90"/>
<smd name="2" x="1.1" y="-0.8" dx="1.2" dy="1.4" layer="1" rot="R90"/>
<smd name="1" x="-1.1" y="-0.8" dx="1.2" dy="1.4" layer="1" rot="R90"/>
<wire x1="-1.6" y1="1.25" x2="1.6" y2="1.25" width="0.127" layer="51"/>
<wire x1="-1.6" y1="-1.25" x2="1.6" y2="-1.25" width="0.127" layer="51"/>
<wire x1="1.6" y1="1.25" x2="1.6" y2="-1.25" width="0.127" layer="51"/>
<wire x1="-1.6" y1="1.25" x2="-1.6" y2="-1.25" width="0.127" layer="51"/>
<polygon width="0.127" layer="51">
<vertex x="-1.6" y="1.25"/>
<vertex x="-1.6" y="0.45"/>
<vertex x="-0.7" y="0.45"/>
<vertex x="-0.7" y="1.25"/>
</polygon>
<polygon width="0.127" layer="51">
<vertex x="1.6" y="1.25"/>
<vertex x="0.7" y="1.25"/>
<vertex x="0.7" y="0.45"/>
<vertex x="1.6" y="0.45"/>
</polygon>
<polygon width="0.127" layer="51">
<vertex x="-1.6" y="-1.25"/>
<vertex x="-0.7" y="-1.25"/>
<vertex x="-0.7" y="-0.45"/>
<vertex x="-1.6" y="-0.45"/>
</polygon>
<polygon width="0.127" layer="51">
<vertex x="1.6" y="-1.25"/>
<vertex x="0.7" y="-1.25"/>
<vertex x="0.7" y="-0.45"/>
<vertex x="1.6" y="-0.45"/>
</polygon>
<wire x1="-0.2238" y1="1.25" x2="0.2238" y2="1.25" width="0.127" layer="21"/>
<wire x1="-1.6" y1="-0.0238" x2="-1.6" y2="0.0238" width="0.127" layer="21"/>
<wire x1="1.6" y1="-0.0238" x2="1.6" y2="0.0238" width="0.127" layer="21"/>
<wire x1="-0.2238" y1="-1.25" x2="0.2238" y2="-1.25" width="0.127" layer="21"/>
<wire x1="-0.05" y1="0.1" x2="0.05" y2="0.1" width="0.05" layer="51"/>
<wire x1="0.05" y1="0.1" x2="0.05" y2="-0.1" width="0.05" layer="51"/>
<wire x1="0.05" y1="-0.1" x2="-0.05" y2="-0.1" width="0.05" layer="51"/>
<wire x1="-0.05" y1="-0.1" x2="-0.05" y2="0.1" width="0.05" layer="51"/>
<wire x1="-0.15" y1="0.1" x2="-0.15" y2="0" width="0.05" layer="51"/>
<wire x1="-0.15" y1="0" x2="-0.15" y2="-0.1" width="0.05" layer="51"/>
<wire x1="0.15" y1="0.1" x2="0.15" y2="0" width="0.05" layer="51"/>
<wire x1="0.15" y1="0" x2="0.15" y2="-0.1" width="0.05" layer="51"/>
<wire x1="-0.15" y1="0" x2="-0.25" y2="0" width="0.05" layer="51"/>
<wire x1="-0.25" y1="0" x2="-0.7" y2="-0.45" width="0.05" layer="51"/>
<wire x1="0.15" y1="0" x2="0.25" y2="0" width="0.05" layer="51"/>
<wire x1="0.25" y1="0" x2="0.7" y2="0.45" width="0.05" layer="51"/>
<text x="-1.786" y="1.678" size="1.27" layer="21" ratio="12" align="bottom-right">>NAME</text>
</package>
<package name="RF_SHIELD-.65X.65">
<wire x1="-8.65" y1="8.65" x2="8.65" y2="8.65" width="0.127" layer="51"/>
<wire x1="8.65" y1="8.65" x2="8.65" y2="-8.65" width="0.127" layer="51"/>
<wire x1="8.65" y1="-8.65" x2="-8.65" y2="-8.65" width="0.127" layer="51"/>
<wire x1="-8.65" y1="-8.65" x2="-8.65" y2="8.65" width="0.127" layer="51"/>
<wire x1="-7.65" y1="-7.65" x2="-7.65" y2="7.65" width="0.127" layer="51"/>
<wire x1="-7.65" y1="7.65" x2="7.65" y2="7.65" width="0.127" layer="51"/>
<wire x1="7.65" y1="7.65" x2="7.65" y2="-7.65" width="0.127" layer="51"/>
<wire x1="7.65" y1="-7.65" x2="-7.65" y2="-7.65" width="0.127" layer="51"/>
<smd name="P$1" x="-8.15" y="-6.375" dx="4.55" dy="1" layer="1" rot="R90"/>
<smd name="P$2" x="-6.375" y="8.15" dx="4.55" dy="1" layer="1"/>
<smd name="P$3" x="8.15" y="6.375" dx="4.55" dy="1" layer="1" rot="R270"/>
<smd name="P$4" x="6.375" y="-8.15" dx="4.55" dy="1" layer="1" rot="R180"/>
<smd name="P$5" x="-8.15" y="0" dx="1" dy="3.8" layer="1"/>
<smd name="P$6" x="8.15" y="0" dx="1" dy="3.8" layer="1"/>
<smd name="P$7" x="0" y="8.15" dx="1" dy="3.8" layer="1" rot="R90"/>
<smd name="P$8" x="0" y="-8.15" dx="1" dy="3.8" layer="1" rot="R90"/>
<smd name="P$9" x="-8.15" y="5.875" dx="3.55" dy="1" layer="1" rot="R270"/>
<smd name="P$10" x="-5.875" y="-8.15" dx="3.55" dy="1" layer="1"/>
<smd name="P$11" x="8.15" y="-5.875" dx="3.55" dy="1" layer="1" rot="R90"/>
<smd name="P$12" x="5.875" y="8.15" dx="3.55" dy="1" layer="1" rot="R180"/>
</package>
</packages>
</library>
</libraries>
<attributes>
</attributes>
<variantdefs>
</variantdefs>
<classes>
<class number="0" name="default" width="0" drill="0">
</class>
<class number="1" name="rf" width="0" drill="0">
<clearance class="1" value="0.6"/>
</class>
</classes>
<designrules name="LaenPCBOrder *">
<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">Laen's PCB Order Design Rules

Please make sure your boards conform to these design rules.</description>
<param name="layerSetup" value="(1*16)"/>
<param name="mtCopper" value="0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm 0.0356mm"/>
<param name="mtIsolate" value="1.5011mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm 0.1499mm 0.2007mm"/>
<param name="mdWireWire" value="6mil"/>
<param name="mdWirePad" value="6mil"/>
<param name="mdWireVia" value="6mil"/>
<param name="mdPadPad" value="6mil"/>
<param name="mdPadVia" value="6mil"/>
<param name="mdViaVia" value="6mil"/>
<param name="mdSmdPad" value="6mil"/>
<param name="mdSmdVia" value="6mil"/>
<param name="mdSmdSmd" value="6mil"/>
<param name="mdViaViaSameLayer" value="8mil"/>
<param name="mnLayersViaInSmd" value="2"/>
<param name="mdCopperDimension" value="15mil"/>
<param name="mdDrill" value="6mil"/>
<param name="mdSmdStop" value="0mil"/>
<param name="msWidth" value="6mil"/>
<param name="msDrill" value="13mil"/>
<param name="msMicroVia" value="13mil"/>
<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="7mil"/>
<param name="rlMaxPadTop" value="20mil"/>
<param name="rlMinPadInner" value="7mil"/>
<param name="rlMaxPadInner" value="20mil"/>
<param name="rlMinPadBottom" value="7mil"/>
<param name="rlMaxPadBottom" value="20mil"/>
<param name="rlMinViaOuter" value="7mil"/>
<param name="rlMaxViaOuter" value="20mil"/>
<param name="rlMinViaInner" value="7mil"/>
<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="17mil"/>
<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="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="U1" library="Microchip" package="TSSOP-16" value="MRF49XA" x="8.89" y="8.89" smashed="yes" rot="R90">
<attribute name="NAME" x="5.085" y="5.113" size="0.6096" layer="21" ratio="12"/>
</element>
<element name="C1" library="SparkFun-Passives" package="0805-CAP_POL" value="10uF" x="14.986" y="11.303" smashed="yes" rot="R270">
<attribute name="NAME" x="14.943" y="9.005" size="0.6096" layer="21" ratio="12"/>
<attribute name="VALUE" x="13.468" y="12.745" size="0.6096" layer="27" rot="R270"/>
</element>
<element name="C2" library="SparkFun-Passives" package="0805" value="1.2pF" x="8.001" y="16.129" smashed="yes" rot="R90">
<attribute name="NAME" x="6.096" y="15.4305" size="0.6096" layer="21" ratio="12"/>
<attribute name="VALUE" x="9.398" y="15.113" size="0.6096" layer="27" rot="R90"/>
</element>
<element name="J$1" library="SparkFun-Connectors" package="SMA-EDGE" value="SMA_EDGE" x="10.16" y="22.987" smashed="yes"/>
<element name="L1" library="Passives" package="0805" value="100nH" x="5.842" y="13.716" smashed="yes">
<attribute name="NAME" x="3.372" y="13.135" size="0.6096" layer="21" ratio="12"/>
</element>
<element name="L2" library="Passives" package="0805" value="8.2nH" x="8.89" y="13.716" smashed="yes">
<attribute name="NAME" x="11.5" y="15.421" size="0.6096" layer="21" ratio="12"/>
</element>
<element name="L3" library="Passives" package="0805" value="22nH" x="9.779" y="16.129" smashed="yes" rot="R270">
<attribute name="NAME" x="11.5" y="16.437" size="0.6096" layer="21" ratio="12"/>
</element>
<element name="C3" library="SparkFun-Passives" package="0805" value="27pF" x="8.89" y="18.542" smashed="yes">
<attribute name="NAME" x="10.414" y="18.6055" size="0.6096" layer="21" ratio="12"/>
<attribute name="VALUE" x="7.874" y="17.145" size="0.6096" layer="27"/>
</element>
<element name="C4" library="SparkFun-Passives" package="0805" value="2.7pF" x="11.938" y="13.716" smashed="yes">
<attribute name="NAME" x="13.462" y="13.9065" size="0.6096" layer="21" ratio="12"/>
<attribute name="VALUE" x="10.922" y="12.319" size="0.6096" layer="27"/>
</element>
<element name="C5" library="SparkFun-Passives" package="0805" value="2.2nF" x="4.953" y="8.255" smashed="yes" rot="R90">
<attribute name="NAME" x="3.175" y="7.0485" size="0.6096" layer="21" ratio="12"/>
<attribute name="VALUE" x="6.35" y="7.239" size="0.6096" layer="27" rot="R90"/>
</element>
<element name="Y1" library="Passives" package="FA-238" value="10MHz" x="13.335" y="6.985" smashed="yes" rot="R270">
<attribute name="NAME" x="15.105" y="5.107" size="0.6096" layer="21" ratio="12"/>
</element>
<element name="C6" library="SparkFun-Passives" package="0805" value="0.1uF" x="12.827" y="11.176" smashed="yes" rot="R90">
<attribute name="NAME" x="12.192" y="9.0805" size="0.6096" layer="21" ratio="12"/>
<attribute name="VALUE" x="14.224" y="10.16" size="0.6096" layer="27" rot="R90"/>
</element>
<element name="JP1" library="SparkFun-Connectors" package="1X07" value="" x="1.905" y="1.651" smashed="yes">
<attribute name="VALUE" x="0.635" y="-1.524" size="1.27" layer="27"/>
</element>
<element name="C7" library="SparkFun-Passives" package="0805" value="2.2nF" x="4.953" y="11.303" smashed="yes" rot="R270">
<attribute name="NAME" x="3.175" y="9.9695" size="0.6096" layer="21" ratio="12"/>
<attribute name="VALUE" x="3.556" y="12.319" size="0.6096" layer="27" rot="R270"/>
</element>
<element name="U$1" library="Passives" package="RF_SHIELD-.65X.65" value="RF-SHIELD" x="9.652" y="11.938"/>
</elements>
<signals>
<signal name="N$1">
<contactref element="U1" pad="12"/>
<contactref element="L2" pad="2"/>
<contactref element="L3" pad="2"/>
<contactref element="C4" pad="1"/>
<wire x1="9.779" y1="15.229" x2="9.79" y2="15.218" width="0.7874" layer="1"/>
<wire x1="9.79" y1="15.218" x2="9.79" y2="13.716" width="0.7874" layer="1"/>
<wire x1="9.79" y1="13.716" x2="11.038" y2="13.716" width="0.7874" layer="1"/>
<wire x1="9.215" y1="11.84" x2="9.215" y2="13.025" width="0.4064" layer="1"/>
<wire x1="9.215" y1="13.025" x2="9.79" y2="13.6" width="0.4064" layer="1"/>
<wire x1="9.79" y1="13.6" x2="9.79" y2="13.716" width="0.4064" layer="1"/>
</signal>
<signal name="N$2">
<contactref element="U1" pad="13"/>
<contactref element="C2" pad="1"/>
<contactref element="L1" pad="2"/>
<contactref element="L2" pad="1"/>
<wire x1="8.001" y1="15.229" x2="7.99" y2="15.218" width="0.7874" layer="1"/>
<wire x1="7.99" y1="15.218" x2="7.99" y2="13.716" width="0.7874" layer="1"/>
<wire x1="6.742" y1="13.716" x2="7.99" y2="13.716" width="0.7874" layer="1"/>
<wire x1="8.565" y1="11.84" x2="8.565" y2="13.025" width="0.4064" layer="1"/>
<wire x1="8.565" y1="13.025" x2="7.99" y2="13.6" width="0.4064" layer="1"/>
<wire x1="7.99" y1="13.6" x2="7.99" y2="13.716" width="0.4064" layer="1"/>
</signal>
<signal name="N$3">
<contactref element="C2" pad="2"/>
<contactref element="L3" pad="1"/>
<contactref element="C3" pad="1"/>
<wire x1="7.99" y1="18.542" x2="7.99" y2="17.04" width="0.7874" layer="1"/>
<wire x1="7.99" y1="17.04" x2="8.001" y2="17.029" width="0.7874" layer="1"/>
<wire x1="8.001" y1="17.029" x2="9.779" y2="17.029" width="0.7874" layer="1"/>
</signal>
<signal name="3.3V">
<contactref element="L1" pad="1"/>
<contactref element="C7" pad="1"/>
<contactref element="U1" pad="14"/>
<contactref element="C1" pad="A"/>
<contactref element="C6" pad="1"/>
<contactref element="JP1" pad="1"/>
<wire x1="4.942" y1="13.716" x2="4.942" y2="12.214" width="0.7874" layer="1"/>
<wire x1="4.942" y1="12.214" x2="4.953" y2="12.203" width="0.7874" layer="1"/>
<wire x1="12.827" y1="10.276" x2="13.705" y2="10.276" width="0.4064" layer="1"/>
<wire x1="13.705" y1="10.276" x2="13.982" y2="10.553" width="0.4064" layer="1"/>
<wire x1="13.982" y1="10.553" x2="14.986" y2="10.553" width="0.4064" layer="1"/>
<wire x1="7.915" y1="11.84" x2="7.915" y2="9.992" width="0.4064" layer="1"/>
<wire x1="7.915" y1="9.992" x2="8.636" y2="9.271" width="0.4064" layer="1"/>
<wire x1="8.636" y1="9.271" x2="10.795" y2="9.271" width="0.4064" layer="1"/>
<wire x1="10.795" y1="9.271" x2="11.8" y2="10.276" width="0.4064" layer="1"/>
<wire x1="11.8" y1="10.276" x2="12.827" y2="10.276" width="0.4064" layer="1"/>
<via x="16.51" y="10.16" extent="1-16" drill="0.4064"/>
<wire x1="14.986" y1="10.553" x2="16.117" y2="10.553" width="0.4064" layer="1"/>
<wire x1="16.117" y1="10.553" x2="16.51" y2="10.16" width="0.4064" layer="1"/>
<wire x1="4.953" y1="12.203" x2="3.694" y2="12.203" width="0.4064" layer="1"/>
<wire x1="3.694" y1="12.203" x2="3.302" y2="11.811" width="0.4064" layer="1"/>
<via x="3.302" y="11.811" extent="1-16" drill="0.4064"/>
<wire x1="1.905" y1="1.651" x2="1.651" y2="1.905" width="0.4064" layer="16"/>
<wire x1="1.651" y1="1.905" x2="1.651" y2="10.16" width="0.4064" layer="16"/>
<wire x1="1.651" y1="10.16" x2="3.302" y2="11.811" width="0.4064" layer="16"/>
<wire x1="3.302" y1="11.811" x2="14.859" y2="11.811" width="0.4064" layer="16"/>
<wire x1="14.859" y1="11.811" x2="16.51" y2="10.16" width="0.4064" layer="16"/>
</signal>
<signal name="GND">
<contactref element="C4" pad="2"/>
<contactref element="J$1" pad="GND@0"/>
<contactref element="J$1" pad="GND@3"/>
<contactref element="J$1" pad="GND@2"/>
<contactref element="J$1" pad="GND@1"/>
<contactref element="U1" pad="11"/>
<contactref element="C5" pad="2"/>
<contactref element="Y1" pad="2"/>
<contactref element="Y1" pad="4"/>
<contactref element="Y1" pad="3"/>
<contactref element="C1" pad="C"/>
<contactref element="C6" pad="2"/>
<contactref element="JP1" pad="7"/>
<contactref element="C7" pad="2"/>
<polygon width="0.4064" layer="1">
<vertex x="-1.27" y="26.67"/>
<vertex x="20.32" y="26.67"/>
<vertex x="20.32" y="-1.27"/>
<vertex x="-1.27" y="-1.27"/>
</polygon>
<polygon width="0.4064" layer="16">
<vertex x="-2.54" y="27.94"/>
<vertex x="21.59" y="27.94"/>
<vertex x="21.59" y="-2.54"/>
<vertex x="-2.54" y="-2.54"/>
</polygon>
<via x="9.779" y="10.287" extent="1-16" drill="0.4064"/>
<via x="6.223" y="10.033" extent="1-16" drill="0.4064"/>
<via x="13.97" y="13.335" extent="1-16" drill="0.4064"/>
<via x="13.97" y="14.986" extent="1-16" drill="0.4064"/>
<via x="11.049" y="14.986" extent="1-16" drill="0.4064"/>
<via x="18.161" y="24.638" extent="1-16" drill="0.4064"/>
<via x="18.161" y="23.114" extent="1-16" drill="0.4064"/>
<wire x1="12.838" y1="13.716" x2="12.838" y2="12.087" width="0.4064" layer="1"/>
<wire x1="12.838" y1="12.087" x2="12.827" y2="12.076" width="0.4064" layer="1"/>
<via x="6.731" y="14.986" extent="1-16" drill="0.4064"/>
<via x="6.731" y="16.383" extent="1-16" drill="0.4064"/>
<via x="5.461" y="18.923" extent="1-16" drill="0.4064"/>
<via x="8.763" y="24.638" extent="1-16" drill="0.4064"/>
<via x="7.239" y="24.638" extent="1-16" drill="0.4064"/>
<via x="5.715" y="24.638" extent="1-16" drill="0.4064"/>
<via x="4.191" y="24.638" extent="1-16" drill="0.4064"/>
<via x="2.54" y="24.638" extent="1-16" drill="0.4064"/>
<via x="0.889" y="24.638" extent="1-16" drill="0.4064"/>
<via x="0.889" y="23.114" extent="1-16" drill="0.4064"/>
<via x="6.731" y="18.923" extent="1-16" drill="0.4064"/>
<via x="2.667" y="18.923" extent="1-16" drill="0.4064"/>
<via x="2.667" y="17.399" extent="1-16" drill="0.4064"/>
<via x="2.667" y="15.875" extent="1-16" drill="0.4064"/>
<via x="2.667" y="14.351" extent="1-16" drill="0.4064"/>
<via x="4.191" y="4.953" extent="1-16" drill="0.4064"/>
<via x="2.667" y="4.953" extent="1-16" drill="0.4064"/>
<via x="2.667" y="8.255" extent="1-16" drill="0.4064"/>
<via x="2.667" y="6.604" extent="1-16" drill="0.4064"/>
<via x="6.731" y="17.653" extent="1-16" drill="0.4064"/>
<via x="0.889" y="21.59" extent="1-16" drill="0.4064"/>
<via x="18.161" y="21.59" extent="1-16" drill="0.4064"/>
<via x="2.667" y="12.827" extent="1-16" drill="0.4064"/>
<via x="2.667" y="9.779" extent="1-16" drill="0.4064"/>
<via x="13.716" y="18.923" extent="1-16" drill="0.4064"/>
<via x="12.7" y="17.78" extent="1-16" drill="0.4064"/>
<via x="16.637" y="18.923" extent="1-16" drill="0.4064"/>
<via x="15.113" y="18.923" extent="1-16" drill="0.4064"/>
<via x="16.637" y="17.399" extent="1-16" drill="0.4064"/>
<via x="16.637" y="15.875" extent="1-16" drill="0.4064"/>
<via x="16.637" y="14.351" extent="1-16" drill="0.4064"/>
<via x="12.446" y="14.986" extent="1-16" drill="0.4064"/>
<via x="16.637" y="12.827" extent="1-16" drill="0.4064"/>
<via x="16.637" y="11.303" extent="1-16" drill="0.4064"/>
<via x="16.637" y="4.953" extent="1-16" drill="0.4064"/>
<via x="16.637" y="8.255" extent="1-16" drill="0.4064"/>
<via x="16.637" y="6.604" extent="1-16" drill="0.4064"/>
<contactref element="U$1" pad="P$8"/>
<contactref element="U$1" pad="P$2"/>
<contactref element="U$1" pad="P$10"/>
<contactref element="U$1" pad="P$5"/>
<contactref element="U$1" pad="P$12"/>
<contactref element="U$1" pad="P$1"/>
<contactref element="U$1" pad="P$3"/>
<contactref element="U$1" pad="P$4"/>
<contactref element="U$1" pad="P$9"/>
<contactref element="U$1" pad="P$6"/>
<contactref element="U$1" pad="P$7"/>
<contactref element="U$1" pad="P$11"/>
<via x="11.049" y="17.145" extent="1-16" drill="0.4064"/>
<via x="15.24" y="13.335" extent="1-16" drill="0.4064"/>
<via x="5.207" y="14.986" extent="1-16" drill="0.4064"/>
<via x="4.064" y="18.923" extent="1-16" drill="0.4064"/>
<via x="16.637" y="24.638" extent="1-16" drill="0.4064"/>
</signal>
<signal name="N$5">
<contactref element="C3" pad="2"/>
<contactref element="J$1" pad="SIG"/>
<wire x1="11.049" y1="18.542" x2="12.7" y2="20.193" width="1.1938" layer="1" curve="90"/>
<wire x1="12.7" y1="20.193" x2="12.7" y2="22.987" width="1.1938" layer="1"/>
<wire x1="9.79" y1="18.542" x2="10.033" y2="18.542" width="0.7874" layer="1"/>
<wire x1="10.033" y1="18.542" x2="11.049" y2="18.542" width="1.1938" layer="1"/>
</signal>
<signal name="RSSIO">
<contactref element="U1" pad="15"/>
<contactref element="C5" pad="1"/>
<wire x1="7.265" y1="11.84" x2="7.265" y2="9.434971875" width="0.4064" layer="1"/>
<wire x1="7.265" y1="9.434971875" x2="5.185028125" y2="7.355" width="0.4064" layer="1"/>
<wire x1="5.185028125" y1="7.355" x2="4.953" y2="7.355" width="0.4064" layer="1"/>
<contactref element="JP1" pad="2"/>
<wire x1="4.953" y1="7.355" x2="5.08" y2="7.239" width="0.4064" layer="1"/>
<wire x1="5.08" y1="7.239" x2="5.08" y2="6.096" width="0.4064" layer="1"/>
<via x="5.08" y="6.096" extent="1-16" drill="0.4064"/>
<wire x1="5.08" y1="6.096" x2="5.08" y2="2.286" width="0.4064" layer="16"/>
<wire x1="5.08" y1="2.286" x2="4.445" y2="1.651" width="0.4064" layer="16"/>
</signal>
<signal name="SS">
<contactref element="U1" pad="3"/>
<contactref element="JP1" pad="5"/>
<wire x1="7.915" y1="5.94" x2="7.915" y2="7.407" width="0.4064" layer="1"/>
<wire x1="7.915" y1="7.407" x2="8.89" y2="8.382" width="0.4064" layer="1"/>
<wire x1="8.89" y1="8.382" x2="9.398" y2="8.382" width="0.4064" layer="1"/>
<via x="9.398" y="8.382" extent="1-16" drill="0.4064"/>
<wire x1="9.398" y1="8.382" x2="9.271" y2="8.255" width="0.4064" layer="16"/>
<wire x1="9.271" y1="8.255" x2="9.271" y2="7.239" width="0.4064" layer="16"/>
<wire x1="9.271" y1="7.239" x2="12.065" y2="4.445" width="0.4064" layer="16"/>
<wire x1="12.065" y1="4.445" x2="12.065" y2="1.651" width="0.4064" layer="16"/>
</signal>
<signal name="SCK">
<contactref element="U1" pad="2"/>
<contactref element="JP1" pad="4"/>
<wire x1="7.265" y1="5.94" x2="7.265" y2="8.027" width="0.4064" layer="1"/>
<wire x1="7.265" y1="8.027" x2="7.874" y2="8.636" width="0.4064" layer="1"/>
<via x="7.874" y="8.636" extent="1-16" drill="0.4064"/>
<wire x1="7.874" y1="8.636" x2="7.874" y2="7.62" width="0.4064" layer="16"/>
<wire x1="7.874" y1="7.62" x2="9.525" y2="5.969" width="0.4064" layer="16"/>
<wire x1="9.525" y1="5.969" x2="9.525" y2="1.651" width="0.4064" layer="16"/>
</signal>
<signal name="SDI">
<contactref element="U1" pad="1"/>
<contactref element="JP1" pad="3"/>
<wire x1="6.615" y1="5.94" x2="6.615" y2="7.101" width="0.4064" layer="1"/>
<wire x1="6.615" y1="7.101" x2="6.35" y2="7.366" width="0.4064" layer="1"/>
<via x="6.35" y="7.366" extent="1-16" drill="0.4064"/>
<wire x1="6.35" y1="7.366" x2="6.985" y2="6.731" width="0.4064" layer="16"/>
<wire x1="6.985" y1="6.731" x2="6.985" y2="1.651" width="0.4064" layer="16"/>
</signal>
<signal name="SDO">
<contactref element="U1" pad="4"/>
<contactref element="JP1" pad="6"/>
<wire x1="8.565" y1="5.94" x2="8.565" y2="7.041" width="0.4064" layer="1"/>
<wire x1="8.565" y1="7.041" x2="9.017" y2="7.493" width="0.4064" layer="1"/>
<wire x1="9.017" y1="7.493" x2="10.16" y2="7.493" width="0.4064" layer="1"/>
<via x="10.16" y="7.493" extent="1-16" drill="0.4064"/>
<wire x1="10.16" y1="7.493" x2="14.605" y2="3.048" width="0.4064" layer="16"/>
<wire x1="14.605" y1="3.048" x2="14.605" y2="1.651" width="0.4064" layer="16"/>
</signal>
<signal name="N$12">
<contactref element="U1" pad="8"/>
<contactref element="Y1" pad="1"/>
<wire x1="12.535" y1="8.085" x2="11.641" y2="8.085" width="0.4064" layer="1"/>
<wire x1="11.641" y1="8.085" x2="11.165" y2="7.609" width="0.4064" layer="1"/>
<wire x1="11.165" y1="7.609" x2="11.165" y2="5.94" width="0.4064" layer="1"/>
</signal>
</signals>
</board>
</drawing>
</eagle>

license: MIT

path: /MRF49XA Breakout.brd

filename: MRF49XA Breakout.brd


text:
//go:build !test
// +build !test

package resourcestore

// defaultRetryTimes defines the amount of default retries for each cleanup
// function.
var defaultRetryTimes = 20

repository: cri-o/cri-o

license_type: permissive

repo_name: cri-o/cri-o

branch_name: refs/heads/main

gha_language: Go

extension: go


text:
/*
	A queue gives you a FIFO or first-in firs-out order.
	The element you inserted first is also the first one to come out again.
*/
package queue

import (
	"sync"

	. "github.com/zrcoder/dsGo"
	base "github.com/zrcoder/dsGo/base/queue"
)

type Queen struct {
	sync.Mutex
	inner *base.Queen
}

func New() *Queen {
	return &Queen{inner: base.New()}
}

// put a given item into the queue
func (q *Queen) Enqueue(item Any) {
	q.Lock()
	q.inner.Enqueue(item)
	q.Unlock()
}

// remove the first item from the queue and returns it
func (q *Queen) Dequeue() Any {
	q.Lock()
	item := q.inner.Dequeue()
	q.Unlock()
	return item
}

repository: fguby/dsGo

repo_name: fguby/dsGo

branch_name: refs/heads/master


text:
########################################################
# tf_core_profiler library
########################################################

file(GLOB_RECURSE tf_core_profiler_srcs
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/*.proto"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/tfprof_options.h"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/tfprof_options.cc"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/internal/*.h"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/internal/*.cc"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/internal/advisor/*.h"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/internal/advisor/*.cc"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/platform/regexp.h"
)

file(GLOB_RECURSE tf_core_profiler_exclude_srcs
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/internal/*test.cc"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/internal/advisor/*test.cc"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/internal/print_model_analysis.cc"
    "${PROJECT_SOURCE_DIR}/tensorflow/core/profiler/internal/print_model_analysis.h"
)
list(REMOVE_ITEM tf_core_profiler_srcs ${tf_core_profiler_exclude_srcs})

add_library(tf_core_profiler OBJECT
    ${tf_core_profiler_srcs}
)
add_dependencies(tf_core_profiler
    tf_core_lib
)

repository: Yeolar/tension

repo_name: Yeolar/tension

extension: cmake


text:
DESCRIPTION = "High-accuracy NES and Famicom emulator"

LICENSE = "GPLv3"
LIC_FILES_CHKSUM = "file://LICENSE;md5=d32239bcb673463ab874e80d47fae504"

inherit libretro

LIBRETRO_GIT_REPO = "github.com/SourMesen/Mesen.git"

LIBRETRO_MAKEFILE_PREFIX = "Libretro"
LIBRETRO_CORE = "Libretro/mesen"

repository: hansenlabs/meta-retro

repo_name: hansenlabs/meta-retro

extension: bb


text:
using LNF.Repository;
using System;
using System.Collections.Generic;
using System.Data;

namespace sselData.AppCode.DAL
{
    public class UserGroupDA
    {
        public static DataTable GetAllUserGroups()
        {
            return DataCommand.Create()
                .Param("Action", "All")
                .FillDataTable("UserGroup_Select");
        }

        [Obsolete("No longer used?")]
        public static List<int> GetUserGroupIDs()
        {
            List<int> result = new List<int>();
            var cmd = DataCommand.Create().Param("Action", "All");
            using (var reader = cmd.ExecuteReader("ClientOrgUserGroupTS"))
            {
                while (reader.Read())
                    result.Add(reader.Value("UserGroupID", 0));
            }
            return result;
        }
    }
}

repository: lurienanofab/sseldata

repo_name: lurienanofab/sseldata

extension: cs


text:
DESCRIPTION = "Params::Validate - Validate method/function parameters"
SECTION = "libs"
LICENSE = "Artistic|GPL"
PR = "r13"

SRC_URI = "http://search.cpan.org/CPAN/authors/id/D/DR/DROLSKY/Params-Validate-${PV}.tar.gz"

S = "${WORKDIR}/Params-Validate-${PV}"

inherit cpan

FILES_${PN} = "${PERLLIBDIRS}/auto/Params/Validate/* \
                ${PERLLIBDIRS}/Params \
                ${PERLLIBDIRS}/Attribute"


text:
using System;

using UnityEngine;

namespace pdxpartyparrot.Game.Data
{
    [CreateAssetMenu(fileName="CreditsData", menuName="pdxpartyparrot/Game/Data/Credits Data")]
    [Serializable]
    public sealed class CreditsData : ScriptableObject
    {
        [Serializable]
        public struct Credits
        {
            public string title;

            public string[] contributor;
        }

        [SerializeField]
        private Credits[] _credits;
    }
}

gha_language: C#


text:
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

#nullable disable

using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.CodeAnalysis.Editor.Shared.Extensions;
using Microsoft.CodeAnalysis.Editor.Shared.Utilities;
using Microsoft.CodeAnalysis.Editor.Undo;
using Microsoft.CodeAnalysis.LanguageService;
using Microsoft.CodeAnalysis.Notification;
using Microsoft.CodeAnalysis.Rename;
using Microsoft.CodeAnalysis.Shared.Extensions;
using Microsoft.CodeAnalysis.Text;
using Microsoft.VisualStudio.Text;
using Microsoft.VisualStudio.Text.Operations;
using Roslyn.Utilities;

namespace Microsoft.CodeAnalysis.Editor.Implementation.RenameTracking
{
    internal sealed partial class RenameTrackingTaggerProvider
    {
        private class RenameTrackingCommitter
        {
            private readonly StateMachine _stateMachine;
            private readonly SnapshotSpan _snapshotSpan;
            private readonly IEnumerable<IRefactorNotifyService> _refactorNotifyServices;
            private readonly ITextUndoHistoryRegistry _undoHistoryRegistry;
            private readonly string _displayText;
            private readonly AsyncLazy<RenameTrackingSolutionSet> _renameSymbolResultGetter;

            public RenameTrackingCommitter(
                StateMachine stateMachine,
                SnapshotSpan snapshotSpan,
                IEnumerable<IRefactorNotifyService> refactorNotifyServices,
                ITextUndoHistoryRegistry undoHistoryRegistry,
                string displayText)
            {
                _stateMachine = stateMachine;
                _snapshotSpan = snapshotSpan;
                _refactorNotifyServices = refactorNotifyServices;
                _undoHistoryRegistry = undoHistoryRegistry;
                _displayText = displayText;
                _renameSymbolResultGetter = AsyncLazy.Create(c => RenameSymbolWorkerAsync(c));
            }

            /// <summary>
            /// Returns non-null error message if renaming fails.
            /// </summary>
            public async Task<(NotificationSeverity severity, string message)?> TryCommitAsync(CancellationToken cancellationToken)
            {
                _stateMachine.ThreadingContext.ThrowIfNotOnUIThread();

                try
                {
                    return await TryApplyChangesToWorkspaceAsync(cancellationToken).ConfigureAwait(false);
                }
                finally
                {
                    // Clear the state machine so that future updates to the same token work, and any text changes
                    // caused by this update are not interpreted as potential renames.  Intentionally pass
                    // CancellationToken.None.  We must clear this state out.
                    await _stateMachine.ThreadingContext.JoinableTaskFactory.SwitchToMainThreadAsync(CancellationToken.None);
                    _stateMachine.ClearTrackingSession();
                }
            }

            public async Task<RenameTrackingSolutionSet> RenameSymbolAsync(CancellationToken cancellationToken)
                => await _renameSymbolResultGetter.GetValueAsync(cancellationToken).ConfigureAwait(false);

            private async Task<RenameTrackingSolutionSet> RenameSymbolWorkerAsync(CancellationToken cancellationToken)
            {
                var document = _snapshotSpan.Snapshot.GetOpenDocumentInCurrentContextWithChanges();
                var newName = _snapshotSpan.GetText();

                Contract.ThrowIfNull(document, "Invoked rename tracking smart tag but cannot find the document for the snapshot span.");

                // Get copy of solution with the original name in the place of the renamed name
                var solutionWithOriginalName = await CreateSolutionWithOriginalNameAsync(
                    document, cancellationToken).ConfigureAwait(false);

                var symbol = await TryGetSymbolAsync(solutionWithOriginalName, document.Id, cancellationToken).ConfigureAwait(false);
                Contract.ThrowIfNull(symbol, "Invoked rename tracking smart tag but cannot find the symbol.");

                var options = new SymbolRenameOptions(RenameOverloads: _stateMachine.TrackingSession.ForceRenameOverloads);
                var renamedSolution = await Renamer.RenameSymbolAsync(solutionWithOriginalName, symbol, options, newName, cancellationToken).ConfigureAwait(false);
                return new RenameTrackingSolutionSet(symbol, solutionWithOriginalName, renamedSolution);
            }

            /// <summary>
            /// Returns non-null error message if renaming fails.
            /// </summary>
            private async Task<(NotificationSeverity, string)?> TryApplyChangesToWorkspaceAsync(CancellationToken cancellationToken)
            {
                // Now that the necessary work has been done to create the intermediate and final
                // solutions during PreparePreview, check one more time for cancellation before making all of the
                // workspace changes.
                cancellationToken.ThrowIfCancellationRequested();

                // Undo must backtrack to the state with the original identifier before the state
                // with the user-edited identifier. For example,
                //
                //   1. Original:                           void M() { M(); }
                //   2. User types:                         void Method() { M(); }
                //   3. Invoke rename:                      void Method() { Method(); }
                //
                // The undo process should be as follows
                //   1. Back to original name everywhere:   void M() { M(); }       // No tracking session
                //   2. Back to state 2 above:              void Method() { M(); }  // Resume tracking session
                //   3. Finally, start undoing typing:      void M() { M(); }
                //
                // As far as the user can see, undo state 1 never actually existed so we must insert
                // a state here to facilitate the undo. Do the work to obtain the intermediate and
                // final solution without updating the workspace, and then finally disallow
                // cancellation and update the workspace twice.

                var renameTrackingSolutionSet = await RenameSymbolAsync(cancellationToken).ConfigureAwait(false);

                var document = _snapshotSpan.Snapshot.GetOpenDocumentInCurrentContextWithChanges();
                var newName = _snapshotSpan.GetText();

                var workspace = document.Project.Solution.Workspace;

                // Since the state machine is only watching buffer changes, it will interpret the
                // text changes caused by undo and redo actions as potential renames, so carefully
                // update the state machine after undo/redo actions.

                var changedDocuments = renameTrackingSolutionSet.RenamedSolution.GetChangedDocuments(renameTrackingSolutionSet.OriginalSolution);
                try
                {
                    // When this action is undone (the user has undone twice), restore the state
                    // machine to so that they can continue their original rename tracking session.

                    await _stateMachine.ThreadingContext.JoinableTaskFactory.SwitchToMainThreadAsync(cancellationToken);
                    var trackingSessionId = _stateMachine.StoreCurrentTrackingSessionAndGenerateId();
                    var result = TryUpdateWorkspaceForResetOfTypedIdentifier(workspace, renameTrackingSolutionSet.OriginalSolution, trackingSessionId);
                    if (result is not null)
                        return result;

                    // Now that the solution is back in its original state, notify third parties about
                    // the coming rename operation.
                    if (!_refactorNotifyServices.TryOnBeforeGlobalSymbolRenamed(workspace, changedDocuments, renameTrackingSolutionSet.Symbol, newName, throwOnFailure: false))
                        return (NotificationSeverity.Error, EditorFeaturesResources.Rename_operation_was_cancelled_or_is_not_valid);

                    // move all changes to final solution based on the workspace's current solution, since the current solution
                    // got updated when we reset it above.
                    var finalSolution = workspace.CurrentSolution;
                    foreach (var docId in changedDocuments)
                    {
                        // because changes have already been made to the workspace (UpdateWorkspaceForResetOfTypedIdentifier() above),
                        // these calls can't be cancelled and must be allowed to complete.
                        var root = await renameTrackingSolutionSet.RenamedSolution.GetDocument(docId).GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
                        finalSolution = finalSolution.WithDocumentSyntaxRoot(docId, root);
                    }

                    // Undo/redo on this action must always clear the state machine
                    await _stateMachine.ThreadingContext.JoinableTaskFactory.SwitchToMainThreadAsync(cancellationToken);
                    return TryUpdateWorkspaceForGlobalIdentifierRename(
                        workspace,
                        finalSolution,
                        _displayText,
                        changedDocuments,
                        renameTrackingSolutionSet.Symbol,
                        newName,
                        trackingSessionId);
                }
                finally
                {
                    // Explicit CancellationToken.None here.  We must clean up our state no matter what.
                    await _stateMachine.ThreadingContext.JoinableTaskFactory.SwitchToMainThreadAsync(CancellationToken.None);
                    RenameTrackingDismisser.DismissRenameTracking(workspace, changedDocuments);
                }
            }

            private async Task<Solution> CreateSolutionWithOriginalNameAsync(
                Document document, CancellationToken cancellationToken)
            {
                var syntaxTree = await document.GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false);
                var fullText = syntaxTree.GetText(cancellationToken);
                var textChange = new TextChange(new TextSpan(_snapshotSpan.Start, _snapshotSpan.Length), _stateMachine.TrackingSession.OriginalName);

                var newFullText = fullText.WithChanges(textChange);
#if DEBUG
                var syntaxTreeWithOriginalName = syntaxTree.WithChangedText(newFullText);
                var documentWithOriginalName = document.WithSyntaxRoot(syntaxTreeWithOriginalName.GetRoot(cancellationToken));

                Debug.Assert(newFullText.ToString() == documentWithOriginalName.GetTextSynchronously(cancellationToken).ToString());
#endif

                // Apply the original name to all linked documents to construct a consistent solution
                var solution = document.Project.Solution;
                foreach (var documentId in document.GetLinkedDocumentIds().Add(document.Id))
                {
                    solution = solution.WithDocumentText(documentId, newFullText);
                }

                return solution;
            }

            private async Task<ISymbol> TryGetSymbolAsync(Solution solutionWithOriginalName, DocumentId documentId, CancellationToken cancellationToken)
            {
                var documentWithOriginalName = solutionWithOriginalName.GetDocument(documentId);
                var syntaxTreeWithOriginalName = await documentWithOriginalName.GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false);

                var syntaxFacts = documentWithOriginalName.GetLanguageService<ISyntaxFactsService>();
                var semanticFacts = documentWithOriginalName.GetLanguageService<ISemanticFactsService>();
                var semanticModel = await documentWithOriginalName.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);

                var token = await syntaxTreeWithOriginalName.GetTouchingWordAsync(_snapshotSpan.Start, syntaxFacts, cancellationToken).ConfigureAwait(false);
                var tokenRenameInfo = RenameUtilities.GetTokenRenameInfo(semanticFacts, semanticModel, token, cancellationToken);

                return tokenRenameInfo.HasSymbols ? tokenRenameInfo.Symbols.First() : null;
            }

            /// <summary>
            /// Returns non-null error message if renaming fails.
            /// </summary>
            private (NotificationSeverity, string)? TryUpdateWorkspaceForResetOfTypedIdentifier(Workspace workspace, Solution newSolution, int trackingSessionId)
            {
                _stateMachine.ThreadingContext.ThrowIfNotOnUIThread();

                // Update document in an ITextUndoTransaction with custom behaviors on undo/redo to
                // deal with the state machine.

                var undoHistory = _undoHistoryRegistry.RegisterHistory(_stateMachine.Buffer);
                using var localUndoTransaction = undoHistory.CreateTransaction(EditorFeaturesResources.Text_Buffer_Change);

                var undoPrimitiveBefore = new UndoPrimitive(_stateMachine.Buffer, trackingSessionId, shouldRestoreStateOnUndo: true);
                localUndoTransaction.AddUndo(undoPrimitiveBefore);

                if (!workspace.TryApplyChanges(newSolution))
                    return (NotificationSeverity.Error, EditorFeaturesResources.Rename_operation_could_not_complete_due_to_external_change_to_workspace);

                // If we successfully updated the workspace then make sure the undo transaction is committed and is
                // always able to undo anything any other external listener did.

                // Never resume tracking session on redo
                var undoPrimitiveAfter = new UndoPrimitive(_stateMachine.Buffer, trackingSessionId, shouldRestoreStateOnUndo: false);
                localUndoTransaction.AddUndo(undoPrimitiveAfter);

                localUndoTransaction.Complete();

                return null;
            }

            /// <summary>
            /// Returns non-null error message if renaming fails.
            /// </summary>
            private (NotificationSeverity, string)? TryUpdateWorkspaceForGlobalIdentifierRename(
                Workspace workspace,
                Solution newSolution,
                string undoName,
                IEnumerable<DocumentId> changedDocuments,
                ISymbol symbol,
                string newName,
                int trackingSessionId)
            {
                _stateMachine.ThreadingContext.ThrowIfNotOnUIThread();

                // Perform rename in a workspace undo action so that undo will revert all
                // references. It should also be performed in an ITextUndoTransaction to handle

                var undoHistory = _undoHistoryRegistry.RegisterHistory(_stateMachine.Buffer);

                using var workspaceUndoTransaction = workspace.OpenGlobalUndoTransaction(undoName);
                using var localUndoTransaction = undoHistory.CreateTransaction(undoName);

                var undoPrimitiveBefore = new UndoPrimitive(_stateMachine.Buffer, trackingSessionId, shouldRestoreStateOnUndo: false);
                localUndoTransaction.AddUndo(undoPrimitiveBefore);

                if (!workspace.TryApplyChanges(newSolution))
                    return (NotificationSeverity.Error, EditorFeaturesResources.Rename_operation_could_not_complete_due_to_external_change_to_workspace);

                try
                {
                    if (!_refactorNotifyServices.TryOnAfterGlobalSymbolRenamed(workspace, changedDocuments, symbol, newName, throwOnFailure: false))
                        return (NotificationSeverity.Information, EditorFeaturesResources.Rename_operation_was_not_properly_completed_Some_file_might_not_have_been_updated);

                    return null;
                }
                finally
                {
                    // If we successfully updated the workspace then make sure the undo transaction is committed and is
                    // always able to undo anything any other external listener did.

                    // Never resume tracking session on redo
                    var undoPrimitiveAfter = new UndoPrimitive(_stateMachine.Buffer, trackingSessionId, shouldRestoreStateOnUndo: false);
                    localUndoTransaction.AddUndo(undoPrimitiveAfter);

                    localUndoTransaction.Complete();
                    workspaceUndoTransaction.Commit();
                }
            }
        }
    }
}

repository: dotnet/roslyn

repo_name: dotnet/roslyn

gha_license_id: MIT


text:
#include <WebUSB.h>

// bitcoin library
#include <Bitcoin.h>
#include <Hash.h>

// screen libs
#include <Wire.h>
#include <Adafruit_GFX.h>
#include <Adafruit_SSD1306.h>
#include <Adafruit_FeatherOLED.h>

// SD card libs
#include <SPI.h>
#include <SD.h>

// root key (master)
HDPrivateKey rootKey;
// account key (m/44'/1'/0'/)
HDPrivateKey hd;

// the screen
Adafruit_FeatherOLED oled = Adafruit_FeatherOLED();

// set to false to use on mainnet
#define USE_TESTNET true

WebUSB WebUSBSerial(1 /* https:// */, "localhost:3000");

#define Serial WebUSBSerial

// cleans the display and shows message on the screen
void show(String msg, bool done=true){
    oled.clearDisplay();
    oled.setCursor(0,0);
    oled.println(msg);
    if(done){
        oled.display();
    }
}

void send_command(String command, String payload) {
    Serial.println(command + "," + payload);
}

// uses last bit of the analogRead values
// to generate a random byte
byte getRandomByte(int analogInput = A0){
    byte val = 0;
    for(int i = 0; i < 8; i++){
        int init = analogRead(analogInput);
        int count = 0;
        // waiting for analog value to change
        while(analogRead(analogInput) == init){
            ++count;
        }
        // if we've got a new value right away
        // use last bit of the ADC
        if (count == 0) {
            val = (val << 1) | (init & 0x01);
        } else { // if not, use last bit of count
            val = (val << 1) | (count & 0x01);
        }
    }
}

HDPrivateKey getRandomKey(int analogInput = A0){
    byte seed[64];
    // fill seed with random bytes
    for(int i=0; i<sizeof(seed); i++){
        seed[i] = getRandomByte(analogInput);
    }
    // increase randomness by applying sha512
    // seed -> sha512(seed)
    sha512(seed, sizeof(seed), seed);
    HDPrivateKey key;
    key.fromSeed(seed, sizeof(seed), USE_TESTNET);
    return key;
}

// This function displays info about transaction.
// As OLED screen is small we show one output at a time
// and use Button B to switch to the next output
// Buttons A and C work as Confirm and Cancel
bool requestTransactionSignature(Transaction tx){
    // when digital pins are set with INPUT_PULLUP in the setup
    // they show 1 when not pressed, so we need to invert them
    bool confirm = !digitalRead(9);
    bool not_confirm = !digitalRead(5);
    bool more_info = !digitalRead(6);
    int i = 0; // index of output that we show
    // waiting for user to confirm / cancel
    while((!confirm && !not_confirm)){
        // show one output on the screen
        oled.clearDisplay();
        oled.setCursor(0,0);
        oled.print("Sign? Output ");
        oled.print(i);
        oled.println();
        TransactionOutput output = tx.txOuts[i];
        oled.print(output.address(USE_TESTNET));
        oled.println(":");
        oled.print(((float)output.amount)/100000);
        oled.print(" mBTC");
        oled.display();
        // waiting user to press any button
        while((!confirm && !not_confirm && !more_info)){
            confirm = !digitalRead(9);
            not_confirm = !digitalRead(5);
            more_info = !digitalRead(6);
        }
        delay(300); // wait to release the button
        more_info = false; // reset to default
        // scrolling output
        i++;
        if(i >= tx.outputsNumber){
            i=0;
        }
    }
    if(confirm){
        show("Ok, confirmed.\nSigning...");
        return true;
    }else{
        show("Cancelled");
        return false;
    }
}

void sign_tx(char * cmd){
    String success_command = String("sign_tx");
    String error_command = String("sign_tx_error");
    Transaction tx;
    // first we need to convert tx from hex
    byte raw_tx[2000];
    bool electrum = false;
    size_t l = fromHex(cmd, strlen(cmd), raw_tx, sizeof(raw_tx));
    if(l == 0){
        show("can't decode tx from hex");
        send_command(error_command, "can't decode tx from hex");
        return;
    }
    size_t l_parsed;
    // check if transaction is from electrum
    if(memcmp(raw_tx,"EPTF",4)==0){
        // if electrum transaction
        l_parsed = tx.parse(raw_tx+6, l-6);
        electrum = true;
    }else if(memcmp(raw_tx, "PSBT", 4)==0){
        // TODO: add PSBT support
        send_command(error_command, "PSBT is not supported yet");
        return;
    }else{
        l_parsed = tx.parse(raw_tx, l);
    }
    // then we parse transaction
    if(l_parsed == 0){
        show("can't parse tx");
        send_command(error_command, "can't parse tx");
        return;
    }
    bool ok = requestTransactionSignature(tx);
    if(ok){
        for(int i=0; i<tx.inputsNumber; i++){
            // default path if we get raw tx without derivation path
            int index1 = 0;
            int index2 = 0;
            // if electrum transaction
            if(electrum){
                // unsigned transaction from electrum has all info in scriptSig:
                // 01ff4c53ff<xpub><2-byte index1><2-byte index2>
                byte arr[100] = { 0 };
                // serialize() will add script len varint in the beginning
                // serializeScript will give only script content
                size_t scriptLen = tx.txIns[i].scriptSig.serializeScript(arr, sizeof(arr));
                // it's enough to compare public keys of hd keys
                byte sec[33];
                hd.privateKey.publicKey().sec(sec, 33);
                if(memcmp(sec, arr+50, 33) != 0){
                    show("Wrong master pubkey!");
                    send_command(error_command, "Wrong master pubkey!");
                    return;
                }
                index1 = littleEndianToInt(arr+scriptLen-4, 2);
                index2 = littleEndianToInt(arr+scriptLen-2, 2);
            }
            tx.signInput(i, hd.child(index1).child(index2).privateKey);
        }
        show("ok, signed");
        send_command(success_command, tx);
    }else{
        show("cancelled");
        send_command(error_command, "user cancelled");
    }
}

void load_xprv(){
    show("Loading private key");
    // open the file. note that only one file can be open at a time,
    // so you have to close this one before opening another.
    File file = SD.open("xprv.txt");
    char xprv_buf[120] = { 0 };
    if(file){
        // read content from the file to buffer
        size_t len = file.available();
        if(len > sizeof(xprv_buf)){
            len = sizeof(xprv_buf);
        }
        file.read(xprv_buf, len);
        // close the file
        file.close();
        // import hd key from buffer
        HDPrivateKey imported_hd(xprv_buf);
        if(imported_hd){ // check if parsing was successfull
            // we will use bip44: m/44'/coin'/0'
            // coin = 1 for testnet, 0 for mainnet
            rootKey = imported_hd;
            hd = rootKey.hardenedChild(44).hardenedChild(USE_TESTNET).hardenedChild(0);
            show(hd); // show xprv on the screen
            send_command("load_xprv", hd.xpub()); // print xpub to serial
        }else{
            send_command("load_xprv_error", "can't parse xprv.txt");
        }
    } else {
        send_command("load_xprv_error", "xprv.txt file is missing");
    }
}

void get_address(char * cmd, bool change=false){
    String s(cmd);
    int index = s.toInt();
    String addr = hd.child(change).child(index).privateKey.address();
    send_command("addr", addr);
    show(addr);
}

void generate_key(String command){
    show("Generating new key...");
    rootKey = getRandomKey();
    hd = rootKey.hardenedChild(44).hardenedChild(USE_TESTNET).hardenedChild(0);
    show(hd);
    send_command(command, hd.xpub());
}

void parseCommand(char * cmd){
    if(memcmp(cmd, "sign_tx", strlen("sign_tx"))==0){
        sign_tx(cmd + strlen("sign_tx") + 1);
        return;
    }
    // TODO: load_xprv <file>
    if(memcmp(cmd, "load_xprv", strlen("load_xprv"))==0){
        load_xprv();
        return;
    }
    if(memcmp(cmd, "xpub", strlen("xpub"))==0){
        send_command("xpub", hd.xpub());
        return;
    }
    if(memcmp(cmd, "addr", strlen("addr"))==0){
        get_address(cmd + strlen("addr"));
        return;
    }
    if(memcmp(cmd, "changeaddr", strlen("changeaddr"))==0){
        get_address(cmd + strlen("changeaddr"), true);
        return;
    }
    if(memcmp(cmd, "generate_key", strlen("generate_key"))==0){
        generate_key("generate_key");
        return;
    }
    // TODO: save_xprv <file>
    send_command("error", "unknown command");
}

void setup() {
    // setting buttons as inputs
    pinMode(9, INPUT_PULLUP);
    pinMode(6, INPUT_PULLUP);
    pinMode(5, INPUT_PULLUP);
    // screen init
    oled.init();
    oled.setBatteryVisible(false);
    show("I am alive!");
    // loading master private key
    if (!SD.begin(4)){
        // Serial.println("error: no SD card controller on pin 4");
        return;
    }
    load_xprv();
    // serial connection
    Serial.begin(9600);
    while(!Serial){
        ; // wait for serial port to open
    }
    show("Ready for requests");
}

void loop() {
    // reads serial port
    while(Serial.available()){
        // stores new request
        char buf[4000] = { 0 };
        // reads a line to buf
        Serial.readBytesUntil('\n', buf, sizeof(buf));
        // parses the command and does something
        parseCommand(buf);
        // clear the buffer
        memset(buf, 0, sizeof(buf));
    }
}

extension: ino


text:
long euler1() {
	long s = 0;
	for (int i = 1; i < 1000; i++)
		if ((i % 3) == 0 || (i % 5) == 0)
			s += i;
	return s;
}

repository: jscrane/eulerino

repo_name: jscrane/eulerino

extension: cpp