Picaxe chips and general electronics

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

XRobots

Well-Known Member
I did a quick forum search on this before posting and I couldn't find anything specifically related. Has anyone discovered Picaxe chips for building simple (or more complex) electronic displays / devices with lights / servos / buttons etc?

Obviously Predator's electronic gauntlet / display springs to mind, and I'm sure people have built them with working lights in, but if you don't have much electronics experience then the Picaxe is the thing for you. They are used in schools and start at extremely low prices, it's a bit like a Basic Stamp if you've heard of those, but starting at £1/2 each so it doesn't matter if you fry a few.

I'm in no way affiliated with Picaxe or any distributors, but I've used them extensively for robot projects and sequencing lights / sounds / motors / buttons etc in interactive movie props.

Check out: http://www.picaxe.co.uk

...they have worldwide distributors, lots of documentation and a very active support forum.
 

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

Ei luj

New Member
Here's a company called Microchip that makes similar chips to the Picaxe, they also sell the programmer and Basic software:

Products:
http://www.microchipdirect.com/NewProductT...ee&TreeID=6

Link to the more common chips; the one I'm getting is the PIC16F877A-I/P (it has 33 links to the outside world that you can make inputs or outputs... if you have 28 LEDs that go into a wristcomputer countdown, you will need that many)
http://www.microchipdirect.com/Chart.aspx?...10&treeid=1

Link to the programmer and software that you load onto your PC, the programmer plugs into the USB socket...
the DV164006 has everything you need, cables etcetera:
http://www.microchip.com/stellent/idcplg?I...ocName=en010046
Here's the software:
http://www.microchipdirect.com/productsear...ywords=SW500041

I ordered this stuff a couple days ago, and they ship FedEx, so shouldn't take more than a week to get.
But its about $230 for the programmer and $250 for the software, but when you consider wiring up 13 IC's and a bazillion #30 wires to do a wristcomputer countdown, then it may be better to program it.

---
Ei'luj
 

XRobots

Well-Known Member
Pic chips are great, but if you don't want the expense of the programmer etc then the Picaxe it the way to go as you only need two resistors to program it from the PC serial port and the software is free - you can either program in GUI flow chart mode, or in a basic type language for more complex stuff.

Picaxe's are actually based on Microchip Pic chips, but Rev Ed (the company that makes them) have developed a pre-loaded boot strap and the software suite to make the programming interface easier and keep the cost to the end user down - you can literally start with a £1.15 Picaxe-08 on a bit of strip board with a few resistors, to sequence LEDs and provide logic from inputs, and that's you're total expenditure.

If you want more ins and outs there are larger Picaxes, but you could always use shift registers or some other supporting ICs, like a some 7-segment LED display drivers, to provide more outputs.

This is worth a read : http://www.rev-ed.co.uk/docs/picaxe_manual1.pdf
 

Ei luj

New Member
OK you got me thinking with the LED display drivers, they take four inputs each and if you have four of those to run the 28 LEDs, then you only need 16 I/O lines from the PIC chip....

I did a non PIC countdown circuit and it takes 13 IC's including the oscillator (resonator) and the aforementioned bazillion #30 wires...
If I used the PIC, it would be one resonator IC, one switch debounce IC, four display drivers, and the PIC, for a total of 7 parts. Not bad :D

I looked at the website you provided and for some reason it balked when I tried to go to the price listing... I will try a different browser... and see if they have a distributor in the US.

---
Ei'luj
 

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

XRobots

Well-Known Member
http://www.tech-supplies.co.uk/ is their online sales site for the UK.

http://www.rev-ed.co.uk/picaxe/distributors.htm for worldwide distributors - there are plenty of US ones.

http://hackaday.com/?s=picaxe the first source of sample Picaxe projects that spring to mind.

You could always just use 8 outputs to drive all the display segments, provided they were lit in 8 groups of 3 or 4 LEDs, and the 8 groups could flash in any order and rate. Then you could just use one Picaxe-20M and a darlington driver chip to source enough current to dive 4 LEDs from each output, and you'd still get 8 inputs too... depends how movie accurate you want to make it I guess.
 

Ei luj

New Member
Thanks a million for the links :D (wish I'd have run across this before I spent $ on the Microchip products :0 )

Here's my countdown in action:

th_DSCN0554.jpg

That's what I would be trying to emulate. Somebody posted the numbers in another thread; I'd try those out also.

----
Ei'luj
 

XRobots

Well-Known Member
That looks good. Yeah, it would be quite tricky to simplify I guess.

If I were going to do it myself with all of the 28 outputs totally independent, then I think I'd just use four 8 output Picaxes and sync them together, so one of them generates a sync pulse/signal that goes to one input of the other three, then they know which bits to turn on and off at the right time. You'd have enough spare inputs on them all for a 'global rest', start and stop buttons, and a number of other things too.

Of course you could use plain Pic chips, I just like being able to easily re-program a Picaxe without removing it from the circuit, oh, and the cost I guess...

http://www.parallax.com for BASIC Stamps and Propeller chips
Yep - the Picaxe is very much like the Basic Stamps in terms of programming, but not so bad if you fry a few ;-)
 

PredaHawk

New Member
Yep - the Picaxe is very much like the Basic Stamps in terms of programming, but not so bad if you fry a few ;-)

BS2.jpg.gif


Here's a clip I posted of a simple, low speed, animatronic shoulder cannon servo using this Parallax BS2 (above) that I picked up on eBay. It can also drive LEDs very easily. There is a lot of documentation out there for free, along with software to get you going.

Needless to say, it's a work in progress. There will be a full progress report when I get the electronics sorted out. Stay tuned...


http://www.youtube.com/watch?v=wWCMk3ulvFc
 

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

torredator

New Member
I have to say that this is the coolest thing i have ever seen!
all i want to know is how simple is this Picaxe to work with?
as my electronic knowledge ends with using my Cell phone, I Pod and this computer!







 

PredaHawk

New Member
I have to say that this is the coolest thing i have ever seen!
all i want to know is how simple is this Picaxe to work with?
as my electronic knowledge ends with using my Cell phone, I Pod and this computer!
Here is the coding I used for the BASIC stamp (BS2) that controls the 2 servos for my Cannon WIP (sorry this is so long)

' {$STAMP BS2}

' {$PBASIC 2.5}

'----------Hardware Configuration Information----------

' Mid Servo is PIN 5 in X7 Header Slot #8

' Top Servo is PIN 14 in X7 Header Slot #17

'----------Initialize Servo Variables----------

deploytopservo VAR Word
deploymidservo VAR Word
stowtopservo VAR Word
stowmidservo VAR Word
cycle_counter VAR Word

'----------Rotational Values----------

'---Default Ranges TOP is 400 S to 1100 D---
'---Default Ranges MID is 600 S to 1000 D---

deploytopservo = 1100
deploymidservo = 1000
stowtopservo = 400
stowmidservo = 600

'----------Set PIN Values----------

LOW 5
LOW 14
INPUT 8
INPUT 11

'----------Set Servos to STOWED----------
PULSOUT 5, stowmidservo
PULSOUT 14, stowtopservo

'----------Program----------

Main:

DEBUG CLS

DO
DEBUG HOME, "Waiting for Input |"
DEBUG HOME, "Waiting for Input -"

IF IN8 = 0 THEN Stow
IF IN11 = 0 THEN Deploy
LOOP

'----------Subroutines----------
Stow:

FOR cycle_counter = deploytopservo TO stowtopservo
PULSOUT 14, cycle_counter
PAUSE 5
NEXT

FOR cycle_counter = deploymidservo TO stowmidservo
PULSOUT 5, cycle_counter
PAUSE 5
NEXT

GOTO Main

Deploy:
FOR cycle_counter = stowmidservo TO deploymidservo
PULSOUT 5, cycle_counter
PAUSE 5
NEXT

FOR cycle_counter = stowtopservo TO deploytopservo
PULSOUT 14, cycle_counter
PAUSE 5
NEXT

GOTO Main

I haven't used PIC before, but this gives you an idea about how PBASIC programming goes. It's very simple (IMO) to use after learning the basic formatting and some of the commands. Parallax has tons of information, tutorials and downloads. The sky is the limit. You can make a simple pushbutton servo control or automate your entire home with a BASIC stamp.
 
Last edited by a moderator:

XRobots

Well-Known Member
all i want to know is how simple is this Picaxe to work with?
The Picaxe is very similar to the Basic Stamp in terms of programming and functionality. I guess take a look at the Picaxe manual link I posted above and also check out their enthusiast forums: http://www.picaxeforum.co.uk/ - there are a lot of helpful people in there, and also more links to documentation at the top of that page. Basically they're used a lot in schools, so they're pretty easy to work with.
 

Ei luj

New Member
@all

I went and got my Microchip kit from the FedEx office and will be digging into the intricacies of Basic.... wish me luck, I'm a hardware engineer :eek:

@ PredaHawk

How big is that controller board you are using? My wristcomputer housing inside dimensions is around 8" long by 1-7/8" wide and 3/8" thick.... but there is way more room in my powerpack :D

@Xrobots

Thanks for the ideas on four chips with 8 outputs each, the programming might need to be slightly different for each, but it wouldn't vary much, would it?

---
Ei'luj
 

XRobots

Well-Known Member
Thanks for the ideas on four chips with 8 outputs each, the programming might need to be slightly different for each, but it wouldn't vary much, would it?
I guess it would be pretty similar, three of the Pics would wait for input signals before clocking on to the next stage, and the first 'master' Pic would generate the timing and it advances through the sequence. Should be pretty simple to achieve.
 

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

PredaHawk

New Member
I looked over the Picaxe components available from HVWTECH.COM

The cost of the PIC components versus that of BASIC Stamp parts is WAY LESS. Granted, I haven't used PICAXE before, I think it warrants further investigation on my part based on the cost-savings along.

Sure, BS2 modules run more lines of code than say PIC-14 modules, but my code isn't really that long (50 lines) and a 14M can handle 80 lines. At $3.95 US, how can you go wrong! I'm thinking that using a BS2 is too much muscle (and cost) for the simple 3 servo control project I have going on.

Plus, the PIC programmer has a graphical, flow-chart programming mode which intrigues me, since I use Dia (for Linux) to flowchart, then go back and write the BASIC code for the Stamp. This has it all in one shot.


Thanks for turning me on to this, X !

.:
 

Ei luj

New Member
"Plus, the PIC programmer has a graphical, flow-chart programming mode which intrigues me, since I use Dia (for Linux) to flowchart, then go back and write the BASIC code for the Stamp. This has it all in one shot."

PredaHawk,

Which software package has the graphical flow-chart programming mode?

I have the Microchip PicBasic Pro.

(continuing to dig into PicBasic....)

---
Ei'luj
 

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

Don't want to see this ad? Sign up for anRPF Premium Membershiptoday. Support the community. Stop the ads.

Top