SunFounder Thales Kit for Raspberry Pi Pico, Release 1.0
1. Connect 3V3 and GND of Pico to the power bus of the breadboard.
2. Insert 74HC595 across the middle gap into the breadboard.
3. Connect the GP0 pin of Pico to the DS pin (pin 14) of 74HC595 with a jumper wire.
4. Connect the GP1 pin of Pico to the STcp pin (12-pin) of 74HC595.
5. Connect the GP2 pin of Pico to the SHcp pin (pin 11) of 74HC595.
6. Connect the VCC pin (16 pin) and MR pin (10 pin) on the 74HC595 to the positive power bus.
7. Connect the GND pin (8-pin) and CE pin (13-pin) on the 74HC595 to the negative power bus.
8. Insert the LED Segment Display into the breadboard, and connect a 220 resistor in series with the GND pin to
the negative power bus.
Note:
The color ring of the 220 ohm resistor is red, red, black, black and brown.
9. Follow the table below to connect the 74hc595 and LED Segment Display.
Table 1: Wiring
74HC595
LED Segment Display
Q0
a
Q1
b
Q2
c
Q3
d
Q4
e
Q5
f
Q6
g
Q7
dp
Code
import
machine
import
time
SEGCODE
=
[
0x3f
,
0x06
,
0x5b
,
0x4f
,
0x66
,
0x6d
,
0x7d
,
0x07
,
0x7f
,
0x6f
]
sdi
=
machine
.
Pin(
0
,machine
.
Pin
.
OUT)
rclk
=
machine
.
Pin(
1
,machine
.
Pin
.
OUT)
srclk
=
machine
.
Pin(
2
,machine
.
Pin
.
OUT)
def
hc595_shift
(dat):
rclk
.
low()
time
.
sleep_ms(
5
)
for
bit
in
range
(
7
,
-
1
,
-
1
):
srclk
.
low()
time
.
sleep_ms(
5
)
value
=
1
&
(dat
>>
bit)
sdi
.
value(value)
time
.
sleep_ms(
5
)
srclk
.
high()
time
.
sleep_ms(
5
)
time
.
sleep_ms(
5
)
(continues on next page)
3.4. Projects
99
Summary of Contents for Thales Kit
Page 1: ...SunFounder Thales Kit for Raspberry Pi Pico Release 1 0 Jimmy SunFounder Jun 04 2021 ...
Page 2: ......
Page 4: ...ii ...
Page 6: ...SunFounder Thales Kit for Raspberry Pi Pico Release 1 0 2 CONTENTS ...
Page 140: ...SunFounder Thales Kit for Raspberry Pi Pico Release 1 0 136 Chapter 3 For MicroPython User ...
Page 164: ...SunFounder Thales Kit for Raspberry Pi Pico Release 1 0 160 Chapter 4 For Arduino User ...