public AD5206() { config = new SPI.Configuration((Cpu.Pin)Pins.GPIO_PIN_19, false, 0, 0, false, true, 1000, SPI.SPI_module.SPI1); SPI1 = new SPI(config); }
and send a value like this:
public void SendAddressValue(int potAddress, int potValue) { tx_data[0] = (byte)potAddress;//digipot address (0 through 5) tx_data[1] = (byte)potValue;//value to put pot (0 through 255) SPI1.Write(tx_data); }
Pin 19 works but using the same code and just changing the pin to GPIO_PIN_13 shows no Enable pin activity even though I can see activity on the CLOCK and MOSI pins. Can pin 13 not be used as the SPI Enable pin for some reason? Do I have to use just the PWM pins? Thanks!