Page 1 of 1

Several modules simultaneously on GIPIO

Posted: Sat Jun 06, 2015 5:06 pm
by w_t
Hello,
how can I use multiple modules type, Accelerometer, GPS, ultrasound, using the usual pin GIPIO.

Re: Several modules simultaneously on GIPIO

Posted: Sat Jun 06, 2015 5:34 pm
by B.Goode
Just Do It!

What makes you think there is (or might be) a problem?

Simply be thoughtful and assign a different GPIO pin to each module or function, and take care to reflect those choices in your program or script.

Re: Several modules simultaneously on GIPIO

Posted: Sat Jun 06, 2015 7:22 pm
by w_t
So you're saying that I can use the new PIN as SCL and SDA in GIPIO where they are?

Re: Several modules simultaneously on GIPIO

Posted: Sat Jun 06, 2015 7:47 pm
by DougieLawson
w_t wrote:So you're saying that I can use the new PIN as SCL and SDA in GIPIO where they are?
CLK, MISO, MOSI & CS0 is one SPI bus, CLK, MISO, MOSI & CS1 is the other SPI bus. So you can run two SPI devices.

With I2C SCL, SDA is an addressable bus system each device gets a unique device address (some devices have A0, A1, A2 pins to control their bus address). So connecting more than one device to the bus is simple.

If you need more than two SPI devices you either have to drive your own CS pin or you have to bit-bang the whole protocol on four pins.

Re: Several modules simultaneously on GIPIO

Posted: Wed Jun 10, 2015 9:57 am
by Ritchie
Hello,
I have bought and tested a Velleman VM205 oscilloscope + logic analyzer add-on card.
It works fine for what I need it for.
I also have an ADAFRUIT 2.8" touchscreen for my Raspberry PI
I've tested this too and it works fine once you setup the Graphic interface to send the screensignal to the TFT in the correct(ed) resolution.
Now I want to combine both SPI devices on the same SPI-bus.
How do I do this please ? The spec's for the VM205 kit are here: http://www.velleman.eu ; search for: VM205
The intention is to make a full portable oscilloscope with these 2 .
The Velleman scope-kit only uses these pins : SPI_MOSI , SPI_MISO , SPI_SCLK , SPI_CE0 , GND , 3.3V , 5V
Many thanks for your help in advance !!! Ritchie

Re: Several modules simultaneously on GIPIO

Posted: Thu Jun 11, 2015 1:47 pm
by mikronauts
You cannot combine a third party SPI LCD with another third party card that uses the same SPI port.

- fbtft assumes that it is the only one using that SPI port
- the scope module would make the same assumption

It will not work.
Ritchie wrote:Hello,
I have bought and tested a Velleman VM205 oscilloscope + logic analyzer add-on card.
It works fine for what I need it for.
I also have an ADAFRUIT 2.8" touchscreen for my Raspberry PI
I've tested this too and it works fine once you setup the Graphic interface to send the screensignal to the TFT in the correct(ed) resolution.
Now I want to combine both SPI devices on the same SPI-bus.
How do I do this please ? The spec's for the VM205 kit are here: http://www.velleman.eu ; search for: VM205
The intention is to make a full portable oscilloscope with these 2 .
The Velleman scope-kit only uses these pins : SPI_MOSI , SPI_MISO , SPI_SCLK , SPI_CE0 , GND , 3.3V , 5V
Many thanks for your help in advance !!! Ritchie

Re: Several modules simultaneously on GIPIO

Posted: Thu Jul 16, 2015 7:00 am
by Ritchie
Hello Mikronauts,
Thanks for the reply.
Maybe it is possible using a PIRACK board to plug in both "extention" boards ?
Do you know this board ?
Have a nice day.
Ritchie
mikronauts wrote:You cannot combine a third party SPI LCD with another third party card that uses the same SPI port.

- fbtft assumes that it is the only one using that SPI port
- the scope module would make the same assumption

It will not work.
Ritchie wrote:Hello,
I have bought and tested a Velleman VM205 oscilloscope + logic analyzer add-on card.
It works fine for what I need it for.
I also have an ADAFRUIT 2.8" touchscreen for my Raspberry PI
I've tested this too and it works fine once you setup the Graphic interface to send the screensignal to the TFT in the correct(ed) resolution.
Now I want to combine both SPI devices on the same SPI-bus.
How do I do this please ? The spec's for the VM205 kit are here: http://www.velleman.eu ; search for: VM205
The intention is to make a full portable oscilloscope with these 2 .
The Velleman scope-kit only uses these pins : SPI_MOSI , SPI_MISO , SPI_SCLK , SPI_CE0 , GND , 3.3V , 5V
Many thanks for your help in advance !!! Ritchie

Re: Several modules simultaneously on GIPIO

Posted: Thu Jul 16, 2015 7:54 am
by joan
Both your devices use the main SPI peripheral. There may be two devices connected to that SPI bus, but to do so they must be assigned different slave select gpios.

I.e. if one uses SPI_CE0 the other must use SPI_CE1.

Only you can tell if that is achieveable with the kit you have bought.