reading in data from rs232 port, require to resend as an email

I am reading in some temperature sensor data, via RS232 (actually converted to USB via a CP2102 ), approx every hour into a Windows XP PC. It reads fine into Windows Hyperterminal. I want to be able to send this data out via email as it arrives. Is there any application that can do this, free or commerical, please? I have searched using Google but not found anything. Lyndsay Williams

formatting link

Reply to
Lyn
Loading thread data ...

You may consider to use a scripting language supporting serial port I/O and SMTP. My favorite is Tcl/Tk, it's free (even for commercial purposes) and has both:

formatting link

The ActiveState distribution has "batteries included", the tcllib/smtp package:

formatting link

Tcl basics on serial ports:

formatting link

Tcl basics on SMTP:

formatting link

Regards, Rolf

Lyn wrote, On 02.04.2008 13:16:

Reply to
Rolf Schroedter

My vote would be for Python

formatting link
Python operates at about the same conceptual level as Tcl, but IMO the syntax and sematics are a lot easier to understand. It's also available from active state at
formatting link

Support for sending mail is included above, but the serial port module hasn't made it into the standard library yet and has to be installed separately:

formatting link

--
Grant Edwards                   grante             Yow! Inside, I'm already
                                  at               SOBBING!
                               visi.com
Reply to
Grant Edwards

formatting link

If the OP has Borland C++ Builder or Delphi, he could try using the Turbo Power Asynch component

formatting link
which has some nice packet- handling for the serial port, plus Borland's standard SMTP component. It would be a nice little stand- alone app, bloated only by the massive VCL required to run it (oh, and Windows) :(

But he could also use it to build in debug, onsite testing, configuration etc.

JS

Reply to
sprocket

There are utilities to do that. I'm using one on another project but I've forgotten the name. I'll try to remember to post a reference Thurs Afternoon

Robert

--
Posted via a free Usenet account from http://www.teranews.com
Reply to
Robert Adsett

XP

I would suggest you to VB, you can use MS COM to read serial port and do as you wish.

Cheers!!

-dK

Reply to
dk

XP

Thanks for all your replies, I will wait to see if a utility has been written for this. Lyn

Reply to
Lyn

If the PC could run on Linux, it would just need a few lines of bash script. Just write an email, if you need further information.

regards Guenther

Reply to
Günther Jehle

Refreshed my memory. This is the utility I'm thinking of

msmtp

formatting link

Nice command line interface. You do have to set up a configuration file so it knows what smtp server it should communicate with. It handles all the authentication details etc...

It is possible to use Windows interfaces but if you use Outlook (at least with the method I'm using) pops up a box when you fill in the address field and then pops up another one when you do the actual send (and this one can't be answered until after a 4sec wait). Since neither can be turned off that makes that method unsuitable for automation.

Robert

Reply to
Robert Adsett

I use msmtp, and I don't see how it does what the OP wants. msmtp is just a command-line SMTP client. It's not going to read data periodically from a serial port.

--
Grant Edwards                   grante             Yow! The SAME WAVE keeps
                                  at               coming in and COLLAPSING
                               visi.com            like a rayon MUU-MUU ...
Reply to
Grant Edwards

You're right. I was assuming something else would have to read the serial port. It never occurred to me that that wouldn't be the case, if nothing else something has to know when to read the data and format it into something nice for whoever is receiving the mail. Of course if the data server at the other end of the serial port is nice enough it's concievable that a simple copy might work. Not likely though. Still it does reduce the size of the problem.

Robert

Reply to
Robert Adsett

[...]

Assuming the data is text (or there's a command-line utility that reads the data and converts them to text), you don't really need much more than a shell-script a few lines long to do what the OP wants given a command-line mail program and something like msmtp or ssmtp (or any other MTA).

--
Grant Edwards                   grante             Yow! !  Now I understand
                                  at               advanced MICROBIOLOGY and
                               visi.com            th' new TAX REFORM laws!!
Reply to
Grant Edwards

y

Windows XP

le to

tion

ing

t but

ce Thurs

=A0 =A0 Yow! ! =A0Now I understand

=A0 =A0 =A0 =A0 =A0 =A0 advanced MICROBIOLOGY and

=A0 =A0 =A0 =A0 =A0 =A0th' new TAX REFORM laws!!- Hide quoted text -

Thank you for all your contributions. I am an embedded hardware/ software engineer and not written software for pc for a while. That's why I was looking to buy/ use an off the shelf system. I am thinking of redesigning the system to just add a gsm modem (from old nokia phone) and sent temperature text alerts to a mobile phone. Not all my users will have pcs (e.g. elderly people), and there are more cell phone users than pc users (I think?) in uk. Mrs Lyndsay Williams

formatting link

Reply to
Lyn

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.