PDA

View Full Version : I want to control my dew heaters for my optics



aquasapien
11-15-2006, 08:24 AM
Hi.

Forgive me if this has been hashed already, but I could spend ages going through all the threads.

Ok, what I want to do is this. I have computerized my telescope using steppers and·a bs2 stamp as the controller. It is great. However I want to control my dew heaters for my optics with the same stamp. Now the problem I am having is using the Pulse Width Modulation subroutine that controls·my heating elements at the same time as the other routines, such as the "goto mode" routine.

Essentialy I would like for say pin 5 to be constantly sending the PWM to the heater while other routines are being called. Is this possible, or do I need to break out the PIC as a didcated temp controller?

Thanks for any help

Post Edited By Moderator (Chris Savage (Parallax)) : 11/15/2006 12:30:35 AM GMT

Phil Pilgrim (PhiPi)
11-15-2006, 08:44 AM
aquasapien,

Have you looked at the MoBoStamp-pe? It includes onboard coprocessors that can do the PWM output for you while the Stamp is busy with other tasks. With the factory-installed firmware, setting up an output for PWM is done via the Stamp's OWOUT statement. You can read about it here (http://www.parallax.com/detail.asp?product_id=28300).

-Phil

Gadgetman
11-15-2006, 06:39 PM
Maybe thePWMPal would work?

http://www.parallax.com/detail.asp?product_id=28020

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Don't visit my new website...

Tracy Allen
11-16-2006, 12:19 AM
You can derive an analog voltage from the PWM, by means of a capacitor and an op amp, and drive the heater with the analog signal. I don't know how much power is involved. It would require a power transistor to drive the heater, or, the power transistor itself could be part of the heater.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Tracy Allen
www.emesystems.com (http://www.emesystems.com)

aquasapien
11-16-2006, 03:53 AM
As it stands my heating system consists of parallel strings of 300 ohm risistors, that recieve thier load voltage from a TIP29 transistor with a 12 volt source, the TIP29 communicates through a MCT2e opto isolator with the bs2.

I appreciate the new hardware solutions offered, but I was hoping for a slick little trick of the code that would enable this. If I need to add substanial hardware I will probably just create a dedicated driver out of a pic16f84a as I have a few of them floating around and they are cheap, and my money I like to keep.

I have ran into this before. I have a partially autonomous ROV for lakes that also had similar conflicts between routines. I thought I may be just missing somthing simple in the code, as I am a hack at it.

It would be nice to tie all systems into one chip, but I may be asking too much of any controller, to accomplish such a feat.

In any event I am glad to have finally got here. I look forward reading about others who play with big boy toys like PLC's and microcontrollers. Not many of those people in these parts.

Tracy Allen
11-16-2006, 05:06 AM
Yes, everything that approaches multitasking with the Stamp is done either with time slicing or with external support chips. The external PIC would probably be the way to go to get the best fineness of control with adaptive PWM.

That said, is there feedback from the heater, back to the stamp, in order to maintain the correct temperature? If other tasks that the Stamp does do not take up a high percentage of the processing time, then a little time could go to those other tasks and swapped out with the PWM and heater feedback function. 0.05 second here, 0.1 second there. How much does the heater temperature drift in 0.1 second and is it significant? It could even come down to a bang bang algorithm that tests the heater temperature every 0.05 seconds, and either turns it on for the next 0.05 second (if the temperature is low) or turns it off (if the temperature is high). That would amount to PWM, but on a longer time scale.

I know you don't want to buy anything more, but a chip like the DS1620 can act as a bang-bang thermostat independent of the Stamp, but can also be read or controlled from the Stamp.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Tracy Allen
www.emesystems.com (http://www.emesystems.com)

aquasapien
11-16-2006, 06:27 AM
That is the other option. Dividing the processing time is a viable option. The RA drive is the one component I will need to dedicate with its own hardware as tracking the sky relative to the earths rotation can not be comprimised for photographic reasons.

I am lucky to have a wife who is very proficient in her biz of sewing and such, so she has made me really sweet insulated sheaths for the resistor strips wich keeps the perceptable temp drift low for reasonably small amounts of time.

That being said, the actual goto mode and manual tracking mode would actually comprise a small percentage of the overall processor time. For the fifteen or so seconds it may take to slew to new positions or to engage the servo's for the filters, or the servo for shutter control is minimal in the big scheme of things.

As for temp feedback, no not yet. I have just started to inegrate this heating system, but yes in the next few days I will add feedback. I am not sure of the part number, but the temp sensor I will use is "surplus" from my work were they are used to remotely monitor Battery temps for telco UPS pedestals. It is two wire's with some type of component heat shrunk in the end.

They work well as I have used one for an incubator thermostate for petri dishes. The rct output is arbitrary and needs to be corrolated with a standared temp sensor, but hey, that is what I enjoy most about this hobby. Finding cheap solutions. It may be a huge contrubuter to frustrating times but oh well.

By the way, are you the same Tracy Allen I see all around the internet in regards to this type of thing? If so, it a pleasure to meet you, and thank you for your candid discussion on these topics, you have already helped me more then you may be aware of.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
The singularity is close at hand, Genetics, Nanotechnology, Robotics...and I get to be alive to see it.

Tommy Bot
11-16-2006, 06:31 AM
(This is an external chip solution, but...)

Use one of the stamps output pins to drive a 555 timer at a given frequency. A couple of resistors and a capacitor and you are 2 or 3 dollars down.

Use this link for details on setting it up in Astable mode:
http://home.cogeco.ca/~rpaisley4/LM555.html (http://home.cogeco.ca/~rpaisley4/LM555.html)

page down to the heading:
“Basic Circuits For The LM555 Timer”

4 circuits down you will find the schematic labeled “Independently variable timing for both portions of the output cycle”.
This circuit costs about $1.00 to build unless you use two pots like in this drawing. But you will gain an immense flexibility in tuning your circuit to the right frequency and duty cycle.

Just an option.




▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
(Frequently heard from other's)

Tommy, I know it wasn't designed to·x, but can you make it·do x·anyway?

·

aquasapien
11-16-2006, 09:27 AM
that is a good alternative both price and knowledge. I have been playing with these stamps for a while and like an aparation in the dark the 555 has always been looming around, yet I have never used one.

Maybe now would be the time to try it out. It seems they are the lego of the pre stamp days. Any older circuits and alot of new ones seem to include them.

Chop Chop

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
The singularity is close at hand, Genetics, Nanotechnology, Robotics...and I get to be alive to see it.

Tracy Allen
11-16-2006, 10:09 AM
Last week I was up at the Lowell Observatory outside Flagstaff. I hadn't realized that the shorthand symbol for Pluto, overlaid P and L, were taken from the astronomer's name. Perceival Lowell. They were a little sad about the demotion to less than planet. Anyway, on the Pluto search telescope there was indeed a clock drive for Right Ascension, but not a very good one, and they continually had to adust by hand to keep the crosshairs on a certain star, to keep the photo plate aligned. All night, for each exposure. Then they used an optical comparator as an aid to the naked eye to look for motion in the photographic plates from successive nights. Pretty amazing what patience and motivation can accomplish.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Tracy Allen
www.emesystems.com (http://www.emesystems.com)

aquasapien
11-16-2006, 11:10 AM
I wish I could say I was at the Lowel Obsrvatory last week. The sky here has been dropping rain for more then 3 weeks. Last good night was on Halloween.

A book I recently read talked about the antiquated stature of the observatory. Its dome rotating on old car tires, the dome slits rigged up like sails, and old desk with one of Percival's eyepieces still in it, his marble tomb on the foot path.

It also mentioned that one of the RA drive does have a few flat spots that need to be manhandled. It is hard to imagine sitting for hours on end guiding a scope, plate after plate, and comparing them. Goes to show what passion and patience can accomplish when combined in the propor proportions

So you just happened by the place or are you interested in such things?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
The singularity is close at hand, Genetics, Nanotechnology, Robotics...and I get to be alive to see it.

Tracy Allen
11-17-2006, 12:47 AM
The main observatory there was built around the turn of the century and was ahead of its time, at the time. Hey, they also discovered the red shift that led to ideas about the expansion of the universe. The dome first turned on metal wheels, and when those did not work out, they came up with a scheme to float the dome in a trough of water, but that rocked (in a bad way), and then they came up with the old Ford tires. Still there with shiny hub caps.

I was up there partly on vacation, partly to work with some people doing research on bats. We have integrated a BS2pe into a system that automatically records bat calls. I've always been interested in astronomy too, and know the constellations and individual stars pretty well. But I haven't gotten into making my own telescopes or running out to freeze my buns on winter nights!

I wonder about your RA drive. Do you use a stepper for that? If so, how often do you have to pulse it?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Tracy Allen
www.emesystems.com (http://www.emesystems.com)

Post Edited (Tracy Allen) : 11/16/2006 5:08:29 PM GMT

aquasapien
11-17-2006, 01:33 AM
That is way cool. To have just read a book and within weeks recieve pictures that very closely resembel my minds eye. The dome for that place was built by 10 cowboys in 10 days and is still functions...nice!

Thankyou. I guess the author is very good at articulating. It was a good book by the way. It was "Seeing In the Dark" by Timothy Ferris.

In the pic of the plaqard, could that by chance be guano droppings on it? What is the intended function of recording that bat calls?

My RA drive is a factory unit that indeed is a stepper mated to a gear box to allow the very slow motion without seeing th pulse of the motor steps in the optics. I have not hacked it yet but will soon as even in 8x speed mode it is sooo slow. Unfourtunetly, without a clucth mechanisim I can not disengage it to allow a stepper to slew the scope fast in the RA axis. I have been basically testing the set up by using a stepper on the secondary input shaft while disconneting the factory one.

I am able to manually drive the scope from the warmth of my own house and view realtime images with a web cam and do planatery photos using stacking sofware, but if I want to do exposures or deepspace I have to litterly go out and couple the secondary input shaft to the RA drive, replace the web cam with a better Nikon ccd cam.

My scope is only a six inch newtonian reflector, but its purpos is to act as a testbed for that day I build the 30 incher in the backyard and need to build my own tracking system to avoid remorgaging the hose to buy one. The whole project seemed like a bang bang bang done thing.

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
The singularity is close at hand, Genetics, Nanotechnology, Robotics...and I get to be alive to see it.