text:
61.214" size="1.27" layer="25" ratio="15" rot="R180" align="center-right"/>
<attribute name="VALUE" x="4.572" y="62.2046" size="0.889" layer="25" ratio="15" rot="R180" align="center-right"/>
</element>
<element name="D0" library="tekdemo" package="1X03_LOCK" value="RX1" x="14.732" y="63.754" smashed="yes" rot="R180">
<attribute name="NAME" x="4.572" y="63.754" size="1.27" layer="25" ratio="15" rot="R180" align="center-right"/>
<attribute name="VALUE" x="4.572" y="64.77" size="0.889" layer="25" ratio="15" rot="R180" align="center-right"/>
</element>
<element name="D3" library="tekdemo" package="1X03_LOCK" value="PWM" x="14.732" y="56.134" smashed="yes" rot="R180">
<attribute name="NAME" x="4.572" y="56.134" size="1.27" layer="25" ratio="15" rot="R180" align="center-right"/>
<attribute name="VALUE" x="4.572" y="57.15" size="0.889" layer="25" ratio="15" align="center-left"/>
</element>
<element name="D4" library="tekdemo" package="1X03_LOCK" value="PWM" x="14.732" y="53.594" smashed="yes" rot="R180">
<attribute name="NAME" x="4.572" y="53.594" size="1.27" layer="25" ratio="15" rot="R180" align="center-right"/>
<attribute name="VALUE" x="4.572" y="54.61" size="0.889" layer="25" ratio="15" align="center-left"/>
</element>
<element name="D5" library="tekdemo" package="1X03_LOCK" value="PWM" x="14.732" y="51.054" smashed="yes" rot="R180">
<attribute name="NAME" x="4.572" y="51.054" size="1.27" layer="25" ratio="15" rot="R180" align="center-right"/>
<attribute name="VALUE" x="4.572" y="52.07" size="0.889" layer="25" ratio="15" align="center-left"/>
</element>
<element name="D6" library="tekdemo" package="1X03_LOCK" value="PWM" x="14.732" y="48.514" smashed="yes" rot="R180">
<attribute name="NAME" x="4.572" y="48.514" size="1.27" layer="25" ratio="15" rot="R180" align="center-right"/>
<attribute name="VALUE" x="4.5974" y="49.53" size="0.889" layer="25" ratio="15" align="center-left"/>
</element>
<element name="D9" library="tekdemo" package="1X03_LOCK" value="PWM" x="14.732" y="39.37" smashed="yes" rot="R180">
<attribute name="NAME" x="4.572" y="39.37" size="1.27" layer="25" ratio="15" rot="R180" align="center-right"/>
<attribute name="VALUE" x="4.572" y="40.386" size="0.889" layer="25" ratio="15" align="center-left"/>
</element>
<element name="D10" library="tekdemo" package="1X03_LOCK" value="PWM" x="14.732" y="36.83" smashed="yes" rot="R180">
<attribute name="NAME" x="4.572" y="36.83" size="1.27" layer="25" ratio="15" rot="R180" align="center-right"/>
<attribute name="VALUE" x="4.572" y="37.846" size="0.889" layer="25" ratio="15" align="center-left"/>
</element>
<element name="U$4" library="SMDuino" package="ARDUINO" value="ARDUINO" x="53.34" y="0.254" rot="R90"/>
<element name="IC1" library="adafruit" package="QFN20" value="MCP73871" x="39.878" y="14.732" smashed="yes" rot="R180">
<attribute name="VALUE" x="44.704" y="14.224" size="0.762" layer="25" font="vector" ratio="15" rot="R45" align="center-right"/>
</element>
<element name="U$5" library="tekdemo" package="TEENSY_3.1_BASIC_LOCK" value="TEENSY_3.1_BASICLOCK" x="26.67" y="45.72" smashed="yes"/>
<element name="RTH" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="10K" x="42.672" y="20.574" rot="R90"/>
<element name="CSUP" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="10UF" x="46.228" y="16.51"/>
<element name="CBAT" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="10UF" x="37.846" y="8.89"/>
<element name="RPD3" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="10k" x="35.052" y="15.494" rot="R90"/>
<element name="RPD1" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="10k" x="35.052" y="11.938" smashed="yes" rot="R270">
<attribute name="NAME" x="34.4678" y="11.938" size="0.635" layer="25" ratio="15" rot="R90" align="bottom-center"/>
<attribute name="VALUE" x="35.6362" y="11.938" size="0.635" layer="27" ratio="15" rot="R270" align="bottom-center"/>
</element>
<element name="RDONE" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="200" x="39.624" y="20.574" smashed="yes" rot="R270">
<attribute name="NAME" x="39.0398" y="20.574" size="0.635" layer="25" ratio="15" rot="R90" align="bottom-center"/>
<attribute name="VALUE" x="40.2082" y="20.574" size="0.635" layer="27" ratio="15" rot="R270" align="bottom-center"/>
</element>
<element name="LEDD" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="CHARGED" x="36.83" y="20.574" smashed="yes" rot="R90">
<attribute name="NAME" x="37.4142" y="20.574" size="0.635" layer="25" ratio="15" rot="R270" align="bottom-center"/>
<attribute name="VALUE" x="35.9918" y="20.574" size="0.762" layer="25" ratio="15" rot="R90" align="bottom-center"/>
</element>
<element name="LIPO" library="adafruit" package="JST-PH-2-THM-RA" value="3.0-4.2V" x="45.974" y="6.604" smashed="yes" rot="R180">
<attribute name="NAME" x="50.536" y="0.602" size="1.27" layer="25" font="vector" ratio="15" rot="R90"/>
<attribute name="V" value="3.7-4.2V" x="51.308" y="0.508" size="1.27" layer="25" font="vector" ratio="15" rot="R90" align="center-left"/>
</element>
<element name="U$2" library="tekdemo" package="NET-JUNCTION" value="NET-JUNCTION8-MIL-DIAMETER" x="42.164" y="1.524"/>
<element name="C6" library="tekdemo" package="1210" value="" x="35.306" y="3.556" smashed="yes" rot="R270">
<attribute name="VALUE" x="34.606" y="4.456" size="0.4064" layer="27" rot="R270"/>
</element>
<element name="C4" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="1uf" x="40.894" y="35.052" smashed="yes" rot="R180">
<attribute name="NAME" x="40.894" y="35.6362" size="0.635" layer="25" ratio="15" align="bottom-center"/>
<attribute name="VALUE" x="40.894" y="34.4678" size="0.635" layer="27" ratio="15" rot="R180" align="bottom-center"/>
</element>
<element name="C5" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="0.1uf" x="40.894" y="37.846" smashed="yes" rot="R180">
<attribute name="NAME" x="40.894" y="38.4302" size="0.635" layer="25" ratio="15" align="bottom-center"/>
<attribute name="VALUE" x="40.894" y="37.2618" size="0.635" layer="27" ratio="15" rot="R180" align="bottom-center"/>
</element>
<element name="CSUP1" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="0.1uf" x="40.894" y="28.448"/>
<element name="MCP1" library="tekdemo" package="SOT23" value="MCP1703" x="46.482" y="25.146" smashed="yes" rot="R90">
<attribute name="V" value="MCP1703" x="50.292" y="24.892" size="0.762" layer="25" font="vector" ratio="15" rot="R90" align="bottom-center"/>
</element>
<element name="C1" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="1uf" x="46.482" y="28.448" rot="R180"/>
<element name="C3" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="0.1uf" x="46.482" y="30.734" rot="R180"/>
<element name="CSUP2" library="tekdemo" package="0402-0603-0805-UNIVERSAL" value="0.1uf" x="46.482" y="21.844"/>
</elements>
<signals>
<signal name="PWM3">
<contactref element="D3M" pad="3"/>
<contactref element="LED3" pad="+"/>
<contactref element="D3" pad="3"/>
<contactref element="U$4" pad="D3"/>
<wire x1="2.667" y1="56.134" x2="8.89" y2="56.134" width="0.2032" layer="16"/>
<wire x1="8.89" y1="56.134" x2="9.652" y2="56.007" width="0.2032" layer="16"/>
<wire x1="9.652" y1="56.007" x2="10.795" y2="55.0164" width="0.2032" layer="16"/>
<wire x1="10.795" y1="55.0164" x2="13.2334" y2="55.0164" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="55.0164" x2="13.5128" y2="54.737" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="54.737" x2="15.367" y2="54.737" width="0.2032" layer="16"/>
<wire x1="15.367" y1="54.737" x2="18.034" y2="52.07" width="0.2032" layer="16"/>
<wire x1="18.034" y1="52.07" x2="19.1516" y2="52.07" width="0.2032" layer="16"/>
<wire x1="18.923" y1="6.604" x2="18.034" y2="7.62" width="0.2032" layer="1"/>
<wire x1="18.034" y1="7.62" x2="18.034" y2="14.732" width="0.2032" layer="1"/>
<wire x1="18.034" y1="14.732" x2="18.034" y2="23.114" width="0.2032" layer="1"/>
<wire x1="18.034" y1="23.114" x2="19.05" y2="23.876" width="0.2032" layer="1"/>
<wire x1="19.05" y1="23.876" x2="20.574" y2="23.876" width="0.2032" layer="1"/>
<wire x1="20.574" y1="23.876" x2="22.606" y2="25.908" width="0.2032" layer="1"/>
<wire x1="22.606" y1="25.908" x2="22.606" y2="52.07" width="0.2032" layer="1"/>
<wire x1="19.05" y1="15.748" x2="19.05" y2="14.732" width="0.2032" layer="1"/>
<wire x1="19.05" y1="14.732" x2="18.034" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="3"/>
<wire x1="22.606" y1="52.07" x2="19.1516" y2="52.07" width="0.2032" layer="1"/>
</signal>
<signal name="PWM4">
<contactref element="D4M" pad="3"/>
<contactref element="LED4" pad="+"/>
<contactref element="D4" pad="3"/>
<contactref element="U$4" pad="D4"/>
<wire x1="2.413" y1="53.594" x2="8.89" y2="53.594" width="0.2032" layer="16"/>
<wire x1="8.89" y1="53.594" x2="9.652" y2="53.467" width="0.2032" layer="16"/>
<wire x1="9.652" y1="53.467" x2="10.795" y2="52.4764" width="0.2032" layer="16"/>
<wire x1="10.795" y1="52.4764" x2="13.2334" y2="52.4764" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="52.4764" x2="13.5128" y2="52.197" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="52.197" x2="15.367" y2="52.197" width="0.2032" layer="16"/>
<wire x1="15.367" y1="52.197" x2="18.034" y2="49.53" width="0.2032" layer="16"/>
<wire x1="18.034" y1="49.53" x2="18.9484" y2="49.53" width="0.2032" layer="16"/>
<wire x1="16.383" y1="6.604" x2="17.526" y2="7.62" width="0.2032" layer="1"/>
<wire x1="17.526" y1="7.62" x2="17.526" y2="14.732" width="0.2032" layer="1"/>
<wire x1="17.526" y1="14.732" x2="17.526" y2="23.368" width="0.2032" layer="1"/>
<wire x1="17.526" y1="23.368" x2="18.796" y2="24.384" width="0.2032" layer="1"/>
<wire x1="18.796" y1="24.384" x2="20.32" y2="24.384" width="0.2032" layer="1"/>
<wire x1="20.32" y1="24.384" x2="22.098" y2="26.162" width="0.2032" layer="1"/>
<wire x1="22.098" y1="26.162" x2="22.098" y2="49.53" width="0.2032" layer="1"/>
<wire x1="16.51" y1="15.748" x2="16.51" y2="14.732" width="0.2032" layer="1"/>
<wire x1="16.51" y1="14.732" x2="17.526" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="4"/>
<wire x1="22.098" y1="49.53" x2="18.9484" y2="49.53" width="0.2032" layer="1"/>
</signal>
<signal name="PWM5">
<contactref element="D5M" pad="3"/>
<contactref element="LED5" pad="+"/>
<contactref element="D5" pad="3"/>
<contactref element="U$4" pad="D5"/>
<wire x1="2.667" y1="51.054" x2="8.89" y2="51.054" width="0.2032" layer="16"/>
<wire x1="8.89" y1="51.054" x2="9.652" y2="50.927" width="0.2032" layer="16"/>
<wire x1="9.652" y1="50.927" x2="10.795" y2="49.9364" width="0.2032" layer="16"/>
<wire x1="10.795" y1="49.9364" x2="13.2334" y2="49.9364" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="49.9364" x2="13.5128" y2="49.657" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="49.657" x2="15.367" y2="49.657" width="0.2032" layer="16"/>
<wire x1="15.367" y1="49.657" x2="18.034" y2="46.99" width="0.2032" layer="16"/>
<wire x1="18.034" y1="46.99" x2="19.1516" y2="46.99" width="0.2032" layer="16"/>
<wire x1="13.843" y1="6.604" x2="12.446" y2="8.128" width="0.2032" layer="1"/>
<wire x1="12.446" y1="8.128" x2="12.446" y2="14.732" width="0.2032" layer="1"/>
<wire x1="12.446" y1="14.732" x2="12.446" y2="23.876" width="0.2032" layer="1"/>
<wire x1="12.446" y1="23.876" x2="13.462" y2="24.892" width="0.2032" layer="1"/>
<wire x1="13.462" y1="24.892" x2="20.066" y2="24.892" width="0.2032" layer="1"/>
<wire x1="20.066" y1="24.892" x2="21.59" y2="26.416" width="0.2032" layer="1"/>
<wire x1="21.59" y1="26.416" x2="21.59" y2="46.99" width="0.2032" layer="1"/>
<wire x1="14.224" y1="15.748" x2="14.224" y2="14.732" width="0.2032" layer="1"/>
<wire x1="14.224" y1="14.732" x2="12.446" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="5"/>
<wire x1="21.59" y1="46.99" x2="19.1516" y2="46.99" width="0.2032" layer="1"/>
</signal>
<signal name="PWM6">
<contactref element="D6M" pad="3"/>
<contactref element="LED6" pad="+"/>
<contactref element="D6" pad="3"/>
<contactref element="U$4" pad="D6"/>
<wire x1="2.413" y1="48.514" x2="8.89" y2="48.514" width="0.2032" layer="16"/>
<wire x1="8.89" y1="48.514" x2="9.652" y2="48.387" width="0.2032" layer="16"/>
<wire x1="9.652" y1="48.387" x2="10.795" y2="47.3964" width="0.2032" layer="16"/>
<wire x1="10.795" y1="47.3964" x2="13.2334" y2="47.3964" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="47.3964" x2="13.5128" y2="47.117" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="47.117" x2="15.367" y2="47.117" width="0.2032" layer="16"/>
<wire x1="15.367" y1="47.117" x2="18.034" y2="44.45" width="0.2032" layer="16"/>
<wire x1="18.034" y1="44.45" x2="18.9484" y2="44.45" width="0.2032" layer="16"/>
<wire x1="10.287" y1="6.604" x2="11.938" y2="8.128" width="0.2032" layer="1"/>
<wire x1="11.938" y1="8.128" x2="11.938" y2="14.732" width="0.2032" layer="1"/>
<wire x1="11.938" y1="14.732" x2="11.938" y2="24.13" width="0.2032" layer="1"/>
<wire x1="11.938" y1="24.13" x2="13.208" y2="25.4" width="0.2032" layer="1"/>
<wire x1="13.208" y1="25.4" x2="19.812" y2="25.4" width="0.2032" layer="1"/>
<wire x1="19.812" y1="25.4" x2="21.082" y2="26.67" width="0.2032" layer="1"/>
<wire x1="21.082" y1="26.67" x2="21.082" y2="44.45" width="0.2032" layer="1"/>
<wire x1="10.414" y1="15.748" x2="10.414" y2="14.732" width="0.2032" layer="1"/>
<wire x1="10.414" y1="14.732" x2="11.938" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="6"/>
<wire x1="21.082" y1="44.45" x2="18.9484" y2="44.45" width="0.2032" layer="1"/>
</signal>
<signal name="PWM9">
<contactref element="D9M" pad="3"/>
<contactref element="LED9" pad="+"/>
<contactref element="D9" pad="3"/>
<contactref element="U$4" pad="D9"/>
<wire x1="2.667" y1="39.37" x2="8.89" y2="39.37" width="0.2032" layer="16"/>
<wire x1="8.89" y1="39.37" x2="9.652" y2="39.243" width="0.2032" layer="16"/>
<wire x1="9.652" y1="39.243" x2="10.795" y2="38.2524" width="0.2032" layer="16"/>
<wire x1="10.795" y1="38.2524" x2="13.2334" y2="38.2524" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="38.2524" x2="13.5128" y2="37.973" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="37.973" x2="15.367" y2="37.973" width="0.2032" layer="16"/>
<wire x1="15.367" y1="37.973" x2="16.764" y2="36.83" width="0.2032" layer="16"/>
<wire x1="16.764" y1="36.83" x2="19.1516" y2="36.83" width="0.2032" layer="16"/>
<wire x1="7.747" y1="6.604" x2="7.112" y2="7.366" width="0.2032" layer="1"/>
<wire x1="7.112" y1="7.366" x2="7.112" y2="14.732" width="0.2032" layer="1"/>
<wire x1="7.112" y1="14.732" x2="7.112" y2="22.86" width="0.2032" layer="1"/>
<wire x1="7.112" y1="22.86" x2="10.16" y2="25.908" width="0.2032" layer="1"/>
<wire x1="10.16" y1="25.908" x2="19.304" y2="25.908" width="0.2032" layer="1"/>
<wire x1="19.304" y1="25.908" x2="20.574" y2="27.178" width="0.2032" layer="1"/>
<wire x1="20.574" y1="27.178" x2="20.574" y2="36.83" width="0.2032" layer="1"/>
<wire x1="8.128" y1="15.748" x2="8.128" y2="14.732" width="0.2032" layer="1"/>
<wire x1="8.128" y1="14.732" x2="7.112" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="9"/>
<wire x1="20.574" y1="36.83" x2="19.1516" y2="36.83" width="0.2032" layer="1"/>
</signal>
<signal name="PWM10">
<contactref element="D10M" pad="3"/>
<contactref element="LED10" pad="+"/>
<contactref element="D10" pad="3"/>
<contactref element="U$4" pad="D10"/>
<wire x1="2.413" y1="36.83" x2="8.89" y2="36.83" width="0.2032" layer="16"/>
<wire x1="8.89" y1="36.83" x2="9.652" y2="36.703" width="0.2032" layer="16"/>
<wire x1="9.652" y1="36.703" x2="10.795" y2="35.7124" width="0.2032" layer="16"/>
<wire x1="10.795" y1="35.7124" x2="13.2334" y2="35.7124" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="35.7124" x2="13.5128" y2="35.433" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="35.433" x2="15.367" y2="35.433" width="0.2032" layer="16"/>
<wire x1="15.367" y1="35.433" x2="16.764" y2="34.29" width="0.2032" layer="16"/>
<wire x1="16.764" y1="34.29" x2="18.9484" y2="34.29" width="0.2032" layer="16"/>
<wire x1="5.207" y1="6.604" x2="6.604" y2="7.874" width="0.2032" layer="1"/>
<wire x1="6.604" y1="7.874" x2="6.604" y2="14.732" width="0.2032" layer="1"/>
<wire x1="6.604" y1="14.732" x2="6.604" y2="23.114" width="0.2032" layer="1"/>
<wire x1="6.604" y1="23.114" x2="9.906" y2="26.416" width="0.2032" layer="1"/>
<wire x1="9.906" y1="26.416" x2="18.796" y2="26.416" width="0.2032" layer="1"/>
<wire x1="18.796" y1="26.416" x2="20.066" y2="27.686" width="0.2032" layer="1"/>
<wire x1="20.066" y1="27.686" x2="20.066" y2="34.29" width="0.2032" layer="1"/>
<wire x1="5.588" y1="15.748" x2="5.588" y2="14.732" width="0.2032" layer="1"/>
<wire x1="5.588" y1="14.732" x2="6.604" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="10"/>
<wire x1="20.066" y1="34.29" x2="18.9484" y2="34.29" width="0.2032" layer="1"/>
</signal>
<signal name="MGND">
<contactref element="D23M" pad="1"/>
<contactref element="D22M" pad="1"/>
<contactref element="D21M" pad="1"/>
<contactref element="D20M" pad="1"/>
<contactref element="D10M" pad="1"/>
<contactref element="D9M" pad="1"/>
<contactref element="D6M" pad="1"/>
<contactref element="D5M" pad="1"/>
<contactref element="D4M" pad="1"/>
<contactref element="D3M" pad="1"/>
<contactref element="C2" pad="-"/>
<contactref element="C10" pad="-"/>
<contactref element="C7" pad="-"/>
<wire x1="5.207" y1="1.524" x2="7.747" y2="1.524" width="1.778" layer="16"/>
<wire x1="7.747" y1="1.524" x2="10.287" y2="1.524" width="1.778" layer="16"/>
<wire x1="10.287" y1="1.524" x2="13.843" y2="1.524" width="1.778" layer="16"/>
<wire x1="13.843" y1="1.524" x2="16.383" y2="1.524" width="1.778" layer="16"/>
<wire x1="16.383" y1="1.524" x2="18.923" y2="1.524" width="1.778" layer="16"/>
<wire x1="18.923" y1="1.524" x2="22.733" y2="1.524" width="1.778" layer="16"/>
<wire x1="22.733" y1="1.524" x2="25.273" y2="1.524" width="1.778" layer="16"/>
<wire x1="25.273" y1="1.524" x2="27.813" y2="1.524" width="1.778" layer="16"/>
<wire x1="27.813" y1="1.524" x2="30.353" y2="1.524" width="1.778" layer="16"/>
<contactref element="U$2" pad="P$1"/>
<contactref element="C6" pad="2"/>
<wire x1="35.306" y1="2.794" x2="35.306" y2="1.956" width="0.254" layer="1"/>
<wire x1="38.354" y1="2.794" x2="38.354" y2="1.524" width="0.254" layer="1"/>
<wire x1="40.64" y1="2.794" x2="40.64" y2="1.524" width="0.254" layer="1"/>
<wire x1="38.354" y1="1.524" x2="40.64" y2="1.524" width="1.778" layer="1"/>
<wire x1="40.64" y1="1.524" x2="42.0878" y2="1.524" width="1.778" layer="1"/>
<wire x1="38.354" y1="1.524" x2="35.306" y2="1.524" width="1.778" layer="1"/>
<wire x1="35.306" y1="1.524" x2="30.353" y2="1.524" width="1.778" layer="1"/>
<wire x1="35.306" y1="1.956" x2="35.306" y2="1.524" width="0.254" layer="1"/>
<wire x1="30.353" y1="1.524" x2="27.813" y2="1.524" width="1.778" layer="1"/>
<wire x1="27.813" y1="1.524" x2="25.273" y2="1.524" width="1.778" layer="1"/>
<wire x1="25.273" y1="1.524" x2="22.733" y2="1.524" width="1.778" layer="1"/>
</signal>
<signal name="PWM23">
<contactref element="D23M" pad="3"/>
<contactref element="LED23" pad="+"/>
<wire x1="22.733" y1="6.604" x2="24.13" y2="7.874" width="0.2032" layer="1"/>
<wire x1="24.13" y1="7.874" x2="24.13" y2="14.732" width="0.2032" layer="1"/>
<wire x1="24.13" y1="14.732" x2="24.13" y2="24.638" width="0.2032" layer="1"/>
<wire x1="24.13" y1="24.638" x2="23.114" y2="25.654" width="0.2032" layer="1"/>
<wire x1="23.114" y1="25.654" x2="23.114" y2="54.61" width="0.2032" layer="1"/>
<wire x1="23.114" y1="54.61" x2="34.1884" y2="54.61" width="0.2032" layer="1"/>
<wire x1="23.114" y1="16.002" x2="23.114" y2="14.732" width="0.2032" layer="1"/>
<wire x1="23.114" y1="14.732" x2="24.13" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="23/A9"/>
</signal>
<signal name="PWM22">
<contactref element="D22M" pad="3"/>
<contactref element="LED22" pad="+"/>
<wire x1="25.273" y1="6.604" x2="24.638" y2="7.874" width="0.2032" layer="1"/>
<wire x1="24.638" y1="7.874" x2="24.638" y2="14.732" width="0.2032" layer="1"/>
<wire x1="24.638" y1="14.732" x2="24.638" y2="24.892" width="0.2032" layer="1"/>
<wire x1="24.638" y1="24.892" x2="23.622" y2="25.908" width="0.2032" layer="1"/>
<wire x1="23.622" y1="25.908" x2="23.622" y2="52.07" width="0.2032" layer="1"/>
<wire x1="23.622" y1="52.07" x2="34.3916" y2="52.07" width="0.2032" layer="1"/>
<wire x1="25.654" y1="16.002" x2="25.654" y2="14.732" width="0.2032" layer="1"/>
<wire x1="25.654" y1="14.732" x2="24.638" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="22/A8"/>
</signal>
<signal name="PWM21">
<contactref element="D21M" pad="3"/>
<contactref element="LED21" pad="+"/>
<wire x1="27.813" y1="6.604" x2="29.21" y2="7.874" width="0.2032" layer="1"/>
<wire x1="29.21" y1="7.874" x2="29.21" y2="14.732" width="0.2032" layer="1"/>
<wire x1="29.21" y1="14.732" x2="29.21" y2="23.114" width="0.2032" layer="1"/>
<wire x1="24.13" y1="28.194" x2="24.13" y2="49.53" width="0.2032" layer="1"/>
<wire x1="24.13" y1="49.53" x2="34.1884" y2="49.53" width="0.2032" layer="1"/>
<wire x1="28.194" y1="16.002" x2="28.194" y2="14.732" width="0.2032" layer="1"/>
<wire x1="28.194" y1="14.732" x2="29.21" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="21/A7"/>
<wire x1="29.21" y1="23.114" x2="24.13" y2="28.194" width="0.2032" layer="1"/>
</signal>
<signal name="PWM20">
<contactref element="D20M" pad="3"/>
<contactref element="LED20" pad="+"/>
<wire x1="34.3916" y1="46.99" x2="24.638" y2="46.99" width="0.2032" layer="1"/>
<wire x1="30.353" y1="6.604" x2="29.718" y2="7.874" width="0.2032" layer="1"/>
<wire x1="29.718" y1="7.874" x2="29.718" y2="14.732" width="0.2032" layer="1"/>
<wire x1="29.718" y1="14.732" x2="29.718" y2="23.368" width="0.2032" layer="1"/>
<wire x1="24.638" y1="28.448" x2="24.638" y2="46.99" width="0.2032" layer="1"/>
<wire x1="30.734" y1="16.002" x2="30.734" y2="14.732" width="0.2032" layer="1"/>
<wire x1="30.734" y1="14.732" x2="29.718" y2="14.732" width="0.2032" layer="1"/>
<contactref element="U$5" pad="20/A6"/>
<wire x1="29.718" y1="23.368" x2="24.638" y2="28.448" width="0.2032" layer="1"/>
</signal>
<signal name="3.3V">
<contactref element="D13" pad="2"/>
<contactref element="D12" pad="2"/>
<contactref element="D11" pad="2"/>
<contactref element="D8" pad="2"/>
<contactref element="D7" pad="2"/>
<contactref element="A5" pad="2"/>
<contactref element="A4" pad="2"/>
<contactref element="A0" pad="2"/>
<contactref element="A1" pad="2"/>
<contactref element="A2" pad="2"/>
<contactref element="A3" pad="2"/>
<contactref element="D2" pad="2"/>
<contactref element="D1" pad="2"/>
<contactref element="D0" pad="2"/>
<contactref element="MCP1703" pad="2"/>
<contactref element="D10" pad="2"/>
<contactref element="D9" pad="2"/>
<contactref element="D6" pad="2"/>
<contactref element="D5" pad="2"/>
<contactref element="D4" pad="2"/>
<contactref element="D3" pad="2"/>
<contactref element="U$4" pad="AREF"/>
<contactref element="U$4" pad="3V3"/>
<contactref element="U$5" pad="3.3V"/>
<wire x1="2.667" y1="24.13" x2="6.35" y2="24.13" width="0.508" layer="1"/>
<wire x1="6.35" y1="24.13" x2="9.398" y2="27.178" width="0.508" layer="1"/>
<wire x1="9.398" y1="27.178" x2="10.16" y2="27.178" width="0.508" layer="1"/>
<wire x1="10.16" y1="27.178" x2="12.192" y2="29.337" width="0.508" layer="1"/>
<wire x1="12.192" y1="29.337" x2="12.192" y2="31.877" width="1.016" layer="1"/>
<wire x1="12.192" y1="31.877" x2="12.192" y2="34.417" width="1.016" layer="1"/>
<wire x1="12.192" y1="34.417" x2="12.192" y2="36.957" width="1.016" layer="1"/>
<wire x1="12.192" y1="36.957" x2="12.192" y2="39.497" width="1.016" layer="1"/>
<wire x1="12.192" y1="39.497" x2="12.192" y2="42.037" width="1.016" layer="1"/>
<wire x1="12.192" y1="42.037" x2="12.192" y2="46.101" width="1.016" layer="1"/>
<wire x1="12.192" y1="46.101" x2="12.192" y2="48.641" width="1.016" layer="1"/>
<wire x1="12.192" y1="48.641" x2="12.192" y2="51.181" width="1.016" layer="1"/>
<wire x1="12.192" y1="51.181" x2="12.192" y2="53.721" width="1.016" layer="1"/>
<wire x1="12.192" y1="53.721" x2="12.192" y2="56.261" width="1.016" layer="1"/>
<wire x1="12.192" y1="56.261" x2="12.192" y2="58.801" width="1.016" layer="1"/>
<wire x1="12.192" y1="58.801" x2="12.192" y2="61.341" width="1.016" layer="1"/>
<wire x1="12.192" y1="61.341" x2="12.192" y2="63.881" width="1.016" layer="1"/>
<wire x1="40.64" y1="63.373" x2="40.64" y2="60.833" width="1.016" layer="1"/>
<wire x1="40.64" y1="60.833" x2="40.64" y2="58.293" width="1.016" layer="1"/>
<wire x1="40.64" y1="58.293" x2="40.64" y2="55.753" width="1.016" layer="1"/>
<wire x1="40.64" y1="55.753" x2="40.64" y2="53.213" width="1.016" layer="1"/>
<wire x1="40.64" y1="53.213" x2="40.64" y2="50.673" width="1.016" layer="1"/>
<wire x1="34.3916" y1="57.15" x2="36.068" y2="57.15" width="0.6096" layer="16"/>
<wire x1="36.068" y1="57.15" x2="36.068" y2="40.132" width="0.6096" layer="16"/>
<wire x1="12.192" y1="63.881" x2="13.716" y2="65.278" width="0.6096" layer="1"/>
<wire x1="13.716" y1="65.278" x2="15.494" y2="65.278" width="0.6096" layer="1"/>
<wire x1="15.494" y1="65.278" x2="17.018" y2="63.754" width="0.6096" layer="1"/>
<wire x1="17.018" y1="63.754" x2="27.686" y2="63.754" width="0.6096" layer="1"/>
<contactref element="C4" pad="+"/>
<contactref element="C5" pad="+"/>
<wire x1="41.994" y1="35.052" x2="41.656" y2="35.052" width="0.6096" layer="1"/>
<wire x1="41.994" y1="37.592" x2="41.656" y2="37.846" width="0.6096" layer="1"/>
<wire x1="41.994" y1="32.7" x2="41.656" y2="33.292" width="0.6096" layer="1"/>
<wire x1="41.656" y1="33.292" x2="41.656" y2="35.052" width="0.6096" layer="1"/>
<wire x1="41.994" y1="35.052" x2="41.656" y2="35.39" width="0.6096" layer="1"/>
<wire x1="41.656" y1="35.39" x2="41.656" y2="37.846" width="0.6096" layer="1"/>
<via x="25.654" y="30.48" extent="1-16" drill="0.635"/>
<wire x1="25.654" y1="30.48" x2="21.336" y2="26.162" width="0.6096" layer="16"/>
<wire x1="21.336" y1="26.162" x2="15.24" y2="26.162" width="0.6096" layer="16"/>
<wire x1="15.24" y1="26.162" x2="12.192" y2="29.337" width="0.6096" layer="16"/>
<contactref element="MCP1" pad="2"/>
<contactref element="C1" pad="+"/>
<contactref element="C3" pad="+"/>
<wire x1="47.582" y1="26.096" x2="47.244" y2="26.688" width="0.508" layer="1"/>
<wire x1="47.244" y1="26.688" x2="47.244" y2="28.448" width="0.508" layer="1"/>
<wire x1="47.244" y1="28.448" x2="47.244" y2="30.734" width="0.508" layer="1"/>
<wire x1="41.994" y1="37.592" x2="41.656" y2="37.93" width="0.508" layer="1" curve="-90"/>
<wire x1="41.656" y1="37.93" x2="41.656" y2="40.132" width="0.6096" layer="1"/>
<via x="41.656" y="40.132" extent="1-16" drill="0.635"/>
<wire x1="41.656" y1="40.132" x2="36.068" y2="40.132" width="0.6096" layer="16"/>
<wire x1="27.686" y1="63.754" x2="29.718" y2="65.786" width="0.6096" layer="1"/>
<wire x1="29.718" y1="65.786" x2="39.116" y2="65.786" width="0.6096" layer="1"/>
<wire x1="39.116" y1="65.786" x2="40.64" y2="64.262" width="0.6096" layer="1"/>
<wire x1="40.64" y1="64.262" x2="40.64" y2="63.373" width="0.6096" layer="1"/>
<wire x1="47.244" y1="30.734" x2="46.99" y2="39.37" width="0.6096" layer="1"/>
<wire x1="46.99" y1="39.37" x2="46.99" y2="42.418" width="0.6096" layer="1"/>
<wire x1="46.99" y1="42.418" x2="45.466" y2="43.942" width="0.6096" layer="1"/>
<via x="45.466" y="43.942" extent="1-16" drill="0.635"/>
<wire x1="45.466" y1="43.942" x2="41.656" y2="47.752" width="0.6096" layer="16"/>
<wire x1="50.673" y1="35.814" x2="50.8" y2="36.322" width="0.6096" layer="1"/>
<wire x1="50.8" y1="36.322" x2="47.752" y2="39.37" width="0.6096" layer="1"/>
<wire x1="47.752" y1="39.37" x2="46.99" y2="39.37" width="0.6096" layer="1"/>
<via x="41.656" y="47.752" extent="1-16" drill="0.635"/>
<wire x1="40.64" y1="50.673" x2="40.64" y2="48.768" width="0.6096" layer="1"/>
<wire x1="40.64" y1="48.768" x2="41.656" y2="47.752" width="0.6096" layer="1"/>
<wire x1="39.624" y1="45.72" x2="25.654" y2="45.72" width="0.6096" layer="1"/>
<wire x1="25.654" y1="45.72" x2="25.654" y2="30.48" width="0.6096" layer="1"/>
<wire x1="41.656" y1="40.132" x2="45.466" y2="43.942" width="0.6096" layer="1"/>
<wire x1="39.624" y1="45.72" x2="41.656" y2="47.752" width="0.6096" layer="1"/>
</signal>
<signal name="AGND">
<contactref element="U$5" pad="AGND"/>
</signal>
<signal name="A5">
<contactref element="A5" pad="3"/>
<contactref element="U$4" pad="A5"/>
<contactref element="U$5" pad="19/A5"/>
<wire x1="34.1884" y1="44.45" x2="40.132" y2="44.45" width="0.254" layer="1"/>
<wire x1="40.132" y1="44.45" x2="45.212" y2="49.53" width="0.254" layer="1"/>
<wire x1="45.212" y1="49.53" x2="45.212" y2="58.166" width="0.254" layer="1"/>
<wire x1="45.212" y1="58.166" x2="50.673" y2="63.754" width="0.254" layer="1"/>
<wire x1="43.18" y1="63.627" x2="43.688" y2="63.754" width="0.254" layer="16"/>
<wire x1="43.688" y1="63.754" x2="50.673" y2="63.754" width="0.254" layer="16"/>
</signal>
<signal name="A4">
<contactref element="A4" pad="3"/>
<contactref element="U$4" pad="A4"/>
<contactref element="U$5" pad="18/A4"/>
<wire x1="34.3916" y1="41.91" x2="38.354" y2="41.91" width="0.254" layer="1"/>
<wire x1="38.354" y1="41.91" x2="45.974" y2="49.53" width="0.254" layer="1"/>
<wire x1="45.974" y1="49.53" x2="45.974" y2="56.388" width="0.254" layer="1"/>
<wire x1="45.974" y1="56.388" x2="50.927" y2="61.214" width="0.254" layer="1"/>
<wire x1="43.18" y1="61.087" x2="43.688" y2="61.214" width="0.254" layer="16"/>
<wire x1="43.688" y1="61.214" x2="50.927" y2="61.214" width="0.254" layer="16"/>
</signal>
<signal name="A3">
<contactref element="A3" pad="3"/>
<contactref element="U$4" pad="A3"/>
<wire x1="50.673" y1="58.674" x2="43.688" y2="58.674" width="0.2032" layer="16"/>
<wire x1="43.688" y1="58.674" x2="43.18" y2="58.547" width="0.2032" layer="16"/>
<contactref element="U$5" pad="17/A3"/>
<wire x1="34.1884" y1="39.37" x2="36.576" y2="39.37" width="0.254" layer="1"/>
<wire x1="36.576" y1="39.37" x2="46.736" y2="49.53" width="0.254" layer="1"/>
<wire x1="46.736" y1="49.53" x2="46.736" y2="54.61" width="0.254" layer="1"/>
<wire x1="46.736" y1="54.61" x2="50.673" y2="58.674" width="0.254" layer="1"/>
</signal>
<signal name="A2">
<contactref element="A2" pad="3"/>
<contactref element="U$4" pad="A2"/>
<wire x1="50.927" y1="56.134" x2="43.688" y2="56.134" width="0.2032" layer="16"/>
<wire x1="43.688" y1="56.134" x2="43.18" y2="56.007" width="0.2032" layer="16"/>
<contactref element="U$5" pad="16/A2"/>
<wire x1="34.3916" y1="36.83" x2="34.798" y2="36.83" width="0.254" layer="1"/>
<wire x1="34.798" y1="36.83" x2="47.498" y2="49.53" width="0.254" layer="1"/>
<wire x1="47.498" y1="49.53" x2="47.498" y2="52.832" width="0.254" layer="1"/>
<wire x1="47.498" y1="52.832" x2="50.927" y2="56.134" width="0.254" layer="1"/>
</signal>
<signal name="A1">
<contactref element="A1" pad="3"/>
<contactref element="U$4" pad="A1"/>
<wire x1="43.18" y1="53.467" x2="43.688" y2="53.594" width="0.2032" layer="16"/>
<wire x1="43.688" y1="53.594" x2="50.673" y2="53.594" width="0.2032" layer="16"/>
<contactref element="U$5" pad="15/A1"/>
<wire x1="34.1884" y1="34.29" x2="36.322" y2="36.322" width="0.254" layer="1"/>
<wire x1="36.322" y1="36.322" x2="36.322" y2="37.592" width="0.254" layer="1"/>
<wire x1="36.322" y1="37.592" x2="48.26" y2="49.53" width="0.254" layer="1"/>
<wire x1="48.26" y1="49.53" x2="48.26" y2="51.054" width="0.254" layer="1"/>
<wire x1="48.26" y1="51.054" x2="50.673" y2="53.594" width="0.254" layer="1"/>
</signal>
<signal name="A0">
<contactref element="A0" pad="3"/>
<contactref element="U$4" pad="A0"/>
<wire x1="50.927" y1="51.054" x2="43.688" y2="51.054" width="0.2032" layer="16"/>
<wire x1="43.688" y1="51.054" x2="43.18" y2="50.927" width="0.2032" layer="16"/>
<contactref element="U$5" pad="14/A0"/>
<wire x1="34.3916" y1="31.75" x2="36.83" y2="34.29" width="0.254" layer="1"/>
<wire x1="36.83" y1="34.29" x2="36.83" y2="37.338" width="0.254" layer="1"/>
<wire x1="36.83" y1="37.338" x2="50.546" y2="51.054" width="0.254" layer="1"/>
<wire x1="50.546" y1="51.054" x2="50.927" y2="51.054" width="0.254" layer="1"/>
</signal>
<signal name="GND">
<contactref element="D11" pad="1"/>
<contactref element="D12" pad="1"/>
<contactref element="D13" pad="1"/>
<contactref element="D8" pad="1"/>
<contactref element="D7" pad="1"/>
<contactref element="A5" pad="1"/>
<contactref element="A4" pad="1"/>
<contactref element="A3" pad="1"/>
<contactref element="A2" pad="1"/>
<contactref element="A1" pad="1"/>
<contactref element="A0" pad="1"/>
<contactref element="D2" pad="1"/>
<contactref element="D1" pad="1"/>
<contactref element="D0" pad="1"/>
<contactref element="D10" pad="1"/>
<contactref element="D9" pad="1"/>
<contactref element="D6" pad="1"/>
<contactref element="D5" pad="1"/>
<contactref element="D4" pad="1"/>
<contactref element="D3" pad="1"/>
<contactref element="U$4" pad="GND3"/>
<contactref element="U$4" pad="GND1"/>
<contactref element="U$4" pad="GND2"/>
<contactref element="IC1" pad="10"/>
<contactref element="U$5" pad="GND"/>
<contactref element="CSUP" pad="-"/>
<contactref element="CBAT" pad="-"/>
<contactref element="RPD3" pad="-"/>
<contactref element="RPD1" pad="-"/>
<contactref element="RTH" pad="-"/>
<contactref element="IC1" pad="11"/>
<wire x1="19.1516" y1="62.23" x2="29.21" y2="62.23" width="0.6096" layer="16"/>
<wire x1="29.21" y1="62.23" x2="31.75" y2="59.69" width="0.6096" layer="16"/>
<wire x1="31.75" y1="59.69" x2="31.75" y2="25.4" width="0.6096" layer="16"/>
<wire x1="31.75" y1="25.4" x2="37.084" y2="17.78" width="0.6096" layer="16"/>
<contactref element="LIPO" pad="2"/>
<via x="37.084" y="17.78" extent="1-16" drill="0.3048"/>
<polygon width="0.3048" layer="16" isolate="0.381" rank="6">
<vertex x="53.34" y="0.254"/>
<vertex x="53.34" y="69.088"/>
<vertex x="0" y="69.088"/>
<vertex x="0" y="0.254"/>
</polygon>
<via x="35.052" y="17.272" extent="1-16" drill="0.3048"/>
<via x="35.052" y="10.16" extent="1-16" drill="0.3048"/>
<wire x1="42.672" y1="21.336" x2="42.672" y2="22.352" width="0.254" layer="1"/>
<via x="42.672" y="22.352" extent="1-16" drill="0.3048"/>
<via x="38.1" y="17.78" extent="1-16" drill="0.3048"/>
<via x="37.084" y="16.764" extent="1-16" drill="0.3048"/>
<polygon width="0.254" layer="1" isolate="0.2032">
<vertex x="39.243" y="15.4686"/>
<vertex x="36.576" y="15.494"/>
<vertex x="36.576" y="18.288"/>
<vertex x="39.1922" y="18.288"/>
</polygon>
<polygon width="0.254" layer="16" isolate="0.381">
<vertex x="38.481" y="19.0754"/>
<vertex x="35.814" y="19.05"/>
<vertex x="35.814" y="16.51"/>
<vertex x="38.4302" y="16.51"/>
</polygon>
<via x="37.592" y="17.272" extent="1-16" drill="0.3048"/>
<wire x1="35.052" y1="11.176" x2="35.052" y2="10.16" width="0.254" layer="1"/>
<wire x1="35.052" y1="16.256" x2="35.052" y2="17.272" width="0.254" layer="1"/>
<wire x1="45.466" y1="1.524" x2="44.196" y2="1.524" width="1.778" layer="1"/>
<wire x1="44.196" y1="1.524" x2="43.18" y2="1.524" width="1.778" layer="1"/>
<wire x1="45.466" y1="1.524" x2="46.99" y2="1.524" width="1.778" layer="1"/>
<wire x1="46.99" y1="1.524" x2="48.26" y2="1.524" width="1.778" layer="1"/>
<via x="43.18" y="1.524" extent="1-16" drill="0.635"/>
<via x="44.196" y="1.524" extent="1-16" drill="0.635"/>
<via x="45.466" y="1.524" extent="1-16" drill="0.635"/>
<via x="48.26" y="1.524" extent="1-16" drill="0.635"/>
<via x="46.99" y="1.524" extent="1-16" drill="0.635"/>
<wire x1="38.608" y1="8.89" x2="39.878" y2="8.89" width="0.6096" layer="1"/>
<via x="39.878" y="8.89" extent="1-16" drill="0.635"/>
<contactref element="U$2" pad="P$4"/>
<wire x1="42.2402" y1="1.524" x2="43.18" y2="1.524" width="1.778" layer="1"/>
<contactref element="R5" pad="-"/>
<contactref element="R20" pad="-"/>
<contactref element="R9" pad="-"/>
<contactref element="R3" pad="-"/>
<contactref element="R4" pad="-"/>
<contactref element="R21" pad="-"/>
<contactref element="R23" pad="-"/>
<contactref element="R22" pad="-"/>
<contactref element="R10" pad="-"/>
<contactref element="R6" pad="-"/>
<wire x1="30.734" y1="21.336" x2="30.734" y2="22.606" width="0.254" layer="1"/>
<wire x1="28.194" y1="21.336" x2="28.194" y2="22.606" width="0.254" layer="1"/>
<wire x1="25.654" y1="21.336" x2="25.654" y2="22.606" width="0.254" layer="1"/>
<wire x1="23.114" y1="21.336" x2="23.114" y2="22.606" width="0.254" layer="1"/>
<wire x1="19.05" y1="21.336" x2="19.05" y2="22.606" width="0.254" layer="1"/>
<wire x1="16.51" y1="21.336" x2="16.51" y2="22.606" width="0.254" layer="1"/>
<wire x1="14.224" y1="21.336" x2="14.224" y2="22.606" width="0.254" layer="1"/>
<wire x1="10.414" y1="21.336" x2="10.414" y2="22.606" width="0.254" layer="1"/>
<wire x1="8.128" y1="21.336" x2="8.128" y2="22.606" width="0.254" layer="1"/>
<wire x1="5.588" y1="21.336" x2="5.588" y2="22.606" width="0.254" layer="1"/>
<via x="5.588" y="22.606" extent="1-16" drill="0.3302"/>
<via x="8.128" y="22.606" extent="1-16" drill="0.3302"/>
<via x="10.414" y="22.606" extent="1-16" drill="0.3302"/>
<via x="14.224" y="22.606" extent="1-16" drill="0.3302"/>
<via x="16.51" y="22.606" extent="1-16" drill="0.3302"/>
<via x="19.05" y="22.606" extent="1-16" drill="0.3302"/>
<via x="23.114" y="22.606" extent="1-16" drill="0.3302"/>
<via x="25.654" y="22.606" extent="1-16" drill="0.3302"/>
<via x="28.194" y="22.606" extent="1-16" drill="0.3302"/>
<via x="30.734" y="22.606" extent="1-16" drill="0.3302"/>
<contactref element="MCP1703" pad="1"/>
<wire x1="14.732" y1="63.627" x2="14.732" y2="61.087" width="1.016" layer="1"/>
<wire x1="14.732" y1="61.087" x2="14.732" y2="58.547" width="1.016" layer="1"/>
<wire x1="14.732" y1="58.547" x2="14.732" y2="56.007" width="1.016" layer="1"/>
<wire x1="14.732" y1="56.007" x2="14.732" y2="53.467" width="1.016" layer="1"/>
<wire x1="14.732" y1="53.467" x2="14.732" y2="50.927" width="1.016" layer="1"/>
<wire x1="14.732" y1="50.927" x2="14.732" y2="48.387" width="1.016" layer="1"/>
<wire x1="14.732" y1="48.387" x2="14.732" y2="45.847" width="1.016" layer="1"/>
<wire x1="14.732" y1="45.847" x2="14.732" y2="41.783" width="1.016" layer="1"/>
<wire x1="14.732" y1="41.783" x2="14.732" y2="39.243" width="1.016" layer="1"/>
<wire x1="14.732" y1="39.243" x2="14.732" y2="36.703" width="1.016" layer="1"/>
<wire x1="14.732" y1="36.703" x2="14.732" y2="34.163" width="1.016" layer="1"/>
<wire x1="14.732" y1="34.163" x2="14.732" y2="31.623" width="1.016" layer="1"/>
<wire x1="14.732" y1="31.623" x2="14.732" y2="29.083" width="1.016" layer="1"/>
<contactref element="C4" pad="-"/>
<contactref element="C5" pad="-"/>
<wire x1="46.99" y1="16.51" x2="48.514" y2="17.018" width="0.6096" layer="1"/>
<via x="48.514" y="17.018" extent="1-16" drill="0.635"/>
<contactref element="CSUP1" pad="-"/>
<wire x1="41.656" y1="28.448" x2="41.656" y2="30.8" width="0.6096" layer="1"/>
<wire x1="41.656" y1="30.8" x2="41.994" y2="30.8" width="0.6096" layer="1"/>
<wire x1="41.656" y1="30.8" x2="41.722" y2="30.734" width="0.6096" layer="1" curve="90"/>
<wire x1="41.722" y1="30.734" x2="43.434" y2="30.734" width="0.6096" layer="1"/>
<via x="43.434" y="30.734" extent="1-16" drill="0.635"/>
<wire x1="40.132" y1="35.052" x2="40.132" y2="37.846" width="0.6096" layer="1"/>
<wire x1="40.132" y1="35.052" x2="38.862" y2="35.052" width="0.6096" layer="1"/>
<via x="38.862" y="35.052" extent="1-16" drill="0.635"/>
<wire x1="40.132" y1="37.846" x2="38.862" y2="37.846" width="0.6096" layer="1"/>
<via x="38.862" y="37.846" extent="1-16" drill="0.635"/>
<wire x1="41.656" y1="28.448" x2="43.434" y2="28.448" width="0.6096" layer="1"/>
<via x="43.434" y="28.448" extent="1-16" drill="0.635"/>
<wire x1="38.1" y1="50.927" x2="31.242" y2="50.8" width="0.6096" layer="1"/>
<via x="31.242" y="50.8" extent="1-16" drill="0.635"/>
<contactref element="MCP1" pad="1"/>
<contactref element="C1" pad="-"/>
<contactref element="C3" pad="-"/>
<contactref element="CSUP2" pad="-"/>
<wire x1="47.244" y1="21.844" x2="49.022" y2="21.844" width="0.508" layer="1"/>
<via x="49.022" y="21.844" extent="1-16" drill="0.635"/>
<wire x1="47.582" y1="24.196" x2="47.648" y2="24.13" width="0.508" layer="1" curve="90"/>
<wire x1="47.648" y1="24.13" x2="49.022" y2="24.13" width="0.6096" layer="1"/>
<via x="49.022" y="24.13" extent="1-16" drill="0.635"/>
<wire x1="45.72" y1="28.448" x2="44.45" y2="28.448" width="0.508" layer="1"/>
<via x="44.45" y="28.448" extent="1-16" drill="0.635"/>
<wire x1="45.72" y1="30.734" x2="44.45" y2="30.734" width="0.508" layer="1"/>
<via x="44.45" y="30.734" extent="1-16" drill="0.635"/>
<wire x1="38.878" y1="16.732" x2="38.878" y2="15.748" width="0.2032" layer="1"/>
</signal>
<signal name="D0-RX1">
<contactref element="D0" pad="3"/>
<contactref element="U$4" pad="D0"/>
<wire x1="2.413" y1="63.754" x2="8.89" y2="63.754" width="0.2032" layer="16"/>
<wire x1="8.89" y1="63.754" x2="9.652" y2="63.627" width="0.2032" layer="16"/>
<wire x1="9.652" y1="63.627" x2="10.795" y2="62.6364" width="0.2032" layer="16"/>
<wire x1="10.795" y1="62.6364" x2="13.208" y2="62.6364" width="0.2032" layer="16"/>
<wire x1="13.208" y1="62.6364" x2="13.4874" y2="62.357" width="0.2032" layer="16"/>
<wire x1="13.4874" y1="62.357" x2="15.367" y2="62.357" width="0.2032" layer="16"/>
<wire x1="15.367" y1="62.357" x2="18.034" y2="59.69" width="0.2032" layer="16"/>
<wire x1="18.034" y1="59.69" x2="18.9484" y2="59.69" width="0.2032" layer="16"/>
<contactref element="U$5" pad="0"/>
</signal>
<signal name="D1-TX1">
<contactref element="D1" pad="3"/>
<contactref element="U$4" pad="D1"/>
<wire x1="2.667" y1="61.214" x2="8.89" y2="61.214" width="0.2032" layer="16"/>
<wire x1="8.89" y1="61.214" x2="9.652" y2="61.087" width="0.2032" layer="16"/>
<wire x1="9.652" y1="61.087" x2="10.795" y2="60.0964" width="0.2032" layer="16"/>
<wire x1="10.795" y1="60.0964" x2="13.2334" y2="60.0964" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="60.0964" x2="13.5128" y2="59.817" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="59.817" x2="15.367" y2="59.817" width="0.2032" layer="16"/>
<wire x1="15.367" y1="59.817" x2="18.034" y2="57.15" width="0.2032" layer="16"/>
<wire x1="18.034" y1="57.15" x2="19.1516" y2="57.15" width="0.2032" layer="16"/>
<contactref element="U$5" pad="1"/>
</signal>
<signal name="D7-RX3">
<contactref element="D7" pad="3"/>
<contactref element="U$4" pad="D7"/>
<wire x1="2.667" y1="45.974" x2="8.89" y2="45.974" width="0.2032" layer="16"/>
<wire x1="8.89" y1="45.974" x2="9.652" y2="45.847" width="0.2032" layer="16"/>
<wire x1="9.652" y1="45.847" x2="10.795" y2="44.8564" width="0.2032" layer="16"/>
<wire x1="10.795" y1="44.8564" x2="13.2334" y2="44.8564" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="44.8564" x2="13.5128" y2="44.577" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="44.577" x2="15.367" y2="44.577" width="0.2032" layer="16"/>
<wire x1="15.367" y1="44.577" x2="18.034" y2="41.91" width="0.2032" layer="16"/>
<wire x1="18.034" y1="41.91" x2="19.1516" y2="41.91" width="0.2032" layer="16"/>
<contactref element="U$5" pad="7"/>
</signal>
<signal name="D8-TX3">
<contactref element="D8" pad="3"/>
<contactref element="U$4" pad="D8"/>
<wire x1="2.413" y1="41.91" x2="8.89" y2="41.91" width="0.2032" layer="16"/>
<wire x1="8.89" y1="41.91" x2="9.652" y2="41.783" width="0.2032" layer="16"/>
<wire x1="9.652" y1="41.783" x2="10.795" y2="40.7924" width="0.2032" layer="16"/>
<wire x1="10.795" y1="40.7924" x2="13.2334" y2="40.7924" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="40.7924" x2="13.5128" y2="40.513" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="40.513" x2="15.367" y2="40.513" width="0.2032" layer="16"/>
<wire x1="15.367" y1="40.513" x2="16.764" y2="39.37" width="0.2032" layer="16"/>
<wire x1="16.764" y1="39.37" x2="18.9484" y2="39.37" width="0.2032" layer="16"/>
<contactref element="U$5" pad="8"/>
</signal>
<signal name="D2">
<contactref element="D2" pad="3"/>
<contactref element="U$4" pad="D2"/>
<wire x1="2.413" y1="58.674" x2="8.89" y2="58.674" width="0.2032" layer="16"/>
<wire x1="8.89" y1="58.674" x2="9.652" y2="58.547" width="0.2032" layer="16"/>
<wire x1="9.652" y1="58.547" x2="10.795" y2="57.5564" width="0.2032" layer="16"/>
<wire x1="10.795" y1="57.5564" x2="13.2334" y2="57.5564" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="57.5564" x2="13.5128" y2="57.277" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="57.277" x2="15.367" y2="57.277" width="0.2032" layer="16"/>
<wire x1="15.367" y1="57.277" x2="18.034" y2="54.61" width="0.2032" layer="16"/>
<wire x1="18.034" y1="54.61" x2="18.9484" y2="54.61" width="0.2032" layer="16"/>
<contactref element="U$5" pad="2"/>
</signal>
<signal name="D11/MOSI">
<contactref element="D11" pad="3"/>
<contactref element="U$4" pad="D11"/>
<wire x1="2.667" y1="34.29" x2="8.89" y2="34.29" width="0.2032" layer="16"/>
<wire x1="8.89" y1="34.29" x2="9.652" y2="34.163" width="0.2032" layer="16"/>
<wire x1="9.652" y1="34.163" x2="10.795" y2="33.1724" width="0.2032" layer="16"/>
<wire x1="10.795" y1="33.1724" x2="13.2334" y2="33.1724" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="33.1724" x2="13.5128" y2="32.893" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="32.893" x2="15.367" y2="32.893" width="0.2032" layer="16"/>
<wire x1="15.367" y1="32.893" x2="16.764" y2="31.75" width="0.2032" layer="16"/>
<wire x1="16.764" y1="31.75" x2="19.1516" y2="31.75" width="0.2032" layer="16"/>
<contactref element="U$5" pad="11"/>
</signal>
<signal name="D12/MISO">
<contactref element="D12" pad="3"/>
<contactref element="U$4" pad="D12"/>
<wire x1="2.413" y1="31.75" x2="8.89" y2="31.75" width="0.2032" layer="16"/>
<wire x1="8.89" y1="31.75" x2="9.652" y2="31.623" width="0.2032" layer="16"/>
<wire x1="9.652" y1="31.623" x2="10.795" y2="30.6324" width="0.2032" layer="16"/>
<wire x1="10.795" y1="30.6324" x2="13.2334" y2="30.607" width="0.2032" layer="16"/>
<wire x1="13.2334" y1="30.607" x2="13.5128" y2="30.3276" width="0.2032" layer="16"/>
<wire x1="13.5128" y1="30.3276" x2="15.367" y2="30.353" width="0.2032" layer="16"/>
<wire x1="15.367" y1="30.353" x2="16.764" y2="29.21" width="0.2032" layer="16"/>
<wire x1="16.764" y1="29.21" x2="18.9484" y2="29.21" width="0.2032" layer="16"/>
<contactref element="U$5" pad="12"/>
</signal>
<signal name="D13/SCK">
<contactref element="D13" pad="3"/>
<contactref element="U$4" pad="D13"/>
<wire x1="2.667" y1="29.21" x2="8.89" y2="29.21" width="0.2032" layer="16"/>
<wire x1="8.89" y1="29.21" x2="9.652" y2="29.083" width="0.2032" layer="16"/>
<wire x1="9.652" y1="29.083" x2="13.208" y2="25.4" width="0.2032" layer="16"/>
<contactref element="U$5" pad="13"/>
<wire x1="34.1884" y1="29.21" x2="26.162" y2="29.21" width="0.2032" layer="1"/>
<via x="26.162" y="29.21" extent="1-16" drill="0.3048"/>
<wire x1="26.162" y1="29.21" x2="22.098" y2="25.4" width="0.2032" layer="16"/>
<wire x1="22.098" y1="25.4" x2="13.208" y2="25.4" width="0.2032" layer="16"/>
</signal>
<signal name="N$17">
<contactref element="LED3" pad="-"/>
<contactref element="R3" pad="+"/>
<wire x1="19.05" y1="17.272" x2="19.05" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="N$18">
<contactref element="LED4" pad="-"/>
<contactref element="R4" pad="+"/>
<wire x1="16.51" y1="17.272" x2="16.51" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="N$19">
<contactref element="LED5" pad="-"/>
<contactref element="R5" pad="+"/>
<wire x1="14.224" y1="17.272" x2="14.224" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="N$20">
<contactref element="LED6" pad="-"/>
<contactref element="R6" pad="+"/>
<wire x1="10.414" y1="17.272" x2="10.414" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="N$21">
<contactref element="LED9" pad="-"/>
<contactref element="R9" pad="+"/>
<wire x1="8.128" y1="17.272" x2="8.128" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="N$22">
<contactref element="LED10" pad="-"/>
<contactref element="R10" pad="+"/>
<wire x1="5.588" y1="17.272" x2="5.588" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="N$23">
<contactref element="LED20" pad="-"/>
<contactref element="R20" pad="+"/>
<wire x1="30.734" y1="17.526" x2="30.734" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="N$24">
<contactref element="LED21" pad="-"/>
<contactref element="R21" pad="+"/>
<wire x1="28.194" y1="17.526" x2="28.194" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="N$25">
<contactref element="LED22" pad="-"/>
<contactref element="R22" pad="+"/>
<wire x1="25.654" y1="17.526" x2="25.654" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="N$26">
<contactref element="LED23" pad="-"/>
<contactref element="R23" pad="+"/>
<wire x1="23.114" y1="17.526" x2="23.114" y2="19.812" width="0.2032" layer="1"/>
</signal>
<signal name="VIN">
<contactref element="U$5" pad="VIN"/>
<contactref element="LEDD" pad="+"/>
<contactref element="IC1" pad="19"/>
<contactref element="IC1" pad="18"/>
<contactref element="IC1" pad="17"/>
<contactref element="IC1" pad="9"/>
<contactref element="IC1" pad="4"/>
<contactref element="IC1" pad="3"/>
<wire x1="34.3916" y1="62.23" x2="32.766" y2="60.706" width="0.6096" layer="16"/>
<wire x1="32.766" y1="60.706" x2="32.766" y2="25.908" width="0.6096" layer="16"/>
<wire x1="32.766" y1="25.908" x2="39.878" y2="18.796" width="0.6096" layer="16"/>
<wire x1="39.878" y1="18.796" x2="39.878" y2="11.176" width="0.6096" layer="16"/>
<via x="39.878" y="11.176" extent="1-16" drill="0.3048"/>
<wire x1="39.878" y1="11.176" x2="39.878" y2="12.732" width="0.254" layer="1"/>
<wire x1="39.878" y1="11.176" x2="39.37" y2="11.176" width="0.254" layer="16"/>
<via x="39.37" y="11.176" extent="1-16" drill="0.3048"/>
<via x="40.386" y="11.176" extent="1-16" drill="0.3048"/>
<wire x1="39.37" y1="11.176" x2="40.386" y2="11.176" width="0.508" layer="1"/>
<wire x1="40.386" y1="11.176" x2="39.878" y2="11.176" width="0.254" layer="16"/>
<wire x1="39.378" y1="12.732" x2="39.37" y2="11.176" width="0.254" layer="1"/>
<wire x1="40.378" y1="12.732" x2="40.386" y2="11.176" width="0.254" layer="1"/>
<polygon width="0.254" layer="16" rank="2">
<vertex x="36.576" y="10.668"/>
<vertex x="36.576" y="18.288"/>
<vertex x="43.688" y="18.288"/>
<vertex x="43.688" y="10.668"/>
</polygon>
<wire x1="39.378" y1="16.732" x2="39.37" y2="18.034" width="0.254" layer="1"/>
<via x="39.37" y="18.034" extent="1-16" drill="0.3048"/>
<wire x1="39.37" y1="18.034" x2="37.592" y2="19.812" width="0.254" layer="1"/>
<wire x1="37.592" y1="19.812" x2="36.83" y2="19.812" width="0.254" layer="1"/>
<wire x1="41.878" y1="14.732" x2="43.18" y2="14.732" width="0.254" layer="1"/>
<via x="43.18" y="14.732" extent="1-16" drill="0.3048"/>
<wire x1="41.878" y1="15.232" x2="43.18" y2="15.24" width="0.254" layer="1"/>
<via x="43.18" y="15.24" extent="1-16" drill="0.3048"/>
</signal>
<signal name="VBAT">
<contactref element="IC1" pad="14"/>
<contactref element="IC1" pad="15"/>
<contactref element="IC1" pad="16"/>
<contactref element="CBAT" pad="+"/>
<contactref element="LIPO" pad="1"/>
<wire x1="44.974" y1="6.604" x2="44.212" y2="7.366" width="0.6096" layer="1"/>
<wire x1="44.212" y1="7.366" x2="37.084" y2="7.366" width="0.6096" layer="1"/>
<wire x1="37.084" y1="7.366" x2="37.084" y2="8.89" width="0.6096" layer="1"/>
<wire x1="37.084" y1="8.89" x2="37.084" y2="11.684" width="0.6096" layer="1"/>
<polygon width="0.254" layer="1">
<vertex x="36.576" y="10.668"/>
<vertex x="36.576" y="14.478"/>
<vertex x="38.862" y="14.478"/>
<vertex x="38.862" y="10.668"/>
</polygon>
<wire x1="38.878" y1="12.732" x2="38.878" y2="11.938" width="0.254" layer="1"/>
<wire x1="38.878" y1="11.938" x2="38.354" y2="11.938" width="0.254" layer="1"/>
<wire x1="37.878" y1="14.232" x2="37.084" y2="14.232" width="0.254" layer="1"/>
<wire x1="37.084" y1="14.232" x2="37.084" y2="13.732" width="0.254" layer="1"/>
<wire x1="37.878" y1="13.732" x2="37.084" y2="13.732" width="0.254" layer="1"/>
<wire x1="37.084" y1="13.732" x2="37.084" y2="13.716" width="0.254" layer="1"/>
</signal>
<signal name="RST">
<contactref element="U$4" pad="RST"/>
</signal>
<signal name="VSUPPLY">
<contactref element="IC1" pad="1"/>
<contactref element="IC1" pad="20"/>
<contactref element="U$4" pad="VIN"/>
<contactref element="CSUP" pad="+"/>
<contactref element="MCP1703" pad="3"/>
<contactref element="C10" pad="+"/>
<contactref element="C2" pad="+"/>
<contactref element="C7" pad="+"/>
<wire x1="41.878" y1="13.732" x2="42.926" y2="13.716" width="0.254" layer="1"/>
<wire x1="42.926" y1="13.716" x2="43.434" y2="13.208" width="0.254" layer="1"/>
<wire x1="42.958" y1="12.732" x2="43.434" y2="13.208" width="0.254" layer="1"/>
<contactref element="D22M" pad="2"/>
<contactref element="D20M" pad="2"/>
<contactref element="D3M" pad="2"/>
<contactref element="D10M" pad="2"/>
<contactref element="D6M" pad="2"/>
<contactref element="D21M" pad="2"/>
<contactref element="D9M" pad="2"/>
<contactref element="D23M" pad="2"/>
<contactref element="D5M" pad="2"/>
<contactref element="D4M" pad="2"/>
<wire x1="32.766" y1="5.334" x2="38.354" y2="5.334" width="1.778" layer="1"/>
<wire x1="38.354" y1="5.334" x2="40.64" y2="5.334" width="1.778" layer="1"/>
<wire x1="5.461" y1="4.064" x2="8.001" y2="4.064" width="1.778" layer="16"/>
<wire x1="8.001" y1="4.064" x2="10.541" y2="4.064" width="1.778" layer="16"/>
<wire x1="10.541" y1="4.064" x2="14.097" y2="4.064" width="1.778" layer="16"/>
<wire x1="14.097" y1="4.064" x2="16.637" y2="4.064" width="1.778" layer="16"/>
<wire x1="16.637" y1="4.064" x2="19.177" y2="4.064" width="1.778" layer="16"/>
<wire x1="19.177" y1="4.064" x2="22.987" y2="4.064" width="1.778" layer="16"/>
<wire x1="22.987" y1="4.064" x2="25.527" y2="4.064" width="1.778" layer="16"/>
<wire x1="25.527" y1="4.064" x2="28.067" y2="4.064" width="1.778" layer="16"/>
<wire x1="28.067" y1="4.064" x2="30.607" y2="4.064" width="1.778" layer="16"/>
<polygon width="0.254" layer="1">
<vertex x="43.688" y="10.668"/>
<vertex x="41.0464" y="10.668"/>
<vertex x="41.0464" y="13.716"/>
<vertex x="43.688" y="13.716"/>
</polygon>
<wire x1="40.878" y1="12.732" x2="40.878" y2="11.938" width="0.254" layer="1"/>
<wire x1="40.878" y1="11.938" x2="41.656" y2="11.938" width="0.254" layer="1"/>
<wire x1="41.656" y1="11.938" x2="41.656" y2="12.732" width="0.254" layer="1"/>
<wire x1="41.656" y1="12.732" x2="42.958" y2="12.732" width="0.254" layer="1"/>
<wire x1="40.64" y1="5.334" x2="42.164" y2="5.334" width="1.778" layer="1"/>
<contactref element="C6" pad="1"/>
<wire x1="35.306" y1="4.318" x2="35.306" y2="5.156" width="0.254" layer="1"/>
<wire x1="38.354" y1="4.318" x2="38.354" y2="5.334" width="0.2

license: MIT

repository: tekdemo/TeensyBreakout

license_type: permissive

repo_name: tekdemo/TeensyBreakout

branch_name: refs/heads/master

extension: brd


text:
54" layer="1"/>
<wire x1="40.64" y1="4.318" x2="40.64" y2="5.334" width="0.254" layer="1"/>
<wire x1="42.164" y1="5.334" x2="43.18" y2="4.318" width="1.016" layer="1"/>
<wire x1="43.18" y1="4.318" x2="49.53" y2="4.318" width="1.016" layer="1"/>
<wire x1="49.53" y1="4.318" x2="49.53" y2="8.636" width="1.016" layer="1"/>
<wire x1="49.53" y1="8.636" x2="46.482" y2="11.684" width="1.016" layer="1"/>
<wire x1="46.482" y1="11.684" x2="42.926" y2="11.684" width="1.016" layer="1"/>
<wire x1="32.766" y1="5.334" x2="31.496" y2="4.064" width="1.778" layer="1"/>
<wire x1="31.496" y1="4.064" x2="30.607" y2="4.064" width="1.778" layer="1"/>
<wire x1="30.607" y1="4.064" x2="28.067" y2="4.064" width="1.778" layer="1"/>
<wire x1="28.067" y1="4.064" x2="25.527" y2="4.064" width="1.778" layer="1"/>
<wire x1="43.434" y1="13.208" x2="45.466" y2="14.986" width="0.6096" layer="1"/>
<wire x1="45.466" y1="14.986" x2="45.466" y2="16.51" width="0.6096" layer="1"/>
<contactref element="CSUP1" pad="+"/>
<wire x1="40.132" y1="26.416" x2="40.132" y2="28.448" width="0.6096" layer="1"/>
<wire x1="40.132" y1="28.448" x2="40.132" y2="31.75" width="0.6096" layer="1"/>
<wire x1="40.132" y1="31.75" x2="39.794" y2="31.75" width="0.6096" layer="1"/>
<wire x1="50.673" y1="45.974" x2="52.578" y2="44.196" width="0.6096" layer="1"/>
<wire x1="52.578" y1="44.196" x2="52.578" y2="19.05" width="0.6096" layer="1"/>
<wire x1="52.578" y1="19.05" x2="48.26" y2="14.986" width="0.6096" layer="1"/>
<wire x1="48.26" y1="14.986" x2="45.466" y2="14.986" width="0.6096" layer="1"/>
<contactref element="MCP1" pad="3"/>
<contactref element="CSUP2" pad="+"/>
<wire x1="45.72" y1="21.844" x2="45.72" y2="25.146" width="0.508" layer="1"/>
<wire x1="45.72" y1="25.146" x2="45.382" y2="25.146" width="0.508" layer="1"/>
<wire x1="45.466" y1="16.51" x2="45.466" y2="17.526" width="0.6096" layer="1"/>
<wire x1="45.466" y1="17.526" x2="45.466" y2="21.59" width="0.6096" layer="1"/>
<wire x1="45.466" y1="21.59" x2="45.72" y2="21.844" width="0.6096" layer="1"/>
<wire x1="44.196" y1="22.352" x2="40.132" y2="26.416" width="0.6096" layer="1"/>
<wire x1="44.196" y1="22.352" x2="44.196" y2="18.796" width="0.6096" layer="1"/>
<wire x1="44.196" y1="18.796" x2="45.466" y2="17.526" width="0.6096" layer="1"/>
<wire x1="32.766" y1="5.334" x2="35.306" y2="5.156" width="0" layer="19" extent="1-1"/>
</signal>
<signal name="N$1">
<contactref element="IC1" pad="5"/>
<contactref element="RTH" pad="+"/>
<wire x1="41.878" y1="15.732" x2="42.672" y2="15.748" width="0.254" layer="1"/>
<wire x1="42.672" y1="15.748" x2="42.672" y2="19.812" width="0.254" layer="1"/>
</signal>
<signal name="N$2">
<contactref element="IC1" pad="12"/>
<contactref element="RPD3" pad="+"/>
<wire x1="37.878" y1="15.232" x2="37.87" y2="15.24" width="0.254" layer="1"/>
<wire x1="37.87" y1="15.24" x2="35.56" y2="15.24" width="0.254" layer="1"/>
<wire x1="35.56" y1="15.24" x2="35.052" y2="14.732" width="0.254" layer="1"/>
</signal>
<signal name="N$4">
<contactref element="IC1" pad="13"/>
<contactref element="RPD1" pad="+"/>
<wire x1="37.878" y1="14.732" x2="36.83" y2="14.732" width="0.254" layer="1"/>
<wire x1="36.83" y1="14.732" x2="35.052" y2="12.7" width="0.254" layer="1"/>
</signal>
<signal name="N$6">
<contactref element="IC1" pad="6"/>
<contactref element="RDONE" pad="-"/>
<wire x1="40.878" y1="16.732" x2="40.894" y2="17.764" width="0.254" layer="1"/>
<wire x1="40.894" y1="17.764" x2="39.624" y2="19.812" width="0.254" layer="1"/>
</signal>
<signal name="N$7">
<contactref element="RDONE" pad="+"/>
<contactref element="LEDD" pad="-"/>
<wire x1="39.624" y1="21.336" x2="36.83" y2="21.336" width="0.254" layer="1"/>
</signal>
<signal name="N$3">
<polygon width="0.508" layer="1" spacing="0.508" isolate="0.508" rank="6">
<vertex x="0" y="0"/>
<vertex x="0" y="66.04"/>
<vertex x="12.7" y="66.04"/>
<vertex x="15.494" y="68.834"/>
<vertex x="53.34" y="68.834"/>
<vertex x="53.34" y="0"/>
</polygon>
</signal>
</signals>
<errors>
<approved hash="3,1,1a481a7a1a621a50"/>
<approved hash="3,1,2a480a7a0a622a50"/>
<approved hash="3,1,5048727a72625050"/>
<approved hash="3,1,58481e7a1e625850"/>
<approved hash="3,1,1a381a0a1a221a10"/>
<approved hash="3,1,2a380a0a0a222a10"/>
<approved hash="3,1,5038720a72225010"/>
<approved hash="3,1,58381e0a1e225810"/>
<approved hash="3,1,1a281a1a19e219d0"/>
<approved hash="3,1,2a280a1a09e229d0"/>
<approved hash="3,1,5028721a71e253d0"/>
<approved hash="3,1,58281e1a1de25bd0"/>
<approved hash="3,1,1a301a021a221a10"/>
<approved hash="3,1,2a300a020a222a10"/>
<approved hash="3,1,5030720272225010"/>
<approved hash="3,1,58301e021e225810"/>
<approved hash="3,1,1a381a0a1a021a30"/>
<approved hash="3,1,2a380a0a0a022a30"/>
<approved hash="3,1,5038720a72025030"/>
<approved hash="3,1,58381e0a1e025830"/>
<approved hash="3,1,1dd01de21de21dd0"/>
<approved hash="3,1,2dd00de20de22dd0"/>
<approved hash="3,1,57d075e275e257d0"/>
<approved hash="3,1,5fd019e219e25fd0"/>
<approved hash="3,1,1a283a1a39e219d0"/>
<approved hash="3,1,1a281a1a19e219d0"/>
<approved hash="3,1,3028021a01e233d0"/>
<approved hash="3,1,5828761a75e25bd0"/>
<approved hash="3,1,1a383a0a3a221a10"/>
<approved hash="3,1,1a381a0a1a221a10"/>
<approved hash="3,1,3038020a02223010"/>
<approved hash="3,1,1a483a7a3a621a50"/>
<approved hash="3,1,1a481a7a1a621a50"/>
<approved hash="3,1,3048027a02623050"/>
<approved hash="3,1,5848767a76625850"/>
<approved hash="3,1,1a303a023a021a30"/>
<approved hash="3,1,1a301a021a021a30"/>
<approved hash="3,1,5830760276025830"/>
<approved hash="3,1,5838760a76225810"/>
<approved hash="3,1,1028381a3828101a"/>
<approved hash="3,1,10303802381c102e"/>
<approved hash="3,1,3028081a0828301a"/>
<approved hash="3,1,30300802081c302e"/>
<approved hash="3,1,30280a1a0a28301a"/>
<approved hash="3,1,30300a020a1c302e"/>
<approved hash="3,1,50001a321a225010"/>
<approved hash="3,1,502c1a1e1a2a5018"/>
<approved hash="3,1,10401c721c641056"/>
<approved hash="3,1,10301c021c3c100e"/>
<approved hash="3,1,10201a121ae210d0"/>
<approved hash="3,1,103c1a0e1a1a1028"/>
<approved hash="3,1,10240216026a1058"/>
<approved hash="3,1,1048027a026a1058"/>
<approved hash="3,1,2dfe000600da2d22"/>
<approved hash="3,1,aa7c78047859aa21"/>
<approved hash="3,1,aafe340634d5aa2d"/>
<approved hash="3,1,aa78780079d6abae"/>
<approved hash="3,1,da3bfa09fa03da31"/>
<approved hash="3,1,d63a12081202d630"/>
<approved hash="3,1,d63612041202d630"/>
<approved hash="3,1,da37fa05fa03da31"/>
<approved hash="5,1,e2f31875f953f334"/>
<approved hash="19,1,99fe53c86c2a5481"/>
<approved hash="19,1,226c782ffc9076fc"/>
<approved hash="19,1,4b1c6ddc62d04410"/>
<approved hash="19,1,453c63fc622444e4"/>
<approved hash="19,1,c50d204d206ec52e"/>
<approved hash="19,1,3bfefec9ac8d997b"/>
<approved hash="19,1,9e7764969fd39cab"/>
<approved hash="19,1,226c782ffc9076fc"/>
<approved hash="19,1,3d022a422a603d20"/>
<approved hash="19,1,4b1c6ddc62d04410"/>
<approved hash="19,1,453c63fc622444e4"/>
<approved hash="19,1,3d022a422a603d20"/>
<approved hash="19,1,4b1c6ddc62d04410"/>
<approved hash="19,1,453c63fc622444e4"/>
<approved hash="19,1,c50d204d206ec52e"/>
<approved hash="5,1,2277ae402f1dd021"/>
<approved hash="5,1,966264eaa6e927da"/>
<approved hash="5,1,72e1859f7bd37274"/>
<approved hash="5,1,22bfd9f894df3769"/>
<approved hash="5,1,17ace03746878417"/>
<approved hash="5,1,26362f5d0cfc302c"/>
<approved hash="3,1,d61012221222d610"/>
<approved hash="3,1,da11fa23fa23da11"/>
<approved hash="3,1,50301c021c625050"/>
<approved hash="3,1,50441c761c7a5048"/>
<approved hash="3,1,50301c021c025030"/>
<approved hash="3,1,50241c161c2a5018"/>
<approved hash="3,1,1030080208621050"/>
<approved hash="3,1,10440876087a1048"/>
<approved hash="3,1,1030080208021030"/>
<approved hash="3,1,10240816082a1018"/>
<approved hash="3,1,5030020202625050"/>
<approved hash="3,1,50440276027a5048"/>
<approved hash="3,1,5030020202025030"/>
<approved hash="3,1,50240216022a5018"/>
<approved hash="3,1,1030180218621050"/>
<approved hash="3,1,10441876187a1048"/>
<approved hash="3,1,1030180218021030"/>
<approved hash="3,1,10241816182a1018"/>
<approved hash="3,1,3030020202623050"/>
<approved hash="3,1,30440276027a3048"/>
<approved hash="3,1,3030020202023030"/>
<approved hash="3,1,30240216022a3018"/>
<approved hash="3,1,d030fa02fa62d050"/>
<approved hash="3,1,d044fa76fa7ad048"/>
<approved hash="3,1,d030fa02fa02d030"/>
<approved hash="3,1,d024fa16fa2ad018"/>
<approved hash="3,1,3030080208623050"/>
<approved hash="3,1,30440876087a3048"/>
<approved hash="3,1,3038080a0818302a"/>
<approved hash="3,1,30300802082c301e"/>
<approved hash="3,1,1030380238621050"/>
<approved hash="3,1,10443876387a1048"/>
<approved hash="3,1,1038380a3818102a"/>
<approved hash="3,1,10303802382c101e"/>
<approved hash="3,1,d0300c020c62d050"/>
<approved hash="3,1,d0440c760c7ad048"/>
<approved hash="3,1,d0380c0a0c18d02a"/>
<approved hash="3,1,d0300c020c2cd01e"/>
<approved hash="3,1,10300c020c621050"/>
<approved hash="3,1,10440c760c7a1048"/>
<approved hash="3,1,10380c0a0c18102a"/>
<approved hash="3,1,10300c020c2c101e"/>
<approved hash="3,1,1030020202621050"/>
<approved hash="3,1,10440276027a1048"/>
<approved hash="3,1,d63a12081222d610"/>
<approved hash="3,1,da3bfa09fa23da11"/>
<approved hash="3,1,c8160a240a22c810"/>
<approved hash="3,1,d815fe27fe21d813"/>
<approved hash="3,1,10081a3a1a2a1018"/>
<approved hash="3,1,10241a161a2a1018"/>
<approved hash="3,1,10301a021ae210d0"/>
<approved hash="3,1,11c41bf61bfa11c8"/>
<approved hash="3,1,50441a761a7a5048"/>
<approved hash="3,1,50301a021a625050"/>
<approved hash="3,1,1030380238621050"/>
<approved hash="3,1,10443876387a1048"/>
</errors>
</board>
</drawing>
<compatibility>
<note version="6.3" minversion="6.2.2" severity="warning">
Since Version 6.2.2 text objects can contain more than one line,
which will not be processed correctly with this version.
</note>
</compatibility>
</eagle>


text:
################################################################################
# Custom cmake module for CEGUI to find the MiniZip library
################################################################################
include(FindPackageHandleStandardArgs)

find_path(MINIZIP_H_PATH NAMES minizip/unzip.h)
find_library(MINIZIP_LIB NAMES minizip PATH_SUFFIXES dynamic/${CEGUI_ARCH_SUFFIX})
find_library(MINIZIP_LIB_DBG NAMES minizip_d minizipd PATH_SUFFIXES dynamic/${CEGUI_ARCH_SUFFIX})
mark_as_advanced(MINIZIP_H_PATH MINIZIP_LIB MINIZIP_LIB_DBG)

if (WIN32 OR APPLE)
    find_library(MINIZIP_LIB_STATIC NAMES minizip PATH_SUFFIXES static/${CEGUI_ARCH_SUFFIX})
    find_library(MINIZIP_LIB_STATIC_DBG NAMES minizip_d minizipd PATH_SUFFIXES static/${CEGUI_ARCH_SUFFIX})
    mark_as_advanced(MINIZIP_LIB_STATIC MINIZIP_LIB_STATIC_DBG)
endif()

if (APPLE)
    set(MINIZIP_DEFINITIONS USE_FILE32API)
    mark_as_advanced(MINIZIP_DEFINITIONS)
endif()

cegui_find_package_handle_standard_args(Minizip MINIZIP_LIB MINIZIP_H_PATH)

# set up output vars
if (MINIZIP_FOUND)
    set (MINIZIP_INCLUDE_DIR ${MINIZIP_H_PATH})
    set (MINIZIP_LIBRARIES ${MINIZIP_LIB})
    if (MINIZIP_LIB_DBG)
        set (MINIZIP_LIBRARIES_DBG ${MINIZIP_LIB_DBG})
    endif()
    if (MINIZIP_LIB_STATIC)
        set (MINIZIP_LIBRARIES_STATIC ${MINIZIP_LIB_STATIC})
    endif()
    if (MINIZIP_LIB_STATIC_DBG)
        set (MINIZIP_LIBRARIES_STATIC_DBG ${MINIZIP_LIB_STATIC_DBG})
    endif()
else()
    set (MINIZIP_INCLUDE_DIR)
    set (MINIZIP_LIBRARIES)
    set (MINIZIP_LIBRARIES_DBG)
    set (MINIZIP_LIBRARIES_STATIC)
    set (MINIZIP_LIBRARIES_STATIC_DBG)
endif()

repository: cegui/cegui

repo_name: cegui/cegui

gha_license_id: MIT

extension: cmake


text:
// This file is distributed under the MIT license.
// See the LICENSE file for details.

#include <type_traits>

#include <visionaray/detail/algorithm.h>

#include "../simd/type_traits.h"
#include "../config.h"
#include "math.h"

namespace MATH_NAMESPACE
{

//--------------------------------------------------------------------------------------------------
// vectorN members

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>::vector(T const& s)
{
    for (size_t d = 0; d < Dim; ++d)
    {
        data_[d] = s;
    }
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>::vector(T const* data/*[Dim]*/)
{
    algo::copy(data, data + Dim, data_);
}

template <size_t Dim, typename T>
template <typename U>
MATH_FUNC
inline vector<Dim, T>::vector(vector<Dim, U> const& rhs)
{
    // Cannot copy, use static casts
    for (size_t d = 0; d < Dim; ++d)
    {
        data_[d] = static_cast<T>(rhs.data()[d]);
    }
}

template <size_t Dim, typename T>
template <size_t Dim1, size_t Dim2, typename U>
MATH_FUNC
inline vector<Dim, T>::vector(vector<Dim1, U> const& first, vector<Dim2, U> const& second)
{
    static_assert(Dim1 + Dim2 == Dim, "Incompatible vector dimensions");
    algo::copy(first.data(), first.data() + Dim1, data_);
    algo::copy(second.data(), second.data() + Dim2, data_ + Dim1);
}

template <size_t Dim, typename T>
template <typename U>
MATH_FUNC
inline vector<Dim, T>& vector<Dim, T>::operator=(vector<Dim, U> const& rhs)
{
    std::copy( rhs.data(), rhs.data() + Dim, data_ );
    return *this;
}

template <size_t Dim, typename T>
MATH_FUNC
inline T* vector<Dim, T>::data()
{
    return data_;
}

template <size_t Dim, typename T>
MATH_FUNC
inline T const* vector<Dim, T>::data() const
{
    return data_;
}

template <size_t Dim, typename T>
MATH_FUNC
inline T& vector<Dim, T>::operator[](size_t i)
{
    return data_[i];
}

template <size_t Dim, typename T>
MATH_FUNC
inline T const& vector<Dim, T>::operator[](size_t i) const
{
    return data_[i];
}

//--------------------------------------------------------------------------------------------------
// Basic arithmetic
//

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator+(vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = +v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator-(vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = -v[d];
    }

    return result;
}

// vector op vector

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator+(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = u[d] + v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator-(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = u[d] - v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator*(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = u[d] * v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator/(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = u[d] / v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator&(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = u[d] & v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator|(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = u[d] | v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator^(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = u[d] ^ v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator<<(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = u[d] << v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator>>(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = u[d] >> v[d];
    }

    return result;
}

// vector op scalar

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator+(vector<Dim, T> const& v, T const& s)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = v[d] + s;
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator-(vector<Dim, T> const& v, T const& s)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = v[d] - s;
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator*(vector<Dim, T> const& v, T const& s)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = v[d] * s;
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator/(vector<Dim, T> const& v, T const& s)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = v[d] / s;
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator&(vector<Dim, T> const& v, T const& s)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = v[d] & s;
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator|(vector<Dim, T> const& v, T const& s)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = v[d] | s;
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator^(vector<Dim, T> const& v, T const& s)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = v[d] ^ s;
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator<<(vector<Dim, T> const& v, T const& s)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = v[d] << s;
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator>>(vector<Dim, T> const& v, T const& s)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = v[d] >> s;
    }

    return result;
}

// scalar op vector

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator+(T const& s, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = s + v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator-(T const& s, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = s - v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator*(T const& s, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = s * v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator/(T const& s, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = s / v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator&(T const& s, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = s & v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator|(T const& s, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = s | v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator^(T const& s, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = s ^ v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator<<(T const& s, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = s << v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> operator>>(T const& s, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = s >> v[d];
    }

    return result;
}

// append operations

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator+=(vector<Dim, T>& u, vector<Dim, T> const& v)
{
    u = u + v;
    return u;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator+=(vector<Dim, T>& v, T const& s)
{
    v = v + s;
    return v;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator-=(vector<Dim, T>& u, vector<Dim, T> const& v)
{
    u = u - v;
    return u;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator-=(vector<Dim, T>& v, T const& s)
{
    v = v - s;
    return v;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator*=(vector<Dim, T>& u, vector<Dim, T> const& v)
{
    u = u * v;
    return u;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator*=(vector<Dim, T>& v, T const& s)
{
    v = v * s;
    return v;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator/=(vector<Dim, T>& u, vector<Dim, T> const& v)
{
    u = u / v;
    return u;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator/=(vector<Dim, T>& v, T const& s)
{
    v = v / s;
    return v;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator&=(vector<Dim, T>& u, vector<Dim, T> const& v)
{
    u = u & v;
    return u;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator&=(vector<Dim, T>& v, T const& s)
{
    v = v & s;
    return v;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator|=(vector<Dim, T>& u, vector<Dim, T> const& v)
{
    u = u | v;
    return u;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator|=(vector<Dim, T>& v, T const& s)
{
    v = v | s;
    return v;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator^=(vector<Dim, T>& u, vector<Dim, T> const& v)
{
    u = u ^ v;
    return u;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator^=(vector<Dim, T>& v, T const& s)
{
    v = v ^ s;
    return v;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator<<=(vector<Dim, T>& u, vector<Dim, T> const& v)
{
    u = u << v;
    return u;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator<<=(vector<Dim, T>& v, T const& s)
{
    v = v << s;
    return v;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator>>=(vector<Dim, T>& u, vector<Dim, T> const& v)
{
    u = u >> v;
    return u;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T>& operator>>=(vector<Dim, T>& v, T const& s)
{
    v = v >> s;
    return v;
}

//--------------------------------------------------------------------------------------------------
// Geometric functions
//

template <size_t Dim, typename T>
MATH_FUNC
inline T dot(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    T result(0.0);

    for (size_t d = 0; d < Dim; ++d)
    {
        result += u[d] * v[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> faceforward(
        vector<Dim, T> const& n,
        vector<Dim, T> const& i,
        vector<Dim, T> const& nref
        )
{
    return select( dot(nref, i) < T(0.0), -n, n );
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> reflect(vector<Dim, T> const& i, vector<Dim, T> const& n)
{
    return T(2.0) * dot(n, i) * n - i;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> refract(vector<Dim, T> const& i, vector<Dim, T> const& n, T const& eta)
{
    T cosi = dot(n, i);
    T sini = max(T(0.0), T(1.0) - cosi * cosi);
    T sint = eta * eta * sini;

    return select(
            sint >= T(1.0),
            vector<Dim, T>(0.0),
            eta * -i + (eta * cosi - sqrt(T(1.0) - sint)) * n
            );
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> floor(vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = floor(v[d]);
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> ceil(vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = ceil(v[d]);
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> round(vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = round(v[d]);
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> fract(vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = fract(v[d]);
    }

    return result;
}

//-------------------------------------------------------------------------------------------------
// Misc.
//

template <size_t Dim, typename M, typename T>
MATH_FUNC
inline vector<Dim, T> select(M const& m, vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = select(m, u[d], v[d]);
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> min(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = min(u[d], v[d]);
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> max(vector<Dim, T> const& u, vector<Dim, T> const& v)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = max(u[d], v[d]);
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> step(vector<Dim, T> const& edge, vector<Dim, T> const& x)
{
    vector<Dim, T> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = step(edge[d], x[d]);
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline vector<Dim, T> rotate(vector<Dim, T> v, int count = 1)
{
    auto tmp = v;

    for (size_t d = 0; d < Dim; ++d)
    {
        auto d2 = (d + count) % Dim;
        v[d2] = tmp[d];
    }

    return v;
}

// Returns the index of the smallest element of the vector
template <size_t Dim, typename T>
MATH_FUNC
inline size_t min_index(vector<Dim, T> const& u)
{
    size_t i = u[1] < u[0] ? 1 : 0;

    for (size_t n = 2; n < Dim; ++n)
    {
        i = u[n] < u[i] ? n : i;
    }

    return i;
}

// Returns the index of the largest element of the vector
template <size_t Dim, typename T>
MATH_FUNC
inline size_t max_index(vector<Dim, T> const& u)
{
    size_t i = u[1] < u[0] ? 0 : 1;

    for (size_t n = 2; n < Dim; ++n)
    {
        i = u[n] < u[i] ? i : n;
    }

    return i;
}

// Returns the indices of the smallest and largest elements of the vector
template <size_t Dim, typename T>
MATH_FUNC
inline vector<2, size_t> minmax_index(vector<Dim, T> const& u)
{
    vector<2, size_t> i(
            u[1] < u[0] ? 1 : 0,
            u[1] < u[0] ? 0 : 1
            );

    for (size_t n = 2; n < Dim; ++n)
    {
        i.x = u[n] < u[i.x] ? n : i.x;
        i.y = u[n] < u[i.y] ? i.y : n;
    }

    return i;
}

// Returns the smallest element
template <size_t Dim, typename T>
MATH_FUNC
inline T min_element(vector<Dim, T> const& u)
{
    T result = u[0];

    for (size_t n = 1; n < Dim; ++n)
    {
        result = select(
                u[n] < result,
                u[n],
                result
                );
    }

    return result;
}

// Returns the largest element
template <size_t Dim, typename T>
MATH_FUNC
inline T max_element(vector<Dim, T> const& u)
{
    T result = u[0];

    for (size_t n = 1; n < Dim; ++n)
    {
        result = select(
                u[n] > result,
                u[n],
                result
                );
    }

    return result;
}

// Returns the smallest and the largest element
template <size_t Dim, typename T>
MATH_FUNC
inline vector<2, T> minmax_element(vector<Dim, T> const& u)
{
    vector<2, T> result(u[0]);

    for (size_t n = 1; n < Dim; ++n)
    {
        result.x = select(
                u[n] < result.x,
                u[n],
                result.x
                );

        result.y = select(
                u[n] > result.y,
                u[n],
                result.y
                );
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline T hadd(vector<Dim, T> const& u)
{
    T result(0.0);

    for (size_t d = 0; d < Dim; ++d)
    {
        result += u[d];
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline T hmul(vector<Dim, T> const& u)
{
    T result(1.0);

    for (size_t d = 0; d < Dim; ++d)
    {
        result *= u[d];
    }

    return result;
}

//-------------------------------------------------------------------------------------------------
// Convert from float to int
//

template <size_t Dim, typename T>
MATH_FUNC
inline auto convert_to_float(vector<Dim, T> const& v)
    -> vector<Dim, decltype(convert_to_float(v[0]))>
{
    vector<Dim, decltype(convert_to_float(v[0]))> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = convert_to_float(v[d]);
    }

    return result;
}

template <size_t Dim, typename T>
MATH_FUNC
inline auto convert_to_int(vector<Dim, T> const& v)
    -> vector<Dim, decltype(convert_to_int(v[0]))>
{
    vector<Dim, decltype(convert_to_int(v[0]))> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        result[d] = convert_to_int(v[d]);
    }

    return result;
}

namespace simd
{

//-------------------------------------------------------------------------------------------------
// SIMD conversions
//

// pack ---------------------------------------------------

template <size_t Dim, typename T, size_t N>
VSNRAY_FUNC
inline auto pack(array<vector<Dim, T>, N> const& vecs)
    -> vector<Dim, float_from_simd_width_t<N>>
{
    using U = float_from_simd_width_t<N>; // TODO: generalize, not just float!
    using float_array = aligned_array_t<U>;

    vector<Dim, U> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        float_array v;
        for (size_t i = 0; i < N; ++i)
        {
            v[i] = vecs[i][d];
        }
        result[d] = U(v);
    }

    return result;
}

// pack four vectors

template <size_t Dim, typename T>
VSNRAY_FUNC
inline auto pack(
        vector<Dim, T> const& v1,
        vector<Dim, T> const& v2,
        vector<Dim, T> const& v3,
        vector<Dim, T> const& v4
        )
    -> vector<Dim, float_from_simd_width_t<4>>
{
    return pack( array<vector<Dim, T>, 4>{{
            v1, v2, v3, v4
            }} );
}

// pack eight vectors

template <size_t Dim, typename T>
inline auto pack(
        vector<Dim, T> const& v1,
        vector<Dim, T> const& v2,
        vector<Dim, T> const& v3,
        vector<Dim, T> const& v4,
        vector<Dim, T> const& v5,
        vector<Dim, T> const& v6,
        vector<Dim, T> const& v7,
        vector<Dim, T> const& v8
        )
    -> vector<Dim, float_from_simd_width_t<8>>
{
    return pack( array<vector<Dim, T>, 8>{{
            v1, v2, v3, v4, v5, v6, v7, v8
            }} );
}

// unpack -------------------------------------------------

template <
    size_t Dim,
    typename T,
    typename = typename std::enable_if<is_simd_vector<T>::value>::type
    >
inline array<vector<Dim, element_type_t<T>>, num_elements<T>::value> unpack(vector<Dim, T> const& v)
{
    using U = element_type_t<T>;

    array<vector<Dim, U>, num_elements<T>::value> result;

    for (size_t d = 0; d < Dim; ++d)
    {
        U const* data = reinterpret_cast<U const*>(&v[d]);

        for (int i = 0; i < num_elements<T>::value; ++i)
        {
            result[i][d] = data[i];
        }
    }

    return result;
}

} // simd
} // MATH_NAMESPACE

repository: szellmann/visionaray

repo_name: szellmann/visionaray

extension: inl


text:
DESCRIPTION = "library for easy implementation of a RDP/VNC server"
HOMEPAGE = "https://libvnc.github.io"
SECTION = "libs"
PRIORITY = "optional"
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=361b6b837cad26c6900a926b62aada5f"

DEPENDS += "zlib libsdl jpeg libpng gtk+ libgcrypt nettle gnutls gmp"
RDEPENDS_${PN} += "libpng gtk+ libgcrypt"

inherit autotools binconfig pkgconfig

SRC_URI  = "\
    ${DEBIAN_MIRROR}/main/libv/libvncserver/libvncserver_0.9.10+dfsg.orig.tar.xz \
    file://0001-remove-webclients-build.patch \
    file://0002-common-add-sha1.patch \
"

SRC_URI[md5sum] = "e883b6c7bd339a5e1c48645051abe5c4"
SRC_URI[sha256sum] = "583f28869b82aec57768d7d18cd7ff81bf092ecbbc1209b587c2c2cd68330250"

S = "${WORKDIR}/${BPN}-LibVNCServer-${PV}"

TARGET_LDFLAGS += "-lgcrypt"

extension: bb


text:
package loaderx

import (
	"go/ast"
	"go/types"

	"golang.org/x/tools/go/loader"
)

func FuncDeclOfTypeFunc(pkgInfo *loader.PackageInfo, typeFunc *types.Func) *ast.FuncDecl {
	for ident, def := range pkgInfo.Defs {
		if typeFuncDef, ok := def.(*types.Func); ok {
			if typeFuncDef == typeFunc {
				return FuncDeclOf(ident, FileOf(ident, pkgInfo.Files...))
			}
		}
	}
	return nil
}

func FuncDeclOf(ident *ast.Ident, file *ast.File) (funcDecl *ast.FuncDecl) {
	ast.Inspect(file, func(node ast.Node) bool {
		if decl, ok := node.(*ast.FuncDecl); ok {
			if decl.Name == ident {
				funcDecl = decl
				return false
			}
		}
		return true
	})
	return
}

func GetIdentChainCallOfCallFun(expr ast.Expr) (list []*ast.Ident) {
	switch expr.(type) {
	case *ast.SelectorExpr:
		selectorExpr := expr.(*ast.SelectorExpr)
		list = append(list, GetIdentChainCallOfCallFun(selectorExpr.X)...)
		list = append(list, selectorExpr.Sel)
	case *ast.Ident:
		list = append(list, expr.(*ast.Ident))
	}
	return
}

func ForEachFuncResult(program *loader.Program, typeFunc *types.Func, walker func(resultTypeAndValues ...types.TypeAndValue)) {
	if typeFunc == nil {
		return
	}

	pkgInfo := program.Package(typeFunc.Pkg().Path())
	funcDecl := FuncDeclOfTypeFunc(pkgInfo, typeFunc)

	if funcDecl == nil {
		// todo find way to location interface
		return
	}

	signature := typeFunc.Type().(*types.Signature)
	results := signature.Results()
	resultLength := results.Len()

	returnStmtList := make([]*ast.ReturnStmt, 0)

	// collect all return stmt
	ast.Inspect(funcDecl, func(node ast.Node) bool {
		switch node.(type) {
		case *ast.FuncLit:
			// skip func inline declaration
			return false
		case *ast.ReturnStmt:
			returnStmtList = append(returnStmtList, node.(*ast.ReturnStmt))
		}
		return true
	})

	for _, returnStmt := range returnStmtList {
		namedResults := make([]ast.Expr, resultLength)
		typeAndValues := make([]types.TypeAndValue, resultLength)
		skip := false

		ast.Inspect(funcDecl, func(node ast.Node) bool {
			switch node.(type) {
			// skip for `switch-case` if return no in
			case *ast.CaseClause:
				caseBody := node.(*ast.CaseClause)
				return !hasReturn(node) || caseBody.Pos() <= returnStmt.Pos() && returnStmt.Pos() < caseBody.End()
			case *ast.IfStmt:
				ifBody := node.(*ast.IfStmt).Body
				return !hasReturn(node) || ifBody.Pos() <= returnStmt.Pos() && returnStmt.Pos() < ifBody.End()
			case *ast.ReturnStmt:
				currentReturnStmt := node.(*ast.ReturnStmt)
				if !skip && currentReturnStmt == returnStmt {
					if currentReturnStmt.Results == nil {
						for i := 0; i < resultLength; i++ {
							typeAndValues[i] = MustEvalExpr(program.Fset, pkgInfo.Pkg, namedResults[i])
							typeAndValues[i] = patchTypeAndValue(results.At(i).Type(), typeAndValues[i])
						}
						walker(typeAndValues...)
					} else {
						if len(currentReturnStmt.Results) < resultLength {
							if callExpr, ok := currentReturnStmt.Results[0].(*ast.CallExpr); ok {
								identList := GetIdentChainCallOfCallFun(callExpr.Fun)
								ForEachFuncResult(program, pkgInfo.ObjectOf(identList[len(identList)-1]).(*types.Func), walker)
							}
						} else {
							for i := 0; i < resultLength; i++ {
								typeAndValues[i] = MustEvalExpr(program.Fset, pkgInfo.Pkg, currentReturnStmt.Results[i])
								typeAndValues[i] = patchTypeAndValue(results.At(i).Type(), typeAndValues[i])
							}
							walker(typeAndValues...)
						}
					}
				}
			case *ast.AssignStmt:
				// only scan before return
				if node != nil && node.Pos() >= returnStmt.Pos() {
					return false
				}

				assignStmt := node.(*ast.AssignStmt)

				if len(assignStmt.Rhs) == 1 {
					if _, ok := assignStmt.Rhs[0].(*ast.FuncLit); ok {
						return false
					}
				}

				if len(assignStmt.Lhs) == len(assignStmt.Rhs) {
					for i, expr := range assignStmt.Lhs {
						if ident, ok := expr.(*ast.Ident); ok {
							for resultIndex := 0; resultIndex < resultLength; resultIndex++ {
								if pkgInfo.ObjectOf(ident) == results.At(resultIndex) {
									namedResults[resultIndex] = assignStmt.Rhs[i]
								}
							}
						}
					}
				} else {
					if callExpr, ok := assignStmt.Rhs[0].(*ast.CallExpr); ok {
						allNamedResult := false
						for resultIndex := 0; resultIndex < resultLength; resultIndex++ {
							switch lhs := assignStmt.Lhs[0].(type) {
							case *ast.Ident:
								if pkgInfo.ObjectOf(lhs) == results.At(resultIndex) {
									allNamedResult = true
								}
							case *ast.SelectorExpr:
								if pkgInfo.ObjectOf(lhs.Sel) == results.At(resultIndex) {
									allNamedResult = true
								}
							}
						}
						if allNamedResult {
							identList := GetIdentChainCallOfCallFun(callExpr.Fun)
							skip = true
							ForEachFuncResult(program, pkgInfo.ObjectOf(identList[len(identList)-1]).(*types.Func), walker)
						}
					}
				}
			}
			return true
		})
	}
}

func hasReturn(node ast.Node) (ok bool) {
	ast.Inspect(node, func(n ast.Node) bool {
		switch n.(type) {
		case *ast.ReturnStmt:
			ok = true
		}
		return true
	})
	return
}

func patchTypeAndValue(tpe types.Type, typeAndValue types.TypeAndValue) types.TypeAndValue {
	if typeAndValue.IsValue() && typeAndValue.Value == nil {
		return types.TypeAndValue{
			Type: typeAndValue.Type,
		}
	}
	_, isInterface := tpe.(*types.Interface)
	if !isInterface && typeAndValue.Type == types.Typ[types.UntypedNil] {
		return types.TypeAndValue{
			Type: tpe,
		}
	}
	return typeAndValue
}

func MethodOf(named *types.Named, funcName string) (typeFunc *types.Func) {
	for i := 0; i < named.NumMethods(); i++ {
		method := named.Method(i)
		if method.Name() == funcName {
			return method
		}
	}

	if structType, ok := named.Underlying().(*types.Struct); ok {
		for i := 0; i < structType.NumFields(); i++ {
			field := structType.Field(i)
			if field.Anonymous() {
				typeFuncAnonymous := MethodOf(IndirectType(field.Type()).(*types.Named), funcName)
				if typeFunc == nil {
					typeFunc = typeFuncAnonymous
				} else if typeFuncAnonymous != nil {
					typeFunc = nil
				}
			}
		}
	}
	return
}

func IndirectType(tpe types.Type) types.Type {
	switch tpe.(type) {
	case *types.Pointer:
		return IndirectType(tpe.(*types.Pointer).Elem())
	default:
		return tpe
	}
}

repository: johnnyeven/libtools

repo_name: johnnyeven/libtools

extension: go


text:
DESCRIPTION = "QCOM Firmware for DragonBoard 410c"

LICENSE = "Proprietary"
LIC_FILES_CHKSUM = "file://LICENSE;md5=4d087ee0965cb059f1b2f9429e166f64"

SRC_URI = "http://builds.96boards.org/releases/dragonboard410c/qualcomm/firmware/linux-board-support-package-r${PV}.zip;qcom-eula=true"
SRC_URI[md5sum] = "e1c7e8957b8f37a91cadc18c1aef5c04"
SRC_URI[sha256sum] = "a76405fae85399343bc421b6101ba765d92b3709f2d4ae8afe85dc300cf72c7e"

DEPENDS += "mtools-native"

COMPATIBLE_MACHINE = "(dragonboard-410c)"
PACKAGE_ARCH = "${MACHINE_ARCH}"

S = "${WORKDIR}/linux-board-support-package-r${PV}"

python do_unpack() {
    eula = d.getVar('ACCEPT_EULA_'+d.getVar('MACHINE', True), True)
    eula_file = d.getVar('QCOM_EULA_FILE', True)
    pkg = d.getVar('PN', True)
    if eula == None:
        bb.fatal("To use '%s' you need to accept the EULA at '%s'. "
                 "Please read it and in case you accept it, write: "
                 "ACCEPT_EULA_dragonboard-410c = \"1\" in your local.conf." % (pkg, eula_file))
    elif eula == '0':
        bb.fatal("To use '%s' you need to accept the EULA." % pkg)
    else:
        bb.note("EULA has been accepted for '%s'" % pkg)

    try:
        bb.build.exec_func('base_do_unpack', d)
    except:
        raise
}

do_compile() {
	:
}

do_install() {
    install -d  ${D}/lib/firmware/
    cp -r ./proprietary-linux/* ${D}/lib/firmware/

    MTOOLS_SKIP_CHECK=1 mcopy -i ./bootloaders-linux/NON-HLOS.bin \
    ::image/modem.* ::image/mba.mbn ::image/wcnss.* ${D}/lib/firmware/

    # Venus firmware have been merged in linux-firmware in a different location than
    # what we've been using for now. Let's add symlinks for now, until we switch to linux-firmware
    install -d ${D}/lib/firmware/qcom/venus-1.8/
    for f in ${D}/lib/firmware/venus.*; do
        f=$(basename $f)
        ln -s /lib/firmware/$f ${D}/lib/firmware/qcom/venus-1.8/$f
    done

    install -d ${D}${sysconfdir}/
    install -m 0644 LICENSE ${D}${sysconfdir}/QCOM-LINUX-BOARD-SUPPORT-LICENSE
}

FILES_${PN} += "/lib/firmware/*"
INSANE_SKIP_${PN} += "arch"


text:
// Copyright 2018 The Periph Authors. All rights reserved.
// Use of this source code is governed under the Apache License, Version 2.0
// that can be found in the LICENSE file.

package sn3218_test

import (
	"log"
	"time"

	"periph.io/x/periph/conn/i2c/i2creg"
	"periph.io/x/periph/experimental/devices/sn3218"
	"periph.io/x/periph/host"
)

func Example() {
	if _, err := host.Init(); err != nil {
		log.Fatal(err)
	}

	b, err := i2creg.Open("")
	if err != nil {
		log.Fatal(err)
	}
	defer b.Close()

	d, err := sn3218.New(b)
	if err != nil {
		log.Fatal(err)
	}
	defer d.Halt()

	// By default, the device is disabled and brightness is 0 for all LEDs
	// So let's set the brightness to a low value and enable the device to
	// get started
	d.BrightnessAll(1)
	d.Sleep()

	// Switch LED 7 on
	if err := d.Switch(7, true); err != nil {
		log.Fatal("Error while switching LED", err)
	}

	time.Sleep(1000 * time.Millisecond)
}

repository: jdevelop/periph

repo_name: jdevelop/periph

gha_language: Go