There is no support to switch the communication dynamically from SDIO to SPI. On the other hand the BCM43362 uses power up stripping to determine communication interface of either SDIO or SPI and this requires power reset of the BCM43362.
Yes, I agree to that , basically what my scenario is
1. While powering up , if a button is pressed use SDIO for Wi-Fi, else use SPI for Wi-Fi...
2. The Code should have the wwd_sdio / wwd_spi driver which would be used while powering up depending up on the button state. so wwd_sdio & wwd_spi has to be compiled along with the code.
Is there any way to do this?
Yes it can be done, we can compile both SPI and SDIO drivers and load them to the micro. Based on the GPIO input we can initialize either SPI or SDIO interface to communicate with Broadcom WiFi module.
But this use case ties up both peripherals, SDOI and SPI, on the MCU. There is a possibility to move one of the peripheral to a different port but so far there were no need.
Do you have a specific use case that this may be needed?
Okay,I think it's better to explain the scenario..
1. Our Custom board has 1 SDIO & 1 SPI interface ,
2. In normal scenario Wi-Fi SN8000x use SDIO and SPI will be used by SD card ,
3. If the board boots with a button being pressed (indicates both has been swapped , so Wi-Fi-> SPI & SD card -> SDIO),and mcu need to select/initialize driver accordingly.
4. And no other devicess will be using this SDIO & SPI
Hoe can I achieve this ? (Sorry I'm not much familiar with the Make files and stuff)
The code that controls the wifi interface is determined at compile time(not run time). You would need to write a lot of code in order to compile in both drivers and then select the right one depending on the GPIO.
I have a question....
If I use BUS = SDIO in the make file , does all the wifi communication with MCU and WiFi chip goes through the file wwd_sdio.c ? or is there any any other file do I have to check ?
Hi I did this integration of SPI+SDIO driver so that the Wifi module can be swapped between SDIO & SPI port. Need some merging in the SDIO SPI low level drivers and had to edit some bus protocol to achieve this.
If someone need this feature I can guide