The grove port (a.k.a. Port A) on the device supports three kind of units; I²2, GPIO and UART, but only one protocol at a time.
The unit protocols can be distinguished by their corresponding color:
Red for I2C (Inter-Integrated Circuit)
Black for GPIO (General Purpose Input/Output)
Blue for UART (Universal Asynchronous Receiver/Transmitter)
Although grove Port A can handle all three protocols for one connected unit,
it cannot handle multiple protocols on one port at once.
To combine multiple units we need to expand Port A.
To expand the ports of an Atom device we need the Port ABC base.
It will expand the device with an A (I2C), B (GPIO) and a C (UART) port.
The port ABC Base
Combining I2C units
Combining I2C units does not require expanding port A.
Every I2C unit has an unique hardware address which allows the controller to distuingish the data from different units.
I2C units with different hardware addresses can be daisy-chained with an Hub unit.
Hub Unit
The hub unit does not require any additional codeblocks.
Units with the same hardware address (similar units, e.g. three Ultrasonic units) cannot be daisy chained with a Hub unit.
For this purpose we need a so-called I2C multiplexer or PaHub.
PaHub unit
The PaHub requires additional code and must be added to UIFlow2 blocks as a unit.
The units port setting needs to be changed to the PaHub and the corresponding port number on the PaHub.
PaHub Port + unit configuration