Support for Wifi/spi and user spi

Does the Giantboard support a user SPI port if the WILC1000 Wifi Board is used through the SPI port. If so, are they the same SPI port or do I sacrifice one of the other SERCOM ports.
Overall is is possible to have 1xI2C, 2xSerial, 1xUser SPI, 1xWIFI SPI?

Hello, welcome. It is possible to have 2 spi devices on the same spi bus. You would need to add the other spi device to a custom device tree overlay and set a CS pin for the second device. I have some example device tree overlays here. You can mix and match overlays if done with care. If you get stuck I can put an overlay together for you.

Can you confirm if the following is possible:

  • Giantbaord Wifi featherwing (SPI0 + PB0/PB3/PD13+ PD20 as chip select)
  • User SPI0 using standard overlay and PWML1 as user Chip select
    (Note that one spi channel is Interrupt enabled and controlled by the kernel and
    the other is controlled by the user, so how do we prevent conflict)
  • I2C using PB31/PC0
  • Wakeup from ‘suspend to memory’ (I presume this is the ‘EN’ pin ?)
  • Console on PD2/PD3
  • Flexcom4 UART. Can this be converted to 3 wire with RTS enabled for
    use as RS485?)
  • Third serial port using URXD2/TXD2 pins PD23 and PD24.
  • A user IRQ line. How would this work

Also, can the wifi be put in low-power mode independently of the processor and how?
Thanks. Lachlan

Sorry that its taken me a little bit to respond, I needed to do some research and look over the datasheet.

Giantbaord Wifi featherwing (SPI0 + PB0/PB3/PD13+ PD20 as chip select)

Do you want PB0/PB3/PD13 and PD20 all to be CS pins?

User SPI0 using standard overlay and PWML1 as user Chip select
(Note that one spi channel is Interrupt enabled and controlled by the kernel and
the other is controlled by the user, so how do we prevent conflict)

I’ve used WiFi and Ethernet together on the same bus, both using an IRQ and never had an issue. It partly depends on if your devices are being read in real time and inturrption of that flow is detrimental. SPI over DMA I believe helps as the CPU just fills up the buffer when it can and the device can access that data when it needs it.

I2C using PB31/PC0

This overlay Enabled I2C on PB31/PC0

Wakeup from ‘suspend to memory’ (I presume this is the ‘EN’ pin ?)

Thats correct, the EN will restore the device from mem suspend.

Console on PD2/PD3

The console is enabled by default on these pins.

Flexcom4 UART. Can this be converted to 3 wire with RTS enabled for
use as RS485?)

I’ve never used RS485, but the kernel has some docs on setting it up in the device tree here

Third serial port using URXD2/TXD2 pins PD23 and PD24.

Should be possible, you’ll need to add another uart with a different name and register. Instead of uart2 it would be uart3 and the register could be @400 and the reg line inside the device needs to be reg = <0x400 0x200>; This is untested and might not work with these exact settings. I would have a look over the docs about flexcom here.

A user IRQ line. How would this work

I never used an IRQ from userspace, not sure how you would go about that. I’m not sure if the kernel supports such a thing.