euro-yesman-1u: work in progress board updates

wip/yesman
Katharina Fey 3 years ago
parent 8c2ba6c1be
commit 4fe31aca6b
Signed by: kookie
GPG Key ID: 90734A9E619C8A6C
  1. 856
      hardware/devices/euro-yesman-1u/board/button_leds.sch
  2. 664
      hardware/devices/euro-yesman-1u/board/button_leds.sch-bak
  3. 80
      hardware/devices/euro-yesman-1u/board/yesman-board-cache.lib
  4. 1303
      hardware/devices/euro-yesman-1u/board/yesman-board.sch
  5. 1303
      hardware/devices/euro-yesman-1u/board/yesman-board.sch-bak
  6. 121
      hardware/devices/euro-yesman-1u/src/io.rs
  7. 205
      hardware/devices/euro-yesman-1u/src/main.rs

@ -0,0 +1,856 @@
EESchema Schematic File Version 4
EELAYER 30 0
EELAYER END
$Descr A4 11693 8268
encoding utf-8
Sheet 2 2
Title "Button and LED I/O section"
Date "2021-05-06"
Rev "A1"
Comp "breadmachine"
Comment1 ""
Comment2 ""
Comment3 ""
Comment4 ""
$EndDescr
Connection ~ 10250 2600
Wire Wire Line
10250 2600 10250 1650
Connection ~ 8800 2600
Wire Wire Line
8800 2600 8800 1650
Connection ~ 7350 2600
Wire Wire Line
7350 2600 7350 1650
Connection ~ 5700 2600
Wire Wire Line
5700 1650 5700 2600
Connection ~ 4200 2600
Wire Wire Line
4200 2600 4200 1650
Connection ~ 10250 4000
Wire Wire Line
10250 2600 10150 2600
Wire Wire Line
10250 4000 10250 2600
Wire Wire Line
10250 4000 10150 4000
Wire Wire Line
10250 5450 10250 4000
Wire Wire Line
10150 5450 10250 5450
Connection ~ 8800 4000
Wire Wire Line
8800 2600 8700 2600
Wire Wire Line
8800 4000 8800 2600
Wire Wire Line
8800 4000 8700 4000
Wire Wire Line
8800 5450 8800 4000
Wire Wire Line
8700 5450 8800 5450
Connection ~ 7350 4000
Wire Wire Line
7350 5450 7250 5450
Wire Wire Line
7350 4000 7350 5450
Wire Wire Line
7350 4000 7250 4000
Wire Wire Line
7350 2600 7350 4000
Wire Wire Line
7250 2600 7350 2600
Connection ~ 5700 4000
Wire Wire Line
5700 2600 5600 2600
Wire Wire Line
5700 4000 5700 2600
Wire Wire Line
5700 4000 5600 4000
Wire Wire Line
5700 5450 5700 4000
Wire Wire Line
5600 5450 5700 5450
Connection ~ 4200 4000
Wire Wire Line
4200 5450 4100 5450
Wire Wire Line
4200 4000 4200 5450
Wire Wire Line
4200 4000 4100 4000
Wire Wire Line
4200 2600 4200 4000
Wire Wire Line
4100 2600 4200 2600
Wire Wire Line
9000 5450 9550 5450
Wire Wire Line
9000 5900 9000 5450
Wire Wire Line
7550 5900 9000 5900
Wire Wire Line
7550 5450 8100 5450
Wire Wire Line
7550 5900 7550 5450
Wire Wire Line
5900 5900 7550 5900
Wire Wire Line
5900 5450 6650 5450
Wire Wire Line
5900 5900 5900 5450
Wire Wire Line
4400 5900 5900 5900
Wire Wire Line
4400 5450 5000 5450
Wire Wire Line
4400 5900 4400 5450
Wire Wire Line
2900 5900 4400 5900
Connection ~ 1800 5900
Wire Wire Line
2900 5450 3500 5450
Wire Wire Line
2900 5900 2900 5450
Wire Wire Line
1800 5900 2900 5900
Wire Wire Line
1800 5900 1450 5900
Wire Wire Line
1800 5450 1800 5900
Wire Wire Line
2000 5450 1800 5450
Wire Wire Line
9000 4000 9550 4000
Wire Wire Line
9000 4450 9000 4000
Wire Wire Line
7550 4450 9000 4450
Wire Wire Line
7550 4000 8100 4000
Wire Wire Line
7550 4450 7550 4000
Wire Wire Line
5900 4450 7550 4450
Wire Wire Line
5900 4450 5900 4000
Wire Wire Line
4400 4450 5900 4450
Wire Wire Line
4400 4000 5000 4000
Wire Wire Line
4400 4450 4400 4000
Wire Wire Line
2900 4450 4400 4450
Connection ~ 1800 4450
Wire Wire Line
2900 4450 1800 4450
Wire Wire Line
2900 4000 2900 4450
Wire Wire Line
3500 4000 2900 4000
Wire Wire Line
1800 4450 1450 4450
Wire Wire Line
1800 4000 1800 4450
Wire Wire Line
2000 4000 1800 4000
Connection ~ 2700 2600
Wire Wire Line
2700 4000 2600 4000
Wire Wire Line
2700 2600 2700 1650
Wire Wire Line
2600 2600 2700 2600
Wire Wire Line
9000 2600 9550 2600
Wire Wire Line
9000 3050 9000 2600
Wire Wire Line
7550 3050 9000 3050
Wire Wire Line
7550 2600 8100 2600
Wire Wire Line
7550 3050 7550 2600
Wire Wire Line
5900 3050 5900 2600
Wire Wire Line
4400 3050 5900 3050
Wire Wire Line
4400 3050 4400 2600
Wire Wire Line
2900 3050 4400 3050
Connection ~ 1800 3050
Wire Wire Line
2900 2600 3500 2600
Wire Wire Line
2900 3050 2900 2600
Wire Wire Line
1800 3050 2900 3050
Wire Wire Line
1800 2600 2000 2600
Wire Wire Line
1800 3050 1800 2600
Wire Wire Line
1450 3050 1800 3050
Text HLabel 1450 5900 0 50 Input ~ 0
LED_C
Text HLabel 1450 4450 0 50 Input ~ 0
LED_B
Text HLabel 1450 3050 0 50 Input ~ 0
LED_A
Text HLabel 10250 1650 1 50 Input ~ 0
LED_6
Text HLabel 8800 1650 1 50 Input ~ 0
LED_5
Text HLabel 7350 1650 1 50 Input ~ 0
LED_4
Text HLabel 5700 1650 1 50 Input ~ 0
LED_3
Text HLabel 4200 1650 1 50 Input ~ 0
LED_2
Text HLabel 2700 1650 1 50 Input ~ 0
LED_1
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64D3
P 9850 3900
F 0 "SW?" H 9850 4385 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 9850 4294 50 0000 C CNN
F 2 "" H 9850 4300 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 9850 4300 50 0001 C CNN
1 9850 3900
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64C9
P 9850 2500
F 0 "SW?" H 9850 2985 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 9850 2894 50 0000 C CNN
F 2 "" H 9850 2900 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 9850 2900 50 0001 C CNN
1 9850 2500
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64BF
P 9850 5350
F 0 "SW?" H 9850 5835 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 9850 5744 50 0000 C CNN
F 2 "" H 9850 5750 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 9850 5750 50 0001 C CNN
1 9850 5350
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64B5
P 8400 3900
F 0 "SW?" H 8400 4385 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 8400 4294 50 0000 C CNN
F 2 "" H 8400 4300 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 8400 4300 50 0001 C CNN
1 8400 3900
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64AB
P 8400 2500
F 0 "SW?" H 8400 2985 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 8400 2894 50 0000 C CNN
F 2 "" H 8400 2900 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 8400 2900 50 0001 C CNN
1 8400 2500
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B617B
P 8400 5350
F 0 "SW?" H 8400 5835 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 8400 5744 50 0000 C CNN
F 2 "" H 8400 5750 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 8400 5750 50 0001 C CNN
1 8400 5350
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999F0F
P 6950 3900
F 0 "SW?" H 6950 4385 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 6950 4294 50 0000 C CNN
F 2 "" H 6950 4300 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 6950 4300 50 0001 C CNN
1 6950 3900
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999F09
P 6950 2500
F 0 "SW?" H 6950 2985 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 6950 2894 50 0000 C CNN
F 2 "" H 6950 2900 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 6950 2900 50 0001 C CNN
1 6950 2500
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999F03
P 6950 5350
F 0 "SW?" H 6950 5835 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 6950 5744 50 0000 C CNN
F 2 "" H 6950 5750 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 6950 5750 50 0001 C CNN
1 6950 5350
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999EFD
P 5300 3900
F 0 "SW?" H 5300 4385 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 5300 4294 50 0000 C CNN
F 2 "" H 5300 4300 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 5300 4300 50 0001 C CNN
1 5300 3900
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999EF7
P 5300 2500
F 0 "SW?" H 5300 2985 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 5300 2894 50 0000 C CNN
F 2 "" H 5300 2900 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 5300 2900 50 0001 C CNN
1 5300 2500
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999EF1
P 5300 5350
F 0 "SW?" H 5300 5835 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 5300 5744 50 0000 C CNN
F 2 "" H 5300 5750 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 5300 5750 50 0001 C CNN
1 5300 5350
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609947E5
P 3800 3900
F 0 "SW?" H 3800 4385 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 3800 4294 50 0000 C CNN
F 2 "" H 3800 4300 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 3800 4300 50 0001 C CNN
1 3800 3900
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609947DF
P 3800 2500
F 0 "SW?" H 3800 2985 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 3800 2894 50 0000 C CNN
F 2 "" H 3800 2900 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 3800 2900 50 0001 C CNN
1 3800 2500
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609947D9
P 3800 5350
F 0 "SW?" H 3800 5835 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 3800 5744 50 0000 C CNN
F 2 "" H 3800 5750 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 3800 5750 50 0001 C CNN
1 3800 5350
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 6098AC56
P 2300 3900
F 0 "SW?" H 2300 4385 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 2300 4294 50 0000 C CNN
F 2 "" H 2300 4300 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 2300 4300 50 0001 C CNN
1 2300 3900
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60989FEA
P 2300 2500
F 0 "SW?" H 2300 2100 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 2300 2894 50 0000 C CNN
F 2 "" H 2300 2900 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 2300 2900 50 0001 C CNN
1 2300 2500
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60989410
P 2300 5350
F 0 "SW?" H 2300 5835 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 2300 5744 50 0000 C CNN
F 2 "" H 2300 5750 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 2300 5750 50 0001 C CNN
1 2300 5350
1 0 0 -1
$EndComp
Wire Wire Line
2700 2600 2700 4000
Connection ~ 2700 4000
Wire Wire Line
2700 4000 2700 5450
Wire Wire Line
2700 5450 2600 5450
Text HLabel 1450 1850 0 50 Input ~ 0
BTN_A
Wire Wire Line
1450 1850 1800 1850
Wire Wire Line
1800 2300 2000 2300
Wire Wire Line
1800 1850 2900 1850
Wire Wire Line
2900 1850 2900 2300
Wire Wire Line
3350 2300 3500 2300
Connection ~ 1800 1850
Wire Wire Line
3400 1850 4400 1850
Wire Wire Line
4400 1850 4400 2300
Wire Wire Line
4400 2300 4500 2300
Wire Wire Line
4900 1850 5900 1850
Wire Wire Line
5900 1850 5900 2300
Wire Wire Line
6550 1850 7550 1850
Wire Wire Line
7550 1850 7550 2300
Wire Wire Line
7550 2300 7650 2300
Wire Wire Line
7550 1850 9000 1850
Wire Wire Line
9000 1850 9000 2300
Wire Wire Line
9000 2300 9100 2300
Text HLabel 1450 3250 0 50 Input ~ 0
BTN_B
Wire Wire Line
1800 3250 1800 3700
Wire Wire Line
1800 3250 1450 3250
Wire Wire Line
2000 3700 1800 3700
Wire Wire Line
1800 3250 2900 3250
Wire Wire Line
2900 3250 2900 3700
Wire Wire Line
3350 3700 3500 3700
Connection ~ 1800 3250
Wire Wire Line
2900 3250 4400 3250
Wire Wire Line
4400 3250 4400 3700
Wire Wire Line
4400 3700 4500 3700
Wire Wire Line
4400 3250 5900 3250
Wire Wire Line
5900 3250 5900 3700
Wire Wire Line
7550 3250 7550 3700
Wire Wire Line
7550 3700 7650 3700
Wire Wire Line
7550 3250 9000 3250
Wire Wire Line
9000 3250 9000 3700
Wire Wire Line
9000 3700 9100 3700
Text HLabel 1450 4650 0 50 Input ~ 0
BTN_C
Wire Wire Line
2000 5150 1800 5150
Wire Wire Line
1800 5150 1800 4650
Wire Wire Line
1800 4650 1450 4650
Wire Wire Line
1800 4650 2900 4650
Wire Wire Line
2900 4650 2900 5150
Wire Wire Line
3350 5150 3500 5150
Connection ~ 1800 4650
Wire Wire Line
2900 4650 4400 4650
Wire Wire Line
4400 4650 4400 5150
Wire Wire Line
4400 5150 4500 5150
Wire Wire Line
4400 4650 5900 4650
Wire Wire Line
5900 4650 5900 5150
Wire Wire Line
5900 4650 7550 4650
Wire Wire Line
7550 4650 7550 5150
Wire Wire Line
7550 5150 7650 5150
Wire Wire Line
7550 4650 9000 4650
Wire Wire Line
9000 4650 9000 5150
Wire Wire Line
9000 5150 9100 5150
Text HLabel 2800 1650 1 50 Input ~ 0
BTN_1
Text HLabel 4300 1650 1 50 Input ~ 0
BTN_2
Text HLabel 5800 1650 1 50 Input ~ 0
BTN_3
Text HLabel 7450 1650 1 50 Input ~ 0
BTN_4
Wire Wire Line
2800 2300 2600 2300
Wire Wire Line
2800 2300 2800 3700
Wire Wire Line
2800 3700 2600 3700
Connection ~ 2800 2300
Wire Wire Line
2800 3700 2800 5150
Wire Wire Line
2800 5150 2600 5150
Connection ~ 2800 3700
Wire Wire Line
4300 1650 4300 2300
Wire Wire Line
4300 2300 4100 2300
Wire Wire Line
4300 2300 4300 3700
Wire Wire Line
4300 3700 4100 3700
Connection ~ 4300 2300
Wire Wire Line
4300 3700 4300 5150
Wire Wire Line
4300 5150 4100 5150
Connection ~ 4300 3700
Wire Wire Line
5800 1650 5800 2300
Wire Wire Line
5800 2300 5600 2300
Wire Wire Line
5800 2300 5800 3700
Wire Wire Line
5800 3700 5600 3700
Connection ~ 5800 2300
Wire Wire Line
5800 3700 5800 5150
Wire Wire Line
5800 5150 5600 5150
Connection ~ 5800 3700
Wire Wire Line
7450 1650 7450 2300
Wire Wire Line
7450 2300 7250 2300
Wire Wire Line
7450 2300 7450 3700
Wire Wire Line
7450 3700 7250 3700
Connection ~ 7450 2300
Wire Wire Line
7450 3700 7450 5150
Wire Wire Line
7450 5150 7250 5150
Connection ~ 7450 3700
Text HLabel 8900 1650 1 50 Input ~ 0
BTN_5
Text HLabel 10350 1650 1 50 Input ~ 0
BTN_6
Wire Wire Line
8900 1650 8900 2300
Wire Wire Line
8900 2300 8700 2300
Wire Wire Line
8900 2300 8900 3700
Wire Wire Line
8900 3700 8700 3700
Connection ~ 8900 2300
Wire Wire Line
8900 3700 8900 5150
Wire Wire Line
8900 5150 8700 5150
Connection ~ 8900 3700
Wire Wire Line
10350 1650 10350 2300
Wire Wire Line
10350 2300 10150 2300
Wire Wire Line
10350 2300 10350 3700
Wire Wire Line
10350 3700 10150 3700
Connection ~ 10350 2300
Wire Wire Line
10350 3700 10350 5150
Wire Wire Line
10350 5150 10150 5150
Connection ~ 10350 3700
Wire Wire Line
2800 1650 2800 2300
Wire Wire Line
1800 1850 1800 2300
$Comp
L Device:D D?
U 1 1 60DBF379
P 9250 2300
F 0 "D?" H 9250 2083 50 0000 C CNN
F 1 "D" H 9250 2174 50 0000 C CNN
F 2 "" H 9250 2300 50 0001 C CNN
F 3 "~" H 9250 2300 50 0001 C CNN
1 9250 2300
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 60DC02FA
P 9250 3700
F 0 "D?" H 9250 3483 50 0000 C CNN
F 1 "D" H 9250 3574 50 0000 C CNN
F 2 "" H 9250 3700 50 0001 C CNN
F 3 "~" H 9250 3700 50 0001 C CNN
1 9250 3700
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 60DC25F1
P 9250 5150
F 0 "D?" H 9250 4933 50 0000 C CNN
F 1 "D" H 9250 5024 50 0000 C CNN
F 2 "" H 9250 5150 50 0001 C CNN
F 3 "~" H 9250 5150 50 0001 C CNN
1 9250 5150
-1 0 0 1
$EndComp
Wire Wire Line
9400 5150 9550 5150
Wire Wire Line
9550 3700 9400 3700
Wire Wire Line
9550 2300 9400 2300
$Comp
L Device:D D?
U 1 1 60E3106F
P 7800 2300
F 0 "D?" H 7800 2083 50 0000 C CNN
F 1 "D" H 7800 2174 50 0000 C CNN
F 2 "" H 7800 2300 50 0001 C CNN
F 3 "~" H 7800 2300 50 0001 C CNN
1 7800 2300
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 60E318F8
P 7800 3700
F 0 "D?" H 7800 3483 50 0000 C CNN
F 1 "D" H 7800 3574 50 0000 C CNN
F 2 "" H 7800 3700 50 0001 C CNN
F 3 "~" H 7800 3700 50 0001 C CNN
1 7800 3700
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 60E3237B
P 7800 5150
F 0 "D?" H 7800 4933 50 0000 C CNN
F 1 "D" H 7800 5024 50 0000 C CNN
F 2 "" H 7800 5150 50 0001 C CNN
F 3 "~" H 7800 5150 50 0001 C CNN
1 7800 5150
-1 0 0 1
$EndComp
Wire Wire Line
8100 5150 7950 5150
Wire Wire Line
8100 3700 7950 3700
Wire Wire Line
7950 2300 8100 2300
Connection ~ 7550 3250
Connection ~ 7550 3050
Connection ~ 7550 1850
Connection ~ 7550 4650
Connection ~ 7550 4450
Connection ~ 7550 5900
$Comp
L Device:D D?
U 1 1 60F19BB6
P 6250 2300
F 0 "D?" H 6250 2083 50 0000 C CNN
F 1 "D" H 6250 2174 50 0000 C CNN
F 2 "" H 6250 2300 50 0001 C CNN
F 3 "~" H 6250 2300 50 0001 C CNN
1 6250 2300
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 60F1A340
P 6250 3700
F 0 "D?" H 6250 3483 50 0000 C CNN
F 1 "D" H 6250 3574 50 0000 C CNN
F 2 "" H 6250 3700 50 0001 C CNN
F 3 "~" H 6250 3700 50 0001 C CNN
1 6250 3700
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 60F1AD19
P 6250 5150
F 0 "D?" H 6250 4933 50 0000 C CNN
F 1 "D" H 6250 5024 50 0000 C CNN
F 2 "" H 6250 5150 50 0001 C CNN
F 3 "~" H 6250 5150 50 0001 C CNN
1 6250 5150
-1 0 0 1
$EndComp
Wire Wire Line
6400 5150 6650 5150
Wire Wire Line
6400 3700 6650 3700
Wire Wire Line
6400 2300 6650 2300
Wire Wire Line
6100 2300 5900 2300
Wire Wire Line
5900 2600 6650 2600
Wire Wire Line
5900 3050 7550 3050
Connection ~ 5900 3050
Wire Wire Line
5900 3250 7550 3250
Connection ~ 5900 3250
Wire Wire Line
6100 3700 5900 3700
Wire Wire Line
5900 4000 6650 4000
Connection ~ 5900 4450
Connection ~ 5900 4650
Wire Wire Line
5900 5150 6100 5150
Connection ~ 5900 5900
$Comp
L Device:D D?
U 1 1 60FFB6B4
P 4650 2300
F 0 "D?" H 4650 2083 50 0000 C CNN
F 1 "D" H 4650 2174 50 0000 C CNN
F 2 "" H 4650 2300 50 0001 C CNN
F 3 "~" H 4650 2300 50 0001 C CNN
1 4650 2300
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 61002B27
P 4650 3700
F 0 "D?" H 4650 3483 50 0000 C CNN
F 1 "D" H 4650 3574 50 0000 C CNN
F 2 "" H 4650 3700 50 0001 C CNN
F 3 "~" H 4650 3700 50 0001 C CNN
1 4650 3700
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 610036A7
P 4650 5150
F 0 "D?" H 4650 4933 50 0000 C CNN
F 1 "D" H 4650 5024 50 0000 C CNN
F 2 "" H 4650 5150 50 0001 C CNN
F 3 "~" H 4650 5150 50 0001 C CNN
1 4650 5150
-1 0 0 1
$EndComp
Wire Wire Line
5000 5150 4800 5150
Wire Wire Line
5000 3700 4800 3700
Wire Wire Line
5000 2300 4800 2300
Wire Wire Line
4400 2600 5000 2600
Connection ~ 4400 5900
Connection ~ 4400 4650
Connection ~ 4400 4450
Connection ~ 4400 3250
Connection ~ 4400 3050
$Comp
L Device:D D?
U 1 1 610FFBA4
P 3200 2300
F 0 "D?" H 3200 2083 50 0000 C CNN
F 1 "D" H 3200 2174 50 0000 C CNN
F 2 "" H 3200 2300 50 0001 C CNN
F 3 "~" H 3200 2300 50 0001 C CNN
1 3200 2300
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 6110C54E
P 3200 3700
F 0 "D?" H 3200 3483 50 0000 C CNN
F 1 "D" H 3200 3574 50 0000 C CNN
F 2 "" H 3200 3700 50 0001 C CNN
F 3 "~" H 3200 3700 50 0001 C CNN
1 3200 3700
-1 0 0 1
$EndComp
$Comp
L Device:D D?
U 1 1 6111A764
P 3200 5150
F 0 "D?" H 3200 4933 50 0000 C CNN
F 1 "D" H 3200 5024 50 0000 C CNN
F 2 "" H 3200 5150 50 0001 C CNN
F 3 "~" H 3200 5150 50 0001 C CNN
1 3200 5150
-1 0 0 1
$EndComp
Wire Wire Line
3050 2300 2900 2300
Connection ~ 2900 3050
Connection ~ 2900 3250
Wire Wire Line
2900 3700 3050 3700
Connection ~ 2900 4450
Connection ~ 2900 4650
Wire Wire Line
3050 5150 2900 5150
Connection ~ 2900 5900
$EndSCHEMATC

@ -0,0 +1,664 @@
EESchema Schematic File Version 4
EELAYER 30 0
EELAYER END
$Descr A4 11693 8268
encoding utf-8
Sheet 2 2
Title "Button and LED I/O section"
Date "2021-05-06"
Rev "A1"
Comp "breadmachine"
Comment1 ""
Comment2 ""
Comment3 ""
Comment4 ""
$EndDescr
Connection ~ 8500 2500
Wire Wire Line
8500 2500 8500 1550
Connection ~ 7500 2500
Wire Wire Line
7500 2500 7500 1550
Connection ~ 6500 2500
Wire Wire Line
6500 2500 6500 1550
Connection ~ 5500 2500
Wire Wire Line
5500 1550 5500 2500
Connection ~ 4500 2500
Wire Wire Line
4500 2500 4500 1550
Connection ~ 8500 3900
Wire Wire Line
8500 2500 8400 2500
Wire Wire Line
8500 3900 8500 2500
Wire Wire Line
8500 3900 8400 3900
Wire Wire Line
8500 5350 8500 3900
Wire Wire Line
8400 5350 8500 5350
Connection ~ 7500 3900
Wire Wire Line
7500 2500 7400 2500
Wire Wire Line
7500 3900 7500 2500
Wire Wire Line
7500 3900 7400 3900
Wire Wire Line
7500 5350 7500 3900
Wire Wire Line
7400 5350 7500 5350
Connection ~ 6500 3900
Wire Wire Line
6500 5350 6400 5350
Wire Wire Line
6500 3900 6500 5350
Wire Wire Line
6500 3900 6400 3900
Wire Wire Line
6500 2500 6500 3900
Wire Wire Line
6400 2500 6500 2500
Connection ~ 5500 3900
Wire Wire Line
5500 2500 5400 2500
Wire Wire Line
5500 3900 5500 2500
Wire Wire Line
5500 3900 5400 3900
Wire Wire Line
5500 5350 5500 3900
Wire Wire Line
5400 5350 5500 5350
Connection ~ 4500 3900
Wire Wire Line
4500 5350 4400 5350
Wire Wire Line
4500 3900 4500 5350
Wire Wire Line
4500 3900 4400 3900
Wire Wire Line
4500 2500 4500 3900
Wire Wire Line
4400 2500 4500 2500
Connection ~ 6700 5800
Wire Wire Line
7700 5350 7800 5350
Wire Wire Line
7700 5800 7700 5350
Wire Wire Line
6700 5800 7700 5800
Connection ~ 5700 5800
Wire Wire Line
6700 5350 6800 5350
Wire Wire Line
6700 5800 6700 5350
Wire Wire Line
5700 5800 6700 5800
Connection ~ 4700 5800
Wire Wire Line
5700 5350 5800 5350
Wire Wire Line
5700 5800 5700 5350
Wire Wire Line
4700 5800 5700 5800
Connection ~ 3700 5800
Wire Wire Line
4700 5350 4800 5350
Wire Wire Line
4700 5800 4700 5350
Wire Wire Line
3700 5800 4700 5800
Connection ~ 2600 5800
Wire Wire Line
3700 5350 3800 5350
Wire Wire Line
3700 5800 3700 5350
Wire Wire Line
2600 5800 3700 5800
Wire Wire Line
2600 5800 2250 5800
Wire Wire Line
2600 5350 2600 5800
Wire Wire Line
2800 5350 2600 5350
Connection ~ 6700 4350
Wire Wire Line
7700 3900 7800 3900
Wire Wire Line
7700 4350 7700 3900
Wire Wire Line
6700 4350 7700 4350
Connection ~ 5700 4350
Wire Wire Line
6700 3900 6800 3900
Wire Wire Line
6700 4350 6700 3900
Wire Wire Line
5700 4350 6700 4350
Connection ~ 4700 4350
Wire Wire Line
5700 3900 5800 3900
Wire Wire Line
5700 4350 5700 3900
Wire Wire Line
4700 4350 5700 4350
Connection ~ 3700 4350
Wire Wire Line
4700 3900 4800 3900
Wire Wire Line
4700 4350 4700 3900
Wire Wire Line
3700 4350 4700 4350
Connection ~ 2600 4350
Wire Wire Line
3700 4350 2600 4350
Wire Wire Line
3700 3900 3700 4350
Wire Wire Line
3800 3900 3700 3900
Wire Wire Line
2600 4350 2250 4350
Wire Wire Line
2600 3900 2600 4350
Wire Wire Line
2800 3900 2600 3900
Connection ~ 3500 2500
Wire Wire Line
3500 3900 3400 3900
Wire Wire Line
3500 2500 3500 1550
Wire Wire Line
3400 2500 3500 2500
Connection ~ 6700 2950
Wire Wire Line
7700 2500 7800 2500
Wire Wire Line
7700 2950 7700 2500
Wire Wire Line
6700 2950 7700 2950
Connection ~ 5700 2950
Wire Wire Line
6700 2500 6800 2500
Wire Wire Line
6700 2950 6700 2500
Wire Wire Line
5700 2950 6700 2950
Connection ~ 4700 2950
Wire Wire Line
5700 2500 5800 2500
Wire Wire Line
5700 2950 5700 2500
Wire Wire Line
4700 2950 5700 2950
Connection ~ 3700 2950
Wire Wire Line
4700 2500 4800 2500
Wire Wire Line
4700 2950 4700 2500
Wire Wire Line
3700 2950 4700 2950
Connection ~ 2600 2950
Wire Wire Line
3700 2500 3800 2500
Wire Wire Line
3700 2950 3700 2500
Wire Wire Line
2600 2950 3700 2950
Wire Wire Line
2600 2500 2800 2500
Wire Wire Line
2600 2950 2600 2500
Wire Wire Line
2250 2950 2600 2950
Text HLabel 2250 5800 0 50 Input ~ 0
LED_C
Text HLabel 2250 4350 0 50 Input ~ 0
LED_B
Text HLabel 2250 2950 0 50 Input ~ 0
LED_A
Text HLabel 8500 1550 1 50 Input ~ 0
LED_6
Text HLabel 7500 1550 1 50 Input ~ 0
LED_5
Text HLabel 6500 1550 1 50 Input ~ 0
LED_4
Text HLabel 5500 1550 1 50 Input ~ 0
LED_3
Text HLabel 4500 1550 1 50 Input ~ 0
LED_2
Text HLabel 3500 1550 1 50 Input ~ 0
LED_1
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64D3
P 8100 3800
F 0 "SW?" H 8100 4285 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 8100 4194 50 0000 C CNN
F 2 "" H 8100 4200 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 8100 4200 50 0001 C CNN
1 8100 3800
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64C9
P 8100 2400
F 0 "SW?" H 8100 2885 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 8100 2794 50 0000 C CNN
F 2 "" H 8100 2800 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 8100 2800 50 0001 C CNN
1 8100 2400
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64BF
P 8100 5250
F 0 "SW?" H 8100 5735 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 8100 5644 50 0000 C CNN
F 2 "" H 8100 5650 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 8100 5650 50 0001 C CNN
1 8100 5250
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64B5
P 7100 3800
F 0 "SW?" H 7100 4285 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 7100 4194 50 0000 C CNN
F 2 "" H 7100 4200 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 7100 4200 50 0001 C CNN
1 7100 3800
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B64AB
P 7100 2400
F 0 "SW?" H 7100 2885 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 7100 2794 50 0000 C CNN
F 2 "" H 7100 2800 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 7100 2800 50 0001 C CNN
1 7100 2400
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609B617B
P 7100 5250
F 0 "SW?" H 7100 5735 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 7100 5644 50 0000 C CNN
F 2 "" H 7100 5650 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 7100 5650 50 0001 C CNN
1 7100 5250
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999F0F
P 6100 3800
F 0 "SW?" H 6100 4285 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 6100 4194 50 0000 C CNN
F 2 "" H 6100 4200 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 6100 4200 50 0001 C CNN
1 6100 3800
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999F09
P 6100 2400
F 0 "SW?" H 6100 2885 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 6100 2794 50 0000 C CNN
F 2 "" H 6100 2800 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 6100 2800 50 0001 C CNN
1 6100 2400
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999F03
P 6100 5250
F 0 "SW?" H 6100 5735 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 6100 5644 50 0000 C CNN
F 2 "" H 6100 5650 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 6100 5650 50 0001 C CNN
1 6100 5250
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999EFD
P 5100 3800
F 0 "SW?" H 5100 4285 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 5100 4194 50 0000 C CNN
F 2 "" H 5100 4200 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 5100 4200 50 0001 C CNN
1 5100 3800
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999EF7
P 5100 2400
F 0 "SW?" H 5100 2885 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 5100 2794 50 0000 C CNN
F 2 "" H 5100 2800 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 5100 2800 50 0001 C CNN
1 5100 2400
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60999EF1
P 5100 5250
F 0 "SW?" H 5100 5735 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 5100 5644 50 0000 C CNN
F 2 "" H 5100 5650 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 5100 5650 50 0001 C CNN
1 5100 5250
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609947E5
P 4100 3800
F 0 "SW?" H 4100 4285 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 4100 4194 50 0000 C CNN
F 2 "" H 4100 4200 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 4100 4200 50 0001 C CNN
1 4100 3800
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609947DF
P 4100 2400
F 0 "SW?" H 4100 2885 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 4100 2794 50 0000 C CNN
F 2 "" H 4100 2800 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 4100 2800 50 0001 C CNN
1 4100 2400
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 609947D9
P 4100 5250
F 0 "SW?" H 4100 5735 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 4100 5644 50 0000 C CNN
F 2 "" H 4100 5650 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 4100 5650 50 0001 C CNN
1 4100 5250
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 6098AC56
P 3100 3800
F 0 "SW?" H 3100 4285 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 3100 4194 50 0000 C CNN
F 2 "" H 3100 4200 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 3100 4200 50 0001 C CNN
1 3100 3800
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60989FEA
P 3100 2400
F 0 "SW?" H 3100 2885 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 3100 2794 50 0000 C CNN
F 2 "" H 3100 2800 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 3100 2800 50 0001 C CNN
1 3100 2400
1 0 0 -1
$EndComp
$Comp
L Switch:SW_MEC_5G_2LED SW?
U 1 1 60989410
P 3100 5250
F 0 "SW?" H 3100 5735 50 0000 C CNN
F 1 "SW_MEC_5G_2LED" H 3100 5644 50 0000 C CNN
F 2 "" H 3100 5650 50 0001 C CNN
F 3 "http://www.apem.com/int/index.php?controller=attachment&id_attachment=488" H 3100 5650 50 0001 C CNN
1 3100 5250
1 0 0 -1
$EndComp
Wire Wire Line
3500 2500 3500 3900
Connection ~ 3500 3900
Wire Wire Line
3500 3900 3500 5350
Wire Wire Line
3500 5350 3400 5350
Text HLabel 2250 1750 0 50 Input ~ 0
BTN_A
Wire Wire Line
2250 1750 2600 1750
Wire Wire Line
2600 1750 2600 2200
Wire Wire Line
2600 2200 2800 2200
Wire Wire Line
2600 1750 3700 1750
Wire Wire Line
3700 1750 3700 2200
Wire Wire Line
3700 2200 3800 2200
Connection ~ 2600 1750
Wire Wire Line
3700 1750 4700 1750
Wire Wire Line
4700 1750 4700 2200
Wire Wire Line
4700 2200 4800 2200
Connection ~ 3700 1750
Wire Wire Line
4700 1750 5700 1750
Wire Wire Line
5700 1750 5700 2200
Wire Wire Line
5700 2200 5800 2200
Connection ~ 4700 1750
Wire Wire Line
5700 1750 6700 1750
Wire Wire Line
6700 1750 6700 2200
Wire Wire Line
6700 2200 6800 2200
Connection ~ 5700 1750
Wire Wire Line
6700 1750 7700 1750
Wire Wire Line
7700 1750 7700 2200
Wire Wire Line
7700 2200 7800 2200
Connection ~ 6700 1750
Text HLabel 2250 3150 0 50 Input ~ 0
BTN_B
Wire Wire Line
2600 3150 2600 3600
Wire Wire Line
2600 3150 2250 3150
Wire Wire Line
2800 3600 2600 3600
Wire Wire Line
2600 3150 3700 3150
Wire Wire Line
3700 3150 3700 3600
Wire Wire Line
3700 3600 3800 3600
Connection ~ 2600 3150
Wire Wire Line
3700 3150 4700 3150
Wire Wire Line
4700 3150 4700 3600
Wire Wire Line
4700 3600 4800 3600
Connection ~ 3700 3150
Wire Wire Line
4700 3150 5700 3150
Wire Wire Line
5700 3150 5700 3600
Wire Wire Line
5700 3600 5800 3600
Connection ~ 4700 3150
Wire Wire Line
5700 3150 6700 3150
Wire Wire Line
6700 3150 6700 3600
Wire Wire Line
6700 3600 6800 3600
Connection ~ 5700 3150
Wire Wire Line
6700 3150 7700 3150
Wire Wire Line
7700 3150 7700 3600
Wire Wire Line
7700 3600 7800 3600
Connection ~ 6700 3150
Text HLabel 2250 4550 0 50 Input ~ 0
BTN_C
Wire Wire Line
2800 5050 2600 5050
Wire Wire Line
2600 5050 2600 4550
Wire Wire Line
2600 4550 2250 4550
Wire Wire Line
2600 4550 3700 4550
Wire Wire Line
3700 4550 3700 5050
Wire Wire Line
3700 5050 3800 5050
Connection ~ 2600 4550
Wire Wire Line
3700 4550 4700 4550
Wire Wire Line
4700 4550 4700 5050
Wire Wire Line
4700 5050 4800 5050
Connection ~ 3700 4550
Wire Wire Line
4700 4550 5700 4550
Wire Wire Line
5700 4550 5700 5050
Wire Wire Line
5700 5050 5800 5050
Connection ~ 4700 4550
Wire Wire Line
5700 4550 6700 4550
Wire Wire Line
6700 4550 6700 5050
Wire Wire Line
6700 5050 6800 5050
Connection ~ 5700 4550
Wire Wire Line
6700 4550 7700 4550
Wire Wire Line
7700 4550 7700 5050
Wire Wire Line
7700 5050 7800 5050
Connection ~ 6700 4550
Text HLabel 3600 1550 1 50 Input ~ 0
BTN_1
Text HLabel 4600 1550 1 50 Input ~ 0
BTN_2
Text HLabel 5600 1550 1 50 Input ~ 0
BTN_3
Text HLabel 6600 1550 1 50 Input ~ 0
BTN_4
Wire Wire Line
3600 1550 3600 2200
Wire Wire Line
3600 2200 3400 2200
Wire Wire Line
3600 2200 3600 3600
Wire Wire Line
3600 3600 3400 3600
Connection ~ 3600 2200
Wire Wire Line
3600 3600 3600 5050
Wire Wire Line
3600 5050 3400 5050
Connection ~ 3600 3600
Wire Wire Line
4600 1550 4600 2200
Wire Wire Line
4600 2200 4400 2200
Wire Wire Line
4600 2200 4600 3600
Wire Wire Line
4600 3600 4400 3600
Connection ~ 4600 2200
Wire Wire Line
4600 3600 4600 5050
Wire Wire Line
4600 5050 4400 5050
Connection ~ 4600 3600
Wire Wire Line
5600 1550 5600 2200
Wire Wire Line
5600 2200 5400 2200
Wire Wire Line
5600 2200 5600 3600
Wire Wire Line
5600 3600 5400 3600
Connection ~ 5600 2200
Wire Wire Line
5600 3600 5600 5050
Wire Wire Line
5600 5050 5400 5050
Connection ~ 5600 3600
Wire Wire Line
6600 1550 6600 2200
Wire Wire Line
6600 2200 6400 2200
Wire Wire Line
6600 2200 6600 3600
Wire Wire Line
6600 3600 6400 3600
Connection ~ 6600 2200
Wire Wire Line
6600 3600 6600 5050
Wire Wire Line
6600 5050 6400 5050
Connection ~ 6600 3600
Text HLabel 7600 1550 1 50 Input ~ 0
BTN_5
Text HLabel 8600 1550 1 50 Input ~ 0
BTN_6
Wire Wire Line
7600 1550 7600 2200
Wire Wire Line
7600 2200 7400 2200
Wire Wire Line
7600 2200 7600 3600
Wire Wire Line
7600 3600 7400 3600
Connection ~ 7600 2200
Wire Wire Line
7600 3600 7600 5050
Wire Wire Line
7600 5050 7400 5050
Connection ~ 7600 3600
Wire Wire Line
8600 1550 8600 2200
Wire Wire Line
8600 2200 8400 2200
Wire Wire Line
8600 2200 8600 3600
Wire Wire Line
8600 3600 8400 3600
Connection ~ 8600 2200
Wire Wire Line
8600 3600 8600 5050
Wire Wire Line
8600 5050 8400 5050
Connection ~ 8600 3600
$EndSCHEMATC

@ -36,6 +36,28 @@ X ~ 2 0 -150 110 U 50 50 1 1 P
ENDDRAW
ENDDEF
#
# Device_D
#
DEF Device_D D 0 40 N N 1 F N
F0 "D" 0 100 50 H V C CNN
F1 "Device_D" 0 -100 50 H V C CNN
F2 "" 0 0 50 H I C CNN
F3 "" 0 0 50 H I C CNN
$FPLIST
TO-???*
*_Diode_*
*SingleDiode*
D_*
$ENDFPLIST
DRAW
P 2 0 1 10 -50 50 -50 -50 N
P 2 0 1 0 50 0 -50 0 N
P 4 0 1 10 50 50 50 -50 -50 0 50 50 N
X K 1 -150 0 100 R 50 50 1 1 P
X A 2 150 0 100 L 50 50 1 1 P
ENDDRAW
ENDDEF
#
# Device_R
#
DEF Device_R R 0 0 N Y 1 F N
@ -117,29 +139,45 @@ X VDDA 9 200 1500 100 D 50 50 1 1 W
ENDDRAW
ENDDEF
#
# Switch_SW_Push_LED
# Switch_SW_MEC_5G_2LED
#
DEF Switch_SW_Push_LED SW 0 40 Y N 1 F N
F0 "SW" 25 225 50 H V L CNN
F1 "Switch_SW_Push_LED" 0 -125 50 H V C CNN
F2 "" 0 300 50 H I C CNN
F3 "" 0 300 50 H I C CNN
DEF Switch_SW_MEC_5G_2LED SW 0 40 Y N 1 F N
F0 "SW" -200 300 50 H V L CNN
F1 "Switch_SW_MEC_5G_2LED" 0 -350 50 H V C CNN
F2 "" 0 400 50 H I C CNN
F3 "" 0 400 50 H I C CNN
$FPLIST
SW*MEC*5G*
$ENDFPLIST
DRAW
C -80 100 20 0 1 0 N
C 80 100 20 0 1 0 N
P 2 0 0 0 -150 -75 -100 -25 N
P 2 0 0 0 -100 -75 -50 -25 N
P 2 0 0 0 -100 0 100 0 N
P 2 0 0 0 -25 50 -25 -50 N
P 3 0 0 0 -150 -50 -150 -75 -125 -75 N
P 3 0 0 0 -100 -50 -100 -75 -75 -75 N
P 4 0 0 0 -25 0 50 50 50 -50 -25 0 F
P 2 0 1 0 0 150 0 220 N
P 2 0 1 0 100 150 -100 150 N
X 1 1 -200 100 100 R 50 50 0 1 P
X 2 2 200 100 100 L 50 50 0 1 P
X K 3 -200 0 100 R 50 50 0 1 P
X A 4 200 0 100 L 50 50 0 1 P
C -80 200 20 0 1 0 N
C 80 200 20 0 1 0 N
P 2 0 0 0 -200 -100 -100 -100 N
P 2 0 0 0 -200 200 -100 200 N
P 2 0 0 0 -150 -275 -100 -225 N
P 2 0 0 0 -100 -275 -50 -225 N
P 2 0 0 0 -100 -200 100 -200 N
P 2 0 0 0 -100 0 -100 -200 N
P 2 0 0 0 -25 -150 -25 -250 N
P 2 0 0 0 25 50 25 -50 N
P 2 0 0 0 100 0 -100 0 N
P 2 0 0 0 100 0 100 -200 N
P 2 0 0 0 100 75 50 25 N
P 2 0 0 0 100 200 200 200 N
P 2 0 0 0 150 75 100 25 N
P 2 0 0 0 200 -100 100 -100 N
P 3 0 0 0 -150 -250 -150 -275 -125 -275 N
P 3 0 0 0 -100 -250 -100 -275 -75 -275 N
P 3 0 0 0 100 50 100 75 75 75 N
P 3 0 0 0 150 50 150 75 125 75 N
P 4 0 0 0 -25 -200 50 -150 50 -250 -25 -200 F
P 4 0 0 0 25 0 -50 50 -50 -50 25 0 F
P 2 0 1 0 0 250 0 320 N
P 2 0 1 0 100 250 -100 250 N
X 1 1 -300 200 100 R 50 50 0 1 P
X 2 2 -300 -100 100 R 50 50 0 1 P
X K 3 300 -100 100 L 50 50 0 1 P
X A 4 300 200 100 L 50 50 0 1 P
ENDDRAW
ENDDEF
#

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

@ -1,23 +1,16 @@
use crate::{LayerSelect, Sequencer};
use embedded_hal::digital::v2::{InputPin, OutputPin};
use stm32f1xx_hal::gpio::{
gpioa::{PA1, PA2, PA3, PA4},
gpiob::{PB0, PB1, PB5, PB6, PB7, PB8, PB9},
Input, Output, PullDown, PushPull,
use embedded_hal::{
digital::v2::{InputPin, OutputPin},
prelude::*,
};
use stm32f1xx_hal::{
delay::Delay,
gpio::{
gpioa::{PA1, PA2, PA3, PA4},
gpiob::{PB0, PB1, PB5, PB6, PB7, PB8},
Input, Output, PullDown, PushPull,
},
};
struct NoneOutput;
impl OutputPin for NoneOutput {
type Error = ();
fn set_low(&mut self) -> Result<(), ()> {
Ok(())
}
fn set_high(&mut self) -> Result<(), ()> {
Ok(())
}
}
/// An I/O abstraction for yesman
///
@ -31,98 +24,62 @@ pub struct Io {
pub led2: PA2<Output<PushPull>>,
pub led3: PA3<Output<PushPull>>,
pub led4: PA4<Output<PushPull>>,
// Button input states
pub btn1: PB0<Input<PullDown>>,
pub btn1_last: bool,
pub btn2: PB1<Input<PullDown>>,
pub btn2_last: bool,
pub btn3: PB5<Input<PullDown>>,
pub btn3_last: bool,
pub btn4: PB6<Input<PullDown>>,
pub btn4_last: bool,
// Eurorack signal I/O
pub clk: PB7<Input<PullDown>>,
pub clk_last: bool,
pub clk_led: PB9<Output<PushPull>>,
pub gate: PB8<Output<PushPull>>,
}
impl Io {
pub fn startup(&mut self, _: &mut Delay) {
set_output(&mut self.led1, true);
set_output(&mut self.led2, true);
set_output(&mut self.led3, true);
set_output(&mut self.led4, true);
// TODO: silly start-up animation here
}
/// Check the state of each pin and update the sequencer accordingly
pub fn update_sequence(&mut self, seq: &mut Sequencer) {
// Update sequencer states based on button inputs
// btn_rising_edge(&mut self.btn1_last, &mut self.btn1, || seq.toggle(0));
// btn_rising_edge(&mut self.btn2_last, &mut self.btn2, || seq.toggle(1));
// btn_rising_edge(&mut self.btn3_last, &mut self.btn3, || seq.toggle(2));
// btn_rising_edge(&mut self.btn4_last, &mut self.btn4, || seq.toggle(3));
// // Update LED states based on sequencer
// let l = seq.layer(LayerSelect::A);
// set_output(&mut self.led1, l[0]);
// set_output(&mut self.led2, l[1]);
// set_output(&mut self.led3, l[2]);
// set_output(&mut self.led4, l[3]);
btn_rising_edge(&mut self.btn1_last, &mut self.btn1, || seq.toggle(0));
btn_rising_edge(&mut self.btn2_last, &mut self.btn2, || seq.toggle(1));
btn_rising_edge(&mut self.btn3_last, &mut self.btn3, || seq.toggle(2));
btn_rising_edge(&mut self.btn4_last, &mut self.btn4, || seq.toggle(3));
// Update LED states based on sequencer
let l = seq.layer(LayerSelect::A);
set_output(&mut self.led1, l[0]);
set_output(&mut self.led2, l[1]);
set_output(&mut self.led3, l[2]);
set_output(&mut self.led4, l[3]);
}
pub fn update_cv(&mut self, seq: &mut Sequencer) {
pub fn update_cv(&mut self, _: &mut Sequencer) {
// Always output the current steps - if no clock is coming in this will change nothing in our output
// set_output(&mut self.gate, !seq.get().0);
// set_output(&mut self.gate, seq.get().0);
// // On a rising clock edge, step the sequencer
// rising_edge(
// &mut self.clk_last,
// &mut self.clk,
// &mut self.clk_led,
// |led| {
// set_output(led, false);
// },
// );
// If the clock pin is high
if let Ok(true) = self.clk.is_high() {
// And this is the first time we run this code
if !self.clk_last {
// Just set the LED to on for now
self.clk_led.set_high().ok();
self.clk_last = true;
}
// If the clock pin goes low
} else if let Ok(false) = self.clk.is_high() {
// We set the `last` bool to false and reset the LED
self.clk_last = false;
self.clk_led.set_low().ok();
}
// On a rising clock edge, step the sequencer
// btn_rising_edge(&mut self.clk_last, &mut self.clk, || seq.step());
}
}
/// If the button is pressed _and_ it was previously not pressed,
/// run the given closure and update the button state to avoid
/// running it again
#[inline]
fn btn_rising_edge<I: InputPin, F: FnMut()>(last: &mut bool, i: &mut I, mut f: F) {
rising_edge(last, i, &mut NoneOutput, |_: &mut NoneOutput| f());
}
/// If the button is pressed _and_ it was previously not pressed,
/// run the given closure and update the button state to avoid
/// running it again
#[inline]
fn rising_edge<I: InputPin, F: FnMut(&mut O), O: OutputPin>(
last: &mut bool,
i: &mut I,
o: &mut O,
mut f: F,
) {
if let Ok(true) = i.is_high() {
if !*last {
f(o);
f();
*last = true;
}
} else if let Ok(false) = i.is_high() {
@ -130,6 +87,12 @@ fn rising_edge<I: InputPin, F: FnMut(&mut O), O: OutputPin>(
}
}
/// Set the output of a PIN. For LEDs this means `true` is off,
/// `false` is on.
///
/// This is because LEDs are wired from 3V3 to the output, which turns
/// a low pin into a drain, and thus power can flow. This is done to
/// reduce load on the stm32 when a lot of LEDs are active at once.
fn set_output<O: OutputPin>(o: &mut O, s: bool) {
if s {
o.set_high().ok();

@ -1,72 +1,161 @@
#![no_main]
#![no_std]
#![no_main]
// // mod io;
use cortex_m_rt::entry;
use embedded_hal::digital::v2::{InputPin, OutputPin};
use stm32f1xx_hal::{delay::Delay, pac, prelude::*};
// // mod seq;
// // pub use seq::{LayerSelect, SeqLayer, Sequencer};
// Halt the MCU when panic
#[allow(unused_imports)]
use panic_halt;
use panic_halt as _;
mod io;
use core::mem::MaybeUninit;
use cortex_m_rt::entry;
use embedded_hal::digital::v2::OutputPin;
use pac::interrupt;
use stm32f1xx_hal::gpio::*;
use stm32f1xx_hal::{pac, prelude::*};
// These two are owned by the ISR. main() may only access them during the initialization phase,
// where the interrupt is not yet enabled (i.e. no concurrent accesses can occur).
// After enabling the interrupt, main() may not have any references to these objects any more.
// For the sake of minimalism, we do not use RTIC here, which would be the better way.
static mut LED: MaybeUninit<stm32f1xx_hal::gpio::gpiob::PB9<Output<PushPull>>> =
MaybeUninit::uninit();
static mut INT_PIN: MaybeUninit<stm32f1xx_hal::gpio::gpioa::PA7<Input<PullDown>>> =
MaybeUninit::uninit();
#[interrupt]
fn EXTI9_5() {
let led = unsafe { &mut *LED.as_mut_ptr() };
let int_pin = unsafe { &mut *INT_PIN.as_mut_ptr() };
if int_pin.check_interrupt() {
led.toggle().ok();
// if we don't clear this bit, the ISR would trigger indefinitely
int_pin.clear_interrupt_pending_bit();
}
}
mod seq;
pub use seq::{LayerSelect, SeqLayer, Sequencer};
#[entry]
fn main() -> ! {
// initialization phase
let p = pac::Peripherals::take().unwrap();
let _cp = cortex_m::peripheral::Peripherals::take().unwrap();
{
// the scope ensures that the int_pin reference is dropped before the first ISR can be executed.
let mut rcc = p.RCC.constrain();
let mut gpioa = p.GPIOA.split(&mut rcc.apb2);
let mut gpiob = p.GPIOB.split(&mut rcc.apb2);
let mut afio = p.AFIO.constrain(&mut rcc.apb2);
let led = unsafe { &mut *LED.as_mut_ptr() };
*led = gpiob.pb9.into_push_pull_output(&mut gpiob.crh);
let int_pin = unsafe { &mut *INT_PIN.as_mut_ptr() };
*int_pin = gpioa.pa7.into_pull_down_input(&mut gpioa.crl);
int_pin.make_interrupt_source(&mut afio);
int_pin.trigger_on_edge(&p.EXTI, Edge::RISING);
int_pin.enable_interrupt(&p.EXTI);
} // initialization ends here
unsafe {
pac::NVIC::unmask(pac::Interrupt::EXTI9_5);
// Grab handles for the underlying hardware objects
let dp = pac::Peripherals::take().unwrap();
let cp = cortex_m::Peripherals::take().unwrap();
// Initialise GPIOC via the HAL
let mut rcc = dp.RCC.constrain();
let mut gpioa = dp.GPIOA.split(&mut rcc.apb2);
let mut gpiob = dp.GPIOB.split(&mut rcc.apb2);
// Create an LED output
let mut led1 = gpioa.pa1.into_push_pull_output(&mut gpioa.crl);
let mut led2 = gpioa.pa2.into_push_pull_output(&mut gpioa.crl);
let mut led3 = gpioa.pa3.into_push_pull_output(&mut gpioa.crl);
let mut led4 = gpioa.pa4.into_push_pull_output(&mut gpioa.crl);
// Create a button input
let btn1 = gpiob.pb0.into_pull_down_input(&mut gpiob.crl);
let btn2 = gpiob.pb1.into_pull_down_input(&mut gpiob.crl);
let btn3 = gpiob.pb5.into_pull_down_input(&mut gpiob.crl);
let btn4 = gpiob.pb6.into_pull_down_input(&mut gpiob.crl);
// Eurorack clock input/ gate output
let clk = gpiob.pb7.into_pull_down_input(&mut gpiob.crl);
let gate = gpiob.pb8.into_push_pull_output(&mut gpiob.crh);
// Setup the I/O states
let mut io = io::Io {
led1,
led2,
led3,
led4,
btn1,
btn2,
btn3,
btn4,
btn1_last: false,
btn2_last: false,
btn3_last: false,
btn4_last: false,
clk,
clk_last: false,
gate,
};
let mut seq = Sequencer::default();
// Initialize the delay object with the MCU frequency
let mut flash = dp.FLASH.constrain();
let clocks = rcc
.cfgr
.use_hse(8.mhz())
.sysclk(48.mhz())
.pclk1(24.mhz())
.freeze(&mut flash.acr);
let mut delay = Delay::new(cp.SYST, clocks);
io.startup(&mut delay);
loop {
// Update sequencer state based on inputs
io.update_sequence(&mut seq);
// Write out gate CV
io.update_cv(&mut seq);
// Wait 5ms until we do it again
delay.delay_ms(5_u16);
}
loop {}
}
// #![no_main]
// #![no_std]
// // // mod io;
// // // mod seq;
// // // pub use seq::{LayerSelect, SeqLayer, Sequencer};
// use panic_halt as _;
// use core::mem::MaybeUninit;
// use cortex_m_rt::entry;
// use embedded_hal::digital::v2::OutputPin;
// use pac::interrupt;
// use stm32f1xx_hal::gpio::*;
// use stm32f1xx_hal::{pac, prelude::*};
// // These two are owned by the ISR. main() may only access them during the initialization phase,
// // where the interrupt is not yet enabled (i.e. no concurrent accesses can occur).
// // After enabling the interrupt, main() may not have any references to these objects any more.
// // For the sake of minimalism, we do not use RTIC here, which would be the better way.
// static mut LED: MaybeUninit<stm32f1xx_hal::gpio::gpiob::PB9<Output<PushPull>>> =
// MaybeUninit::uninit();
// static mut INT_PIN: MaybeUninit<stm32f1xx_hal::gpio::gpioa::PA7<Input<PullDown>>> =
// MaybeUninit::uninit();
// #[interrupt]
// fn EXTI9_5() {
// let led = unsafe { &mut *LED.as_mut_ptr() };
// let int_pin = unsafe { &mut *INT_PIN.as_mut_ptr() };
// if int_pin.check_interrupt() {
// led.toggle().ok();
// // if we don't clear this bit, the ISR would trigger indefinitely
// int_pin.clear_interrupt_pending_bit();
// }
// }
// #[entry]
// fn main() -> ! {
// // initialization phase
// let p = pac::Peripherals::take().unwrap();
// let _cp = cortex_m::peripheral::Peripherals::take().unwrap();
// {
// // the scope ensures that the int_pin reference is dropped before the first ISR can be executed.
// let mut rcc = p.RCC.constrain();
// let mut gpioa = p.GPIOA.split(&mut rcc.apb2);
// let mut gpiob = p.GPIOB.split(&mut rcc.apb2);
// let mut afio = p.AFIO.constrain(&mut rcc.apb2);
// let led = unsafe { &mut *LED.as_mut_ptr() };
// *led = gpiob.pb9.into_push_pull_output(&mut gpiob.crh);
// let int_pin = unsafe { &mut *INT_PIN.as_mut_ptr() };
// *int_pin = gpioa.pa7.into_pull_down_input(&mut gpioa.crl);
// int_pin.make_interrupt_source(&mut afio);
// int_pin.trigger_on_edge(&p.EXTI, Edge::RISING);
// int_pin.enable_interrupt(&p.EXTI);
// } // initialization ends here
// unsafe {
// pac::NVIC::unmask(pac::Interrupt::EXTI9_5);
// }
// loop {}
// }
//// The following code uses RTIC but doesn't work
// use panic_halt as _;

Loading…
Cancel
Save