Wednesdays: SimpleBot for LCA 2015 Open Hardware MiniConf

61 views
Skip to first unread message

Angus Gratton

unread,
Nov 18, 2014, 11:43:00 PM11/18/14
to CCHS
Hi everyone,

As many folks know, CCHS has been involved in preparing the projects
for previous Arduino MiniConfs at LCA. In January 2015 the Arduino
MiniConf is growing up into an Open Hardware MiniConf[1], but there's
still a half-day build project involved.

This year the project is going to be the latest revision of the
SimpleBot[2] designed by Andrew Fisher for NodeBots AU days. He's been
updating the SimpleBot chassis to mount a Raspberry Pi Model B+, so
the high-level computation (node.js or anything else you fancy) can
happen on board the SimpleBot.

On top of the Model B+ will be a Freetronics PiLeven[3]. This is an
Arduino Uno compatible board in a Raspberry Pi form factor. On top of
that there's going to be a custom "SimpleBot Shield"[4] to break out
sensors (ultrasonic distance, LDR) and "motors" (continuous rotation
servos), as well as any other customisations people want to make. The
shield will also feature an addressable RGB LED on each corner,
because (to quote Andy G) "you have to have bling".

So far the development has been pretty informal between Jon, Andy G,
Andrew F & myself, with Alec providing some Raspberry Pi setup
expertise.

However it'd be great to have any other interested CCHS members
involved as well - if you're interested in building a "beta" robot,
testing out some ideas, or otherwise contributing. The SimpleBots are
a great low cost base, and there's a lot of directions you could take
one.

We've been meeting up to talk SimpleBots on Wednesday evenings. I
realise this is pretty late notice for tonight, but if you're
interested it'd be great to see you either tonight or next week - or
just post here on the mailing list.

Oh, and definitely consider attending Linux Conf in Auckland this
January[5], as well! Lots of good reasons to come.

Angus

[1] http://www.openhardwareconf.org/index.php/Main_Page
[2] https://github.com/nodebotsau/simplebot
[3] http://freetronics.com/pileven
[4] http://github.com/freetronics/simplebot_shield
[5] http://lca2015.linux.org.au/
[6] -ERRTOOMANYFOOTNOTES

Andy Gelme

unread,
Nov 18, 2014, 11:48:37 PM11/18/14
to connected-commu...@googlegroups.com
hi All,

On 2014-11-19 15:44 , Angus Gratton wrote:
> The shield will also feature an addressable RGB LED on each corner,
> because (to quote Andy G) "you have to have bling".

... and robot status and inter-robot identification.

It'll be interesting to see if unique blinking LED patterns can be
distinguished using the LDR ... or blinking colour patterns using a Pixy.

--
-O- cheers = /\ /\/ /) `/ =
--O -- http://www.geekscape.org --
OOO -- an...@geekscape.org -- http://twitter.com/geekscape --

Angus Gratton

unread,
Nov 18, 2014, 11:54:25 PM11/18/14
to connected-commu...@googlegroups.com
On Wed, Nov 19, 2014 at 03:48:31PM +1100, Andy Gelme wrote:
> On 2014-11-19 15:44 , Angus Gratton wrote:
> > The shield will also feature an addressable RGB LED on each corner,
> > because (to quote Andy G) "you have to have bling".
>
> ... and robot status and inter-robot identification.
>
> It'll be interesting to see if unique blinking LED patterns can be
> distinguished using the LDR ... or blinking colour patterns using a Pixy.

Yes, absolutely, the RGB LEDs are a great idea with heaps of
applications. They're also likely to help with simple identification
when 30 robots all come up on the Wifi at once. :)


Angus

Roboticist Mark

unread,
Nov 19, 2014, 5:02:30 AM11/19/14
to connected-commu...@googlegroups.com
I'm in,

I've been looking for a project to use my B+ in/on

when's the next order for freetronics parts ? and how many boards are you putting together Angus ?

Mark

Luke Weston

unread,
Nov 19, 2014, 7:05:46 AM11/19/14
to connected-commu...@googlegroups.com
Hi Angus,

It looks good. :)

What are you planning with regards to the power supply?
I would probably use either a 2S LiPo pack (7.4V nom.) or a 6-pack AA
holder (9V nom.)
It will be worth measuring the current consumption of the complete
active hardware stack (Raspberry, plus WiFi, plus PiLeven, plus
SimpleBot shield and motors running) to ensure that there's sufficient
charge capacity for good user experience, i.e. not recharging it every
5 minutes.

It's probably worth putting a terminal block on the SimpleBot shield
to connect the battery up to Vin. (add an appropriate protective fuse
or PPTC in series, especially a good idea if high-energy-density
batteries such as LiPos are used.) And add a power switch on board,
and/or power LED? If the SimpleBot Shield is on the top of the stack
then it will be easiest to see/access those parts there rather than on
a lower board. (The WS2812s can arguably function as a power LED, but
it can be nice to know that the power supply is online without any
dependence on the state of the microcontroller/software, for
fault-finding purposes.)

With power supplied to the SimpleBot shield, the SBS will supply
unregulated Vin to the PiLeven, and the PiLeven will supply its 5V
rail back to the SBS (as well as the 5V rail into the Raspberry). (You
could plug the battery supply into the PiLeven if you wanted to, but
this adds the extra construction step of making a battery cable with a
2.1mm barrel plug on it, and putting screw terminals on the SBS avoids
this.)

I would probably replace the 7806 regulator with a low-dropout
regulator, because an ordinary 7806 with relatively high dropout
voltage won't work with a 7.2V-7.4V rechargeable battery pack (2S) and
that seems like a good power option to support, avoiding the size/cost
increase of going up to a 3S battery pack. The buck converter on the
PiLeven will already be happy with 7V.

On the SBS board layout, can C5 and C6 be physically moved closer to
the regulator? They seem to be a fair distance away and they don't
need to be?

It's a shame that the PiLeven doesn't have the full 40-pin GPIO header
on it, and the identifier EEPROM (as per the Raspberry Pi HAT
specification). That might have come in handy for smart
identification/provisioning of the peripheral hardware connected to
the Raspberry Pi. I wonder if it can be hacked up a bit by putting the
EEPROM onto a little daughterboard with a 2-pin DuPont-style connector
that plugs into the unused I2C ID EEPROM pins at the end of the
Raspberry's IO header?

I would change C5 and C6 on the SBS to both be either 25V or 16V, both
the same not one of each. This makes for better part sourcing
logistics, cheaper and easier, and it's also easier for beginners
assembling the kit when there's more commonality in the components, if
they have to solder those ones themselves.

I'd like to consider the possible use case of connecting the SBS to a
couple of external motor drivers for driving a pair of powerful DC
motors on a bigger robot - so you'd probably have 4 signal lines plus
ground - a TTL direction plus PWM signal, one pair for each motor
driver, or perhaps a protocol such as I2C. But I think this is already
covered, there are already plenty of spare 'hackable' I/O pins on the
SBS, including I2C - but anyway it's something worth thinking about.

Another possible modification/hacking use case I would be thinking
about would be removing the Raspberry Pi to reduce cost - I'd maybe
remove the Raspberry Pi, remove the PiLeven, replace the PiLeven with
an Eleven or similar Uno-compatible, and then I'd be looking at using
spare digital pins on the Arduino (D0/D1 UART, or SPI or something) to
talk to a wireless communications link - another module that could
communicate over Bluetooth, Bluetooth Low Energy, 802.11 or 802.15.4
etc, which could potentially reduce cost and power consumption (if
802.11 used) compared to the Raspberry Pi plus Pi WiFi module - or in
the case of Bluetooth LE you're adding an extra form of connectivity
potential that you don't already have, as well as reducing cost and
power. (Well, I suppose you could add a USB dongle to the Raspberry
based system to add Bluetooth if you wanted to.) To accommodate this I
would consider adding a 4-pin breakout header on the SBS that has 5V,
ground and D0/D1.
> --
> You received this message because you are subscribed to the Google Groups "Connected Community HackerSpace" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to connected-community-h...@googlegroups.com.
> To post to this group, send an email to connected-commu...@googlegroups.com.
> To view this discussion on the web, visit https://groups.google.com/d/msgid/connected-community-hackerspace/20141119044419.GA24419%40ex2.lan.
> For more options, visit https://groups.google.com/d/optout.



--
This email is intended only for the personal and confidential use of
the human(s) named above. If intercepted by an extraterrestrial
civilization, all opinions expressed in this email are my own and do
not necessarily reflect the opinion of mankind as a whole.

Angus Gratton

unread,
Nov 19, 2014, 4:13:59 PM11/19/14
to connected-commu...@googlegroups.com
On Wed, Nov 19, 2014 at 02:02:30AM -0800, Roboticist Mark wrote:
> I'm in,
>
> I've been looking for a project to use my B+ in/on
>
> when's the next order for freetronics parts ? and how many boards are you
> putting together Angus ?

Hi Mark,

Yay! Sounds great. Getting involved is a bit DIY at the
moment. There's a small stack of bits you will need:

- 1x Raspberry Pi B+ (Model B will do in a pinch).

- 1x USB Wifi adapter. If you don't have one lying around then the
space has some they can sell you - I'm not exactly what the price is
or how you buy them, perhaps someone else can explain.

- 1x PiLeven. You can get this from Freetronics by mail or Tronixlabs
will deliver one to the space for free (thanks John!)

- 1x SimpleBot Shield PCB. These are on order at the moment, when they
get here I will have spares so I can give you one (same offer
extended to other members who want to build beta robots ahead of the
conf).

- 1x Ultrasonic rangefinder SR04 (or similar) - Tronixlabs has these
http://tronixlabs.com/sensors/distance/ultrasonic/ultrasonic-distance-sensor-module-hr-sco4-2-450-cm/

- 2x Continuous rotation servos. Tronixlabs has these that look quite good:
http://tronixlabs.com/nodebots/continuous-360-degree-rotation-servo-sm-s4303r/
or there are cheaper models online if you have time:
http://www.aliexpress.com/item/Freeship-5x-360-degree-Continuous-Rotation-Servos-DC-Gear-Motor-Smart-Car-Robot-4kg-cm-DC/725050285.html
or hobbyking, etc.

- 6xAA battery holder, 7806 linear regulator in TO-220 package - Jaycar

- Inline male headers, LDR, reset button - there should be spares of
these things lying around so you can grab some from us.

- CoreFlute chassis base. Andrew Fisher is the person to ask for help
lasercutting this. The new design is (I think) finalised as of last
night, so there will be plenty of CoreFlute lasercutting in the
coming weeks.

I think that's everything, at least for a base simplebot.


... in the next month we'll be placing bulk orders for these things
for the MiniConf so we might be able to squeeze people on to those
orders, but at the moment we're all more or less putting our own bits
together in ones and twos - and that's what I'd recommend as well for
now, as the bulk stuff might be arriving "just in time" (and the bulk
savings aren't massive I don't think).

Cheers,


Angus

Angus Gratton

unread,
Nov 19, 2014, 6:02:54 PM11/19/14
to connected-commu...@googlegroups.com
Hi Luke,

On Wed, Nov 19, 2014 at 11:05:43PM +1100, Luke Weston wrote:
> It looks good. :)

Thanks. :)

> What are you planning with regards to the power supply?
> I would probably use either a 2S LiPo pack (7.4V nom.) or a 6-pack AA
> holder (9V nom.)

Yes, good suggestions. These options got discussed, and we also talked
about using a 5V "power bank" USB phone charger, as these are really
cheap.

The current plan is 6-pack AA.

The major downside others pointed out for the 2S pack is that you need
a specialised LiPo multicell charger, and not a lot of people have
those.

> It will be worth measuring the current consumption of the complete
> active hardware stack (Raspberry, plus WiFi, plus PiLeven, plus
> SimpleBot shield and motors running) to ensure that there's sufficient
> charge capacity for good user experience, i.e. not recharging it every
> 5 minutes.

Yes, I actually got a sample of the wifi adapter we want to use on
Monday so I ran a test that night running everything but the motors.

This was with cheap ALDI alkaline batteries because the other unknown
factor is actual alkaline battery capacity. A test program ran that
kept the wifi alive and polled the Firmata instance on the PiLeven,
which was also monitoring voltages. That setup ran for almost 8 hours,
there's a graph here:
http://i.imgur.com/EU0gxzS.png

(According to the PiLeven design the regulator should have cut out at
a slightly higher voltage than it did, about 5.8V, but it was a pretty
good result anyhow).

Current draw running that setup is a bit less than 330mA @ 5V. On the
input side I measured 250mA from 7.2V and 285mA from 6V.

The servos will add about 100mA (combined) when idling, 200mA when
driving and 500mA at stall. Because they're driven from the less
efficient linear 6V reg this might halve the battery life, but I think
close to 4 hours is still OK from Alkaline cells (should be longer
from NiMH rechargeables).

> It's probably worth putting a terminal block on the SimpleBot shield
> to connect the battery up to Vin. (add an appropriate protective fuse
> or PPTC in series, especially a good idea if high-energy-density
> batteries such as LiPos are used.) And add a power switch on board,

Good suggestion. We've gone with a DC jack into the PiLeven DC
In. Although (as you also pointed out) this is an extra construction
step, it has the advantage of being already polarity protected. I also
found some nice cheap screw-terminal-to-2.1mm adapters so we might use
those to save fiddly soldering.

A power switch is a bit interesting, because cutting the power
suddenly on Raspberry Pis has a habit of corrupting their SD
cards. Unplugging the battery pack should be a reasonable compromise,
and it's less inviting to just cut power on impulse.

> and/or power LED? If the SimpleBot Shield is on the top of the stack
> then it will be easiest to see/access those parts there rather than on
> a lower board. (The WS2812s can arguably function as a power LED, but
> it can be nice to know that the power supply is online without any
> dependence on the state of the microcontroller/software, for
> fault-finding purposes.)

The power LED on the B+ kind of sticks out on the end at the bottom,
so that's OK for that. It's always nice to have more LEDs though I
guess!


> I would probably replace the 7806 regulator with a low-dropout
> regulator, because an ordinary 7806 with relatively high dropout
> voltage won't work with a 7.2V-7.4V rechargeable battery pack (2S) and
> that seems like a good power option to support, avoiding the size/cost
> increase of going up to a 3S battery pack. The buck converter on the
> PiLeven will already be happy with 7V.

Good suggestion. The determining factors for the reg were cost and
(through)holiness.

I'm kind of hoping that even though dropout on a 7806 is typical 2V @
1A, it'll be a lot less at the ~250mA of useful current we care about. I haven't seen an actual graph for this though, so maybe it's a bad assumption - I wil test it.

If the dropout is no good, these look they might be OK as an
alternative (0.4V @ 500mA, about twice the cost)
http://www.digikey.com.au/product-detail/en/LF60ABV/497-7316-5-ND/1038562

If you know of any other throughhole 6V LDOs that are also cheap, it'd
be great to have alternatives. :)


> On the SBS board layout, can C5 and C6 be physically moved closer to
> the regulator? They seem to be a fair distance away and they don't
> need to be?

It's not apparent on the board layout, only on a "comment" layer in
Kicad, but the spacing there is for a TO-220 heatsink. I calculated
that at stall current the regulator will get pretty hot, and didn't
want someone driving their robot into a wall for 5 minutes and then
picking it up.

C5 & C6 are standard cheap bulk electrolytics (ie bad ESR) so any
extra impedance from long traces is probably a minor factor. The 6V
rail only drives servos so I didn't add any other bypassing. Maybe
this will prove to be a mistake, I don't know!

> It's a shame that the PiLeven doesn't have the full 40-pin GPIO header
> on it, and the identifier EEPROM (as per the Raspberry Pi HAT
> specification). That might have come in handy for smart
> identification/provisioning of the peripheral hardware connected to
> the Raspberry Pi. I wonder if it can be hacked up a bit by putting the
> EEPROM onto a little daughterboard with a 2-pin DuPont-style connector
> that plugs into the unused I2C ID EEPROM pins at the end of the
> Raspberry's IO header?

This could be done. It's a bit funny though, there's actually not a
whole lot that the I2C EEPROM can do for the PiLeven config. It can
setup the RTS GPIO pin, that we use for auto-reset, but there's a
bunch of other minor config that has to happen in Linux regardless
(disabling serial console, disabling getty) - and as far as I know
it's not possible to do anything in userland via the HAT config
EEPROM.

That said, the shorter header is really only because the PiLeven
design predated the B+ release by a few weeks. Probably something that
can be changed in a future revision.

> I would change C5 and C6 on the SBS to both be either 25V or 16V, both
> the same not one of each. This makes for better part sourcing
> logistics, cheaper and easier, and it's also easier for beginners
> assembling the kit when there's more commonality in the components, if
> they have to solder those ones themselves.

Good point. I planned to order them as identical 25V capacitors
anyhow, but I see it's confusing having different ratings on the
schematic.

> I'd like to consider the possible use case of connecting the SBS to a
> couple of external motor drivers for driving a pair of powerful DC
> motors on a bigger robot - so you'd probably have 4 signal lines plus
> ground - a TTL direction plus PWM signal, one pair for each motor
> driver, or perhaps a protocol such as I2C. But I think this is already
> covered, there are already plenty of spare 'hackable' I/O pins on the
> SBS, including I2C - but anyway it's something worth thinking about.

Yes, I reckon this would be a fun upgrade. :)

> Another possible modification/hacking use case I would be thinking
> about would be removing the Raspberry Pi to reduce cost - I'd maybe
> remove the Raspberry Pi, remove the PiLeven, replace the PiLeven with
> an Eleven or similar Uno-compatible, and then I'd be looking at using
> spare digital pins on the Arduino (D0/D1 UART, or SPI or something) to
> talk to a wireless communications link - another module that could
> communicate over Bluetooth, Bluetooth Low Energy, 802.11 or 802.15.4
> etc, which could potentially reduce cost and power consumption (if
> 802.11 used) compared to the Raspberry Pi plus Pi WiFi module - or in
> the case of Bluetooth LE you're adding an extra form of connectivity
> potential that you don't already have, as well as reducing cost and
> power. (Well, I suppose you could add a USB dongle to the Raspberry
> based system to add Bluetooth if you wanted to.) To accommodate this I
> would consider adding a 4-pin breakout header on the SBS that has 5V,
> ground and D0/D1.

Andy made this suggestion as well actually, he pointed as there's no
reason the Shield itself can't be used as you describe - similar to
the earlier SimpleBot revisions.

The catch is that when it's used on the PiLeven D0/D1 are taken and
not really available for other uses unless you cut jumpers on the
PiLeven itself and reorder things. So there's a tradeoff there.

In the end we settled on the 4 pin header that you see on the side of
the shield, with two data pins that can be used for software serial.

(To give the other side, the appeal of the Pi on there is people can
explore high level languages and high level processing stuff. I'm
hoping to have some image processing examples and encourage people to
bring webcams from home, so they can add higher level interaction
stuff).

Thanks for all this input, much appreciate the thoughtful feedback. :)


Angus

Roboticist Mark

unread,
Nov 19, 2014, 11:52:41 PM11/19/14
to connected-commu...@googlegroups.com
Hi Angus,

sounds good

I also have a huge amount of Corflute lying around to donate to the cause if needed

the servos which I bought recently are not continuous rotation ones :-(

oh well, another order with dx.com!

Mark

Angus Gratton

unread,
Nov 22, 2014, 3:39:24 AM11/22/14
to connected-commu...@googlegroups.com
On Thu, Nov 20, 2014 at 10:04:15AM +1100, Angus Gratton wrote:
> > I would probably replace the 7806 regulator with a low-dropout
> > regulator, because an ordinary 7806 with relatively high dropout
> > voltage won't work with a 7.2V-7.4V rechargeable battery pack (2S) and
> > that seems like a good power option to support, avoiding the size/cost
> > increase of going up to a 3S battery pack. The buck converter on the
> > PiLeven will already be happy with 7V.
>
> Good suggestion. The determining factors for the reg were cost and
> (through)holiness.
>
> I'm kind of hoping that even though dropout on a 7806 is typical 2V @
> 1A, it'll be a lot less at the ~250mA of useful current we care about. I haven't seen an actual graph for this though, so maybe it's a bad assumption - I wil test it.
>
> If the dropout is no good, these look they might be OK as an
> alternative (0.4V @ 500mA, about twice the cost)
> http://www.digikey.com.au/product-detail/en/LF60ABV/497-7316-5-ND/1038562

I threw together a test for this. As it happens I just received a
Arachnid Labs Reload:Pro OSHW programmable load, from a Kickstarter
campaign earlier in the year. This seemed like a perfect candidate to
plug that in and put it through its paces.

(Of course just after I set the test up I realised the ST LM78xx
datasheet has a curve on it that explains what I wanted to know, that
wasn't on the Fairchild datasheet I was originally reading. But
sometimes it's fun to test things anyhow.)

I ran a sweep from 0-1A current draw with several different input
voltages. For one set the reg had a big heatsink attached (and temps
stayed mild the whole time). For the other set there was no heatsink
(and the reg got too hot to touch).

Results:
http://i.imgur.com/b7iZEfI.png

So even with our expected lowish current draw it's confirmed we should
switch over to an LDO option as Luke suggested. Especially given how
quickly the alkaline batteries fall below 7.5V.

(The battery life graph, for comparison: http://i.imgur.com/b7iZEfI.png )


Angus

Bernd Wachs

unread,
Nov 22, 2014, 6:10:56 AM11/22/14
to connected-commu...@googlegroups.com
Hello,

I have had some experience with Low Drop Out Voltage regulators and below are some of my observations:

1) Specifications are usually for worst case conditions.
2) For normal voltage regulators regulation decreases quite a lot if running near bottom of limits.
3) Low voltage dropout regulators have a much quiescent current.
4) Higher frequency affect on regulators are quite more pronounced.
5) Different production batches of a device vary quite a bit in actual operation.
6) Power supply design, transformer, diodes, capacitor, cable length.. can have a large affect as well.


Regards
Bernd
> --
> You received this message because you are subscribed to the Google Groups "Connected Community HackerSpace" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to connected-community-h...@googlegroups.com.
> To post to this group, send an email to connected-commu...@googlegroups.com.
> To view this discussion on the web, visit https://groups.google.com/d/msgid/connected-community-hackerspace/20141122084045.GA7514%40ex2.lan.
Reply all
Reply to author
Forward
0 new messages