User avatar
rew
Posts: 435
Joined: Fri Aug 26, 2011 3:25 pm

Re: Raspberrypi expansion system.

Sun Jan 22, 2012 3:20 pm

I have designed an expansion system that fits perfectly on a raspberry pi.

I"ve made a little breakout board that breaks out all the serial busses of the raspberry pi GPIO connector.

It fits directly on the  GPIO connector, hanging over the top and left side of the rpi a bit. As an alternative, you can use male header on this board and use a flatcable to connect with the raspberry pi.

Next you can connect small expansion boards, as you require. Although the raspberry pi can output full-hd to a display, sometimes something simpler and cheaper is necessary. When a 16x2 (I"ll have to check if other sizes will work, but I think they will) character LCD is necessary, add the SPI_LCD module: 

Other modules already available are:

* spi_servos : Drives up to 6 servo motors.

* spi_6fets: drives up to 6 moderate loads. (up to 1A, to test: Will it hold out at 2A? But PCB traces and connectors may not be up to the job at > 10A total…)

* spi_3fets: drives up to 3 heavier loads. In theory up to 10A per channel. Again: We"ll have to check if the PCB can handle that….

Other modules planned are:

* spi_dio: digital input/outputs.

* spi_relay: Several relays. It should be possible to drive mains loads with this.

* spi_ssr: solid state relays. Same, different technology. Which one will have the higher load capacity I don"t know yet.

* spi_ir: recieve and send IR remote control signals.

* spi_temp: measure temperatures. Works with an lm35 (minus something to about 80 or 100 degrees). To check: If it gets reasonable performance with a type-k thermocouple.

* spi_opto_in: optocoupler inputs.

* spi_opto_out: optocoupler outputs.

* spi_ain: analog inputs.

* spi_buttons: several push buttons.

* spi_hbridge: An H-bridge. Possibly two. This allows driving of one or two motors (both directions) or a stepper.

If you have suggestions for other modules you may want to see, let me know.
Check out our raspberry pi addons: https://www.bitwizard.nl/shop/

paulie
Posts: 275
Joined: Thu Jan 19, 2012 6:51 pm

Re: Raspberrypi expansion system.

Sun Jan 22, 2012 3:45 pm

Very nice!
How many "devices" could you hang off this at once?
Would like lcd screen & serial I/o at same time, and ideally audio in/out too -might have to be usb soundcard.
Two suggestions are rs232, and a 2x10 pin connector for GPS modules (or whatever the manufacturers" current standard ) (i have a Jupiter 8 ,old but still works)
It has been my custom to use Xeyes

elaverick
Posts: 6
Joined: Mon Dec 12, 2011 3:31 pm

Re: Raspberrypi expansion system.

Sun Jan 22, 2012 4:46 pm

I really like this concept.  The Gertboard is an impressive bit of engineering (especially so early on) but I like the simplicity of this.

The spi_buttons has particular interest for me as I quite fancy trying to interface some button controls for an arcade machine style project.  How are you planning on having the buttons connected?  Ideally for my needs I'd like to see a set of screw terminals and then be able to provide my own button controls into these.  Also how many buttons would this support? For a full arcade setup for single player you'd probably be looking at 12 buttons in total (4 micro switches for the joysticks, 6 buttons, 1 start button, 1 credit button), would this be feasible or would I be better looking at a more traditional USB solution?  (Dunno why I just much prefer the idea of directly interfacing the controls to the Pi)

Lynbarn
Posts: 464
Joined: Wed Jan 04, 2012 11:03 pm
Contact: Website

Re: Raspberrypi expansion system.

Sun Jan 22, 2012 5:14 pm

rew said:


I have designed an expansion system that fits perfectly on a raspberry pi.

I"ve made a little breakout board that breaks out all the serial busses of the raspberry pi GPIO connector.

It fits directly on the  GPIO connector, hanging over the top and left side of the rpi a bit. As an alternative, you can use male header on this board and use a flatcable to connect with the raspberry pi.

...
If you have suggestions for other modules you may want to see, let me know.



Great start, but I have a few points: The production 'Pis (is that batch baking?) will not have the headers populated. There has been discussion elsewhere about whether they should be Male or Female. It would help if there was some form of recommendation from The Foundation, so that the majority of 'Pis would be compatible.

Also, is there a need for the expansion board to hang over a bit? To ensure it fitted inside one of the many cases being designed, surely it would be better to make it fit inside the envelope of the Raspberry Pi board when plugged in directly to the GPIO pins (or sockets) rather than needing a ribbon cable?

Thirdly, are the additional boards stackable, do they have through connectors?

Additional modules: how about a battery-backed RTC?

User avatar
psergiu
Posts: 224
Joined: Mon Nov 07, 2011 8:36 am
Location: TX, U.S.A. (was: RO, E.U.)
Contact: Website

Re: Raspberrypi expansion system.

Sun Jan 22, 2012 5:37 pm

Lynbarn said:





Additional modules: how about a battery-backed RTC?


I second this - a battery-backed RTC + UART pins on a board that does not overhang over the RPi sides and is as low profile as possible will be the most requested board by anyone wanting to use the RPi as a network device.

It would be very nice if it can be stacked below the RPi so if the foundation releases the CSI camera add-on you could make a el-cheapo IP-Cam / Video recording device who can save correct timestamps over the video stream without a NTP server available. Just sell them without the 1.27" headers soldered - anyone can solder them as they wish.

Also - all 10 boards sold on eBay had male headers soldered on, so we can consider this being the standard unless the Foundations says otherwise.

User avatar
rew
Posts: 435
Joined: Fri Aug 26, 2011 3:25 pm

Re: Raspberrypi expansion system.

Sun Jan 22, 2012 6:18 pm


How many "devices" could you hang off this at once?


Current implementation is similar to I2C: one byte for addressing, which includes a bit for read/write. So 128.

You'll have a power distribution problem before that I guess.

If you want you can modify the software  a bit to use 2 byte adresses....

I don't know if we can achieve enough speed to do audio in/out. Moreover, about $2 will get you an USB audio in/out module (from china with shipping on ebay), so with the raspberry pi as master audio in/out is not neccessary. For RS232 the same argument holds.


.... Buttons .....


I was planning about 4 buttons per board. I was planning on putting the microswitches on the board, but providing headers as well. The boards are cheap as long as I keep them small. So big things like screw terminals have to be a bit limited.

If you need 12 buttons, you might get 2 boards "digital IO". With the pullups enabled, these are great for button input.


Also, is there a need for the expansion board to hang over a bit? To ensure it fitted inside one of the many cases being designed, surely it would be better to make it fit inside the envelope of the Raspberry Pi board when plugged in directly to the GPIO pins (or sockets) rather than needing a ribbon cable?


Yes and no... I would have preferred to have the connector completely at the other end of the board. Then the board would have overlapped completely with the RPI. However, I think my board would then bump into the composite out connector which is quite high.

As I don't have an RPI yet, I have to keep some margins, to allow me to hope that it will work "first time". Improvements later on.

If someone is going to make a case, they will make the bare RPI fit. Any additions won't fit an "off the shelf RPI box".


.... are they stackable .....


Yes, they have through-connectors. First you can clamp on multiple connectors on a single cable. If you don't want that, you have a second SPI connector on each board. On the other hand, if you're not using the stock software on the embedded processor on the board, you might be wanting to reprogram that. One of the SPI connectors becomes the ICSP programming connector if you flip the solder jumper....

I realised just recently: The rpi_serial board has two SPI buses. This means that  you can connect both to a single board configured to allow ICSP programming on the second connector. Now the RPI becomes a programmer for the board as well. Software still has to be written to enable that.... One of these days....

If you're going to have to solder the GPIO pins onto the RPI anyway, I can deliver the boards with two sets of male headers, and a set of female headers. Use both male headers and a "bring your own" cable, or connect the female to the male in any position you like (RPI on top/rpi_serial on top, with male/female headers on the RPI....)

I'll look into the RTC thingy. Any good reason you don't expect to have NTP connectivity?
Check out our raspberry pi addons: https://www.bitwizard.nl/shop/

jwatte
Posts: 203
Joined: Sat Aug 13, 2011 7:28 pm

Re: Raspberrypi expansion system.

Mon Jan 23, 2012 4:47 am

I see two or three things missing from the RasPi "attachment" space right now:

1) A mechanical specification for how it's "supposed" to be. If I want to attach more than one thing, some kind of daisy-chaining must be supported. But how? Do I put females on the bottom, with very tall pins to serve as males on the top? Do I route kitty-korner on the board, so each board is 180 degrees off from the previous? What's the suggested set-off distance? How should a case opening be shaped to account for the GPIO?

2) A software specification for how to share. Some things will want to use GPIO. Some things will want to use serial busses that share those pins. Some things will want to use particular chip select pins and SPI. Some way needs to be found to negotiate all these. Perhaps one way of doing it is to say that each expansion board rotates one step between the chip select and some GPIO pins, so it looks like pin N is in position 0 for the N-th expansion board? (This assumes SPI is the common bus)

The software could then enumerate from chip select 0 and up, sending a query of some standard sort on SPI, to ask each module what it is. Of course, that means you need a custom controller (AVR, PIC, etc) on each plug-in card, because most SPI peripherals do not have plug-and-play/dynamic discovery.

3) Actual boards to try this out with

User avatar
rew
Posts: 435
Joined: Fri Aug 26, 2011 3:25 pm

Re: Raspberrypi expansion system.

Mon Jan 23, 2012 6:36 am

Hi Jwatte,

The "rotating" trick is not useful for SPI. My board simply breaks out both of them to a 6-pin header. Use that if you need SPI.

The "rotating" of IOs would be a useful trick if there were a lot of them. However in fact only about 8 general purpose IOs are available on the GPIO connector. There are a bunch of DNC's, power, and special purpose pins (uart, I2C, SPI).
Check out our raspberry pi addons: https://www.bitwizard.nl/shop/

User avatar
psergiu
Posts: 224
Joined: Mon Nov 07, 2011 8:36 am
Location: TX, U.S.A. (was: RO, E.U.)
Contact: Website

Re: Raspberrypi expansion system.

Mon Jan 23, 2012 7:10 am

rew said:


I'll look into the RTC thingy. Any good reason you don't expect to have NTP connectivity?


Not every RPi will be connected trough ethernet to the great internet. Think solar & battery operated data loggers.

Even if it does have access to NTP: At every reboot Linux will start in January 1st 1970, it will create the wtmp & syslog entries as such then ntp will "jump" the clock 42 years into the future. "uptime" contests will be ruined

dukla2000
Posts: 190
Joined: Tue Jan 10, 2012 12:02 am
Location: Reading.UK.EU

Re: Raspberrypi expansion system.

Tue Jan 24, 2012 12:49 am

psergiu said:


Also – all 10 boards sold on eBay had male headers soldered on, so we can consider this being the standard unless the Foundations says otherwise.


They have already – Liz post on 22 December "The boards you see here differ in one small detail from what you’ll be buying: the GPIO pins here are soldered on so we can run tests to make sure that everything comes out where it should."

http://www.raspberrypi.org/arc.....te/2011/12

/EDIT/ - I see what you mean by standard - the GPIO on the RasPi should be male. But yup, I dont expect production boards to have anything populating that area so rew's suggestion to ship his board with an extra male header is good.
Daily driver: Pi3B, 64GB Samsung Evo+ @100MHz, DVB-T, onboard WiFi for internet, BT/USB dongle for KB/mouse, 250GB HDD via USB for media, Raspbian Jessie Lite with Openbox desktop.
Museum: Pi B

Return to “Other projects”