stm32 add SPI for stm32f4

This commit is contained in:
GeoffThomas
2020-03-22 10:28:47 -05:00
committed by Ron Evans
parent ac73430502
commit b4dddfe439
6 changed files with 217 additions and 93 deletions
+9 -1
View File
@@ -1,9 +1,17 @@
// +build !baremetal sam stm32,!stm32f407 fe310
// +build !baremetal sam stm32 fe310
package machine
import "errors"
// SPI phase and polarity configs CPOL and CPHA
const (
Mode0 = 0
Mode1 = 1
Mode2 = 2
Mode3 = 3
)
var (
ErrTxInvalidSliceSize = errors.New("SPI write and read slices must be same size")
)