Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

PICs VS Stamps

Status
Not open for further replies.

erikgunit

New Member
Hi all. I am nem to the site but not to electronics. I have a pretty good understanding of circuits and circuit design. I am however new to micro controllers. I have used the BASIC stamp from Paralax in the past but was limited by a small number of i/o pins.
What is the difference between a PIC and stamp? From my experience with the stamp from paralax is that is included the serial interface as well as the voltage control and protective resistors are on built in already. How is programming done in with a PIC? From what i have read it seems like C is a common langauge and most likely what i would use seeing as i also have some experience in C. But not only that how can i interface the PIC with the computer in order to program it? I would like to use USB in order to program or USB to serial converter.
I am mainly interested in the major differences, which one is easier to use, etc. I appriciate your input.
 
Check out Swordfish BASIC

Also might be worth reading the JPUG issues on my site.

Stamps are easy but limited. Slightly better are the PICAxe but best of all is an MPLAB compatible programmer.
 
This is my opinion on the Main Differences...

PIC .. not as easy to learn
Stamp.. too easy... your not a developer if you use this in my opinion

PIC... Lots of options
Stamp...Limited options

PIC.. like making a cake from scratch!!!
Stamp... Like buying box cake...

With a PIC you have more control over every single thing meaning you can personalize it more and also doesnt cost $$$...

Stamp cost so much because of their software and already prebuilt hardware...

Look at this stamp module:
**broken link removed**

$75 OMG!!

The Specs:

* Processor Speed: 8 MHz Turbo
* Program Execution Speed: ~6,000 PBASIC instructions/sec.
* RAM Size: 38 Bytes (12 I/0, 26 Variable)
* Scratch Pad RAM: 128 bytes
* EEPROM (Program) Size: 16 x 2 KBytes; (16 K for source; ~4,000 PBASIC instructions)
* Number of I/O Pins: 16 + 2 dedicated serial
* Current Draw @ 5 VDC: 15mA Run, 150 μA Sleep
* Source/Sink Current per I/O: 30 mA / 30 mA
* Source/Sink Current per unit: 60 mA / 60 mA per 8 I/O pins
* PBASIC Commands: 61
* Package: 24-pin DIP
* Commercial-Rated since Rev. B

Ok what you see in BOLD sucks!

8Mhz is fine for most things but at $75 no! no!

The 6,000 instructions/sec sucks! i can get about 2,000,000 with a cheap 8mhz pic.

Ram, EEPROM (for $75 this sux!)

The package is always DIP what if you wanna make something small? or want to use batteries? you are limited a lot there. Here is a nice cheap PIC with way more features:

Now look at this DIP IC:

PIC18F46K20

This is about $4 and its like god compared to that $75 stamp..

Need less pins ...

PIC18F26K20

Same thing smaller pinout.

Specs on PIC:
Program Memory Type Flash
Program Memory (KB) 64
CPU Speed (MIPS) 16 (MILLION INSTRUCTIONS PER SECOND)
RAM Bytes 3,936
Data EEPROM (bytes) 1024
Digital Communication Peripherals 1-A/E/USART, 1-MSSP(SPI/I2C)
Capture/Compare/PWM Peripherals 1 CCP, 1 ECCP
Timers 1 x 8-bit, 3 x 16-bit

ADC 10 ch, 10-bit
Comparators 2
Temperature Range (C) -40 to 125
Operating Voltage Range (V) 1.8 to 3.6


EVERYTHING IS BOLD REALLY! heh

Look at the ram and speed and power it needs and has compared to the stamp. You can make a board for this or with this for like $10 . hece you can have about 7 of these made into stamp type products for the same price of 1 slow stamp! :D
 
Last edited:
My gateway drug into microcontrollers was a Basic Stamp 2 (an impulse purchase of a Homework Board kit at RadioShack).

I started going through the tutorials, and after doing like the first two I started creating my own projects. It was just too easy (I'm an experienced application software engineer and a bit-twiddling geek).

Next I started working on a "real" project. Initially I used the BS2 because it was quick/easy to develop on, but it's WAY limited, and it's slower than molasses flowing uphill in January. It isn't even fast enough to multiplex LEDs.

Since then, I got some PIC stuff and am programming in assembly now, and having a blast.

So, if you're completely wet behind the ears when it comes to MCU programming, a Basic Stamp kit is a good way to get started, but for any "real" projects I'd toss the toy MCU and go PIC.

That said, even a seasoned PIC developer should probably have a Basic Stamp 2 on hand for quick one-off tasks. For example, I'm working on an EMF meter, and needed a source of EMF pulses, so I put one together on a breadboard and plugged a BS2 in, and wrote the code in 5 minutes. Would have taken a bit longer with a PIC. Later on, when I'm finished, I just toss the BS2 back in drawer, and when I need another quick something-or-other, I can pull it out and reprogram it.
 
Last edited:
I always think of the STAMP as Lego to a builder, it's a good learning tool and introductory item into the world of uC's, but it is what it is, limited.

It all depends on what you want to do with your "real world" application. You can get basic compilers and dev kits for the PIC micro's, I have the PICDEM2 board, which has a tiny dev area, and can take several uC's.

My weapons of choice regarding the programming is the Pickit 2 and the ICD2 (both MicroChip products) and USB driven (power also), although if you want to power a device via the ICD2 you will need the adaptor, or give it it's own power source such as a 9v battery.

You have 4 main languages to choose from, Assembly, Basic, C, and Pascal.
C is the most common closely followed by Basic, inline assembler is possible in both also. There are different compilers based on different features, I use CCS C and C18, I have also used Mikro C, which has a very good comprehensive library set.

The PIC micro comes in different versions PIC10, PIC12, PIC16, PIC18, PIC24, PIC32, DS PIC. They range from base, mid to high in each category, although the PIC16 and PIC18 are the most popular.

They are now relatively cheap for what they can do, you can even clock them to 48mhz for a USB 2 application.

Considering the price of the BS2 kits and the sheer fact that the PIC Micro has capabilities far beyond the BS I would start with a PIC16 chip, and go from there.

You can enable weak pullups on certain if not all micro's which give you a +5v signal until it's connected to ground, useful for switches etc.

I have used a PIC16 as a line / column driver for a LED Matrix (multiplexing) and it works fast, I have also used the same technique but using a shift register which is also fast, so the chip has a good speed benchmark.

I think there is even a compiler which will let you compile BS2 code into PIC Basic, it may be PIC Basic Pro even, so if you had any existing BS2 code it would be easily portable.

But remember, this is just one person's oppinion.

Hope this helps.
 
Atom your pick of chip was the slowest. The $49.00 stamp2 has a 20 mhz osc
The stamp2sx is the fastest stamp2 at 50mhz it is $59.00
Features:

* Processor Speed: 50 MHz
* Program Execution Speed: ~10,000 PBASIC instructions/sec.
* RAM Size: 32 Bytes (6 I/0, 26 Variable)
* Scratch Pad RAM: 64 bytes
* EEPROM (Program) Size: 8 x 2 KBytes; ~4,000 PBASIC instructions
* Number of I/O Pins: 16 + 2 dedicated serial
* Current Draw @ 5 VDC: 60mA Run, 500 μA Sleep
* Source/Sink Current per I/O: 30 mA / 30 mA
* Source/Sink Current per unit: 60 mA / 60 mA per 8 I/O pins
* PBASIC Commands: 45
* Package: 24-pin DIP
* Industrial-Rated since Rev. F
And one thing about the stamp you can write your code and sell it and know that no one going to ask you to buy a Commercial License PIC18 MCUs Site License $4995.00 HI-TECH C $3795.00
I say the cheapest would be to go with BoostC at $149.00
But I think the fine print will haunt you

Now don't get me wrong I think the pic is the way to go but it's not for every one
same for the stamp2
I like to know how this adds up Propeller Chip - 40-Pin DIP Chip $7.99
* Model Number: P8X32A-D40
* Processors (cogs): Eight
* Architecture: 32-bits
* System Clock Speed: DC to 80 MHz
* Global RAM/ROM: 64 K bytes; 32 K RAM / 32 K ROM
* Cog RAM: 512 x 32 bits each
* I/O Pins: 32 (simultaneously addressable by all eight cogs)
* Current Source/Sink per I/O: 40 mA
* Clock Modes: (a) External crystal 4 -8 MHz (16 x PLL) (b) Internal oscillator ~12 MHz or ~20 kHz (c) Direct drive
* Package Type: 40-pin DIP

Included in:
 
be80be remember this.... $50 stamp and if going to sell product just to make 100 products it will cost you :

Starting from: 100 pieces $47.20 each

That $4720 for 100 pieces of IC... Thats a huge waste compared to $5 20mhz PIC for 100 pieces about $2.50 (depending on package of IC)

So for:

100x Stamps = $4720
100x PICs = $250

You tell me if you can afford to spend $200 on a license or not. The other $4470 can go on parts and stuff..

Which is more affordable for selling or profit making?

If its a student thing then C18 and many others offer student editions free! with a limit on size but most students never touch that limit anyway
 
be80be remember this.... $50 stamp and if going to sell product just to make 100 products it will cost you :

Starting from: 100 pieces $47.20 each

That $4720 for 100 pieces of IC... Thats a huge waste compared to $5 20mhz PIC for 100 pieces about $2.50 (depending on package of IC)

So for:

100x Stamps = $4720
100x PICs = $250

You tell me if you can afford to spend $200 on a license or not. The other $4470 can go on parts and stuff..

Which is more affordable for selling or profit making?

If its a student thing then C18 and many others offer student editions free! with a limit on size but most students never touch that limit anyway

Atom I know about cost I have used both I think you missed that in my post

But when and if you write that pie in the sky code that sells millions of pic with your name on it You better make sure you own the right to be the man if you know what i'm saying Or write it all in assembly
 
heh its not about rights if you dont copy :D

If you write your own code in C or what ever then you own it. No one else. If your code is similar it should matter really. Code is code and there is many ways to set a bit in C18

PORTAbits.RA1 = 1; or PORTA = 1; or PORTA = 1<<4; etc....

Who are you copying? microchip? if thats the way they intended it to work heh thats the way we use it.
 
Last edited:
I'd be hard pressed to recommend a BS2 anymore. PICBASIC Pro is a Stamp compatible BASIC compiler and is many times faster. For about the price of about 3 BASIC Stamps you could buy a modern programmer, PIC BASIC Pro (or the far superior Swordfish BASIC) and a PIC or two.
 
https://ww1.microchip.com/downloads/en/DeviceDoc/MPLABC18CompilerLicense.txt

I was reading the license for C18 and found...

if You
downloaded the "Student Edition" of the Software from the web, You may
install and use such version of the Software on an unlimited number of
computers for commercial or educational use.

All copies of the Software created by You or for You, including derivatives,
must include the copyright, trademark and other proprietary notices as they
appear on the original. You may not remove or alter any identifying screen
that is produced by the Software.

The above isnt bad. Just a must do :D
 
Last edited:
wow thanks guys. I really appriciate the input. I agree with the basic stamp being too limited and slow. Its worked in the past but i ended up multiplexing a few inputs and was a bit of a headache.

As for what i plan on doing with the chip is make a speed sensor, similar to the ones used for achery and such, where the arrow passes through two sensors and the time that the arrow takes to go through both is divided by the distance between and voila: speed. I plan on outputting this speed to a BCD to decimal decoder and finally to a 7 segment, well probably 2 7 segment displays to show the speed.

I am interested in any advice you have for my application, i think i know how im going to do it but a little advice doesnt hurt. thanks for the info thus far.
 
you could use an reflective IR sensor, when the beam breaks it pulls a IO pin low, and when it comes back i.e the arrow has finished passing through the IO pin goes high (this can be acheived by weak pullups, that way you will only be switching 0v) You can put some variables etc in the routine which checks for the IO state and do some maths and calculate the time then call a function to output on the 7 Segment or just increment the BCD.

This is one way you could do it.

Hope this helps.
 
its probably just me watching a lot of movies but it would be cool to place 2 laser and a few mirrors to reflect laser back and forth and up so it makes like a screen of lasers and a sensor in the end and when the line is broken it sets a flag and when laser 2 which is 1 foot behind laser is broke then it flags another and calcs from flag one to flag 2
 
I was thinking about using lasers. Way too cool!! especially a green one or something like that. Make it look space age!!

Quick question: do you have any experience getting the angle of something passing through the sensors? lets say for example, that the three sensors that are used have a front and back sensor. similar to three colons in a row
: : : if the first front LED (or laser) breaks first followed by the first back sensor, is there any way to get the angle of what ever is passing through the sets of LEDs? Thanks
 
you could make a somewhat cubic sensor. Like a box for exmaple with 2-3 lasers and have 2 way mirror type glass so the laser still reflects off the sensor while the sensor is still able to read the light from laser this way you can add a bunch of mirrors and sensors to determin multiple triggers. Let me draw what i mean lol
 
Here we go lol dont laugh. This is my opinion and crappy PAINT art ok lol

laser-jpg.32839


As you can see if you test what sensors when off you can determine the direction its going in and if you know what it is then the angle shouldnt be hard i think like if its a box then you can just map out the points of the sensors and draw a image from the broken lasers at any given time to see whats the top bottom and determine whats the longest side ect...


I dont know lol its all confusing to me but thats how i would do it. :D

Note when 1 laser breaks multiple lasers may lose that 1 laser to to determine the first spot you should check to see which are on and off and determine the first off. lol

IF all my text explaining sux then sorry lol i was bored and wanted to jump in this. lol
 

Attachments

  • laser.JPG
    laser.JPG
    43.1 KB · Views: 388
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top