# Automating A Brewery



## Wortgames (27/9/06)

If you wanted to use a computer to automate some of the basic timing and temperature functions of a brewery, where would you start?

Presumably you would need some kind of serial interface to connect relays and sensors to, and a program to run it?

Is there anything off-the-shelf which would lend itself well to this?

Building an automation system from scratch is probably a bit beyond me, but I reckon I could have a good go at customising a 'universal' solution if such a beast existed...


----------



## JasonY (27/9/06)

How far are you looking at going? I have messed with some of the PC stuff and to be honest I found it to be a pain in the ass to have a PC in the brewery and eventually gave up. There are a number of PC based interface boards for reading data in and energising contacts. Not sure there are any good of the shelf software programs to match them with however.

If I embark on this again I will most certainly go for a cheapo PLC which has a few analog inputs for temperature measurement and a bunch or relay outputs. Something like this may fit the bill however I have not used one so can't vouch for it.

I think in the end to do a good job it will cost a bit but certainly be fun.


----------



## Wortgames (27/9/06)

Hi JasonY, to be honest I fancied taking a fairly 'organic' approach - start off with something that can manage an HLT element, for example, then expand to include switching the pump and perhaps a valve or two.

I've got an old laptop gathering dust that is worth nothing but should (hopefully) be capable of handling a couple of sensors and relays given the right interface. I can sit it up out of the way at the end of the 'brewery' so I'm not too worried about that.

To start with I would be happy to just get an alarm signal when a target is met, but over time to add a bit here and there, and slowly get it to handle more bits of the process.

I think it would be great fun to 'program' a brew, especially if I could get a real-time view of what's happening, what I'm waiting for and what happens next. It would be good to see real-time temperatures too. I might even be able to program in an "add Irish moss now" alarm... 

I guess the software is the key - I was guessing that hardware and software would go hand-in-hand - is this not the case?


----------



## barls (27/9/06)

im looking in to a similar thing but as a temp control for frementing ill let you know what i come up with


----------



## ArnieW (27/9/06)

Wortgames said:


> If you wanted to use a computer to automate some of the basic timing and temperature functions of a brewery, where would you start?
> 
> Presumably you would need some kind of serial interface to connect relays and sensors to, and a program to run it?
> 
> ...



Hi Wortgames,

take a look at:
HERMAN brewing machine

It's my home-grown machine/obsession. It sounds a bit like the kind of thing you'd like to do, although I'm not sure my own stuff is all that user friendly at this stage. 

The system currently uses a PC with my own program to control a pic micro that does all the magic with interfaces I've built myself. 

But I'm working on a new rig that will be much more modular and easier to use, so if you can wait a bit, maybe I can help.

But feel free to ask questions. 

cheers, Arnie


----------



## Shunty (27/9/06)

A guy from work is helping me build a microcontroller unit for the brewery, based on an ATMega32 chip

At this stage it is only controlling heating and cooling in the fermenting fridge, however there are a heap of outputs (32 total from memory) including pulse witdth modulated outputs for controling element temp via SSR's. The chip can take multiple sensors on the same 3-wire line, we are setting it up to average 3 sensors in the fridge for temp readings. The box outputs 12v to switch external relays

From memory the chip was about $15 NZ, LCD screen $30, and about $30 in misc parts - plus it is a heck of a lot smaler than a pc

Pics to come


----------



## Wortgames (27/9/06)

Neat site Arnie, good work! I guess that's pretty close to what I had in mind.

I fancy a PC & software system for ease of use and real-time intervention, I thought about the chip style but I don't think I'd be happy with the fiddly interface and from what I can work out you more or less need to 'flash' them with your settings before use, then stick to them?

It just struck me that a PC based system could start off as a basic script, timer, thermometer and remote control with very few devices - then as time and money permit you could add a valve here and a pump there and interact with more and more of the tasks.

Unfortunately I have no experience in this area so I don't have a clue what is available (or even where to look), but I'm guessing there must be some kind of customisable PC-based automation systems out there.

Whats the DSE stuff you used Arnie? The link in your site seems to have evolved since you posted it.

I keep looking at the Jaycar catalog too, there's probably something in there that would do the trick, but it's all Greek to me at the moment!


----------



## ArnieW (27/9/06)

Wortgames said:


> Whats the DSE stuff you used Arnie? The link in your site seems to have evolved since you posted it.
> 
> I keep looking at the Jaycar catalog too, there's probably something in there that would do the trick, but it's all Greek to me at the moment!


Hi again Wortgames.

The site is not really up to date. The pic micros are based on the picaxe system from this mob:
Revolution Education

I've long since ditched the parallel interface, although it might still be useful under the right conditions. I love the picaxe system because it is cheap, simple, easy to program, easy to interface, and simple to have things like digital temperature probes for accuracy.

You could run a system on picaxes alone (see my 'Fridge Controller') or use them to work with a PC. In the system I'm currently building I'm working on the idea that the picaxes use some onboard intelligence to work out what should be happening, but the PC acts as a coordinator to automate things. The picaxe works as a semi-automatic controller, but the PC holds all the discrete bits together and can control the whole system if needed.

There are commercially made interface boards (Jaycar, DSE and others) that will interface to a PC, but the picaxe manual gives you many interface ciruits as a starting point. I have done a lot of looking at micro chips and these seem to be the best entry level chips and very easy compared to most.

For about 5 years now I've had a PC running my brewery, and it doesn't really matter what you have hanging off the PC so long as it does the job of switching large currents (in my case up to 15A) safely.

cheers, Arnie


----------



## ArnieW (27/9/06)

Another thing I should have mentioned is that you can get "free" copies of VBexpress from Microsoft which will do the PC programming quite nicely (you can also do C I think).

So there is no excuse not to dabble if you are that way inclined.

cheers, Arnie


----------



## Wortgames (28/9/06)

_So there is no excuse not to dabble if you are that way inclined._ :beerbang: 


So you reckon VB Express is the go for running the thing? I programmed some BASIC as a kid, is it anything like that?!

I picture something like this as the program, how realistic is it?:

1. Timeswitch turns on in the morning, begins heating the HLT, triggers the program to start
2. HLT reaches temp, program triggers 'dough in' alarm (or later, opens valve to fill mash tun from HLT)
3. Program times the mash while monitoring temp and triggering heat as necessary
4. Program triggers 'sparge' alarm (or in future triggers valves & pump as necessary)
5. Program times the boil, alerts for hop additions (& Irish moss!)
6. Program monitors the temp during the chill and signals when cooled.

Even by automating the first bit I reckon I could get a big head start on brewday by waking up when it's ready to sparge :super: 

After that it's all icing on the cake.

Would a simple parallel (or serial?) interface be capable of handling this, with real-time status display? Would the addition of a picaxe help or hinder the PC dsplay? What sort of specs should I be looking for in an interface / picaxe?

It's going to be a steep learning curve so I want to keep it simple, but I always prefer learning from other people's mistakes and set myself up from the start for success  

:beer:


----------



## ArnieW (28/9/06)

> I picture something like this as the program, how realistic is it?:
> 
> 1. Timeswitch turns on in the morning, begins heating the HLT, triggers the program to start
> 2. HLT reaches temp, program triggers 'dough in' alarm (or later, opens valve to fill mash tun from HLT)
> ...



I do all of this and more currently with my system. The only things not yet implemented properly are auto ball valves and my level sensors are still a bit intermittent.

I found that a parallel interface can be quickly limiting, but with serial devices you can easily put them on a common line and address modules individually.

The picaxe gives you the option of having an intelligent processor without a computer, or you can make the two work together. I mainly use them as interfacing devices, but they have much more potential than that.

I find VB to be good because basic is easy for a casual programmer to get the hang of, and the visual part of it means you can draw what your screen will look like. Check out HERMAN program for a dodgy looking screen shot of my home brew program. It will give you an idea at least of what the thing is capable of.

cheers, Arnie


----------



## crozdog (28/9/06)

Wortgames,

you might want to have a look at the PLC's available from Onetemp (web site here).

Prices start @ $145 + gst for a 10 i/o unit The configuration software is windows based & is FREE! You can download the manual & softeare off the above web site to check out how tt use it. 

Onetemp have offices in Sydney, Melbourne, Brisbane & Adelaide. They also sell a range of sensors 7 other bits you may need. 

No affiliation blah blah etc.

Crozdog


----------



## Wortgames (28/9/06)

Dammit, I really am running out of excuses not to get into this :super:

What's the difference between a PLC, a PICAXE and an ATMega32? Are they more-or-less the same beast just from different manufacturers, or totally different technologies?

Arnie, I love that screenshot! I want one...


----------



## sqyre (28/9/06)

Hey,

I dont know much about programing or anything like that but someone once posted a link on here somewhere in the forums about a thing called a labjack. It's a USB I/O box thingy that takes tempreture probe whatchamacallits and all sorts of switching relay thingys and...... doo-lackys. :blink: 

Check it out here.
http://www.oceancontrols.com.au/data_acqui...labjack_u12.htm

When i was looking in to it i found a neat program that lets you draw circuit diagrams and create control panels just by draging and dropping components onto the screen.

You can download a demo but only use 10 components.
http://www.oceancontrols.com.au/pcb_softwa...ilab-expert.htm

Its a bit pricey but it looks like its a fairly easy thing to setup
especially for us blokes who CAN build Dicky Smith stuff but still can't program a video recorder.


----------



## ArnieW (28/9/06)

sqyre said:


> Hey,
> 
> I dont know much about programing or anything like that but someone once posted a link on here somewhere in the forums about a thing called a labjack. It's a USB I/O box thingy that takes tempreture probe whatchamacallits and all sorts of switching relay thingys and...... doo-lackys. :blink:
> 
> ...



Good find Sqyre,

there was nothing like that around when I first started my experimenting in 1999 or 2000. Just the DSE parallel port interface.

Looks like a versatile and simple/easy to get running option, but you do pay for it. I'd guess that temp probe is based on an LM35 which costs less than $5. But with a cable and a nice looking protective shroud you pay $60 for the privelege.

Still, looks good.

cheers, Arnie


----------



## chimera (28/9/06)

Looks a lot like work.

My fermenter temperature controller is a reprogrammed oxygen analyser, uses LM35 sensors and switches a relay to control an electric blanket.

Ive also written numerous controller systems for industrial & military use, and i'll concede the code has been adapted from numerous sources, one being a HLT from a HERMES homebrew system.

Lastly, anybody who wants to pay $60 for the privelege of a LM35 protective shrouded on a cable, send the money to me, ill make one for you!


----------



## Wortgames (28/9/06)

I just Googled LM35, looks like they are probably a good choice for accurate temp sensing?

Would they be compatible with all the options mentioned above?


----------



## chimera (28/9/06)

To be suitable for your use you'll need a device with an analog input scaled something similar to 0-1000mV.

Providing that it would be quite suitable for a PLC or a PIC controller.


----------



## ArnieW (28/9/06)

Hi Wortgames,

you can use an LM35 with Picaxe and the labjack. For it to be ideal with either system, you'd want to amplify it. Straight out of the box, the picaxe will give you 0.5 degC resolution, but this can be improved with an amp. The alternative (and what I use) is a DS18B20 which is a digital temperature probe that the picaxe can read. It is very accurate and stable. It is capable of reading to a ridiculous number of decimal places. In my system I read in 0.1degC steps. I've got both in my electronics kit, cos you never know when you might need them.  

There are many ways to do what you want. A PLC is an industrial strength controller that would certainly do what you want. You will still need to think about interfacing though. The other chips will be more versatile but take longer to work a solution out.

Arnie


----------



## chimera (28/9/06)

Wortgames

if you're looking to automate, probably the first thing you want to do is draw up some sort of system diagram. Include all the temperature sensors, level sensors, heater elements, pumps, solenoid valves etc.

Assuming you're looking to hook up a computer to be the brains of the operation, you'll need a series of analog inputs for things like temperature sensors, digital inputs for level sensors, digital outputs to drive relays which will switch your high voltage stuff like heaters, solenoids, pumps etc.

One device im familiar with is a national instruments USB I/O module. Sub $300 you get a device with 8 12-bit ADC inputs, 2 12-bit DAC outputs, 12 digital I/O lines, which sould be enough for all but the most complex HERMES system.
Dont have a linky, look up NI USB-6008
Its all compatible with LabView software which I believe you can integrate into visual studio.

Once you go down this path, you'll have to source relays, rewire your system via relays into the IO board, and if you get this far then you get to start the fun part of writing software to control and later hopefully automate the system.

Some of the RIMS systems people have build up and have displayed on the internet are brilliant, shows many smart people drink & brew. Im happy to help you out with this, im a research engineer/embedded systems programmer by day, and believe beer related hobbies should could easily involve computer programming, control systems, mains voltage switching, automation loops etc, just as long as you've still got one hand free to hold your beer.


----------



## Wortgames (28/9/06)

_Its all compatible with LabView software which I believe you can integrate into visual studio._

I think for $1200 it would want to clean up after the brew and fetch my slippers too  


I love the idea of integrating some gadgets but I think 'planning' might be a bit extreme.

I guess ultimately it would be cool to have 6 or so temp probes, a pump, a few valves, an element or two and maybe a couple of motorised gadgets.

The first stage as I see it though is to get a couple of probes and use the computer to simply monitor temps at a couple of points and manually switch a couple of devices, then work towards automating those bits and expanding on it based on my programming proficiency.

I've downloaded VBExpress and can't make head or tail of it yet, but I suspect it will be a handy tool to become proficient with and I have some experience with BASIC and MS Access & Excel which might help to get me off the ground.

I also downloaded the trial version of ProfiLab Expert, and it looks fairly straightforward once you get to grips with it, but the ProfiLab / LabJack combination would obviously place all the load on the computer which might be a big ask.

Using a PIC / PLC / wotsit might help to take some of the strain off an old computer.


----------



## chimera (29/9/06)

$1200? aah, you hadnt yet found VS Express versions yet.

To be honest, Im not much for VS myself, but most these sorts of DIO / PLC products either have their own propietry interface, or VS APIs (or both).

Its a learning curve to be sure, but think about the beer!


----------



## ausdb (29/9/06)

crozdog said:


> you might want to have a look at the PLC's available from Onetemp (web site here).
> 
> Prices start @ $145 + gst for a 10 i/o unit The configuration software is windows based & is FREE! You can download the manual & softeare off the above web site to check out how tt use it.



One thing to watch for with the cheap PLC's is the input ytpes, if you are trying to monitor a variable like mash temps or hot liquor temps then you will need one with analogue inputs. I have been rolling this idea around in my head too and are not sure which way to go. Soldering things together is no problems but programming code is not my forte either  

My ultimate dream a fully automated all in one system that automatically lifts the bucket out of the urn, boils, doe automated hop additions, then chills and fills the fermenter :excl:


----------



## Wortgames (29/9/06)

I was actually referring to LabView, which seems to start at $1200?

http://www.ni.com/labview/

A bit rich for my blood!


So far, the software choice looks like being VB Express (free, but a steep learning curve) or ProfiLab Expert ($165, but probably easier to program).

Hardware-wise it's looking like a 'PLC' / 'PIC' / 'whatever the hell the others are called' is virtually essential (any advice on choosing between them?)

It would be interesting to know how well the LabJack option works - but my gut feeling is that it would deliver too much computational work back to the computer, as it appears to be a totally passive connection box. I'm sure this would be no problem on a newer computer but I'm begining to think it might be too much traffic for an old P166MMX running 98.

With a PIC or similar, mundane tasks such as temperature control could be performed independently without having to bother the computer, right? Then just use the computer to interject as necessary?

Can you interact with all of the devices (PLC / PICAXE / ATMega32 / any others) in real time from a PC?

Are there pros / cons to each type of device?


----------



## sluggerdog (29/9/06)

sort of on topic, I had thought about something similar myself but start with the basics.

I was thinking a simple tap timer like: http://cgi.ebay.com.au/Gardena-Electronic-...1QQcmdZViewItem

to start and stop the hlt going into the mash tun however it would need to be ran per litre rather then time, does anyone know if there is such a thing available?


----------



## chimera (29/9/06)

the PLCs do look rather good.

When (I say when, but I have no plans yet) I go down the path of automation i'd want a system that didnt require a PC link, and these PLCs appear to have this potential.


----------



## DJR (29/9/06)

The NI boards if i remember correctly have a free development driver that can be used in VB, C++ etc called NI-DAQ. Hard to find on their site because they want to sell Labview but the NI-DAQ suite will work fine. Might just want to email them about the output capability though, we only ever used it for data acquisition purposes on an input-only board. Labview AFAIK is more of a program creation tool in itself.


----------



## DJR (29/9/06)

sluggerdog said:


> sort of on topic, I had thought about something similar myself but start with the basics.
> 
> I was thinking a simple tap timer like: http://cgi.ebay.com.au/Gardena-Electronic-...1QQcmdZViewItem
> 
> to start and stop the hlt going into the mash tun however it would need to be ran per litre rather then time, does anyone know if there is such a thing available?



A float switch to set the water level would be good, so that when the water level hits a certain amount the flow from the HLT stops, but then you'd have to use a actuated valve of some sort, Geordi wants $300 each for a actuated ball valve so i wonder if there's something more cost effective about?

Edit: something like this for a float switch: http://www.electusdistribution.com.au/prod...D&SUBCATID=

Another edit: Found this 1/2 BSP solenoid, rated to 90C with a 40% duty cycle, should be OK for most applications, for $30 who cares:
http://www.rsaustralia.com/cgi-bin/bv/rsww...heID=aunetscape


----------



## Wortgames (29/9/06)

I had another look at crozdog's link, they look like a pretty good deal in comparison to the others: http://www.onetemp.com.au/PLC's.htm

$260 for a 12-input 8-output device, and free QuickII software (which I have downloaded and will play with later). The only other expense looks like a $35 PC link.

I have a couple of temperature sensors laying around that might do to get started with, I already have a pump and an element in the HLT, so it looks like I could begin automating for around $300.

That PLC is probably overkill but it would be good to have the options for future expansion. I'd like to end up with a couple of temp probes in each vessel, to get a visual idea of temp stratification, as well as sensing incoming water temps etc. Add a couple of water level sensors and I'll fill up 12 slots quite quickly I reckon!

Does this look like a good plan?

It may even be that I can use VBExpress at some point in the future to improve the graphical interface, it doesn't look like QuickII has much scope in this department.


----------



## chimera (29/9/06)

Wortgames - had a play with that Quick II program. For the price, if those PLCs could be used to automate It'd be a top solution.

I cant say much about how to make them work with analog inputs, my experience of PLCs has been all digital I/O.


----------



## Wortgames (29/9/06)

They appear to be the same device that Ocean Controls are selling: http://www.oceancontrols.com.au/plc/fab_plc.htm (thanks JasonY for the link) but OneTemp are slightly cheaper (it looks like Ocean Controls include the LCD panel as standard, but their prices are still a bit higher regardless).

There are a couple of different models available - some are digital only, and others have selectable digital / analog inputs (which is what I'd be getting I guess).





There are also some models there listed as "AC input" - I don't know what this means, maybe analog only? Anyone?


----------



## Wortgames (29/9/06)

Hmm, could be back to the drawing board - I just spoke to a very helpful guy at OneTemp, and while he wasn't sure, he felt pretty confident that the PLCs don't offer real-time interaction with a PC. You can only use the PC to create your program, then you write it to the PLC. You can't tinker with anything during a running process and you can't read temps via the PC.

I also spoke to someone at Ocean Controls, who wasn't much more knowledgable, but he seemed pretty certain that you CAN monitor them in real time (ie, view temps etc) and that you can even adjust analog values (eg setpoints), but he didn't know if you could actually interact with them in terms of 'pausing' the program or manually overriding things. However we both decided that this _might_ be possible by sacrificing one of the inputs as an 'override' switch, and getting the PLC to check the switch before performing each task.

This is going to be hard if even the guys selling these things aren't sure what they can and can't do!

It's looking as if something like the LabJack might be back in pole position, and finding (or making) the right software is the secret to this.


----------



## ArnieW (29/9/06)

DJR said:


> Another edit: Found this 1/2 BSP solenoid, rated to 90C with a 40% duty cycle, should be OK for most applications, for $30 who cares:
> http://www.rsaustralia.com/cgi-bin/bv/rsww...heID=aunetscape


Hi DJR,

I tried to follow that RS link but didn't end up at a solenoid. But for $30 I'd be very surprised if it were suitable for brewing. Most cheap (ie. garden water system types) solenoids work with back pressure (like mains water pressure) and only have a pin hole diaphram - which means that the smallest bit of grain will clog it. This is why the watering system solenoids have an inbuilt filter.

A solenoid for brewing is more likely to be some kind of motorised ball valve, and these do not come cheap. I've been playing around with automating ball valves for about 4 years, and am close to a solution that I like. ONe of the issues is that as the taps get hot, they expand and get tigher, requiring more grunt to operate.




I've added a pic of my latest experiment. Basically it is a grunty geared down DC motor that drives a screw thread that then pushes or pulls the handle on the ball valve. There is a variable resistor mounted on teh top that will ultimately give the control part feedback on valve position, a bit like a servo motor.

cheers, Arnie


----------



## DJR (29/9/06)

Most PLC's are pretty much set and forget, however you could get them to have a function that reports on the status of the various inputs, but i've only seen this for one particular PLC (a Koyo DL05, not sure if it could be done on others). If you're going to have a PC involved anyway, you might as well go the Labjack, get the drivers and write up a little VB Express program for it. You could also get a copy of VB6 from somebody who has an old copy as that's probably enough. But it will require a bit of coding to get it all going.


----------



## DJR (29/9/06)

ArnieW said:


> Hi DJR,
> 
> I tried to follow that RS link but didn't end up at a solenoid. But for $30 I'd be very surprised if it were suitable for brewing. Most cheap (ie. garden water system types) solenoids work with back pressure (like mains water pressure) and only have a pin hole diaphram - which means that the smallest bit of grain will clog it. This is why the watering system solenoids have an inbuilt filter.
> 
> ...



Nice work Arnie - the solenoid valve i put a link to (which didn't work, harumph) was just a $30 nylon solenoid that would be fine for controlling the output of a HLT - but as you say, when grain is involved for a RIMS/HERMS setup then you need a ball valve. The Geordi 3 pc ones with actuator go for $300 so i think if i was going to do it i'd just buy 2 or 3 of them - but for cheap HERMS/RIMS setups then you'd need something like what you've put together.

Edit: here's a link that works this time http://www.rsaustralia.com/cgi-bin/bv/rsww...amp;Ntt=342-023


----------



## ArnieW (29/9/06)

Wortgames said:


> Hardware-wise it's looking like a 'PLC' / 'PIC' / 'whatever the hell the others are called' is virtually essential (any advice on choosing between them?)
> 
> It would be interesting to know how well the LabJack option works - but my gut feeling is that it would deliver too much computational work back to the computer, as it appears to be a totally passive connection box. I'm sure this would be no problem on a newer computer but I'm begining to think it might be too much traffic for an old P166MMX running 98.
> 
> ...



Hi Wortgames,

A PLC will be easier to start with, but may not be as flexible as you would like. A PIC is a microcontroller in a chip, so you can just about do any automated task with the right model. Some PICs are really difficult to program, others are much simpler. The reason the PICAXE is so popular is that the price is right and they are really simple to use because they are targetted at school classrooms.

With a PLC you usually get some basic interfacing/connections. You will still need to build your own to automate your rig. With a PIC you will need to build everything from the ground up. This is what I'm currently doing (actually making printed circuit boards today), so maybe we can talk a bit more about what is possible off-line.

You can certainly interact in real time with PIC based devices with a computer. Check out Hippy's Picaxe Q & A for more details on how you can do lots of stuff with a picaxe, including serial comms which means comms with a PC.

I can give you code examples in visual basic based on my own controller too.

And your 166Mhz Win 98 laptop will do surprisingly well. You don't need to read a temp every second. If you think about how slowly (compared to a computer processor) things change during a mash, you will realise that you actually don't need much processing grunt to drive a brewing machine. My first machine was on a Win 3.1 laptop (admittedly running VB3) and no problems with speed.

My backup laptop I think runs at 166MHz and was coded in VB6, again no performance issues.

Keep dreaming wortgames,

cheers, Arnie


----------



## bigfridge (29/9/06)

Wortgames said:


> Hmm, could be back to the drawing board - I just spoke to a very helpful guy at OneTemp, and while he wasn't sure, he felt pretty confident that the PLCs don't offer real-time interaction with a PC. You can only use the PC to create your program, then you write it to the PLC. You can't tinker with anything during a running process and you can't read temps via the PC.
> 
> I also spoke to someone at Ocean Controls, who wasn't much more knowledgable, but he seemed pretty certain that you CAN monitor them in real time (ie, view temps etc) and that you can even adjust analog values (eg setpoints), but he didn't know if you could actually interact with them in terms of 'pausing' the program or manually overriding things. However we both decided that this _might_ be possible by sacrificing one of the inputs as an 'override' switch, and getting the PLC to check the switch before performing each task.



WortGames,

NNL Beer Supplies has a unit under development that is based on a standalone microprocessor with a built in web server. This lets you point your PC at it to read or change any values using just a web browser, but the unit runs indepandantly just like any other temperature conroller. The unit that we are using has heaps of digital and analogue I/O's so you can read and control temperatures, fluid levels, relays solenoids etc. It has a built in RTC (Real Time CLock) so that it can handle having your HLT up to temperature ready for you to start in the morning.

We will have the first one running in our brewery by the end of the year and then they will be available to buy for between $500 - $1000 for the basic model.

My aim is to make the brewery run just like a washing machine - stepping through the various 'cycles' and riging a bell when the wort is ready to pitch the yeast.

HTH,
Dave


----------



## Wortgames (29/9/06)

Good on you Arnie, I have a feeling you are going to be my ticket to success here :beer: 

The only thing that puts me off the picaxe approach is that it is starting a bit too far down the ladder for my liking - there already aren't enough hours in the day for me to do what I need to do anyway, so starting from scratch with an IC, a soldering iron and a book on electronics theory just isn't going to happen.

The PLC is probably a great idea if you can see yourself getting to a point where the whole thing is fully automated - but I think that will be out of my reach for a while, so I need a more hands-on, real-time solution.

I'm heartened to hear you say the laptop will be up to the task - at least that fits with what I originally had in mind, a computer program doing all the work, where I can click on things to make them happen and automate a few routines.

Do you think the LabJack is the best option for an interface or are there others?

I don't have USB on the laptop but I can probably get hold of a USB PCMCIA card.


----------



## Wortgames (29/9/06)

bigfridge said:


> My aim is to make the brewery run just like a washing machine - stepping through the various 'cycles' and riging a bell when the wort is ready to pitch the yeast.



An excellent analogy!

I suspect it will take me a long time before I'm at that stage though - I'm happy to turn the odd valve myself but if I can automate a few procedures (eg the mash) and monitor a few others (the boil, the chill) from the comfort of an armchair with a beer in one hand and a mouse in the other, then I'll be a very smug little brewer indeed...

:super:


----------



## ArnieW (29/9/06)

Wortgames said:


> Do you think the LabJack is the best option for an interface or are there others?
> 
> I don't have USB on the laptop but I can probably get hold of a USB PCMCIA card.



I don't really know, to be honest. It depends a bit on how much work it is getting access to real time information off the labjack via VB. 

I am close to testing a Tun controller if that helps. This is what I'm currently building circuits for.

It is picaxe based with serial comms to PC. With the PC connected you have PID control of a 20A solid state relay. If no PC is connected, you can still vary temperature setpoint and power %. The unit includes level sensors to make sure you can't turn a heater on when a tun is dry.

As you say though, there are too many things to do. I'm on leave at the moment and unlikely to get the boards done before I'm back at work, but I am getting closer. The Picaxe coding is just about done, and the PC end of it should not be too difficult. 

The only real problem now is that I've already had a glass of Helles and tomorrow is grand final day ...

cheers, Arnie :beerbang:


----------



## Wortgames (29/9/06)

ArnieW said:


> I don't really know, to be honest. It depends a bit on how much work it is getting access to real time information off the labjack via VB.



I'll try and find out some more on Monday. I'm going to call back Ocean Controls, and hopefully get a bit more info regarding the 'interactiveness' of PLCs, I'll also see what they've got to say about using LabJack with VB Express.

LabJack comes with some software, it's a bit confusing trying to work out exactly what though. I'll grill them about it on Monday.


----------



## Zizzle (30/9/06)

Here is my setup using a PC running Linux, some DS1820s and a relay board which I put together for about $20.

http://www.aussiehomebrewer.com/forum/inde...showtopic=10518

Hopefully soon I will also be using it to controll my BIAB mash temps.

Also talked some BS with Pat about having a winch controlled. Imagine this automation:

Night before: fill kettle with water, bag with grain.

Automation begins in the morning: water is heated, winch lowers bag with grain, wait 90 mins maintain temps, winch out bag, begin boil. Hop addition would still need to be done by someone.


----------



## Wortgames (30/9/06)

I realise there is a whole thread going on at the moment about using an immersed grain bag, but I was thinking more along these lines:

1. Timeswitch activates HLT at some ridiculously early time in the morning.
2. HLT reaches temp and switches off.
3. Valve opens, empties HLT into mashtun (mashtun already contains grist, hot liquor is underlet).
4. Mash timer begins. Coffee machine turns on.
5. Alarm sounds when initial mash stage is complete and coffee is ready.
6. I get out of bed to the combined aromas of maris otter and arabica.

:super:


----------



## JasonY (30/9/06)

Wortgames said:


> I realise there is a whole thread going on at the moment about using an immersed grain bag, but I was thinking more along these lines:
> 
> 1. Timeswitch activates HLT at some ridiculously early time in the morning.
> 2. HLT reaches temp and switches off.
> ...




WG, I would definately think about what tasks you want to automate now and in the future. Personally I can't see full automation being worth the effort.

Steps 1 - 4 yes but I would want to have a mash stirrer or something to make sure I don't have a dough ball.

Automated fly sparging would be cool and I only mean in terms of controlling the water from HLT to mash tun not the runoff rate. you would need to set the run off rate but then tell the system to finish the job.

Auto hop adder as shown in the system above would be good too!

Apart from that the only other things I would hope to achieve (assuming things are in the same room) would be monitoring the fermentation fridge & possibly changing setpoints on it for lagers etc? 

If I ever get to it I will be striving to make it have wireless connectivity so I can watch stuff from in the house. Can't say I am anywhere near it now however  

Very interesting to see ppls setups as they go through this!


----------



## Wortgames (30/9/06)

I agree, full automation would be costly and probably of little benefit (unless you were brewing on a daily basis or you were a techno freak anyway).

I have independent temp controllers for my ferm fridges, so they aren't part of the mix at this stage, and while looking at ferm temperature graphs may be mildly interesting I can't really see it improving my beer or making life easier.

It is fascinating to see the 'extreme techno' systems with web interfaces etc, but at this stage all I want to do is to automate some of the more tedious tasks on brewday (mainly timing, temperature and liquid level control) and also reduce human error by laying out every step of the process in advance and sticking to a script.

To a certain extent, even a real-time computer program that didn't actually interface with anything would be helpful - something that would step through the process, time key events and keep me to the master plan. Obviously where it gets exciting is when it can measure and control a few sequences while it is at it.

It just strikes me that it would be great to limit my own potential damage on brewday if I am distracted by other things. A buzzer would alert me to impending tasks, like rearranging some hoses or adding hops, and ultimately I would just assist the program to do the brewing.

So how's this as a prototype software 'brief':

The ideal interface would have 2 windows. The first window would be a graphical representation of the brewery, along with thermometers at key points and perhaps liquid level indicators, pump status and 'active' pipe indicators. It would allow the user to override some things, for example to switch off a valve or pump if necessary or adjust a set point. Think of this as a central 'remote control' for electrical components as well as an easy way to confirm things like temperatures. In an advanced stage, this could even trigger an alarm if temperatures were not within a certain range, which might signal a closed valve for example. 

The second window is a 'brew program' that steps through in real time, much like video editing software. Perhaps you could have a separate 'track' for each output, and you could drag the bar to your desired start and end points. At any time you can see what is currently occurring and what is about to happen next (and when, or what it's trigger will be). It could even have a 'dead man' check-box that you use to confirm that manual tasks such as rearranging hoses or opening valves have been completed ready for the next stage to occur automatically. At any time this script can be 'paused' for manual intervention, and resumed from a different point (this is what PLC's cannot do, it seems).

Of course, half the fun will be in tweaking it each time to polish the process or incorporate a new piece of automation once it has proved to be reliable, so it needs to be relatively easy to rearrange or insert new routines.

How's that? :super:


----------



## Shunty (30/9/06)

Wally

Would i be correct in saying you can program them in C as well? If so I may be able to sort something out for you (I work with a couple of C geniuses)

Cheers
Andrew


----------



## sqyre (30/9/06)

I made a soluniod from a 1/4 turn ball valve and a central locking actuator years ago.

It worked awsome as a fuel switch-over in my custom built landcruiser.

best thing about the central locking units they are pretty strong and you just have to reverse the polarity to push the other way...

Just cut the handle off about 15-20mm up drill ahole and position the central locker so on full extention its fully closed and on retraction the valve is fully open..or viseaversa..

Takes a little mucking with the initial setup but works a charm..



Dunno if this helps with anything... :huh:


----------



## Crazy (1/10/06)

sqyre said:


> I made a soluniod from a 1/4 turn ball valve and a central locking actuator years ago.
> 
> It worked awsome as a fuel switch-over in my custom built landcruiser.
> 
> ...



Sqyre

That is one of the smartest things I have seen writen in ages. I was about to go down the track of little motor drivin 1/4 turns after being unable to locate and cost efective pnumatic actuators. I have a hand full of central locking solaniods in the shed too.

Regards Derrick


----------



## ArnieW (1/10/06)

sqyre said:


> I made a soluniod from a 1/4 turn ball valve and a central locking actuator years ago.
> 
> It worked awsome as a fuel switch-over in my custom built landcruiser.
> 
> ...


Hi Sqyre, nice idea. 

My achilles heel with inventing is a tendency to over-complicate things. I know these solenoids pull quite a load, but I wonder how they'd go with a hot ball valve? I've got a set in my bits box, so I'll have to give it a go sometime.

cheers, Arnie


----------



## Wortgames (1/10/06)

ArnieW said:


> I know these solenoids pull quite a load, but I wonder how they'd go with a hot ball valve?


I can't see this being a problem at all, especially as one of the key technologies in central locking systems is bits of wire bent to the appropriate shape


----------



## Maxt (2/10/06)

sqyre said:


> .... you just have to reverse the polarity




I thought this only worked in Sci fi :blink: :blink:


----------



## sqyre (2/10/06)

> I thought this only worked in Sci fi :blink: :blink:


Only when there are fluctuations in the warpcore....


----------



## Wortgames (2/10/06)

I've been fidgeting like a naughty school boy today. I made this in Photoshop - what do you reckon?


----------



## ArnieW (2/10/06)

Wortgames said:


> I've been fidgeting like a naughty school boy today. I made this in Photoshop - what do you reckon?
> 
> View attachment 9350


Hi Wortgames,

good work, a good way to start the process of automation. My own screen schematic shows in a simple form the status/configuration of the brewery. The physical layout matches the important bits (at least in my mind) of what is actually happening. There are of course many ways to do this. I'd suggest you do whatever makes sense to you.

The devil is in the detail, especially when it comes to writing code to control things. You will soon realise all the things you'd never thought of before. I've approached it from a quality assurance point of view. My code effecively leads me through predictable steps towards a consistent quality. Even if I know what is going on, the program will give me reminders of which chemicals to add to the mash at exactly the right time. Even if I know that at the end of boil I should turn the kettle off, the machine will automatically turn it off unless I override it ...

I found a good place to start was to document all the little bits on a real brewday - like take a note of every time you turn a ball valve on or off.

The other bit I've come to realise is that the machine needs to work well - be a configuration you're happy with - be free of problems like stuck recircs etc - before you begin the work of automating. My rule of thumb is that if I can brew without problems (it took a long time to fix leaks, air in the line causing the pump to perform poorly, a false bottom that couldn't handle things etc.), then I am ready to inject some artificial intelligence into the machine.

:super: Arnie


----------



## Wortgames (3/10/06)

Good points Arnie, but I really want to keep the automation side of things flexible enough to be able to start using it much earlier. Essentially create a kind of 'universal remote control' that will let me link and edit processes according to my whim, rather than plan out the entire thing beforehand (which will probably never happen, I am always changing something).

My system is fairly basic really, it is all separate parts which get plumbed together on brewday. I may incorporate it all into a compact rack like yours one day, but for now it fits me and my facilities.

I currently use hoses and quick disconnects to 'repatch' lines rather than using hard pipes and valves, and I am happy to continue with a largely manual approach to things like priming pumps and tweaking flow rates, but like yourself I want to eliminate human error as much as possible and go for consistent and repeatable results by, for example, always monitoring temps at the same places, timing things accurately and having the next process ready to go at the touch of a ball valve or at a target value being met.

One of my problems is that I brew so infrequently. It is a major investment of time, and I feel like I am starting from scratch every time which reduces my efficiency. So some automation of basic steps and a blow-by-blow plan of attack would both be really helpful to keep me on track and to babysit certain things while I'm distracted.

Are you aware of any software that would give me that sort of real-time access to add, edit or remove upcoming command lines, pause the 'script' etc? Do you reckon it would be doable in VBE?


----------



## ArnieW (3/10/06)

Wortgames said:


> Are you aware of any software that would give me that sort of real-time access to add, edit or remove upcoming command lines, pause the 'script' etc?


Not really - although the labjack stuff you were looking at might do that kind of thing. I have done it with my own system, and you are welcome to the code (it is a hack job and not well documented - details are a weakness  

Currently I have a system where I write a script that is specific to my own machine. The code reads a line of script and then figures out what to do with it. I can pause the script, go to any position in the script, and insert manual commands at any time.

You might find there is enough of an example there to figure out your own system, although in reality you would have to re-write it for whatever bits you have hanging off the PC. 



Wortgames said:


> Do you reckon it would be doable in VBE?


Most certainly. I've done it in VB6 and intend to re-code with VB2005 (but that is still a long way off).

Arnie


----------



## roger mellie (3/10/06)

Stumbled across this site whislt I was looking for a cheap PLC for a project I am working on. US259 for 8 Analog IO and 16 Digital IO - this would seem to be any amount for a brewery.

http://www.lt-automation.com/T100%28e%29.htm

The PLC monitoring ability is provided by Modbus - which allows communicatios to any number of HMI type SCADA packages - some of which allow free access to some of their functions - or a limited number of IO points or 'tags'.

Whilst 'dabbling' in VB to get interation with your process might seem 'do-able' to some - an interface to a PC based HMI package would definitely be more mainstream.

RM


----------



## Wortgames (3/10/06)

I'll certainly take you up on your kind offer Arnie, I think a copy of your existing software will be invaluable in figuring out what I need to do.

I spoke to Ocean Controls again. The PLC's _may_ lend themselves to intervention, but unfortunately all the documentation is Chinese and the controls themselves aren't very intuitive. The consensus seems to be that they are probably not ideal.

LabJack looks quite promising however. It comes with something called DaqFactory Express software, but there don't seem to be any examples of that on the website. There is another option called ISEE which is $45, I have downloaded the trial version of that but it makes no sense at all without the labjack. Finally there is the ProfiLab Expert software for $165 which looks quite impressive and there's a trial version available. Screenshots and info here:

http://oceancontrols.com.au/pcb_software/b...ilab-expert.htm

Apparently though, the labjack is pretty versatile and should be fully compatible with VB. It comes with a swag of DLLs and its own ActiveX control, and it is designed to integrate with a range of systems.

So I'm thinking maybe I'll start off with a labjack, and give ProfiLab a run to see what it can do. If ProfiLab is no good the LabJack should still be a good start for setting up my own control.

Thanks again to Sqyre for posting the LabJack info - it looks like it may be the best option!


----------



## Wortgames (3/10/06)

roger mellie said:


> Stumbled across this site whislt I was looking for a cheap PLC for a project I am working on. US259 for 8 Analog IO and 16 Digital IO - this would seem to be any amount for a brewery.
> 
> http://www.lt-automation.com/T100%28e%29.htm
> 
> ...




OK, that looks pretty interesting too. It certainly looks like you can interact with it in terms of pushing buttons on and off.

I'm confused again now.


----------



## ArnieW (3/10/06)

roger mellie said:


> Stumbled across this site whislt I was looking for a cheap PLC for a project I am working on. US259 for 8 Analog IO and 16 Digital IO - this would seem to be any amount for a brewery.
> 
> http://www.lt-automation.com/T100%28e%29.htm
> 
> ...


Wow, great find RM. The price rocks, as do the features. I do like the idea of wireless control, and remote internet control.

I used PLCs in industry nearly 20 years ago. They certainly have come a long way. Makes me feel a bit nostalgic looking at ladder diagrams though.

Wortgames, I think this might be more suitable than a labjack. Worth reading up on at least. I've just read the circuit cellar review and I want one ... Pity I've invested so much time and effort into a custom system. :blink: 

keep inventing, and brewing great beer, 
Arnie


----------



## roger mellie (3/10/06)

ArnieW said:


> roger mellie said:
> 
> 
> > Stumbled across this site whislt I was looking for a cheap PLC for a project I am working on. US259 for 8 Analog IO and 16 Digital IO - this would seem to be any amount for a brewery.
> ...



It doesnt get much simpler than ladder. The ability to write little basic scripts should make communicating with a HMI package pretty simple. I would imagine that analog comparators would make up the bulk of the code - certainly seems to have that functionality available.

PM me if you are going to go down this road - the main windows HMI package that I use has a free demo available with 32 tags - I could let you have a copy unoffically - the Modbus Driver is available also.

RM


----------



## Wortgames (3/10/06)

I sent them a quick question by email and got a full price list by what looks like auto-reply:

View attachment PriceList.pdf



Can anyone see anywhere on the website that it clearly states how interactive it can be? Not being an expert I'm not really sure what sort of spec I'm looking for. I'm assuming that you can mess about with it in real-time via ethernet (or internet!) but I'd hate to spend all that money on an assumption!


----------



## roger mellie (3/10/06)

Wortgames said:


> I sent them a quick question by email and got a full price list by what looks like auto-reply:
> 
> View attachment 9355
> 
> ...



From what I can gather - the main method of interacting with the PLC would be via serial means - RS-232 via a comms port on a PC. This appears to be inbuilt.

The TCP/IP route requires additional hardware (199 by the looks of things) and is more of a nice to have.

If all you want to do is have a PLC doing stuff automatically, and you then want to interact with that - like changing a temperature setpoint, animate a process page to see whether a valve is open or closed (or indeed open or close a valve), have a sequence that allows you to start , stop, pause etc... then it looks like this little PLC coupled with a windows based HMI (human machine interface) through a Modbus driver (server) would do the trick.

It would certainly be worthwhile asking the questions to the website to confirm this.
RM


----------



## Wortgames (4/10/06)

OK, I sent them an email last night and had this response in my inbox this morning:

-----

_*From: Latin-Tech Inc*_
_*Subject: Our PLC in your Brewery*_

_*Yes, the T100MD2424 can do the job ( http://www.lt-automation.com/T100(e).htm ).
You can do on-line programming or monitoring, either connected to a PC or through internet.
You can make a program that contains an Automatic and a Manual way to run. Using a software key ( from a SCADA or an EXCEL's button) you can switch fom Automatic to Manual, overriding any part of the process.
You can make on-line (real time) changes for temperature setpoints, timer values or any other parameters without stopping the normal operation.
In general you can do the following;
1) Develop a PLC program that allows you to work in automatic (no intervention) or manual modes.
2) Using a SCADA or EXCELL ( http://www.lt-automation.com/Scadas(ing).htm ), you can monitor or change operation parameters.
3) If you have a PC with internet connection and you connect the PLC to this PC, then you are able to access the PLC from any other place, through internet, at no extra cost.
4) Our PLC can be programmed in ladder +Basic, so you can develope several "recipes", simply by changing variables in BASIC
5) With our voice modules ( http://lt-automation.com/VoiceModule.htm ) you can add voice messages for alarms, process functions,etc

If you need any further assistance, please do no hesitate in contacting us again*_

-----

So apart from the shock of having a prompt and thoughtful reply from a real human being, is this all good news?!


(edit: tidy)


----------



## ArnieW (4/10/06)

Wortgames said:


> So apart from the shock of having a prompt and thoughtful reply from a real human being, is this all good news?!


Getting a reply quickly from a real human being is excellent news Wortgames. ... Oh, and the details seem excellent too. 

Did you say their ladder+basic was available via download for a trial period? If that is the case, I'd suggest you play around with it and see if you can get it to do what you want. I vaguely remember that you can "simulate" having a PLC without actually forking out the cash for one.

I believe they come with PID capability also. I'd suggest this is fabulous news - PID will quickly become your friend if you are attempting to reach and maintain a target temperature.

The PLC side of it seems easy (at least in my head). The other bit you will eventually need to think about is interfacing between the PLC and your brewery. It won't be able to switch 10-20A heaters without some additional work, for example. I can help guide you with this stuff though, and I'm sure there are many others who would offer.

cheers, Arnie :beer: 
(enjoying a nice cold Helles in warm and sunny Melbourne - ahh, holidays are a great invention)


----------



## Wortgames (4/10/06)

It's glorious here today isn't it?!

I'm still flip-flopping betwen the PLC and the LabJack to tell the truth.

I've exchanged a couple of PMs with Roger Mellie, he kind of likes the PLC but then he's a bit of a PLC-whisperer it seems so it is familiar territory for him.

The PLC's certainly look like they have heaps of potential but also some drawbacks. Not least of which is if I need to get the speccy software, that is an extra $200 on top of the $350 purchase cost of the small PLC. It's still not entirely clear how much I can pause a 'script' or edit upcoming lines either, although as RM points out the actual processes probably wouldn't change much, just variables like temp and duration, and it shouldn't be too hard to create a pause function.

If PID means what I think it means, ie basic processes like temp control running by themselves, then I can certainly see that it would be useful (essential?!)

There are demo versions of the software and a huge amount of documentation for the PLCs here: http://www.lt-automation.com/Download.htm

I haven't felt brave enough to go near it yet, as I'm still a bit overwhelmed by it all and it will probably take me a month of Sundays to figure out what I was even looking at.

The LabJack is the great unknown, but at $200 to purchase it is significantly cheaper, and it looks like with a bit of effort I (we?  ) can probably rustle up a pretty cool interface for it. Even if it proves necessary to get the top software, ProfiLab, that's only another $165 making a total cost of $365 versus $550.

Another important issue to consider is the probes, as I would probably want at least 3 or 4 of them (and the more the merrier I reckon, subject to cost and available inputs). It looks like the PLC may require some additional circuitry to gear the probe output voltage to suit the PLC input. Not sure about the LabJack, but I'm guessing this could probably be done in the software, thereby reducing hardware costs?

Output-wise I only really need to control one heating element and one pump at this stage, but the future is limited only by my imagination and available outputs. Ultimately it could control any number of valves and robotic features. Again, the LabJack looks attractive here as I could theoretically just add on additional units as I run out of outputs (or inputs for that matter). Both the LabJack and the PLC would obviously require relays on the outputs, but I reckon I can probably figure that out, having a pseudo-electrical background.

I'm dead keen to have a look at your current system though Arnie, and I'd love to hear any more advice regarding the use of temp probes.


----------



## goatherder (4/10/06)

Wortgames said:


> If PID means what I think it means, ie basic processes like temp control running by themselves, then I can certainly see that it would be useful (essential?!)



There's no reason you can't do PID with the labjack - you'll just have to code the PID loop yourself. It shouldn't be big deal to do this. Google just got me this: http://learncontrol.com/pid/code2.html which has pseudocode for a PID loop.


----------



## roger mellie (4/10/06)

goatherder said:


> Wortgames said:
> 
> 
> > If PID means what I think it means, ie basic processes like temp control running by themselves, then I can certainly see that it would be useful (essential?!)
> ...



Maybe I am missing something here - I dont see the point in PID control coupled with Digital (On/Off) final control elements. There isnt anything to modulate. A step controller with Ramp/Soak functionality - now that would be handy - but PID?

I would like to see if Zizzle's way of temp measurement using the DM???? chip could be modified to become 0-5V DC - then the PLC method becomes very cost effective.

RM


----------



## ArnieW (4/10/06)

Wortgames said:


> I'm still flip-flopping betwen the PLC and the LabJack to tell the truth....
> 
> If PID means what I think it means, ie basic processes like temp control running by themselves, then I can certainly see that it would be useful (essential?!)...
> 
> ...


Hi Wortgames,

I can't remember how accessible things were with the labjack in real time, but if that is not an issue then I can see why you are drawn to it.

Goatherder is right about PID. In fact I've coded PID in my machine - it's not quite perfect yet, but it does it better than other systems I've experimented with. 

I'm guessing you may need some input interfacing with both systems to get the best out of them. As an example, if you are using the LM35 temp probes, and you have a 10bit analog to digital converter (you'd have to check what each system is capable of), then you get essentially a 0.5 deg C resolution with a direct connection. If you want better than that you need to amplify the input with op-amps.

OK, so temp probes. My own experience (probably not exhaustive) is that you can get either analog or digital probes - analog are at times easier to use (depends on your system) but are prone to noise and you may need to amplify as mentioned above. Digital are simple if matched with the right system, are not as prone to noise, and will potentially give better resolution/accuracy than an analog one.

My analog probe of choice is the LM35. My digital probe of choice is the DS18B20. I use both in my system - the LM35 gives virtually an instant reading, where the DS18B20 currently takes about 3/4 of a second with the picaxe.

The other main analog probe you can get is a thermister. They are very common, but require a bit of extra calibration, and I don't think they have a linear response which can be a headache. 

I believe that you can connect a DS18B20 directly to your PC serial port and read temps with it (given the right VB or C code). I'm sure I read somewhere about a global temperature montoring project that encouraged this, but I couldn't find reference to it with a google search.

I use the picaxe as a simple interface that does the same job as well as give expansion for many more inputs and outputs. 

cheers, Arnie


----------



## Gulf Brewery (4/10/06)

Hi everyone in this thread

I have sort of been following this thread. I wrote some code in VB.net to monitor temperatures and control step mash (PM if you want the source code). I used the DS1820's as sensors.

If you want code for reading / writing to the DS1820's, have a look at Digitemp and also Martybugs.net

The Gulf Brewery uses the DS1820's for monitoring the brewery - all of the actual temperature controls are done dedicated temperature controllers - would love to automate them, but I can't justify the cost (yet)  


Cheers
Pedro


----------



## ArnieW (4/10/06)

roger mellie said:


> Maybe I am missing something here - I dont see the point in PID control coupled with Digital (On/Off) final control elements. There isnt anything to modulate. A step controller with Ramp/Soak functionality - now that would be handy - but PID?
> 
> RM


I've found PID to be very useful. I use a PID algorithm to vary the power percentage on my heater. The output is a straight digital on/off, but varies with a duty cycle. In my case the system will go on/off via a solid state relay for a percentage of a 1 second period depending on the requested power. 50% power is on for 500mS, off for 500mS. Because it is a heater, it averages out the power nicely. It would be a bit nauseating to watch a light globe do this because it is quite slow.

Anyway the result of this has convinced me that it is very useful. I did it without PID control for a long time, and PID is certainly not essential, but it makes for more stable temps than my previous experiments.

cheers, Arnie


----------



## ArnieW (5/10/06)

sqyre said:


> I made a soluniod from a 1/4 turn ball valve and a central locking actuator years ago.
> 
> It worked awsome as a fuel switch-over in my custom built landcruiser.
> 
> ...


Hi Sqyre,

do you have any more details or pics of this?

I gave it a bash the other day but the results were not spectacular. To get the 1/4 turn, the actuator was too close to the pivot point to get enough leverage. To get it to move the ball valve, it was only reliable for about 1/8th turn (half the ball valve travel). This was with a new ball valve which might be a bit tighter than a used one, but as they heat they get tighter anyway.

cheers, Arnie


----------



## ArnieW (5/10/06)

Gulf Brewery said:


> Hi everyone in this thread
> 
> I have sort of been following this thread. I wrote some code in VB.net to monitor temperatures and control step mash (PM if you want the source code). I used the DS1820's as sensors.
> 
> ...


Hi gulf brewery and gidday zizzle,

thanks for posting the details on the DS1820's. I personally love them for their resolution, ease of use, accuracy etc.

Zizzle, I missed your post earlier in this thread, but good info about what can be done simply.

Arnie


----------



## sqyre (5/10/06)

> Hi Sqyre,
> 
> do you have any more details or pics of this?
> 
> I gave it a bash the other day but the results were not spectacular. To get the 1/4 turn, the actuator was too close to the pivot point to get enough leverage. To get it to move the ball valve, it was only reliable for about 1/8th turn (half the ball valve travel). This was with a new ball valve which might be a bit tighter than a used one, but as they heat they get tighter anyway.





Sorry mate, all i have is a badly blured memory from 10 years ago...

I admit there was teething problems that took a while to work out..i remember the actuator was very close to the pivot point of the valve and i have a recolection of replacing the original cut handle with one set at around 45 degree's. But cant be 100% certain... Also the valve was used for fuel swithching so it possibly lubricated the ball BUT i also have a very vague thought of loosening the internal ball holding assembly so it moved freely.

The parts i used were all pretty much second hand and it might just be a shear fluke it worked at all but it did work in the end, and quite well at that..

SO...the problem your experiencing is the fact the actuator is not strong enough to move the valve the full distance??? or you havent got enough travel to achieve a full 1/4 turn?..or both...

If not strong enough the only thing i would suggest is possibly 1. Make sure your power supply is big enough as i remember mine worked a lot better when hooked up to a car battery than my 2amp supply..

2. maybe explore the option of running 2 actuators with a "T" piece handle with actuators either side, 1 pushing the other pulling. be a bit of an eye-saw hanging off the side of a brew-rig but....it might work.

If your not getting enough travel and your as close to the pivot point as you can get then i dont like your chances.

Sorry to get everyones hopes up....i may have to break out some old ball valves and central lockers and try and find a solution. Also it would depend on the size of the ball valve...Once again cant recall what size it was.

My apologies..

sqyre.


----------



## ArnieW (5/10/06)

sqyre said:


> Sorry mate, all i have is a badly blured memory from 10 years ago...
> 
> My apologies..
> 
> sqyre.


Well I'm a happy little brew au-tow-mater  

I've just cracked the auto ball valve thingy by thinking a bit outside the square.

It was sqyre who got me thinking about actuators ...
Which got me thinking about the more simple up/down motion of gate valves and if I could use an acutator with that ...

Which got me pulling apart a gate valve and thinking that it would be mechanically difficult to maintain a good seal and use an up/down actuator (instead of the three turn thread to open/close it).

When I noticed a stepper motor I had and got to thinking about rotating the handle of a gate valve ...

Which got me thinking that you need a big/expensive stepper to do that properly ...

Which drew my attention to some geared motors I had lying around, and then a quick trip to Jaycar for a pully system and presto ... a working motorised gate valve that (at the moment) takes about 8 seconds to open or close.





This is the top view - on the left is the pully that is in place of the gate valve handle - on the right is the geared output pully from the motor. It has more than enough grunt to do the job.

The gate valve was off the shelf from Bunnings. The motor is one of the Jaycar geared thingys as per:
Geared motor

Now all I need to do is work out some more permanent mounting and then sort out the control gear.

cheers, Arnie


----------



## Wortgames (5/10/06)

Arnie, that is very cool!

Hi Pedro, welcome to the beerporn peepshow!


I heard back from the folks at LabJack. Apparently the LabJack U3 would be the go:
http://www.labjack.com/labjack_u3.php?prodId=25

It has 16 analog/digital IOs plus 4 digital IOs, and sells for US$99.

They seem pretty confident that the free DaqFactory Express software that comes with it will do the trick nicely.

Probe-wise, the options are:

EI-1034, sensor in stainless probe, US$49
EI-1022, sensor in plastic probe, US$29.

However they suggested I could look at the data sheets for the probes, source the core sensors, and make up the probes myself.

It looks like the probes can hook up directly to the LabJack, I just need some wotsits to go between the labjack and the mains relays for the outputs.

The ProfiLab software that Ocean Controls sells is nothing to do with the LabJack folks by the looks of it, which suggests that at least this LabJack stuff is a fairly open standard.

Ocean Controls also sells a similar device, not LabJack brand but I would imagine very similar, called iUSBDAQ:
http://oceancontrols.com.au/data_acquisiti...usb/iusbdaq.htm.
They've got it for $149 plus GST but apparently it sells for $79 in the states, 20% less than the LJ U3.

There's more information (and some cool screenshots) on the iUSBDAQ here in a 1.8Mb PDF:
http://www.hytekautomation.com/Downloads/i...6_UserGuide.pdf

Does anyone fancy sussing that one out for value / features?


----------



## Zizzle (6/10/06)

Hey Arnie, looks great. How do you know when to stop the motor?

I also found another old post of mine:



Zizzle said:


> But probably the easiest way is to go down to your local jaycar and buy a QM1538
> 
> http://www1.tpgi.com.au/users/p8king/qm1538.htm
> 
> ...


----------



## ArnieW (7/10/06)

Zizzle said:


> Hey Arnie, looks great. How do you know when to stop the motor?
> 
> I also found another old post of mine:
> 
> ...


Hi Zizzle,

I'd not come across those data loggers before - a good price and good entry point for automation.

A good question about knowing when to stop the motor. What I tested the other day was that there was enough torque to drive the gate - and I have no doubt that mechanically this is a good solution.

The next bit of R&D is working out the control of it. The simplest solution would be to turn on the motor for a set amount of time (at the moment about 8 secs) to fully open or close the gate valve. Because it is driven by a belt, my guess is that you could actually drive it for a longer time (say 8.5 secs) to ensure it is fully open or closed. Once the valve reaches a limit, the belt slips (a natural clutch). This effectively calibrates the valve every time you reach a limit (fully open or fully closed).

Then if you want to open it 50%, you turn the motor on for 4 seconds. You only recalibrate every time you close it fully or open it fully.

If that fails, the next step would be to put a pot on the gate valve stem. I've attached a picture with the concept.




The pot (on left) could have a pulley with rubber wheel that is driven directly from the stem of the gate valve. It might need to be recalibrated from time to time, but hopefully would be quite accurate. The pot position would indicate the gate valve position.

If there is too much slippage (ie. requires recalibration too often to be useful), the next step would be to have a gear or chain linkage between stem and pot to ensure there is no slippage.

I think I'll get the chance to test this on Monday. I'll let you know how it goes.

 Arnie


----------



## kirem (7/10/06)

Hey arnie,

Have you thought of using a servo motor in your valve experiments?

Kirk


----------



## ArnieW (7/10/06)

kirem said:


> Hey arnie,
> 
> Have you thought of using a servo motor in your valve experiments?
> 
> Kirk


Hi Kirk,

My first experiments ages ago were with servos. There are two main problems with servos and the system I'm working on - firstly, servos generally have about a 180 deg range and the gate valve requires about 3 revolutions; secondly your average servo does not have enough torque for this kind of job. After that, you actually get more bang for your buck with a good geared motor like the one I've got pictured. It is about 1/3 of the price of a basic servo and does the job much better. If you need to hack the servo to get it to do 3 revs, you might as well start from scratch I figure.

cheers, Arnie


----------



## ArnieW (8/10/06)

Wortgames said:


> Arnie, that is very cool!
> 
> Hi Pedro, welcome to the beerporn peepshow!
> 
> ...


Hi Wortgames,

the labjack looks pretty good. I had a browse of the manual, and although the examples were in C (not a language I understand) it looks as though it will be capable of automating the brewery.

I didn't download the code samples, so I can't give you a detailed response.

Regarding probes, I wouldn't waste my money. $5 or so for an LM35, a bit of wire and connection to the labjack with 12 bit analog resolution should give you better than 0.1 deg resolution (providing your voltages are stable). As far as casing goes, it can be as simple as a length of copper pipe that is plugged at the business end. You can buy end caps (either flared types or solder), or you can do something even simpler - clean the end of the pipe (esp inside), flux it, squash it closed in a vice, and then solder, making sure the solder wicks into the compressed part. Cheap and reliable.  

If you are looking for a source of good cheap solid state relays, look no further than:
Oatley Electronics - SSR1

For the price, it's difficult finding a relay to do the same job :super: 

cheers, Arnie


----------



## bugwan (9/2/07)

Just thought I'd dredge up one of my favourite threads!

I'm interested in monitoring temps (ambient, fermenter and fridge eventually) via a PC and running this to a website. I have thoroughly read through Greg Lemis' site: http://www.lemis.com/grog/brewing/temperature-control.html and I'm electronically capable of achieving this (I think!).

I want to do this on a real budget, so I was wondering what people thought of using a digital multimeter (with RS232) to capture temps to a PC? Jaycar have these for less than $50, which is quite a bit cheaper than any other ideas... **EDIT: I think a post from Zizzle has sorted me out above.  The only issue of course would be that multimeters run on batteries!!

I'd love some feedback. Otherwise, have a read through the thread, if you haven't before - really great stuff.


----------



## Zizzle (9/2/07)

I've probably said this earlier in the thread, but if you are handy with a soldering iron, got to their web site, sign up and send a request to Dallas Semi conductor for some free samples of the DS1820.

The build the circuit on this page http://www.linuxfocus.org/English/November...rticle315.shtml. It is small enough to be built into the back of a 9-pin D-shell with no circuit board.

Too easy, costs about $10.


----------



## Tony (9/2/07)

A couple of quick points to add from me 

I have an Allen Bredley Micrologix 1000 at home and am planing on some automation using citect of some other SCADA system.

The motorised valve idea is great. It could be timed for flow control id recon. I currently use solenoids on a couple of parts of my brew rig and they work fine for simple on/off control.

Another piece of equipment i want to aquire is a small (1/2") strait through flow meter. With this i figure i can use the flow to sense when i have enough water in my mash, shut the valve from the HLT and comence the mash cycle, ring alarms if the mash sticks (low flow) etc, etc.

The entire process could be fully run without having to go and look at it.

Wireless conection to the PLC from a laptop in the lounge room while watching the cricket.

you could set up alarms to warn of iminent hop additions....... oh the posabilities are endless.

Just progressed in jobs from electrician/technician to Process Control Engineer so once i get the parts........ its on.

does anyone know of an affordable flow meter? I have briefly looked into it but the prices were scary. 

cheers


----------



## ArnieW (9/2/07)

Tony said:


> A couple of quick points to add from me
> 
> I have an Allen Bredley Micrologix 1000 at home and am planing on some automation using citect of some other SCADA system.
> 
> ...



Ahhh, it's like an old friend has returned. Thanks Bugwan for reigniting the flame of this thread.

Tony, have you thought of a level sensor in the mash tun rather than calculation based on flow? My system uses a simple sensor (like those windscreen water sensors) to tell me when a particular level (like strike level in the mash tun) has been reached.

Just a couple of bucks for the parts and anything you like for the probe/sensor in the tun. I've used both stainless bolts and brass wire as sensors.

The circuit that currently has my attention can be found at: www.siliconchip.com.au/cms/A_30607/printArticle.html

This one is good for an analog input.

If you want a digital input, I can help you with a circuit for that.

cheers, Arnie


----------



## ArnieW (9/2/07)

ArnieW said:


> Hi Zizzle,
> 
> I'd not come across those data loggers before - a good price and good entry point for automation.
> 
> ...


An update on this one.

The gate valve and control circuitry is all in a nice box now and working reliably. I'm very happy with this one, although too busy building the actual brew structure to be focussed on control for the moment.

What I've discovered is that valve position feedback is not needed, so to keep it simple, valve position is determined by the time the motor is energised. I've used my favourite controller the picaxe and some simple code to get it working.

Anyway, here is a picture.





It operates much like my power window in the car. A single press of a button will either fully open or close the gate. A second press will make it stop where it currently is.

The unit I've made has a serial control line attached so it can tell a computer its position, or be directed to a position by the PC.

But that's just because I'm a control freak  

cheers, Arnie


----------



## ArnieW (9/2/07)

And another pic:




The red and black buttons are push buttons for open and close. The LED on each side gives an indication of open and close and will flash while operating.


----------



## bugwan (9/2/07)

Great work Arnie!

Damn I love this thread...! 

EDIT: I have just come back from Jaycar after making some purchases. I am hoping to put together some temp monitoring gear on a serious budget. For those interested, here is the site (thanks Zizzle) I am basing my project on.

I have become a 'member' at the Maxim/Dallas Semiconductor website and ordered four free samples of their temp sensors (DS18S20).
Other components include a 1.5kOhm resistor, 4 diodes and a serial port (D9) socket. The whole lot came to $6.25!

I'll post back when I find my soldering iron! I love the idea of checking temps remotely...plus I can keep a log of fermentation temps to perhaps explain variations in final taste tests. I've never _exactly _reproduced a brew, perhaps my temps are always different?


----------



## Tony (9/2/07)

Beer Porn !!!

I thought about this but i would like to beable to have recipe files in a PLC program and select what im making.

It will do the rest.

Thats why i need flow.

I will keep looking......... i havnt looked very hard so far. I am happy with my rig as a manual job but in the long temp id like to do this.

cheers


----------



## browndog (10/2/07)

All this electronics talk is way over a sheeties head, but it you used a level sensor on your mash tun, would not the varying amounts of grain throw this out ?

cheers

Browndog


----------



## ArnieW (10/2/07)

browndog said:


> All this electronics talk is way over a sheeties head, but it you used a level sensor on your mash tun, would not the varying amounts of grain throw this out ?
> 
> cheers
> 
> Browndog


Hi Browndog,

If you use a fixed sensor that would be right. The first sensor I used I could raise or lower to take this into account. Now I use a fixed one. I'm not overly fussed with slightly different ratios, so I don't find it a problem.

There are other ways of overcoming this as well - like ultrasonic sensors or pressure sensors. Still, I'm happy with a fixed sensor - keeps it simple.

cheers


----------



## randyrob (29/5/07)

was thinking something like this to automate my brew rig

http://cgi.ebay.com.au/USB-adaptor-for-ana...VQQcmdZViewItem


----------



## Jye (29/5/07)

randyrob said:


> was thinking something like this to automate my brew rig
> 
> http://cgi.ebay.com.au/USB-adaptor-for-ana...VQQcmdZViewItem



Sorry guys I havn't read the entire thread, but has anyone tried use a PICAXE? I've just start playing with a PICAXE-18A chip which has 5 inputs and 8 outputs, its also very easy to program using flow diagrams. Ive been thinking how to automate upto the kettle so I can wake up and be ready to boil... long term plan <_<

Edit - OK Ive read the thread and it looks like Arnie has already been using them.


----------



## randyrob (29/5/07)

Heya Jye,

i think a fair few guys do it that way. 

here's some code i've been cutting:


----------



## ArnieW (29/5/07)

randyrob said:


> was thinking something like this to automate my brew rig
> 
> http://cgi.ebay.com.au/USB-adaptor-for-ana...VQQcmdZViewItem


Hi Randyrob,

looks ok at a glance. Have you figured out in detail what you want the machine to do? I think that is the starting point myself - then figure out how to do it (ie. what you actually need). With those analog inputs, you can use LM35 temp sensors or thyristors, but not a digital probe like the DS18B20. If you used LM35s, you would probably want to amplify the output as well.

There are many ways to approach this kind of thing, and the WASP is not unlike the DSE parallel port interface that I first started with.

My main reason for using the picaxe is that I can embed intelligent process control in the machine - and not have to rely on the PC. I've had a few nasty PC crashes at inconvenient times before. With my new rig it will be both stand alone and allow PC control.

cheers, Arnie


----------



## Zizzle (29/5/07)

Right on Arnie.

I'm actually sitting here hacking code on my Atmel Atmega128 based control board for my brewery. I have some PIC P16F628a chips floating around here also, but the AVR gear costs about the same and kicks the PICs in performance and features.

I scored a 240x64 pixel backlit lcd today for nix. Should be able to draw some pretty status updates with that.

So I'm accumulating stuff.
Got some second hand triacs for switching mains. DS1820s of course. 433MHz radio modules for sending wireless updates to/from a PC. Ultrasonic transducers for liquid levels (I have since found that you can get sealed transducers to deal with the humid environment), although the capacitive level sensing idea looks great. March pump waiting to go.

But I still haven't sorted out my actuated valves yet. And a DC supply for whatever drives them. Maybe some electric window motors from the wreckers.


----------



## pokolbinguy (29/5/07)

Holy cow Zizzle next thing you will be able to brew from the touch of a button on your mobile phone. I'm completely lost with all this but thats because I have no idea what all the codes and names etc mean. However sounds like a great idea. and I can't wait to hear about the results. The days when I might be able to brew from my computer while knocking back a few are a long way away but may be close for you guys.

Good luck and hope it all comes together well.

Pok


----------



## ArnieW (30/5/07)

Zizzle said:


> Right on Arnie.
> 
> I'm actually sitting here hacking code on my Atmel Atmega128 based control board for my brewery. I have some PIC P16F628a chips floating around here also, but the AVR gear costs about the same and kicks the PICs in performance and features.
> 
> ...


Good work zizzle,

That LCD is a good score. I'd be interested in how you go with the wireless stuff. I've only heard of people using those modules for one-way comms, and alternate two-way systems (bluetooth, wifi etc) seem pretty expensive. I still dream of having a wifi machine. B) 

Good to hear about sealed ultrasonics as well. I think they should do the job nicely.

As for DC power supply, I think the simplest is an old PC supply scrounged from a surplus machine. You get lots of current at 12V, 5V, 3.3V and even a bit at -5V and -12V. I'm using one with a bit of extra filtering to drive power gear (motors and relays etc.) at 12V, and control (microprocessors) at 5V.

cheers, ARnie


----------



## SpillsMostOfIt (30/5/07)

http://www.sparkfun.com


I bought my bluetooth stuff from them that allows me to wirelessly talk to my AVR stuff. I still don't have a bootloader installed, but when that happens, the world will be a better place... They also have some quite cheap ZigBee stuff if Bluetooth doesn't do it for you.


----------



## GDSever (30/5/07)

Little by little I have been developing a VBExpress (VB2005, or whatever) user interface platform for automating home breweries... Some recent screenshots are at the end of this blog entry:

http://firststatebrewers.com/blog/2007/05/...day-activities/

It still has a long way to go before it is functional, but once completed I intend on making it open source and letting anyone use it. Right now its mostly just the component rendering code, but I have slowly been developing the framework for controlling events and sequencing them as well. My hope is that it'll be easy enough to use that anyone can do it - so long as they can handle the electronics side of things


----------



## randyrob (30/5/07)

Hello Arnie



> Have you figured out in detail what you want the machine to do?



yes, i'm not looking at full automation in anyway just looking at shaving a few hours of the start of my brew day. so it would only have to perform a few simple tasks for me.

something like

1.) set a timer to switch on my 240v electric element on my HLT (say 6am)
2.) when the HLT reaches a desired temperature (say 75*C) open solenoid valve from the HLT to the MLT / start 'dough in' motor.
3.) sound air raid siren 1 1/2 hours after dough in to wake me up for the sparge

saving me 2 1/2 hours off my brewday  

======

heck now i think of it i could even simplyfy it more by setting a manual timer for the HLT and have a temperature controller set to my desired strike temp.

then have another timer that opens the solanoid / switches motor on.

then just set my alarm clock to wake up??????????


====




> There are many ways to approach this kind of thing, and the WASP is not unlike the DSE parallel port interface that I first started with.



i would definately give the parallel port interface a go, can it switch on and off 240v appliances?



> My main reason for using the picaxe is that I can embed intelligent process control in the machine - and not have to rely on the PC. I've had a few nasty PC crashes at inconvenient times before. With my new rig it will be both stand alone and allow PC control.



wow looking foward to seeing that beast!

Thanks Rob.


----------



## Sammus (30/5/07)

I should have quoted a few posts here, but i couldn't be bothered reading back through to find them, anywho, you can get pretty cheap (cheapest i've seen anyway) SSRs, PIDs and thermocouples from www.auberins.com 

None of the thermocouples are particularly useful, theyre mainly designed for surface mount use on coffee machine boilers - plus the PID controllers come with the K type threaded t/c probe. which is actually nickel plated brass, and completely unsuitable for screwing into the side of a vessel containing and pressure (including the pressure exerted my liquid, say). I know this from experience  The PID controller seems to work well though, I prefer my Fuji PXR3, but thu auber instruments ones are roughly 1/4 the price  just thought someone might be interested (no affiliation)

PS I like that labjack thing... one day maybe


----------



## kirem (30/5/07)

I use Auber PID controllers and really like them. I use the screw in threaded probe that came with the unit, but it screws into a plastic tee piece in the wort path exiting the heat exchanger.

I had to seal the probe with food grade sealant once it was screwed into place.

I notice that they have a unit now that has a ramp/soak function, might be good for programmed step mashing or automated mashing then mashout.


----------



## ArnieW (30/5/07)

GDSever said:


> Little by little I have been developing a VBExpress (VB2005, or whatever) user interface platform for automating home breweries... Some recent screenshots are at the end of this blog entry:
> 
> http://firststatebrewers.com/blog/2007/05/...day-activities/
> 
> It still has a long way to go before it is functional, but once completed I intend on making it open source and letting anyone use it. Right now its mostly just the component rendering code, but I have slowly been developing the framework for controlling events and sequencing them as well. My hope is that it'll be easy enough to use that anyone can do it - so long as they can handle the electronics side of things


Ah Garrett, now that you've come out of lurker mode you will have to keep us informed of all sorts of developments like your proposed pressure sensors and experiments with picaxes  

[OT] 

Although I had to wince when I read back through your "snip, snip" blog - ouch - been there ... :blink: 

[/OT]

Your rendering code is looking good. I'm sticking to developing the picaxe end of things for the moment, but one day I will cut my teeth on VB2005.


----------



## ArnieW (30/5/07)

randyrob said:


> i would definately give the parallel port interface a go, can it switch on and off 240v appliances?
> wow looking foward to seeing that beast!



Hi Rob,

The parallel interface does not switch 240V without adding relay drivers to do the work (or SSRs). Most cards will be the same or else be limited to lower current applications than we might be using.

I actually have the DSE kit all wired up but surplus to requirements, and have done VB6 coding to get it to work as well. I'd be happy to let it go to a good home - the documentation for it must be around here somewhere.

There is a link for it here:

http://www.dse.com.au/cgi-bin/dse.storefro...duct/View/K2805

As for working out what the machine will do - I find the temptation is like you describe - figure out something and then figure out the next feature would be good - then figure out the next fancy thing you want it to do - then ...

cheers, Arnie


----------



## ArnieW (30/5/07)

Sammus said:


> I should have quoted a few posts here, but i couldn't be bothered reading back through to find them, anywho, you can get pretty cheap (cheapest i've seen anyway) SSRs, PIDs and thermocouples from www.auberins.com
> 
> None of the thermocouples are particularly useful, theyre mainly designed for surface mount use on coffee machine boilers - plus the PID controllers come with the K type threaded t/c probe. which is actually nickel plated brass, and completely unsuitable for screwing into the side of a vessel containing and pressure (including the pressure exerted my liquid, say). I know this from experience  The PID controller seems to work well though, I prefer my Fuji PXR3, but thu auber instruments ones are roughly 1/4 the price  just thought someone might be interested (no affiliation)
> 
> PS I like that labjack thing... one day maybe


The auberins stuff looks pretty good - they even include 'beer brewing system' as one of the possible functions for the PID I looked at! 

The other possible approach to a new machine would be to use or hack X10 controllers. There is some open source software that allows internet control and is designed for remote house control functions but I'm sure could be used for brewing.

http://misterhouse.sourceforge.net/

cheers, Arnie


----------



## Sammus (30/5/07)

I googled LM35 and found that a LM35DZ (quite cheap) is a sensor with a linear output of 10mV/degC and range of 0-100C.

Does this mean that the signal output will read 0V at 0C and 1000mV at 100C?

If this is the case, then to work out the accuracy of the sensor through a 12bit analogue input (like in the LabJack) would be something like:

voltage resolution of the labjack is about 0.596mV. So there is about 1000/0.596 ~ 1677 discrete steps in the 0-1V range, which equates to 100/1677 ~ 0.06 degC accuracy...

since the range of analogue inputs is 0-2.44V, using an appropriate amp one can gain accuracy ~ 0.02 degC

is there some other intrinsic sensitivity limitation of that little chip? surely you cant get that much accuracy for $1.95 USD


----------



## ArnieW (31/5/07)

Sammus said:


> I googled LM35 and found that a LM35DZ (quite cheap) is a sensor with a linear output of 10mV/degC and range of 0-100C.
> 
> Does this mean that the signal output will read 0V at 0C and 1000mV at 100C?
> 
> ...


The LM35 does work as you say Sammus, although the LM35 has a greater range than the LM35D series (-55 deg to + 150 deg C).

To get any meaningful results from a 12 bit analog input you need to have a very clean power supply, and if you want to amplify you again need some really good design like an instrument amp to make it worthwhile. Personally, I'm not sure anything greater than 0.1 deg resolution is worthwhile or even meaningful given other inaccuracies, beginning with the LM35 itself. If I had a 12 bit input, I'd make sure the supply was good and settle for the LM35 without an amp.

Just my 2c worth.


----------



## alexbrand (31/5/07)

Hey Folks!

A brewing colleague of mine developed a software to control the brewing devices. It is available in German language at the moment only (translation into English soon). It uses the Dallas semiconductor DS18S20 as temperature measurement unit at the COM-port and the parallel-port with a relay card to control the mash tun (heating (gas/electric), stirring device, etc.). It's still a kind of pre-release, butit works. Just ask Zwickel...

For those of you speaking German I could provide a download link to the programme, just send me a PM.

Greetings,

Alex


----------



## Sammus (31/5/07)

ArnieW said:


> The LM35 does work as you say Sammus, although the LM35 has a greater range than the LM35D series (-55 deg to + 150 deg C).
> 
> To get any meaningful results from a 12 bit analog input you need to have a very clean power supply, and if you want to amplify you again need some really good design like an instrument amp to make it worthwhile. Personally, I'm not sure anything greater than 0.1 deg resolution is worthwhile or even meaningful given other inaccuracies, beginning with the LM35 itself. If I had a 12 bit input, I'd make sure the supply was good and settle for the LM35 without an amp.
> 
> Just my 2c worth.



Well I'm considering using a labjack which is controlled by a commputer via a USB port. I'm pretty certain the 5V rail on a computer PSU is pretty clean isnt it?

Also I've done some testing and the 5V rail on the PSU always seem to be out by up to 0.2V - but still stable. Will this mess up the various reference voltages and such in a controller like the labjack?


----------



## bugwan (31/5/07)

alexbrand said:


> Hey Folks!
> 
> A brewing colleague of mine developed a software to control the brewing devices. It is available in German language at the moment only (translation into English soon). It uses the Dallas semiconductor DS18S20 as temperature measurement unit at the COM-port and the parallel-port with a relay card to control the mash tun (heating (gas/electric), stirring device, etc.). It's still a kind of pre-release, butit works. Just ask Zwickel...
> 
> ...



Guten Tag Alex,

I was going to ask if you know Zwickel, but I noticed you mentioned him in your post..! Great to see some international brewers on the site. I've downloaded the software you mentioned from Zwickel and my broken German got me through  
Interesting software, I think there are a couple of brewers here working on a similar product.

My problem is waterproofing my DS18S20s for liquid temp measurement. I guess a stainless probe would be best.

My main aim (in terms of automation) is to be able to monitor temps in the brewery on a web page - (not hard in theory, using Digitemp etc, but they're all Linux solutions and I'm running Windoze). That way, I always know where I'm at. In the future, I'd like to rig up some relays to control temps manually if necessary, so that diacetyl rests etc could be done remotely. Probably not necessary, as it's not hard to do with a timer...but hey, boys and their toys....!


----------



## Zizzle (31/5/07)

The problem with software is that everyone's hardware setup is different, so you can't really make a simple generic brewery controller software package.

To make matters worse, people are using different platforms. I for example, wouldn't waste my time on Windows based PCs. Just too unreliable. People practically throw out old computers that are very capable of running linux. Just grab one and start playing.

A wanted to play around with microcontrollers so I chose to go that way, but backup would be an old PC laptop with Linux on it. You can interface the DS1820s to the serial port and use the parallel port for controlling relays.

I wouldn't use any other temp sensors than the DS1820s. It's easy to interface with. No need to worry about analog signal conditioning, supply conditioning, correction tables, ADCs etc. 

I've been working as a software engineer for the past few years mostly doing embedded work, so for me the software is the easy part.

Reliable mechatronics and sensors is the harder part.


----------



## newguy (31/5/07)

Sammus said:


> I'm pretty certain the 5V rail on a computer PSU is pretty clean isnt it?
> 
> Also I've done some testing and the 5V rail on the PSU always seem to be out by up to 0.2V - but still stable. Will this mess up the various reference voltages and such in a controller like the labjack?



I've never 'scoped a computer 5V supply rail, but I doubt that it is clean. Standard practice when mixing analog and digital is to have separate supply rails and sometimes separate grounds. Digital circuitry creates ugly power supply noise due to its inherent switching (high/low) nature. This switching creates current 'bursts' that play hell with analog electronics.

I wouldn't worry about the 0.2V supply difference. Any well designed electronics will never depend on an external supply for critical internal references - the labjack most likely falls under the 'well designed' category.


----------



## Sammus (31/5/07)

hmm may just go with digital... if I ever get this thing happening 

Ive been reading through the labjack manual online and it seems way over my head... maybe one day though


----------



## alexbrand (31/5/07)

Good morning!



bugwan said:


> My problem is waterproofing my DS18S20s for liquid temp measurement. I guess a stainless probe would be best.



@ bugwan:
I used a capped and salt filled copper tube. It is fast and big...  :




But this is not my definitive solution, at the moment I am working around to get a better "thermometer". I drilled a hole into a SS screw wich will function as a housing for the DS18S20 in the future. This screw then will find its place in the middle of the side wall of my mash tun:



 



This idea was published some weeks ago by a good metal worker in a German brewing forum.

@Zizzle:

Right, different hardware means different software. The reason why I've chosen the DS18S20 are its costs. They are for free if you order a sample at Maxim-IC. Even if you have to pay for them including the interface for the COM port they cost less than 4 USD.

Using DigiTemp by Brian Lane a log file with the temperatures measured is created. And this logfile is read by Thomas' software.



Gut Sud!

Alex


----------



## Zwickel (31/5/07)

bugwan said:


> My problem is waterproofing my DS18S20s for liquid temp measurement. I guess a stainless probe would be best.


Hi bugwan,
at a holliday in oz my wife bought a couple of SS chopsticks. Always when I need something for the brewery, Im going to search the kitchen 
So I found the chopsticks there and got an idea:







filled inside with epoxy.

Cheers


----------



## bugwan (31/5/07)

Zwickel said:


> Hi bugwan,
> at a holliday in oz my wife bought a couple of SS chopsticks. Always when I need something for the brewery, Im going to search the kitchen
> So I found the chopsticks there and got an idea:
> 
> ...



Morgen Alex and Zwickel, you've inspired me with your ideas. Zwickel, never has a piece of cutlery been put to better use!

Does the epoxy interfere with temp measurements - I mean does it insulate the DS18S20 too much??

I'm just setting up a Linux box now, so I should be able to post some web-based temp measurements in the coming days...


----------



## Zwickel (31/5/07)

bugwan said:


> Does the epoxy interfere with temp measurements - I mean does it insulate the DS18S20 too much??


No, not at all. If I put the stick into hot liquid, within seconds it shows the actual temp, very quick.


----------



## ant (1/6/07)

A question for all you automation gear-head types... can someone pls give me some advice on whether this unit would be suitable?

I'm looking for a couple of solenoid valves, in the first instance I'm wanting one to run a HERMS unit, where a low temp reading in the mash tun will trigger the solenoid valve to be opened and recirculate through the HERMS unit. To my simple mind, this unit is s/s, it's 1/2" like the rest of the system, it's normally closed and is temp rated to 80C - a safe temp margin more than I will be running from the mash tun. :huh:


----------



## bugwan (1/6/07)

Zwickel said:


> No, not at all. If I put the stick into hot liquid, within seconds it shows the actual temp, very quick.



Great work Zwickel, thanks again. I'll be in the kitchen tonight....looking for stainless steel chopsticks.


----------



## Doogiechap (1/6/07)

ant said:


> A question for all you automation gear-head types... can someone pls give me some advice on whether this unit would be suitable?
> 
> I'm looking for a couple of solenoid valves, in the first instance I'm wanting one to run a HERMS unit, where a low temp reading in the mash tun will trigger the solenoid valve to be opened and recirculate through the HERMS unit. To my simple mind, this unit is s/s, it's 1/2" like the rest of the system, it's normally closed and is temp rated to 80C - a safe temp margin more than I will be running from the mash tun. :huh:


few 
Ant, they look a little bit like the solenoid valve that I replaced in my gas oven a months ago. It had a plunger with a rubber foot that sealed the input chamber from the output duct. If the design of this unit is anything similar I would think that you could have sealing problems with bits of husk etc. You could always contact the seller to see if they have engineering specs for these  
Cheers
Doug


----------



## ArnieW (1/6/07)

Doogiechap said:


> few
> Ant, they look a little bit like the solenoid valve that I replaced in my gas oven a months ago. It had a plunger with a rubber foot that sealed the input chamber from the output duct. If the design of this unit is anything similar I would think that you could have sealing problems with bits of husk etc. You could always contact the seller to see if they have engineering specs for these
> Cheers
> Doug


I'd echo Doug's comments - the cheaper units have a very small opening which is vulnerable in a brewing environment. The larger opening valves usually have some kind of motor that will rotate the valve stem rather than push a plunger.


----------



## ant (1/6/07)

Good advice gents, thanks. Thought I might be on a winner there, but not to be - as you both rightly pointed out; they have a rubber "NBR" seal.

Back to scouring sites and reading up on what I want... 


EDIT: if the key downside of these valves would be the potential to get grain husk etc stuck - wouldn't an inline filter like this do the job? I'm guessing that if the wort is coming out from below the false bottom, there shouldn't be too much large material. This just seems like a more affordable (ie several hundred $) alternative than some of the other valves...


----------



## Zizzle (1/6/07)

Has anyone run their brewery with gate valves?

Arnie, I know you were experimenting with them.

1/4 turn ball vales need much more torque to turn than the 4 turn gate valve.


----------



## ArnieW (2/6/07)

Zizzle said:


> Has anyone run their brewery with gate valves?
> 
> Arnie, I know you were experimenting with them.
> 
> 1/4 turn ball vales need much more torque to turn than the 4 turn gate valve.


My brewery is running with them, but not yet automated. I've chosen them because they don't have nasty cavities inside a ball valve to get festy. They should also be easier to automate because as you say they require less torque, and with the config I've got should be a simple direct drive.


----------



## Zizzle (3/6/07)

Excellent.

Just looking at the gate valve, it looks pretty easy to pull out the gate and clean.

But I've been looking at other peoples' brew rigs and haven't seen many (any?) gate valves in use.

One good thing about ball valves I would miss though, is being able to tell if the valve is open or closed at a glance.


----------



## Jye (3/6/07)

Im trying to resist this thread but am slowly being sucked in  

Is there some way of freeing the gate and allowing it to slide up and down? If this is the case can you then use an actuator to open and close it?

I dont have one at home to play with so Im putting it out there for you guys.


----------



## twenty (22/11/07)

i appologise for dragging an oldish thread up but this one is cool and it saves me starting another.

Im heading down this path as well, but jaycar dont supply the 1n5818 schottky diode required. They do sell the 1n5819 schottky diode. are these interchangeable?


----------



## Zizzle (22/11/07)

If you mean for the DS1820 serial port circuit then yes, pretty much any schottky diode will do.


----------



## twenty (22/11/07)

thansk zizzle much appreciated


----------



## balls (22/11/07)

[


ArnieW, unfortunatly gate valves will have traces of product hidden in the housing once shut. The only valve that will have the least amount of contact surface hidden is a butterfly valve. I don't know if these are made smaller that 1/2inch s/s. The most important thing is that you can clean it properly without pulling it all to bits! Cheers


----------



## beerbrewer76543 (1/7/10)

Hey all,

Im thinking about automating my HERMS unit (when I get around to building it)

I'm wondering if this would be suitable
Temp Relay Controller

Also, I was hoping to find some solenoid valves that would be suitable, perhaps like these:Blackwoods 1/2 inch solenoid valve

Any advise?

Cheers


----------



## mxd (1/7/10)

I've gone for K190 - 4 Channel Temperature Monitor & Controller from http://www.ozitronics.com/, bought a few SSR's, same ds1820's now just need to build it and write same code 

Probably move to a PID


----------



## Banshee (25/7/10)

mxd said:


> I've gone for K190 - 4 Channel Temperature Monitor & Controller from http://www.ozitronics.com/, bought a few SSR's, same ds1820's now just need to build it and write same code
> 
> Probably move to a PID




Looks good.
How do you do temp. steps?
How do you program it so it turns on at 7am to 50c then when target is reached hold for 20mins then up to 66c and hold for 60 mins then to MO temp and hold for 10 mins then sound an alarm so that i can then manualy rediect the wort to my kettle and get my sparge arm in place to rock'n'roll.

Do you need to write a new program or can you edit the existing software that comes with it and add the commands I want? I'm not a programer but am clue-E. How hard is it to make a new GUI?


----------



## Doogiechap (25/7/10)

L_Bomb said:


> Hey all,
> 
> Im thinking about automating my HERMS unit (when I get around to building it)
> 
> ...



Bloke you will find a few users of the BCS-460 on this forum. A search will bring a couple of opinions.
As far as the solenoids valves are concerned they will be fine for your HLT water, you may find that the valves will struggle to seal/ seat properly with any fine particles in the liquid. 
Good luck with your project bloke !
Cheers
Doug


----------



## schooey (25/7/10)

Doogiechap said:


> As far as the solenoids valves are concerned they will be fine for your HLT water, you may find that the valves will struggle to seal/ seat properly with any fine particles in the liquid.



I use pilot operated solenoid valves in my brewery. If you are using a standard domed false bottom, just cut a circle of termimesh about 20mm bigger in diameter than the FB and put it under the FB in your mash tun. This is what I did, and now I can still have a pretty fine crack and I get a normal mash bed with a fine layer between the FB and the termimesh. Consequently, my clarity of wort to the kettle has improved along with a couple of extra points of efficiency and no issues with the solenoid valves.

Just don't forget to put the FB in, because that doesn't end in a fairy tale I can assure you first hand


----------

