create small linux box for environment monitoring?
Linux - HardwareThis forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
create small linux box for environment monitoring?
I am thinking of creating a small hardware device based on linux that can read input from potentiometer probes and then control AC devices based on the input values. Does anyone know if this is doable with a knowledge of linux, perl, php but no knowledge of electronic circuits and resistors and such? I was thinking of modifying a wrt54g or similar hardware with a light linux distro like openwrt to read the I/O from the probes and then use shell scripts to produce audible alarms and control AC devices based on the probe input values. Any help is appreciated.
Not really. I do not know the hardware details of a WRT54G but you will need some type of circuit to interface your potentiometer probes to regular I/O. You would need an analog to digital converter which is unlikely to be a part of the router.
If you provide more details on what type of the probes and AC devices you are trying to control we might be able to suggest other hardware that is more suitable.
misterhouse is a home automation application written in perl that you might want to take a look at. Of course you can search the web and find lots of information.
Thanks. I was thinking of a serial port for the I/O interface (forgot the wrt54g doesn't have serial). I can add an analog --> digital converter if needed but would a driver need to be written for the kernel for the converter? I am hoping for something where I can read the voltage from the I/O probe into a system variable and then write scripts to perform actions based on the system variable value for the input voltage.
I also need this to go into a small hardware profile (low cost hardware) vs. a home automation solution that requires a dedicated PC.
I am trying to read aquarium environmental parameters (ph, temp, calcium, etc.) and then control devices like heaters, chillers, fans, lights, etc. based on the input values. I know there are devices made to do this but I am trying to build my own controlling device with linux.
You could use a PIC micro controller to do Analog to Digital conversions, and send these values to the wrt54g via the serial port (many PICs have RS-232 support).
Thanks for the suggestions. I found a project that uses busybox linux and owfs (one wire file system) to read one wire devices like sensors and allows access to the devices. For anybody interested, the project can be found at: http://bytality.com/wrrc/
I have read that WRT54Gs do have a TTL serial port header on the circuit board. However, you can not attach real world devices to a serial port. So you need something to read voltage data, turn on lights, pumps etc and be able to communicate via RS232. I've seen various RS232 analog and relay boards on the web like www.controlanything.com but a bit pricy.
There are many different microcontroller options as suggested but with little electronics knowledge this may not be a real option. Depending on the design the WRT54G may be eliminated altogether.
There are lots of single board computers that can run linux with ADCs and other output capabilities etc but again probably do not fall within your budget. http://www.embeddedarm.com/
Good find, makes my previous post worthless... I completely forgot about 1 wire sensors. Then again you did say you had no real electronics knowledge.
I might hesitate a little with using X10 for any critical functions. The control signals travel over the AC power lines and therefore line noise from computers etc could prevent proper operation. There are several types of powerline control technologies but IMHO would stick to relays for your application.
Be sure to let us know how your project progresses.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.