cancel
Showing results for 
Search instead for 
Did you mean: 

Driving STP16DPPS05TTR shift register from STM32F4 for LEDs

cradoumis
Associate II
Posted on July 07, 2016 at 04:21

I am looking for some help on completing a schematic whereas I am driving several LEDs with a shift register.

I am having trouble finding where / how I should be connecting the CLK / SDI / LE/DM1, ~OE/~DM2 pins to the STM32F4. 

#!stm32f4 #!shift-register
3 REPLIES 3
Posted on July 07, 2016 at 07:53

In general, you can wire them up to any pin and bit-bang the serial stream; however, it's more convenient if you use hardware for the serial stream. You have two options - either you use one of the SPI thus connect data to respective MOSI and clock to respective SCK; or USART in synchronous mode, where you connect data to Tx and clock to CLK of the USART. The remaining two pins you can connect to any pin, they have to be driven as outputs ''manually'' anyway.

From the hardware point of view, you have to consider voltage level, pin drive capability (which is usually not an issue these days driving CMOS inputs) and proper ground return issues.

JW

cradoumis
Associate II
Posted on July 08, 2016 at 00:00

OK Thank you.

What I ended up doing was wiring

Pin 3 (CLK) to PB10

Pin 2 (SDI) to PB15

Pin 4 (LE) to PB1

Pin 21 (OE) to PB0

Does this sound right?

Posted on July 08, 2016 at 00:16

Pin 3 (CLK) to PB10

 

Pin 2 (SDI) to PB15

 

Pin 4 (LE) to PB1

 

Pin 21 (OE) to PB0

 

Does this sound right?

 

SPI2 at AF5 for the first two pins? Yes, sounds right.

JW