Project with witch OS/Tools

John
hi guys,

sorry im not so familar with embedded systems/tools etc.. and would like
some commends from the experts. ;-)

at the moment my mini2440 runs with debian,
needed stuff is 
-reading 1-wire temperature sensors detected to a 1-wire busmaster
(DS9490R) (1-wire tools command owget doing the job now)
-write some graphs with rrdtools
-webserver/gui to show temperature/graphs and state of some gpio
pins(relays detected) and change gpio pins state to control some relays,
accessible from any computer with internet (lighttpd php5-cgi wit sqlite
doing the job now) 
- reading 1 adc pin and show value on webserver/gui
- job reading the temperatures and switch the relays depending on the
temperutures. 

thats it.


what is the best way to realise this?
i am quit familiar with linux and bash scripting, and c is still newland
for me.
that is why i am running debian from sdcard.

a read quit a lot about ptxdist round here, seems to be quit nice.
is that also something for me?

this is all for home use only, no business stuff.
thx 
John

davef
Sounds like familiar stuff.  I have been migrating a AVR-based web
server/home automation system to Linux over the last few years.

If you are mostly interested in getting something to work that you can
maintain I would suggest going with PTXdist.  I have been playing with it
for the past 6 months.  They keep the kernel up to date, do all the
patching and provide excellent support for this package.

I did my own thttpd with php, so I write all the control stuff using php. 
I run the /demo/browser from Qt.  The PTXdist package does Qt stuff, but I
had to modify things to do the browser app.

I noticed the latest kernel has more sensor stuff in it, so worth having a
look to see your devices are supported.

No experience with rrdtools, not sure if it is in the PTXdist menuconfig. 
There is Qwt, which I think is a graphing program.

Grab the QuickStart.pdf off their website and have a look.

Cheers,
Dave

john
hi dave, 

was off for a few days.

i just want to check a few standard 1-wire temperature sensors (ds18b20)
connected to a 1-wire busmaster DS9490R, all standard stuff in 2.6 kernel
already,  and if it get to hot/cold i want to switch a fan or heater on
over a gpio pin(connected relayboard)

i dont need the connected display, only a webserver with php to set up a
website/gui to look or just switching some fan/heather/lights via gpio pins
remotely via website from iphone or pc.

everything is up and running since 1 year with lenny and userspace, 
but you now, i just need something to play/optimize, 
that is why i ask about ptxdist.

do i have there the opportunity to setup a root filesystem with a
webserver/php and 1-wire tools and rrdtools.

is that the "better" way to realize my small playground project,
or is the best way to stay with lenny and family.

if everything is up and running, i dont need to change the sysmtem all the
time with the newest kernel and tools etc...

i just donīt have the time to spend 2/3/4 days or even a week or more to
realize ptxdist is the wrong way for me.

whould be also interessting the see/hear what kind of projects you guays
realize with mini2440.

cia
john

davef
I cross-compiled thttpd with php using the PTXdist toolchain and it works
just fine.  I posted a tutorial months ago, which might need a few changes.


I can check in PTXdist if rrdtools is supported.  1-wire stuff I believe
are just kernel choices, which you have already done.

Better?  Well, as I have no experience with lenny and family I can't make a
judgement call on that.  Every month Juergen pushes a new version of the
mini2440 BSP and does a great job supporting their work.  Perhaps, there is
a larger community-based behind lenny . . . don't know.

I think a install of their tools and a look through <ptxdist menuconfig>
would only take a few hours.  The longest task with be downloading their
toolchain.

I am not saying that there won't be any problems!  I have spent the last
week of evenings trying to replicate my project using a newer version.  I
strongly suspect that it is "finger-trouble", as I have found that some
basic things are missing from my "learning-experience".  

I also run msmtp on the platform to send email messages when there are
fault conditions.  I might have to install pppd and chat as well, to talk
to a wireless mobile broadband modem . . . haven't got that far.

I probably spent the better part of a year trying to do everything from
scratch.  Good background, but I hope never to have to do things that way
again!

Good luck.

davef
rrdtool is in PTXdist.

options:
[ ] install rrdcached
[ ] install rrdcgi
[ ] install rrdtool
[ ] install rrdupdate
[ ] built in support for libwrap (tcp wrapper)
() default font

BTW, it was "finger-trouble" all right . . . typing mistake in a manually
edited config file ;(

john
hi dave

ok ptxdist up and running. :-)

ptxdist menuconfig and a / to search the whole menuconfig for something,
help quit a lot.

lighttpd and fastcgi, sqlite,rrdtools and owfs(1-wire) are supported.

a look at /usr/local/lib/ptxdist-2011.12.0/rules/owfs.make shows me the
configs of owfs, and there is "--disable-owserver" :-((

must say a lot of stuff is supported, just need the time to try all out.

what kind of project are you running with the mini2440?

regard
john

Juergen Beisert
John,

if you know how to get the owfs with the owserver cross compiled and
running on you target you are welcome to send us the required
changes/patches and we will add it to the next release of PTXdist

davef
John,

Broadly, you could call it a home automation project.  The main focus has
been to set up a web server (thttpd with php) so my neighbour can monitor
the state of things around his house, specifically freezers.  There can be
power failures, even in rural New Zealand. He has a lot of meat in these
freezers and wanted to be notified of "down-time".

Running msmtp to send emails to his SMTP account and there off to a
SMTP/SMS gateway provider, who then sends him an txt message.

When our house is built all this development work will be focussed on my
own system.  We are off-grid, so there are plenty of monitoring and control
opportunities.

If you want to continue this discussion off-line I'll post my email
address. 

Dave

davef
John,

Previously, I had a quick look at rrdtools and after you mentioning it I
have had a closer look through some of the tutorials.

I used a simple time-based graphing program called XMON on an ATMEL
ATmega32 and EXCEL spreadsheet for a datalogger.

Now, running something like rrdtools on the mini2440 looks quite
attractive.

Have you some experience with rrdtools?  Email me at dave_festing at
hotmail dot com if you want to continue with using rrdtools with PTXdist.

Dave

john
hi dave

merry christmas to down under.

i am a system administrator for windows and linux server for a couple of
our companies.
big part of my job is also doing monitoring of all our customers
systems(600-700),
linux/windows server and environments like temperature/smoke/humidity
sensors etc....

i used a lot off linux stuff there, like rrdtools for the graphing of all
the stuff.
then a got a "Teltonika Modemusb G10"(ftdi kernel driver) and smstools3
doing the alerting over sms, no need of internet connection/gateways etc..,
could be something for you to. ;-)

the "problem" i see with ptxdist is that everything must be cross compiled
on a other system and all the dependencies.
with debian(lenny) life is a bit easier for a systemadministrator like me,
installing something like lighttpd is just apt-get install lighttpd,
wait a few sec and be happy.
installing other packages is just download, untar, configure,make, make
install.
i got a deamon(package) for creating and filling the rrdtools rrd database
files with a nice frontend etc...
think that is goinig to be a lot off compiling/trying stuff under ptxdist
to get it working.

rrdtool is realy nice, creating grahps via simple php templates or scripts
is realy easy and everything is possible from size colour etc...
a export to csv is also possible and and and..
here a sample graph for my iphone, create by a cronjob,
not so warm here in germany like there downunder :-((

http://img526.imageshack.us/img526/8650/graphh.png

regards john

davef
John,

And a Happy New Year to you.

I'll check out smstools3, never heard of it.

You appear to have much much more experience with things Linux than me.  My
comments are based on very limited experience.

All I can do now is wish you good luck in finding the perfect solution for
your requirements.

Cheers,
Dave