SPI with multiple shields/devices

Just to confirm the theory I'm working with here.

I've got a USB Host Shield Controller and an SD Card breakout board, both use SPI to communicate with the Arduino. The MISO, SCK and MOSI pins are special and shared on the Arduino board but the SS is just like any other regular digital pin. Therefore If I arbitarily put on the SS pin USB Host Shield on any unused digital pin and put the SD Card's SS pin on a seperate unused digital pin they should co-operate and work?

Also why is SS defined in two places for the USB library (USB_Host_Shield/Max3421e_constants.h at master · felis/USB_Host_Shield · GitHub)?

MAX_SS
and
SS_PIN

Therefore If I arbitarily put on the SS pin USB Host Shield on any unused digital pin and put the SD Card's SS pin on a seperate unused digital pin they should co-operate and work?

Yes, but you should switch off the first device before activiating the second as only one can be active at a time. Wrap the code for this in a function so it ca be reused easily.

e.g. void activate_SD() and void activate_USB()

robtillaart:
Yes, but you should switch off the first device before activiating the second as only one can be active at a time. Wrap the code for this in a function so it ca be reused easily.

e.g. void activate_SD() and void activate_USB()

Switch off? As in powering down and powering up the slave devices?
I thought all you needed to do to activate and deactivate a slave device would be to was toggle the SS port it is using...

Switch off? As in powering down and powering up the slave devices?
I thought all you needed to do to activate and deactivate a slave device would be to was toggle the SS port it is using...

Meaning the which ever Slave Select output pin is wired to a device, when it's set high the device ignores all activity on the clock and data lines, only when the unique slave select signal is set low will the device listen and respond to commands from the master. So switch off is probably not the best word to use, rather enable/disable or just what it's called in the SPI protocol, slave select.

Lefty