PDA

View Full Version : New to BASIC Stamp - Need Help



DeeLuxx
08-19-2008, 05:17 PM
Hi there,

I'm a 5th form student at Sacred Heart College, in New Zealand and am currently taking electronics as a subject.

My main assignment this year is "to extend the use of an existing technology"

My existing technology is the Vmusic2 module and i choose to extend it by designing and building an aircraft data logger that will record (so far) g force on 3 axis, temperature, humidity and possibly altitude. i am using a Picaxe 28X1 for the main microcontroler.

I ordered two sensors from parallax, the Hitachi H48C Tri-Axis Accelerometer Module and the Sensirion Temperature/Humidity Sensor.

Both of these sensors use the SHIFTIN/OUT commands which are an absolute nightmare to use on the picaxe so after weeks of messing around on the pixace forum and futile attempts at bit bashing i am seriously considering ordering a BASIC Stamp module because, as i understand, the source code can be downloaded for each sensor and dropped straight into the programmer without any modification to the code - apart from subbing in the appropriate pin numbers - is this correct?

I am really sick of getting nitty-gritty with code and just want to get the sensors going in as little time as possible (i have to hand this in soon)

What is the CHEAPEST stamp setup that would work with these sensors.

I already have lots of breadboards, components (resistors, capacitors etc.. ) a seriall programming cable and everything else.

Can you program the stamp without another development/programming board?

Any help would be greatly appreaciated.

Thanks

sylvie369
08-19-2008, 06:07 PM
As you probably noticed, there's sample code for both sensors at the Parallax website: you can also find articles including sample code for both in the "Nuts and Volts" columns available for free download there.

SHIFTIN/SHIFTOUT commands are available for any of the BS2 series, though not for the BS1. That means you can go with whichever of the BS2 microcontrollers suits your needs. A regular BS2 goes for $49 - some of the faster/more memory versions are only a few dollars more, though. A low-end carrier board (which you will also need) goes $16, though I'd spend the extra $4 for the "super carrier board".

When you have that, all you need is a standard serial cable, as long as your computer has a regular old DB-9 style serial port. If you only have USB ports, you'll need the $20 USB/Serial converter.

With the BS2 and the sample code, you should have no problem reading those sensors within just a few minutes of getting set up. I have a nice little setup on a BS2 connected to the Sensiron Temp/Humidity device, sending the readings out through an XBee Pro to be received by another XBee connected toa computer through a Prop Plug. Works like a charm.


Post Edited (sylvie369) : 8/19/2008 11:13:22 AM GMT

SRLM
08-19-2008, 06:46 PM
Sylvie seems to have done a good job at answering the question, but I have one of my own. What exactly is the 5th form student (or rather, what year?) Personally, I'm about to go into my 14th year of education (kindergarten + 1-12th grade) as a college freshman. I guess my question can be broken down into "How many years?"

DeeLuxx
08-20-2008, 10:49 AM
In NZ, kindergarten goes till about then age of 5, then you start primary school (elementary in the states?).

After 6 years of primary school you start intermediate, which is from year 7 to 8.

at year 9, you start college (highschool) and college goes from year 9 to 13.

Year 9 is form 1, year 10 is form 2 etc all the way up to form 7 which is year 13, after that you start university.

DeeLuxx
08-20-2008, 10:58 AM
Also, what would be the absolute cheapest way to go?

would the BASIC Stamp 2 OEM Module (Kit Form) be alright with my sensors?

Thanks

SRLM
08-20-2008, 02:05 PM
Yes, the OEM module would work, since it's just a regular BS2. However, unless you are really good at soldering, chances are that you will make a mistake somewhere and create weeks of headache. Your best be for the BS2 is to use a mdoule thats already made. Its a bit more expensive, but you'll have it ready to go in no time. Another thing to consider is how you're going to hook it up. If you breadboard it you'll need to come up with a serial programming port, or something to convert serial to USB. A 5 volt regulated power supply couldn't hurt, but with just the two sensors it's not a neccessity. If you don't want to breadboard and you want something a bit more permanent, Parallax offers carrier boards.

http://parallax.com/Store/Microcontrollers/BASICStampDevelopmentBoards/tabid/137/CategoryID/12/List/0/SortField/0/Level/a/ProductID/121/Default.aspx

http://parallax.com/Store/Microcontrollers/BASICStampDevelopmentBoards/tabid/137/CategoryID/12/List/0/SortField/0/Level/a/ProductID/122/Default.aspx

However, yes, the absolute cheapest way to go is the OEM module. My recomendation: If you can solder and are going to use the BS2 as a slave, use the OEM. If you are going to use the BS2 as a master, use the standard module.


So, in NZ required schooling lasts for 14 years? In the states its only 13... (with kindergarten)

DeeLuxx
08-20-2008, 03:45 PM
Thanks for the info.

I don't really wanna use a carrier board because that means that i have to permanently solder the sensor to the board. i have the parts for a serial download circuit i ill most probably get the basic stamp 2sx module sine the normal basic stamp 2 is out of stock.

I am still contemplating the oem module as it includes the full download circuit in the module. how hard is the normal basic stamp 2 module to program in terms of the download circuit?

Abut the school thing, NZ is pretty much the same as the states and school only lasts 13 years, with the 13th year being an option.

Thanks

sylvie369
08-20-2008, 05:26 PM
DeeLuxx said...
Thanks for the info.

I don't really wanna use a carrier board because that means that i have to permanently solder the sensor to the board. i have the parts for a serial download circuit i ill most probably get the basic stamp 2sx module sine the normal basic stamp 2 is out of stock.

I am still contemplating the oem module as it includes the full download circuit in the module. how hard is the normal basic stamp 2 module to program in terms of the download circuit?
I don't see why you would have to solder the sensor to a carrier board if that's what you were using. You can take wires off of the appropriate pins on the carrier board just like you would for the OEM version.

I've built a couple of the OEM kits, and while I did find the closely spaced transistors and "reset supervisor" a bit of a challenge, they all worked fine without too much trouble. Make sure you have a good soldering iron and some kind of lighted magnifier to inspect your work carefully.

Steph Lindsay
08-21-2008, 04:04 AM
Have you checked with your local Parallax distributor to see if they have a BS2 in stock? Please know that the BS2sx has slightly different timing requirements for some commands, so you may need to modify BS2 sample code a little bit if there are timing-sensitive commands. The timing differences for each command are clearly explained in the BASIC Stamp Editor Help file, and the software's a free download.


E-Source Ltd.
Auckland
Phone: Intl: +64211929950
Fax: Intl +64 9 521 3832
Web: http://www.basicstamps.co.nz/
Email: sales@esource.co.nz

DeeLuxx
08-21-2008, 04:43 AM
After much consideration, i've decided to get the Board of Education as it includes everything.

Thanks alot for all the helpful information

kevinb2050
08-21-2008, 07:58 AM
Hi, this is a distributor in Australia - I have found he has most parallax stuff in stock

Ronald Nollet [ron@nollet.com.au]

SRLM
08-21-2008, 01:04 PM
The BOE is a good product, and you can add other sensors to it for your project. Maybe a dead man's switch? Or output such as LCD, LEDs or sounds? You are only using a few pins on the BOE for the accelerometer and the sensiron.

I know some people who wished that the 13th year was an option... Some teachers too...
My Economics teacher liked to seed arguments in the class about controversial topics, and one being the years of high school (the last four years of mandatory education). He argued that the final two years of high school was useless for some people, and that by the time they got there they had decided that school was not their forte, and had given up. He thought that students should be given an option of going into a trade school instead of grades 11 and 12, or doing those grades and going onto higher education.