Merge branch 'master' of github.com:c3d2/pentabug
This commit is contained in:
commit
d0dcf5c48d
|
@ -1,6 +1,6 @@
|
|||
PROJECT=pentabug
|
||||
|
||||
APPS = buggy mariotheme geiger ducklings blinker
|
||||
APPS = buggy jumpy mariotheme geiger ducklings wuerfel blinker
|
||||
|
||||
OPTIMIZATION = -Os
|
||||
MCU = atmega88pa
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
#include <pentabug/app.h>
|
||||
#include <pentabug/hal.h>
|
||||
#include <pentabug/matrix.h>
|
||||
|
||||
#ifdef MATRIX
|
||||
uint8_t inv = 0;
|
||||
|
|
61
firmware/apps/jumpy.c
Normal file
61
firmware/apps/jumpy.c
Normal file
|
@ -0,0 +1,61 @@
|
|||
#include <pentabug/app.h>
|
||||
#include <pentabug/hal.h>
|
||||
#include <pentabug/pentatonic.h>
|
||||
#include <pentabug/listen.h>
|
||||
#include <pentabug/helper.h>
|
||||
#include <pentabug/music.h>
|
||||
|
||||
#define SENSITIVITY_FACT 4
|
||||
|
||||
static uint16_t max_sound;
|
||||
static uint8_t first;
|
||||
|
||||
static void init(void) {
|
||||
pentatonic_direction(ALL_OUT);
|
||||
listen_init();
|
||||
|
||||
max_sound = 5;
|
||||
first = 0;
|
||||
}
|
||||
|
||||
static void run(void) {
|
||||
uint16_t sound = listen_measure();
|
||||
|
||||
pentatonic_all_led_set(max_sound >> 5);
|
||||
|
||||
if(!first && sound > max_sound / SENSITIVITY_FACT) {
|
||||
int8_t intensity = SENSITIVITY_FACT + 1 - max_sound / sound;
|
||||
|
||||
intensity = MIN(intensity, SENSITIVITY_FACT + 1);
|
||||
|
||||
motor_on();
|
||||
|
||||
set_note(NOTE_C, (rand() & 3) + 3);
|
||||
|
||||
for(size_t i = 0; i < intensity; ++i) {
|
||||
led_set(RIGHT, rand() & 1);
|
||||
led_set(LEFT, rand() & 1);
|
||||
|
||||
wait_ms(100);
|
||||
}
|
||||
|
||||
// turn everything off
|
||||
|
||||
stop_note();
|
||||
|
||||
motor_off();
|
||||
|
||||
led_off(RIGHT);
|
||||
led_off(LEFT);
|
||||
|
||||
wait_ms(100);
|
||||
} else {
|
||||
first = 0;
|
||||
}
|
||||
|
||||
if(sound > max_sound) {
|
||||
max_sound = sound;
|
||||
}
|
||||
}
|
||||
|
||||
REGISTER(run, init, NULL);
|
100
firmware/apps/wuerfel.c
Normal file
100
firmware/apps/wuerfel.c
Normal file
|
@ -0,0 +1,100 @@
|
|||
#include <stdlib.h>
|
||||
|
||||
#include <pentabug/music.h>
|
||||
#include <pentabug/app.h>
|
||||
#include <pentabug/hal.h>
|
||||
#include <pentabug/matrix.h>
|
||||
|
||||
static uint8_t randm = 0;
|
||||
|
||||
static void init(void) {
|
||||
matrix_start();
|
||||
}
|
||||
static void wuerfel(void) {
|
||||
|
||||
void w_eins(void){
|
||||
matrix_set(1,1,1);
|
||||
}
|
||||
void w_zwei(void){
|
||||
matrix_set(0,0,1);
|
||||
matrix_set(2,2,2);
|
||||
}
|
||||
void w_drei(void){
|
||||
matrix_set(0,0,1);
|
||||
matrix_set(2,2,1);
|
||||
matrix_set(1,1,1);
|
||||
}
|
||||
void w_vier(void){
|
||||
matrix_set(0,0,1);
|
||||
matrix_set(0,2,1);
|
||||
matrix_set(2,2,1);
|
||||
matrix_set(2,0,1);
|
||||
}
|
||||
void w_funf(void){
|
||||
matrix_set(1,1,1);
|
||||
matrix_set(0,0,1);
|
||||
matrix_set(0,2,1);
|
||||
matrix_set(2,2,1);
|
||||
matrix_set(2,0,1);
|
||||
}
|
||||
void w_sechs(void){
|
||||
matrix_set(1,0,1);
|
||||
matrix_set(0,0,1);
|
||||
matrix_set(0,2,1);
|
||||
matrix_set(2,2,1);
|
||||
matrix_set(2,0,1);
|
||||
matrix_set(1,2,1);
|
||||
}
|
||||
void clear(void){
|
||||
for(uint8_t x = 0; x < 3; ++x){
|
||||
for(uint8_t y = 0; y < 3; ++y){
|
||||
matrix_set(x,y,0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(button_clicked(RIGHT)) {
|
||||
for(uint8_t c = 110; c < 140; c = 10 + c){
|
||||
clear();
|
||||
w_eins();
|
||||
wait_ms(c);
|
||||
clear();
|
||||
w_zwei();
|
||||
wait_ms(c);
|
||||
clear();
|
||||
w_drei();
|
||||
wait_ms(c);
|
||||
clear();
|
||||
w_vier();
|
||||
wait_ms(c);
|
||||
clear();
|
||||
w_funf();
|
||||
wait_ms(c);
|
||||
clear();
|
||||
w_sechs();
|
||||
wait_ms(c);
|
||||
}
|
||||
randm = rand()%6;
|
||||
clear();
|
||||
}
|
||||
if(randm==0){
|
||||
w_eins();
|
||||
}
|
||||
else if(randm==1){
|
||||
w_zwei();
|
||||
}
|
||||
else if(randm==2){
|
||||
w_drei();
|
||||
}
|
||||
else if(randm==3){
|
||||
w_vier();
|
||||
}
|
||||
else if(randm==4){
|
||||
w_funf();
|
||||
}
|
||||
else if(randm==5){
|
||||
w_sechs();
|
||||
}
|
||||
}
|
||||
|
||||
REGISTER(wuerfel, init, NULL);
|
12
firmware/include/pentabug/listen.h
Normal file
12
firmware/include/pentabug/listen.h
Normal file
|
@ -0,0 +1,12 @@
|
|||
#ifndef LISTEN_H
|
||||
#define LISTEN_H
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
void listen_init(void);
|
||||
|
||||
void listen_stop(void);
|
||||
|
||||
uint16_t listen_measure(void);
|
||||
|
||||
#endif /* LISTEN_H */
|
66
firmware/lib/listen.c
Normal file
66
firmware/lib/listen.c
Normal file
|
@ -0,0 +1,66 @@
|
|||
#include <pentabug/listen.h>
|
||||
|
||||
#include <avr/io.h>
|
||||
|
||||
#include <pentabug/hal.h>
|
||||
#include <pentabug/lifecycle.h>
|
||||
|
||||
void listen_init(void) {
|
||||
ADCSRA |= (1 << ADEN);
|
||||
}
|
||||
|
||||
void listen_stop(void) {
|
||||
ADCSRA &= ~(1 << ADEN);
|
||||
}
|
||||
|
||||
uint16_t listen_measure(void) {
|
||||
// save previous state
|
||||
|
||||
uint8_t prev_state = PINC & (1 << 0);
|
||||
|
||||
// set to ground for discharge
|
||||
|
||||
DDRC |= 1 << 0;
|
||||
PORTC &= ~(1 << 0);
|
||||
|
||||
// wait for discharge
|
||||
|
||||
wait_ms(1);
|
||||
|
||||
// set direction to input for measurement
|
||||
|
||||
DDRC &= ~(1 << 0);
|
||||
|
||||
// collect some sound waves
|
||||
|
||||
wait_ms(1);
|
||||
|
||||
// start measurement
|
||||
|
||||
// TODO: why can't i move this to the initialization?
|
||||
ADMUX = (1 << REFS0) | (1 << ADLAR);
|
||||
ADCSRA |= (1 << ADPS2) | (1 << ADPS1);
|
||||
|
||||
ADMUX = (ADMUX & ~(0x1F)) | 0;
|
||||
|
||||
ADCSRA |= (1 << ADSC);
|
||||
|
||||
// wait for measurement to finish
|
||||
|
||||
while (ADCSRA & (1 << ADSC)) test_stop_app();
|
||||
|
||||
uint16_t res = ADCL;
|
||||
res |= ADCH << 8;
|
||||
|
||||
// restore state
|
||||
|
||||
if(prev_state) {
|
||||
PORTC |= 1 << 0;
|
||||
}
|
||||
|
||||
DDRC |= 1 << 0;
|
||||
|
||||
// done
|
||||
|
||||
return res;
|
||||
}
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!DOCTYPE eagle SYSTEM "eagle.dtd">
|
||||
<eagle version="6.4">
|
||||
<eagle version="6.5.0">
|
||||
<drawing>
|
||||
<settings>
|
||||
<setting alwaysvectorfont="no"/>
|
||||
|
@ -28,13 +28,13 @@
|
|||
<layer number="18" name="Vias" color="2" fill="1" visible="yes" active="yes"/>
|
||||
<layer number="19" name="Unrouted" color="6" fill="1" visible="yes" active="yes"/>
|
||||
<layer number="20" name="Dimension" color="15" fill="1" visible="no" active="yes"/>
|
||||
<layer number="21" name="tPlace" color="7" fill="1" visible="no" active="yes"/>
|
||||
<layer number="21" name="tPlace" color="7" fill="1" visible="yes" active="yes"/>
|
||||
<layer number="22" name="bPlace" color="7" fill="1" visible="no" active="yes"/>
|
||||
<layer number="23" name="tOrigins" color="15" fill="1" visible="no" active="yes"/>
|
||||
<layer number="23" name="tOrigins" color="15" fill="1" visible="yes" active="yes"/>
|
||||
<layer number="24" name="bOrigins" color="15" fill="1" visible="no" active="yes"/>
|
||||
<layer number="25" name="tNames" color="7" fill="1" visible="no" active="yes"/>
|
||||
<layer number="25" name="tNames" color="7" fill="1" visible="yes" active="yes"/>
|
||||
<layer number="26" name="bNames" color="7" fill="1" visible="no" active="yes"/>
|
||||
<layer number="27" name="tValues" color="7" fill="1" visible="no" active="yes"/>
|
||||
<layer number="27" name="tValues" color="7" fill="1" visible="yes" active="yes"/>
|
||||
<layer number="28" name="bValues" color="7" fill="1" visible="no" active="yes"/>
|
||||
<layer number="29" name="tStop" color="7" fill="3" visible="no" active="yes"/>
|
||||
<layer number="30" name="bStop" color="7" fill="6" visible="no" active="yes"/>
|
||||
|
@ -219,6 +219,8 @@
|
|||
<dimension x1="25.0625" y1="-72.39" x2="24.765" y2="-46.99" x3="41.275" y3="-59.69" textsize="3.5" layer="47" dtype="vertical"/>
|
||||
<text x="154.94" y="1.5875" size="1.27" layer="25" font="vector" ratio="10" rot="R45">for pentabug 2.0</text>
|
||||
<text x="140.0175" y="19.05" size="1.6764" layer="25" font="vector" ratio="10" rot="R45">ledmatrix</text>
|
||||
<wire x1="1.27" y1="9.8425" x2="5.3975" y2="11.43" width="0.6096" layer="21"/>
|
||||
<wire x1="2.2225" y1="25.7175" x2="6.35" y2="24.13" width="0.6096" layer="21"/>
|
||||
</plain>
|
||||
<libraries>
|
||||
<library name="atmel">
|
||||
|
@ -1120,7 +1122,7 @@ design rules under a new name.</description>
|
|||
</element>
|
||||
<element name="IR" library="buglbr" package="TSOP382" value="TSOP382" x="19.05" y="16.51" smashed="yes" rot="R270"/>
|
||||
<element name="LED3" library="SparkFun" package="LED3MM" value="" x="3.81" y="9.2075" smashed="yes" rot="R110">
|
||||
<attribute name="NAME" x="2.7852" y="11.372928125" size="1.27" layer="25" font="vector" ratio="10"/>
|
||||
<attribute name="NAME" x="2.4677" y="11.690428125" size="1.27" layer="25" font="vector" ratio="10"/>
|
||||
<attribute name="VALUE" x="4.709878125" y="11.562284375" size="1.27" layer="27" ratio="10" rot="R110"/>
|
||||
</element>
|
||||
<element name="R5" library="rcl" package="0207/10" value="33R" x="10.16" y="26.47" smashed="yes" rot="R65">
|
||||
|
@ -1666,7 +1668,7 @@ design rules under a new name.</description>
|
|||
<wire x1="55.88" y1="22.86" x2="57.15" y2="21.59" width="0.4064" layer="1"/>
|
||||
<wire x1="57.15" y1="21.59" x2="57.15" y2="20.32" width="0.4064" layer="1"/>
|
||||
</signal>
|
||||
<signal name="SCL">
|
||||
<signal name="PC5/SCL">
|
||||
<contactref element="JP4" pad="2"/>
|
||||
<contactref element="IC1" pad="28"/>
|
||||
<wire x1="53.34" y1="30.45" x2="53.34" y2="29.21" width="0.4064" layer="1"/>
|
||||
|
@ -1679,7 +1681,7 @@ design rules under a new name.</description>
|
|||
<wire x1="27.94" y1="25.4" x2="27.94" y2="29.21" width="0.4064" layer="1"/>
|
||||
<wire x1="27.94" y1="29.21" x2="28.575" y2="29.845" width="0.4064" layer="1"/>
|
||||
</signal>
|
||||
<signal name="SDA">
|
||||
<signal name="PC4/SDA">
|
||||
<contactref element="JP4" pad="3"/>
|
||||
<contactref element="IC1" pad="27"/>
|
||||
<wire x1="55.88" y1="30.45" x2="55.88" y2="29.21" width="0.4064" layer="1"/>
|
||||
|
@ -1843,7 +1845,7 @@ design rules under a new name.</description>
|
|||
<vertex x="92.71" y="0"/>
|
||||
</polygon>
|
||||
</signal>
|
||||
<signal name="PD5_T">
|
||||
<signal name="PC5_T">
|
||||
<contactref element="SV5" pad="2"/>
|
||||
<contactref element="LED8" pad="K"/>
|
||||
<contactref element="S6" pad="2"/>
|
||||
|
@ -1856,7 +1858,7 @@ design rules under a new name.</description>
|
|||
<wire x1="111.76" y1="25.4" x2="116.84" y2="25.4" width="0.6096" layer="1"/>
|
||||
<wire x1="116.84" y1="25.4" x2="118.745" y2="23.495" width="0.6096" layer="1"/>
|
||||
</signal>
|
||||
<signal name="PD6_T">
|
||||
<signal name="PC4_T">
|
||||
<contactref element="SV5" pad="3"/>
|
||||
<contactref element="LED9" pad="K"/>
|
||||
<contactref element="S7" pad="2"/>
|
||||
|
@ -1871,7 +1873,7 @@ design rules under a new name.</description>
|
|||
<wire x1="111.76" y1="27.94" x2="110.49" y2="29.21" width="0.6096" layer="1"/>
|
||||
<wire x1="110.49" y1="29.21" x2="110.49" y2="30.45" width="0.6096" layer="1"/>
|
||||
</signal>
|
||||
<signal name="PC5_T">
|
||||
<signal name="PD5_T">
|
||||
<contactref element="SV4" pad="2"/>
|
||||
<contactref element="LED5" pad="K"/>
|
||||
<contactref element="S3" pad="2"/>
|
||||
|
@ -1885,7 +1887,7 @@ design rules under a new name.</description>
|
|||
<wire x1="101.6" y1="6.35" x2="98.7806" y2="9.1694" width="0.6096" layer="1"/>
|
||||
<wire x1="98.7806" y1="9.1694" x2="98.7806" y2="10.7188" width="0.6096" layer="1"/>
|
||||
</signal>
|
||||
<signal name="PC4_T">
|
||||
<signal name="PD6_T">
|
||||
<contactref element="SV4" pad="3"/>
|
||||
<contactref element="LED6" pad="K"/>
|
||||
<contactref element="S4" pad="2"/>
|
||||
|
@ -1899,7 +1901,7 @@ design rules under a new name.</description>
|
|||
<wire x1="107.95" y1="7.62" x2="110.49" y2="5.08" width="0.6096" layer="1"/>
|
||||
<wire x1="110.49" y1="5.08" x2="110.49" y2="2.54" width="0.6096" layer="1"/>
|
||||
</signal>
|
||||
<signal name="PB2_T">
|
||||
<signal name="PD7_T">
|
||||
<contactref element="SV4" pad="4"/>
|
||||
<contactref element="LED7" pad="K"/>
|
||||
<contactref element="S5" pad="2"/>
|
||||
|
@ -1931,7 +1933,7 @@ design rules under a new name.</description>
|
|||
<vertex x="137.16" y="0"/>
|
||||
</polygon>
|
||||
</signal>
|
||||
<signal name="PC5_L">
|
||||
<signal name="PD5_L">
|
||||
<contactref element="SV__4" pad="2"/>
|
||||
<contactref element="LED10" pad="K"/>
|
||||
<contactref element="LED13" pad="K"/>
|
||||
|
@ -1942,7 +1944,7 @@ design rules under a new name.</description>
|
|||
<wire x1="149.519934375" y1="20.64136875" x2="144.5808" y2="15.70223125" width="0.6096" layer="1"/>
|
||||
<wire x1="144.5808" y1="15.70223125" x2="143.8142875" y2="14.935715625" width="0.6096" layer="1"/>
|
||||
</signal>
|
||||
<signal name="PC4_L">
|
||||
<signal name="PD6_L">
|
||||
<contactref element="SV__4" pad="3"/>
|
||||
<contactref element="LED11" pad="K"/>
|
||||
<contactref element="LED14" pad="K"/>
|
||||
|
@ -1953,7 +1955,7 @@ design rules under a new name.</description>
|
|||
<wire x1="146.0180875" y1="10.7630875" x2="144.78" y2="9.525" width="0.6096" layer="1"/>
|
||||
<wire x1="144.78" y1="9.525" x2="144.78" y2="2.54" width="0.6096" layer="1"/>
|
||||
</signal>
|
||||
<signal name="PB2_L">
|
||||
<signal name="PD7_L">
|
||||
<contactref element="SV__4" pad="4"/>
|
||||
<contactref element="LED12" pad="K"/>
|
||||
<contactref element="LED15" pad="K"/>
|
||||
|
@ -1964,7 +1966,7 @@ design rules under a new name.</description>
|
|||
<wire x1="148.063953125" y1="5.823953125" x2="147.32" y2="5.08" width="0.6096" layer="1"/>
|
||||
<wire x1="147.32" y1="5.08" x2="147.32" y2="2.54" width="0.6096" layer="1"/>
|
||||
</signal>
|
||||
<signal name="PD5_L">
|
||||
<signal name="PC5_L">
|
||||
<contactref element="SV__5" pad="2"/>
|
||||
<contactref element="LED18" pad="A"/>
|
||||
<contactref element="LED16" pad="A"/>
|
||||
|
@ -1977,7 +1979,7 @@ design rules under a new name.</description>
|
|||
<wire x1="147.72388125" y1="12.559140625" x2="147.72388125" y2="14.83611875" width="0.6096" layer="16"/>
|
||||
<wire x1="152.663025" y1="9.896975" x2="152.663025" y2="7.62000625" width="0.6096" layer="16"/>
|
||||
</signal>
|
||||
<signal name="PD6_L">
|
||||
<signal name="PC4_L">
|
||||
<contactref element="SV__5" pad="3"/>
|
||||
<contactref element="LED15" pad="A"/>
|
||||
<contactref element="LED13" pad="A"/>
|
||||
|
@ -1992,7 +1994,7 @@ design rules under a new name.</description>
|
|||
<wire x1="152.663028125" y1="18.043028125" x2="153.67" y2="19.05" width="0.6096" layer="16"/>
|
||||
<wire x1="157.602165625" y1="15.117834375" x2="157.602165625" y2="12.55914375" width="0.6096" layer="16"/>
|
||||
</signal>
|
||||
<signal name="PD7_L">
|
||||
<signal name="PB2_L">
|
||||
<contactref element="SV__5" pad="4"/>
|
||||
<contactref element="LED12" pad="A"/>
|
||||
<contactref element="LED10" pad="A"/>
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!DOCTYPE eagle SYSTEM "eagle.dtd">
|
||||
<eagle version="6.4">
|
||||
<eagle version="6.5.0">
|
||||
<drawing>
|
||||
<settings>
|
||||
<setting alwaysvectorfont="no"/>
|
||||
|
@ -7995,7 +7995,7 @@ Source: www.kingbright.com</description>
|
|||
<instance part="Q1" gate="G$1" x="127" y="71.12"/>
|
||||
<instance part="R3" gate="G$1" x="-25.4" y="25.4" rot="R180"/>
|
||||
<instance part="LED1" gate="G$1" x="53.34" y="-7.62" smashed="yes" rot="R270">
|
||||
<attribute name="NAME" x="41.656" y="-8.636" size="1.778" layer="95"/>
|
||||
<attribute name="NAME" x="35.56" y="-7.366" size="1.778" layer="95"/>
|
||||
<attribute name="VALUE" x="48.768" y="-13.335" size="1.778" layer="96"/>
|
||||
</instance>
|
||||
<instance part="LED2" gate="G$1" x="43.18" y="17.78" smashed="yes" rot="R90">
|
||||
|
@ -8019,12 +8019,16 @@ Source: www.kingbright.com</description>
|
|||
<instance part="R1" gate="G$1" x="172.72" y="15.24" rot="R270"/>
|
||||
<instance part="R2" gate="G$1" x="172.72" y="5.08" rot="R270"/>
|
||||
<instance part="GND13" gate="1" x="172.72" y="-2.54" smashed="yes"/>
|
||||
<instance part="JP5" gate="A" x="91.44" y="91.44"/>
|
||||
<instance part="JP4" gate="A" x="91.44" y="68.58"/>
|
||||
<instance part="GND14" gate="1" x="78.74" y="60.96" smashed="yes"/>
|
||||
<instance part="GND15" gate="1" x="78.74" y="83.82" smashed="yes"/>
|
||||
<instance part="P+4" gate="VCC" x="78.74" y="76.2"/>
|
||||
<instance part="P+6" gate="VCC" x="78.74" y="99.06"/>
|
||||
<instance part="JP5" gate="A" x="91.44" y="60.96"/>
|
||||
<instance part="JP4" gate="A" x="91.44" y="86.36"/>
|
||||
<instance part="GND14" gate="1" x="78.74" y="78.74" smashed="yes"/>
|
||||
<instance part="GND15" gate="1" x="78.74" y="53.34" smashed="yes"/>
|
||||
<instance part="P+4" gate="VCC" x="78.74" y="93.98" smashed="yes">
|
||||
<attribute name="VALUE" x="76.2" y="93.98" size="1.778" layer="96" rot="R90"/>
|
||||
</instance>
|
||||
<instance part="P+6" gate="VCC" x="78.74" y="68.58" smashed="yes">
|
||||
<attribute name="VALUE" x="76.2" y="66.04" size="1.778" layer="96" rot="R90"/>
|
||||
</instance>
|
||||
<instance part="JP1" gate="A" x="195.58" y="30.48"/>
|
||||
<instance part="Q2" gate="G$1" x="-2.54" y="71.12"/>
|
||||
<instance part="R4" gate="G$1" x="-17.78" y="91.44" rot="R180"/>
|
||||
|
@ -8049,8 +8053,8 @@ Source: www.kingbright.com</description>
|
|||
</segment>
|
||||
<segment>
|
||||
<pinref part="JP5" gate="A" pin="2"/>
|
||||
<wire x1="88.9" y1="93.98" x2="78.74" y2="93.98" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="93.98" size="1.778" layer="95"/>
|
||||
<wire x1="88.9" y1="63.5" x2="78.74" y2="63.5" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="63.5" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="VCC" class="0">
|
||||
|
@ -8082,12 +8086,12 @@ Source: www.kingbright.com</description>
|
|||
<segment>
|
||||
<pinref part="JP4" gate="A" pin="1"/>
|
||||
<pinref part="P+4" gate="VCC" pin="VCC"/>
|
||||
<wire x1="78.74" y1="73.66" x2="88.9" y2="73.66" width="0.1524" layer="91"/>
|
||||
<wire x1="78.74" y1="91.44" x2="88.9" y2="91.44" width="0.1524" layer="91"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="JP5" gate="A" pin="1"/>
|
||||
<pinref part="P+6" gate="VCC" pin="VCC"/>
|
||||
<wire x1="78.74" y1="96.52" x2="88.9" y2="96.52" width="0.1524" layer="91"/>
|
||||
<wire x1="78.74" y1="66.04" x2="88.9" y2="66.04" width="0.1524" layer="91"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="JP1" gate="A" pin="2"/>
|
||||
|
@ -8187,7 +8191,7 @@ Source: www.kingbright.com</description>
|
|||
<segment>
|
||||
<pinref part="JP5" gate="A" pin="5"/>
|
||||
<pinref part="GND15" gate="1" pin="GND"/>
|
||||
<wire x1="78.74" y1="86.36" x2="88.9" y2="86.36" width="0.1524" layer="91"/>
|
||||
<wire x1="78.74" y1="55.88" x2="88.9" y2="55.88" width="0.1524" layer="91"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="IR" gate="G$1" pin="GND"/>
|
||||
|
@ -8202,7 +8206,7 @@ Source: www.kingbright.com</description>
|
|||
<segment>
|
||||
<pinref part="JP4" gate="A" pin="5"/>
|
||||
<pinref part="GND14" gate="1" pin="GND"/>
|
||||
<wire x1="78.74" y1="63.5" x2="88.9" y2="63.5" width="0.1524" layer="91"/>
|
||||
<wire x1="78.74" y1="81.28" x2="88.9" y2="81.28" width="0.1524" layer="91"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="N$17" class="0">
|
||||
|
@ -8274,8 +8278,8 @@ Source: www.kingbright.com</description>
|
|||
</segment>
|
||||
<segment>
|
||||
<pinref part="JP5" gate="A" pin="3"/>
|
||||
<wire x1="88.9" y1="91.44" x2="78.74" y2="91.44" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="91.44" size="1.778" layer="95"/>
|
||||
<wire x1="88.9" y1="60.96" x2="78.74" y2="60.96" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="60.96" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="MISO" class="0">
|
||||
|
@ -8404,11 +8408,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="35.56" y="-22.86" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="SCL" class="0">
|
||||
<net name="PC5/SCL" class="0">
|
||||
<segment>
|
||||
<pinref part="JP4" gate="A" pin="2"/>
|
||||
<wire x1="88.9" y1="71.12" x2="78.74" y2="71.12" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="71.12" size="1.778" layer="95"/>
|
||||
<wire x1="88.9" y1="88.9" x2="78.74" y2="88.9" width="0.1524" layer="91"/>
|
||||
<label x="73.66" y="88.9" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="IC1" gate="G$1" pin="PC5(ADC5/SCL)"/>
|
||||
|
@ -8416,11 +8420,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="35.56" y="12.7" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="SDA" class="0">
|
||||
<net name="PC4/SDA" class="0">
|
||||
<segment>
|
||||
<pinref part="JP4" gate="A" pin="3"/>
|
||||
<wire x1="88.9" y1="68.58" x2="78.74" y2="68.58" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="68.58" size="1.778" layer="95"/>
|
||||
<wire x1="88.9" y1="86.36" x2="78.74" y2="86.36" width="0.1524" layer="91"/>
|
||||
<label x="73.66" y="86.36" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="IC1" gate="G$1" pin="PC4(ADC4/SDA)"/>
|
||||
|
@ -8451,8 +8455,8 @@ Source: www.kingbright.com</description>
|
|||
</segment>
|
||||
<segment>
|
||||
<pinref part="JP4" gate="A" pin="4"/>
|
||||
<wire x1="88.9" y1="66.04" x2="78.74" y2="66.04" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="66.04" size="1.778" layer="95"/>
|
||||
<wire x1="88.9" y1="83.82" x2="78.74" y2="83.82" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="83.82" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PD7" class="0">
|
||||
|
@ -8463,8 +8467,8 @@ Source: www.kingbright.com</description>
|
|||
</segment>
|
||||
<segment>
|
||||
<pinref part="JP5" gate="A" pin="4"/>
|
||||
<wire x1="88.9" y1="88.9" x2="78.74" y2="88.9" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="88.9" size="1.778" layer="95"/>
|
||||
<wire x1="88.9" y1="58.42" x2="78.74" y2="58.42" width="0.1524" layer="91"/>
|
||||
<label x="78.74" y="58.42" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="N$7" class="0">
|
||||
|
@ -8527,11 +8531,11 @@ Source: www.kingbright.com</description>
|
|||
<plain>
|
||||
</plain>
|
||||
<instances>
|
||||
<instance part="SV4" gate="G$1" x="35.56" y="63.5" rot="MR180"/>
|
||||
<instance part="SV5" gate="G$1" x="35.56" y="27.94" rot="MR180"/>
|
||||
<instance part="P+11" gate="VCC" x="43.18" y="35.56"/>
|
||||
<instance part="GND17" gate="1" x="50.8" y="55.88"/>
|
||||
<instance part="GND18" gate="1" x="48.26" y="20.32"/>
|
||||
<instance part="SV4" gate="G$1" x="35.56" y="33.02" rot="MR180"/>
|
||||
<instance part="SV5" gate="G$1" x="35.56" y="63.5" rot="MR180"/>
|
||||
<instance part="P+11" gate="VCC" x="48.26" y="71.12"/>
|
||||
<instance part="GND17" gate="1" x="50.8" y="25.4"/>
|
||||
<instance part="GND18" gate="1" x="48.26" y="55.88"/>
|
||||
<instance part="LED5" gate="G$1" x="81.28" y="58.42"/>
|
||||
<instance part="S3" gate="1" x="78.74" y="43.18"/>
|
||||
<instance part="P+12" gate="VCC" x="81.28" y="68.58"/>
|
||||
|
@ -8560,6 +8564,7 @@ Source: www.kingbright.com</description>
|
|||
<segment>
|
||||
<pinref part="SV5" gate="G$1" pin="1"/>
|
||||
<pinref part="P+11" gate="VCC" pin="VCC"/>
|
||||
<wire x1="48.26" y1="68.58" x2="43.18" y2="68.58" width="0.1524" layer="91"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED5" gate="G$1" pin="A"/>
|
||||
|
@ -8591,12 +8596,12 @@ Source: www.kingbright.com</description>
|
|||
<segment>
|
||||
<pinref part="SV4" gate="G$1" pin="5"/>
|
||||
<pinref part="GND17" gate="1" pin="GND"/>
|
||||
<wire x1="50.8" y1="58.42" x2="43.18" y2="58.42" width="0.1524" layer="91"/>
|
||||
<wire x1="50.8" y1="27.94" x2="43.18" y2="27.94" width="0.1524" layer="91"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="SV5" gate="G$1" pin="5"/>
|
||||
<pinref part="GND18" gate="1" pin="GND"/>
|
||||
<wire x1="48.26" y1="22.86" x2="43.18" y2="22.86" width="0.1524" layer="91"/>
|
||||
<wire x1="48.26" y1="58.42" x2="43.18" y2="58.42" width="0.1524" layer="91"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="S3" gate="1" pin="P1"/>
|
||||
|
@ -8634,11 +8639,11 @@ Source: www.kingbright.com</description>
|
|||
<junction x="152.4" y="38.1"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PC5_T" class="0">
|
||||
<net name="PD5_T" class="0">
|
||||
<segment>
|
||||
<pinref part="SV4" gate="G$1" pin="2"/>
|
||||
<wire x1="43.18" y1="66.04" x2="53.34" y2="66.04" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="66.04" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="35.56" x2="53.34" y2="35.56" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="35.56" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED5" gate="G$1" pin="C"/>
|
||||
|
@ -8653,11 +8658,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="71.12" y="50.8" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PC4_T" class="0">
|
||||
<net name="PD6_T" class="0">
|
||||
<segment>
|
||||
<pinref part="SV4" gate="G$1" pin="3"/>
|
||||
<wire x1="43.18" y1="63.5" x2="53.34" y2="63.5" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="63.5" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="33.02" x2="53.34" y2="33.02" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="33.02" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED6" gate="G$1" pin="C"/>
|
||||
|
@ -8672,11 +8677,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="88.9" y="50.8" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PD5_T" class="0">
|
||||
<net name="PC5_T" class="0">
|
||||
<segment>
|
||||
<pinref part="SV5" gate="G$1" pin="2"/>
|
||||
<wire x1="43.18" y1="30.48" x2="53.34" y2="30.48" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="30.48" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="66.04" x2="53.34" y2="66.04" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="66.04" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED8" gate="G$1" pin="C"/>
|
||||
|
@ -8691,11 +8696,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="124.46" y="50.8" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PD6_T" class="0">
|
||||
<net name="PC4_T" class="0">
|
||||
<segment>
|
||||
<pinref part="SV5" gate="G$1" pin="3"/>
|
||||
<wire x1="43.18" y1="27.94" x2="53.34" y2="27.94" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="27.94" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="63.5" x2="53.34" y2="63.5" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="63.5" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED9" gate="G$1" pin="C"/>
|
||||
|
@ -8710,11 +8715,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="142.24" y="50.8" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PB2_T" class="0">
|
||||
<net name="PD7_T" class="0">
|
||||
<segment>
|
||||
<pinref part="SV4" gate="G$1" pin="4"/>
|
||||
<wire x1="43.18" y1="60.96" x2="53.34" y2="60.96" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="60.96" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="30.48" x2="53.34" y2="30.48" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="30.48" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED7" gate="G$1" pin="C"/>
|
||||
|
@ -8735,12 +8740,12 @@ Source: www.kingbright.com</description>
|
|||
<plain>
|
||||
</plain>
|
||||
<instances>
|
||||
<instance part="SV__4" gate="G$1" x="35.56" y="63.5" rot="MR180"/>
|
||||
<instance part="SV__5" gate="G$1" x="35.56" y="27.94" rot="MR180"/>
|
||||
<instance part="P+10" gate="VCC" x="43.18" y="71.12"/>
|
||||
<instance part="P+17" gate="VCC" x="43.18" y="35.56"/>
|
||||
<instance part="GND24" gate="1" x="43.18" y="55.88"/>
|
||||
<instance part="GND25" gate="1" x="43.18" y="20.32"/>
|
||||
<instance part="SV__4" gate="G$1" x="35.56" y="33.02" rot="MR180"/>
|
||||
<instance part="SV__5" gate="G$1" x="35.56" y="60.96" rot="MR180"/>
|
||||
<instance part="P+10" gate="VCC" x="43.18" y="40.64"/>
|
||||
<instance part="P+17" gate="VCC" x="43.18" y="68.58"/>
|
||||
<instance part="GND24" gate="1" x="43.18" y="25.4"/>
|
||||
<instance part="GND25" gate="1" x="43.18" y="53.34"/>
|
||||
<instance part="LED10" gate="G$1" x="81.28" y="50.8"/>
|
||||
<instance part="LED11" gate="G$1" x="91.44" y="50.8"/>
|
||||
<instance part="LED12" gate="G$1" x="101.6" y="50.8"/>
|
||||
|
@ -8774,11 +8779,11 @@ Source: www.kingbright.com</description>
|
|||
<pinref part="GND25" gate="1" pin="GND"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PC5_L" class="0">
|
||||
<net name="PD5_L" class="0">
|
||||
<segment>
|
||||
<pinref part="SV__4" gate="G$1" pin="2"/>
|
||||
<wire x1="43.18" y1="66.04" x2="53.34" y2="66.04" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="66.04" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="35.56" x2="53.34" y2="35.56" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="35.56" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED10" gate="G$1" pin="C"/>
|
||||
|
@ -8795,11 +8800,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="83.82" y="17.78" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PC4_L" class="0">
|
||||
<net name="PD6_L" class="0">
|
||||
<segment>
|
||||
<pinref part="SV__4" gate="G$1" pin="3"/>
|
||||
<wire x1="43.18" y1="63.5" x2="53.34" y2="63.5" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="63.5" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="33.02" x2="53.34" y2="33.02" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="33.02" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED11" gate="G$1" pin="C"/>
|
||||
|
@ -8816,11 +8821,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="93.98" y="17.78" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PB2_L" class="0">
|
||||
<net name="PD7_L" class="0">
|
||||
<segment>
|
||||
<pinref part="SV__4" gate="G$1" pin="4"/>
|
||||
<wire x1="43.18" y1="60.96" x2="53.34" y2="60.96" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="60.96" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="30.48" x2="53.34" y2="30.48" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="30.48" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED12" gate="G$1" pin="C"/>
|
||||
|
@ -8837,11 +8842,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="104.14" y="17.78" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PD5_L" class="0">
|
||||
<net name="PC5_L" class="0">
|
||||
<segment>
|
||||
<pinref part="SV__5" gate="G$1" pin="2"/>
|
||||
<wire x1="43.18" y1="30.48" x2="53.34" y2="30.48" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="30.48" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="63.5" x2="53.34" y2="63.5" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="63.5" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED18" gate="G$1" pin="A"/>
|
||||
|
@ -8855,11 +8860,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="73.66" y="33.02" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PD6_L" class="0">
|
||||
<net name="PC4_L" class="0">
|
||||
<segment>
|
||||
<pinref part="SV__5" gate="G$1" pin="3"/>
|
||||
<wire x1="43.18" y1="27.94" x2="53.34" y2="27.94" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="27.94" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="60.96" x2="53.34" y2="60.96" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="60.96" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED15" gate="G$1" pin="A"/>
|
||||
|
@ -8873,11 +8878,11 @@ Source: www.kingbright.com</description>
|
|||
<label x="73.66" y="43.18" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
</net>
|
||||
<net name="PD7_L" class="0">
|
||||
<net name="PB2_L" class="0">
|
||||
<segment>
|
||||
<pinref part="SV__5" gate="G$1" pin="4"/>
|
||||
<wire x1="43.18" y1="25.4" x2="53.34" y2="25.4" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="25.4" size="1.778" layer="95"/>
|
||||
<wire x1="43.18" y1="58.42" x2="53.34" y2="58.42" width="0.1524" layer="91"/>
|
||||
<label x="48.26" y="58.42" size="1.778" layer="95"/>
|
||||
</segment>
|
||||
<segment>
|
||||
<pinref part="LED12" gate="G$1" pin="A"/>
|
||||
|
|
Loading…
Reference in New Issue
Block a user