HI
I'm using SPI connecting to mutiple max31856(two now) on nrf52DK and SDK15.3
so I control my ss pin to pull low by myself
chip select by changing spi_pin like some code below
void MAX31856_setThermocoupleType(max31856_thermocoupletype_t type ,uint32_t spi_pin)
{
nrf_gpio_pin_clear(spi_pin);
MAX31856_write_reg(MAX31856_CR1_REG);
uint8_t t = MAX31856_read_reg(0xFF);
nrf_gpio_pin_set(spi_pin);
t &= 0xF0; // mask off bottom 4 bits
t |= (uint8_t)type & 0x0F;
nrf_gpio_pin_clear(spi_pin);
MAX31856_write_reg(MAX31856_CR1_REG|0x80);
MAX31856_write_reg(t);
nrf_gpio_pin_set(spi_pin);
}
my miso is 5, mosi is 7 , sck is 8
and ss1 is 6 , ss2 is 9 at first
then i found that ss1 works fine ,but ss2 doesnt
SO I TRY OTHER PINS, AND FOUND THAT pin 2,3,4,6,12,13,14,15,18,19,20,22,23,24,26,27,28,29,30,31 can work
BUT pin 9,10,11,13,17,21,25 cant work
MY QUESTION is why that happened
thanks