I'm doing a project at work which involves multiple (more than 2!) raspberry pies (Model 3 B+) being able to talk to each other (talk to each other means being able to send data of the size of a string, so the size will be one or serveral bytes). My instructor wants this communication to be realized only via gpio pins. His idea is that all the raspberries gpio pins X are connected to each other, as well as all the gpio pins Y, and the gpio pins Z.
If one pi wants to send, it would tell the others on "channel X" that it is sending now, and then switch pin Y to OUTPUT Mode, while all the other pis would switcher their pins Y to INPUT Mode. Then the sending pi would begin encoding the signal in 0s and 1s and (with a little delay) set the output voltage of pin y to either 0 or 1 in order to transmit the signal. Between each bit, the the sending pi would just wait for time t.
Pin Z would be the ground pin.
The Idea was that the data transmission takes place on a very low speed, so that the receiving party can simply wait for time t, to know which gpio-value belongs to which bit.
My Question as somebody who hasn't done mutch with a pi before: Can this idea work out?
A follow up question to that: I read about serial communication in this answer which uses the UART pins, which can be used for one pi to be the sending, and the other one being the receiving end of the transmission line. It seemed to be a very easy-to-setup way of communication between 2 pis. Now my question is: Does serial communication work between more than 2 pis as well? With the rx pin of one of the pis being connected to BOTH of the tx pins of the other 2 ones, for example?