Browsing Posts tagged generators

Oh, we happy, happy few. 09/03/13

Last night, the weather for the next few days was set to be awful, and for today, at least, it really was awful.

BUT, this didn’t bother us!

I mentioned last post that I’d get some photos of the inside of the top wooden shed, and today there was loads happening in it, so I’ve got the photos.Eating in the shed!

But in all the excitement, I’m getting a little ahead of myself here.

This morning, Jon very kindly gave me and the ‘Box’ for TradeBase a lift over to The Plots, and we arrived well before 10.00.  While Jon went down to his own plot, I opened up the sheds and got the trusty Kelly Kettle out for the first brew of many.

I set up the Box and wired up a few lights in the top shed, then Ian arrived, soon to be followed by Gary.

Gary had been threatening to replant the saddest of all sad pear trees from a horribly tiny little pot into a bed just cleared on the Orchard Plot, and you can see it in its new home here.New home for the pear tree

The light brown ‘dust’ you can see in this photo is the blood and bone meal fertilizer that he spread on the ground after planting.  Of course, he put a good few trowel fulls in the hole he’d dug for the tree.  As this is ‘slow release’ fertilizer, it should give the tree plenty of food for at least a season, possibly longer.

Meanwhile, Ian found a wicked-looking billhook with which to attack the huge honeysuckle that has been threatening to take over one of the top Plots for years.  Gary soon joined him, and the pair of them spent well over an hour carefully hacking away to remove a couple of vast brambles and some well-dead rose bushes.

The result?  Check this out:-Honeysuckle no more!

Don’t worry, though.  Ian and Gary have four or five ‘runners’ that it had sent out, and these are now safely, temporarily healed in in a spare bed nearby.  Yes, I know it looks like this area has been devastated, but give it a couple of months and some sunshine, and this will be back to a much more manageable size, and as I said, we’ve got those runners to plant along some chestnut paling further down near the greenhouse.

As promised, Matt had brought one of his fabled stews today, so we thought we’d all properly eat up in the top shed where we’re meant to eat.  This is rather than shivering out on the benches getting slowly drenched by the ever-present drizzle.

Sara had bought some fresh bread, so as you can see by the first photo, after a hard day’s grafting, we enjoyed a proper meal, all sat round a table, inside whilst listening to Classic FM on the radio.

I’d also moved the gas bottle and regulator over from the metal shed, so for the first time in forever, we had a gentle heat in there to keep us warm.  Just how civilised is that?

Afterwards, over the inevitable cup of Plot Tea, Sara commented that all we really needed were duvets and pillows, and we could have a sleep-over.  Well, we had everything else, even a cat!

All too soon, it was time to call it quits for the day, but not before we’d found every tool we’d used outside, put everything away, and I’ve brought the dishes home to give them all a good washing.

Still, having said that, even after all the tea and drinks we’ve had today, both of the vacuum flasks were still full of piping hot water.

More on Wednesday evening…

Second Box? Done! 02/02/13

Yes, yes, yes, I know, Dear Reader.  You’re about to faint.

But it is true.  The second box for TradeBase is actually finished.  What isn’t finished is the A-frame bit that the bike sits in.

But I will finish it, come Hell or high water.  It only needs the wheel sensor whacking on, and if I get a clear run at it (HA!), it’ll only take me a morning or an afternoon.

This second box now has much brighter LED’s than the original ‘demo’ box -bright enough to be easily visible even in direct sunshine.  And it only took another 16 transistors and 30 resistors on one board to achieve this.  Piece of cake!

Other news is that since Ian (no relation) gave me that little TV with the HDMI input socket, I’ve been ‘playing’ with the Raspberry Pi, and having a Big Lot of fun in the process.

I ordered a tiny little ‘wireless dongle’ for it -so I can use it on the Internet at home running wirelessly from my router. This really was a little swine to get going, and it took me a full half-day to get there, but it’s now working fine and very fast when you consider it’s a full computer the size of a credit card for less than £30.00.

“So what?” you quite rightly shout.

Ah, I actually plan to have a Pi down on The Plots in the top shed.  Because it’s so small, I can easily hide it away -probably behind somewhere or even under something, so any potential thieves won’t be able to find it.

I may take an old, empty PC case, and put that in there, complete with a couple of bricks in the bottom.  A scabby old 14″ CRT monitor (…which won’t work…), and a knackered keyboard and mouse will finish off my ‘stage set’.  If any thieves do break in, they see these, and take them.

I can imagine them picking up the empty PC case (…plus two bricks), and saying to each other;-

“Eh, Wayne!  Feel the weight of this!  Must cost a fortune, one of these!”

Ha!  Wait ’til they get it all home and try to plug it in.

Okay, an idle, but very fun thought…

Watch this space…

You must have caught the news recently?  There have been items about the new ‘Raspberry Pi’ single-board computer that the government is hoping to get into schools to teach children proper programming rather than just how to use ‘Word’ or ‘PowerPoint’ (…shudder.  I HATE ‘PowerPoint’…).

We think this is a very, very good thing.

Of course, guys of a similar age to me will fondly remember spending hours and hours over their ZX80’s or ZX81’s typing in programs to play ‘Space Invaders’!  Aaaah…  Happy days!

Nostalgia aside, its great that the Government have finally seen sense and decided to overhaul the computing curriculum.

AnywayDad, what ARE you going on about?

I’ve been following the progress of the little Raspberry Pi with great interest.  As soon as it was announced that it was available, I was one of the hundreds of thousands of guys and gals who totally crashed both the Farnell and Radio Spares websites, all wanting our orders there and then.

When Farnell had put their servers back together (!!!), they mailed me and said that they had received my order, and that my Raspberry Pi would be dispatched late April.  Well, today I received a polite mail telling me that the dispatch is ‘imminent’.


So what’s this all to do with a growing project here in Sunny Sheffield?

Well Dear Reader, as soon as my little board arrives, I’m looking to hook it up to the Electric Bike!

Out go the LED displays and little LED ‘tell-tales’.  In comes a full HD display!  Full high-definition graphics!

Out goes assembler programming, in comes Python, C, C#, HTML and CSS.

As the title says: Watch This Space for further fun and photos!

(Yes.  That photo is obviously my cat, Alfie.  This was his look this morning from my knee as I shouted in glee that my Pi was on its way.)

The parts have arrived! 17/12/11


This morning my smiling postman delivered four more PIC16F876A’s and two opto-sensors.

The PIC’s are for the circuit boards (…I only had one, so making two talk with each other was more than a little difficult…), and the opto-sensors are for the generator.

I plan to have a disc with a couple of holes in connected to the main generator drive wheel that the back wheel of the bike runs on.

These sensors will provide interrupts to the PIC to show that the wheels are moving.  By doing it this way, it means there’s no need to modify a bike to fit an infra red sensor and it will mean that unlike the bike computers you fit to your own bike, there’ll be no need to input the wheel diameter.  Instead, it will measure the speed of the generator and therefore the ‘speed of travel’ of the bike.


Don’t worry, it’s all been properly thought through.

SO, that means I can get changed into my ‘outdoor gear’ and go straight over to The Plots, hopefully for a hard day’s digging.

Being sat at a bench all day writing code and building circuits while eating the Co-Op’s finest donuts is great for the mind (…though not for the waistline, unfortunately…), but digging is good for the soul.

Of course, the promise of Mitzi to cuddle, gallons of Plot Tea to drink in the weak winter sunshine kind of helps too.

Soaking it up. 14/12/11

I left the board plugged in and switched on last night to give it a few hours soak testing.

And it all passed with flying colours.And counting.

To the right you can see it this morning, and it shows its been on for 10 hours, 39 minutes and 52 seconds.

What you can’t see is the dot between the ‘9’ and the ‘5’ which flashes briefly every second as the seconds count up.

Up at the top right, you can see the ’00’ of the speed indicators, which obviously is zero because I’m not on the bike pedaling!

Actually, I need to change a little of the code for doing the speed because it tends to ‘bounce’ as your speed varies, but a little tweak and it will be perfectly readable.

“So, Wardo,” someone shouts. “What’s the plan for today?”

Today I have to go down to good old Maplin’s to pick up yet more bits, and as I ordered them online last night after they’d shut, I expect a call very soon after 9.00.  And yes, now they’re starting to get their stock under control, I checked online, and they have everything in stock.

And talking of stock, yesterday I became the first person in Sheffield to buy Maplin’s entire stock of two different parts from both their Sheffield stores.  I pity anyone else who wanted BC547’s or those cute little 7-segment displays!

Today will be for some 32.768KHz crystals for the embedded RTC’s (Real Time Clock), some little 22pf and 33pf capacitors for running the main PIC clocks and some 330R resistors that drive the anodes of the display LED’s.  I may well see if they have any off-cuts of veroboard because I’m running a little low on that as well.

In other news, I spoke with Sheffield’s Best Electronic Engineer the other day -when I was waiting for that Farnell order to see what time they were likely to tip up (…just after I’d put down the phone!), and due to a mix up, he has a spare soldering iron he had to buy in an emergency because he couldn’t get a part for his Weller iron.

He said I could have it for Christmas!

Okay, its not a Weller, but it’ll be a whole lot better than the little Antex I’m using, and I’m going round to pick it up early next week, so HUGE thanks are in order to him for this.

Anyway, I’d better get in gear.  Much to do today.

14 seconds. 13/12/11

That’s how much the timing circuit gains in one hour.

Now, the purists out there would say I have to correct this, but at this time I really want to crack on with other, more exciting stuff -like getting two PIC’s to chat to each other via the I2C communications I’ve been talking about for the last few days.

Anyway, I’ve now got the bottom six digits showing seconds, minutes and hours as it should. And yes, its showing it in the right format -the seconds and minutes roll over at sixty as they should.

This only took a matter of minutes in ‘C’!  If I’d tried to do this in assembler, it would have taken forever to write and debug.

So, its down to Maplin’s to buy their entire stock of FA02C green segment displays (7) along with their entire stock of BC547C’s (…Er. One…)

More pictures later.

Ladies and Gentlemen… 11/12/11

…I present to you:


Difficult to believe, but its true.

Two digits of your finest counts-per-second.

Yes, I know that ‘counts’ means nothing in the real world (…2.25m to be exact -the circumference of the back bike wheel…), but that’s only a quick calculation, and one I don’t need to do right now.

The most important thing will be to get the new programmer tomorrow morning, see Mr Ward Senior (…a regular Monday lunchtime fixture…), then its on with the dead comfy jogging bottoms, the old grey T-shirt, the worn-out slippers, and I can look forward to not having to shave or shower for days!

Seriously though, it means that once the new programmer is here, I can quickly port-over the code then get some sensible numbers of out it.

And I can’t wait!

Building veroboard ‘creations’ is all very well, but its bad for the eyesight and it plays havoc with the ends of your fingers as you have to keep wiping the veroboard to clear detritus from between the tracks.

And after that?!

Ah, then I have to get to grips with the free printed circuit board software I mentioned many, many months ago from Express PCB.

Then I have to design the board (…no mean feat…), and get it squirted over to Dave so he can make the circuit boards with his ace ‘fabbing’ equipment.

Should be done by no later than Thursday morning.

(…Hang on, I see a flying pig overhead…)

Today’s mission… 11/12/11

…should I choose to accept it will be to program the display board I built last week with some new code.  This will be to give me speed and distance.

Okay, its with the old chip, but as I’ve mentioned before, porting code across chips with ‘C’ and the Microchip Integrated Development Environment (IDE) is ridiculously easy.

It will give me a ‘feel’ for doing it on the ‘proper’ board in the next few days after the new PICKIT3 arrives tomorrow. (…It will arrive.  Its FARNELL, after all…)

BUT, of course there is a slight problem.

In the course of the madess that was the other night, I’m sure I’ve corrupted the code that is currently running on that board.

SO, I’ll have to make sure I’ve got a working copy of that before I try anything fancy with new code.

The state of play. 8/12/11

I didn’t post yesterday for a couple of reasons.

Firstly, I only managed to get just over a half-day in -I had business to attend to down in Sunny Hillsborough in the morning.

Secondly, I once again found myself stuck.

“How can that be!?” Someone shouts, incredulously.  “You’re sooo close!”

Too true, Dear Reader.

So allow me to explain…

I managed to finish off the new board with the eight displays on.  No mean feat this.  I hinted the other day about how difficult the new hook-up wire was to solder, and I’ll explain at some later date -along with photos to prove it.

After finishing it, I spent an hour ‘snagging’ -just looking over the board- before plugging it into the old ‘Velleman’ programming board I first built over a year ago.  This was without the chips in -to check that I was getting sensible voltages at the correct pins.

Everything checked out!

So, I carefully put the chips in -the PIC and the three into eight decoder and gingerly turned the power on.

Please note that at this time, I wasn’t expecting to see any light lit -I hadn’t programmed the PIC, but I wanted to check that the clock was working properly.

It was.  A beautiful 20MHz clock signal.

At this point: Wardo == Happy Bunny.

Now, I had to get a little code onto the PIC -just to turn an LED or two on.  The famous ‘First LED’ and all that.

And this is where it all started to go ‘Breasts Skywards’…

I reset the MPLAB programming suite -that’s the free one from Microchip I’m so fond of.  PIC16F876A, no problem.

Then I checked on the PICPROG2009 programming software that came with the Velleman programmer…

PIC16F876, no problem.  PIC16F876A?  Nope.  Not this century.  No-way, no-how.

Eh?  What?  You are, of course joking, right?!?!

The sound of my jaw hitting the floor was louder even than the Classic FM on in the background at this time.

…Anyway, Dear Reader, I’ll not bore you further with details of the Descent Into Programming Hell that happened over the next four hours, but suffice to say that when I finally crawled into bed last night, I was far from happy.

But still: Onwards and Upwards!

Today is another, fresher day, and I will crack it, even if it kills me.

Flowers to be sent to…

Whose Cat? 21/11/11

(…am I too sexy for?)

Of course, there can only be one answer to this, namely: “My Cat!!”

Check out the blurred photo to the right, and you’ll see my prototype display showing different numbers on different digits.It works!

“SO??!!” You scream.

Ah, and therein lies the rub, so to speak.

What you’re seeing here, Dear Reader is thanks to persistence of vision (…and slowness of camera sensor…).  You’re only seeing one digit at a time.

First, the PIC puts out the ‘6’, leaves it for a millisecond, then it puts out a ‘7’ on the next display, again for a millisecond.  And so on.

Those little displays are multiplexed.  The PIC isn’t displaying all the digits at once -it only looks like it is.

AND its doing it all via interrupts -meaning the PIC is free to do other stuff -like monitor the bikes- in the foreground.

So in The Wardian Household, today there is great joy and gladness.

Now, a shower, a cup of tea, a couple of slices of toast, and then?

Well, I’ll carry on, of course!

11.55 Update.

Corrected small bug -not all the digits were counting up to 9.  A simple ‘mod’ (%10) function cured this. (‘mod’ = ‘modulus’ -remember them from school?)

Now, onto getting it to count ‘clicks’ from the bike’s rear wheel.  Then a little maths, and it’ll give an accurate measure of distance cycled.


SEO Powered By SEOPressor