Closed bockha closed 6 years ago
dotstar.c
@@ -257,11 +257,11 @@ static int boardType(void) {
// Initialize pins/SPI for output
static PyObject *begin(DotStarObject *self) {
if(self->dataPin == 0xFF) { // Use hardware SPI
- if((self->fd = open("/dev/spidev0.0", O_RDWR)) < 0) {
- printf("Can't open /dev/spidev0.0 (try 'sudo')\n");
+ if((self->fd = open("/dev/spidev0.1", O_RDWR)) < 0) {
+ printf("Can't open /dev/spidev0.1 (try 'sudo')\n");
return NULL;
}
- uint8_t mode = SPI_MODE_0 | SPI_NO_CS;
+ uint8_t mode = SPI_MODE_0 ; // | SPI_NO_CS;
ioctl(self->fd, SPI_IOC_WR_MODE, &mode);
// The actual data rate may be less than requested.
// Hardware SPI speed is a function of the system core
This issue was moved to IUNO-TDM/MixerControl#101
SPI1 with CE1 (GPIO17) is used in future revision of motorshield
This issue was moved to IUNO-TDM/MixerControl#116
Modify the dotstar.so to use spi0.1 with chip select according to #3.