PDA

View Full Version : Cool project needs programming help!!



Biofuel_guy
10-09-2008, 04:48 PM
http://forums.parallax.com/images/smilies/idea.gifˇHello Everyone,
I've done my fair share of reading and exploring the BS1 and BS2 but to be honest, I simply don't have what it takes to complete my project. I honestly need a person who can write what seems to be a very simple program for a stamp application.

I would like to automate my biodiesel fuel washing system. This process is very time consuming and I have extremely limited free time.

So, here I am looking for at least one good person to end my frustration.
I've attached a word doc with my projects automation sequence.

Please let me know your thoughts.
Thanks,
Larry
vetteman7243@msn.com (mailto:vetteman7243@msn.com)

SRLM
10-09-2008, 11:30 PM
Wow. That's quite a project, but I think you can do it. You've already got the gist of how to program: break it into logical steps. Now just write the code for each. Mostly it seems that you have three different types of external devices: Fluid switch, Solinoid, and Relay. Once you figure out how to interface each of these with the BS2, then it's simply a matter of watching them and triggering at the correct moment.

SRLM
10-09-2008, 11:32 PM
Probably the easiest way for you to make it is to put each "step" that you outlined into a method, then just call those from a main method as neccessary (GOSUB step_1, GOSUB step_2, etc) You'll probably have lots of Do-While loops, since it seams like you're doing quite a bit of waiting/monitoring.

Lab Rat
10-10-2008, 12:15 AM
for outputs from the stamp to a higher voltage device i have been using solid state relays
it works but they are not the cheapest things you can buy

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
I`m not prejudice I hate everyone equally

Amaral
10-10-2008, 02:35 AM
is this an Commercial unit ?

Biofuel_guy
10-10-2008, 02:41 AM
Hey Guys,

There is no doubt I can do the job of programming this project. The problem is time. By the time I get the programming done I'll be old and wheelchair bound.

Seriously, I run a restaurant full time 12 to 14 hours 6 days a week. Sundays I have to get the other neglected tasks around the house done. I simply don't have the time or patience to learn the language and apply what I learn. Trust me, I'm not lazy..ˇ I just pick have to choose the things I know how to do and look for help with those I'm clueless on.

Oh and yes... I'm using SSR's I bought a while ago. The are 3-24v dc controlled. They are fantastic technology.

Thanks,

Larry

Biofuel_guy
10-10-2008, 03:27 AM
OK... Now that I've received several replies, how about someone bidding out the programming portion of this project. I can earn money. I can't earn time.

The way I see it is: You've got the talent and knowledge. I respect that! I'm in need of a simple program.

Any takers????

Thanks,
Larry

SRLM
10-10-2008, 04:06 AM
I'll take a look at it. No guarantees.

Lab Rat
10-10-2008, 08:11 AM
as a modifier to my previous reply i was playing around and found that using an opto isolator a 220 OHM resistor and a 12 vdc relay i can operate any voltage
and it actually works i have been playing with it

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
I`m not prejudice I hate everyone equally

Biofuel_guy
10-10-2008, 08:21 AM
Are you triggering the isolator directly from the output of the stamp?

Lab Rat
10-10-2008, 08:40 AM
no
doing this actually destroyed two of them this way
i put a 220 ohm resistor between the output of the stamp and the input of the isolater

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
I`m not prejudice I hate everyone equally

Biofuel_guy
10-10-2008, 09:49 AM
Yes.... That makes sense.. Current is a wicked thing especially in small circuits. What a great idea... I'll need to incorporate this into my final design. Thanks Lab Rat.

GICU812
10-10-2008, 12:36 PM
What stamp are you using? The BS2p's have poll functions that would make the L3 monitoring easier.

GICU812
10-10-2008, 01:18 PM
Okay, Ive got something going here.

First off, if you agree to use this, you agree to test all safteys and cutoffs, monitor several cycles manually, and test for every contigency possible before comitting this to unmonitored use. I do not guarentee that I followed your instructions, but I tried.

So basically, check to make sure there isnt any coding errors by causing some malfuctions and seeing how it reacts.

Secondly, make sure you monitor a couple of cycles and ensure that it is working how you requested before commiting this to unmonitored use

Third, I will not be held accoutable for any mistakes I may have made ( and ya'd hafta catch me first http://forums.parallax.com/images/smilies/tongue.gif )

As far as the compensation you were offering, please PM me about it if you are going to use this code, Im not materialistic, but I am in between jobs, and I did spend a few hours on this, more than I might normally just to help someone out on a forum.

Ive taken one liberty with this code, I am only checking for L3 when actually add fluids, not when settling or draining. I would reccomend a hardware interlock on this anyway, so that the adding valves are powered by a closed L3, this way, it can never overflow, the valves simply cannot open under any circumstance when the L3 is activated.

I have also added some debugging. When a startup error occurs, it flashes the YellowLED x number of times depending on which swtich is open Lx. I figure this might save some hair should it ever come up.

This might not be the most concise code, but im assuming you are dedicating this stamp to this task, and it only really takes up 1 byte of ram and 15% of codespace.

Post Edited (GICU812) : 10/10/2008 5:27:59 PM GMT

GICU812
10-10-2008, 01:22 PM
Oh, and that file isnt neccessarally final. If you need something added or changed, let me know. Also, of course, run through the code before loading it to make sure I understood what you were asking for. To be honest, Im not sure exactly why you are filling the tank with fuel before washing it out, but I just followed your document.


Hehe, Ive allready had to tweak it once, I had it set to wash for 2.4 seconds instead of 240 (4 minutes)
I fixed that, but it now uses 2 bytes of RAM, but I could rework that down probably.
I edited the file at 130PM EST, incase you had allready downloaded it.

Thats the kinda thing I need you to check for me. :D

Post Edited (GICU812) : 10/10/2008 5:28:12 PM GMT

SRLM
10-10-2008, 04:21 PM
Ah. Thanks GICU. My offer/looksie withdrawn.

GICU812
10-11-2008, 01:30 AM
Also, would you want to trigger the drain valve in the event of an overflow?

Perhaps, on overflow error, freeze and alarm, wait for Button1, on button1 open drain valve, wait x seconds, return to startup sequence and wait for start button

Because as it is coded, you would have to manually drain\reset the mechanics, as the software just drops everything and the only option is to reset and start the sequence over again.

Lab Rat
10-11-2008, 04:44 AM
aparently someone finally figured out what to do to kill some spare time lol (GICU812)

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
I`m not prejudice I hate everyone equally

Lab Rat
10-11-2008, 04:44 AM
aparently someone finally figured out what to do to kill some spare time lol (GICU812)

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
I`m not prejudice I hate everyone equally

GICU812
10-11-2008, 01:38 PM
Actually it was kind of fun to finally have a project to code for. Mine neveer seem to come to fruition.

Lab Rat
10-11-2008, 08:28 PM
i know what you mean

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
I`m not prejudice I hate everyone equally

GICU812
10-12-2008, 12:07 PM
Hows it looking?

I changed a few things, fixed a bug in the debug output,, fixedˇa timerˇerror (3 seconds instead of 30)ˇand a little cleanup knocked about 5 bytes off the size.

Newer version attatched (1.1)

You know we could easily add a serial LCD display to it. Would be able to assign fuctions to the button, and more easily display the error. They're only like $12

Id still like to have it wait for a button push that would open the drain valve on critical overflow. Let me know.

Anyone else want some coding done?


Post Edited (GICU812) : 10/12/2008 7:02:19 AM GMT

mobile_bob
10-12-2008, 01:26 PM
yes i too would like some coding done, but am not quite ready yet
still working on the hardware.

you will hear from me soon :)

bob g

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Dream it, design it, engineer it, build it, and

do what is necessary to make the damn thing work!