November 23, 2024, 01:43:48 AM

more than 1 module an uext port

Started by marcpaul, November 14, 2013, 07:26:31 PM

Previous topic - Next topic

marcpaul

hey again...

yes there are posts about connecting more than 1 module to uext port but... well...

is there some general rule what i can connect or how many modules i can connect?

i tried the mod-bt and mod-lcd3310 and it wasn't working... or must i change my code to use more than 1 module?

each one alone is working fine...

ok thanks again :)

marc

LubOlimex

Hey marc,

The UEXT has three communication interfaces in it, each using different pins of the UEXT connector - RS232, I2C and SPI.

The most important thing for connecting a module on software level is to identify what interface the module uses! Some modules use I2C, some RS232, some SPI. Once you have identified the interface that you need to be aware that you can't have two SPI modules on a single SPI line, nor two RS232 modules on single RS232 line! Only with the I2C it is possible to have a lot of devices on a single I2C line. Of course, there is no problem to have an RS232 module and an SPI module and number of I2C modules connected at the same time.

The hardware connection is most of the times simple -> plug the UEXT connector - but it might require custom hardware or wire cutting if you want to use more than one module on a single UEXT connector. I also recommend you to take a look at the UEXTx5 splitter:https://www.olimex.com/Products/Modules/Interface/UEXTx5/. Note that if you take 3.3V power from the UEXT of your control board it might provide insufficient for a large number of extension modules.

For your specific case you should be able to use MOD-BT and MOD-LCD3310 simultaneously on the same UEXT since MOD-BT uses RS232 and MOD-LCD3310 uses a modified SPI (the MOD-LCD3310 uses additional pins taking the I2C for display control). The software code you need should handle both RS232 (RX/TX) and this modified SPI communication.

Best regards,
Lub/OLIMEX
Technical support and documentation manager at Olimex

marcpaul

hey thank you for your detailed answer :)

yes i have one of those UEXTx5 splitter :D

ok hmmm when i connect both modules to the splitter the lcd is working fine but i can't get a bluetooth connection...
when i disconnect the lcd and of course comment the includes bluetooth is working fine...

should i use the gpio lcd version or spi? tested both but mainly i used the gpio...

well... trial and error :)

have a nice day

marc

LubOlimex

Hey again,

Better use the SPI version of the example ;)

Can you check if you have R4, R5, R7, R9, R10 mounted on the board? You might need to remove those if you aren't aiming for full UART (just RX and TX are needed for data communication with MOD-BT). We actually don't populate those resistors in the last MOD-BT revision. Only CTS signal remains (pin 7 of the connector for MOD-BT)! Be careful with CTS (Clear To Send)! It might disable the whole BT communication if it is sending is not enabled by CTS.

Best regards,
Lub/OLIMEX
Technical support and documentation manager at Olimex

marcpaul

YES

it's working... i connected only the pins necessary for the mod-bt like you said and voila....

niceeee

i read in the philips manual that only rx/tx are used but i thought the other pins are kind of dead and doesn't interfere with other stuff....

well thank you very much...
:D