How to multiple use of pins 10, 50-52 of the Mega?

Hi, what can I do if I want to use two breakout boards both require pins 10, 50, 51 and 52 of the Arduino Mega?

Which breakout boards are you talking about?

You can wire breakout boards as you like. Shields instead often connect to specific pins.

If they both use the SPI interface (50-52 pins), then you wire these pins together. They are supposed to be all wired together. But you need another pin, such as pin 9 for the second break out board, as the pin 10 is mostly likely the chip_select pin and has to be wired individually. The second break-out board's code will have to change to use pin 9 instead of 10.

newto_arduino:
Hi, what can I do if I want to use two breakout boards both require pins 10, 50, 51 and 52 of the Arduino Mega?

These pins are used in SPI

You are allows to have multiple SPI devices sharing the same MISO(50), MOSI(51), and CLK(52) lines.
one Slave Select line specific for every device, so you have to change pin 10 for the second breakout board to other pin.

Thank you. Yes, they both use the SPI interface (50-52 pins). Both of them use pin 10 for chip_select. Actually, for chip_select, besides pin 9 will any other digital pin work if I just change the pin number in the software?

Most pins can be used as chip select pins. Just avoid pins with special functions, such as serial ports, I2C pins. Also try not use analog pins if you later have plans for more analog inputs. Arduino MEGA 2560 has plenty of digital pins that don't have other functions.