PDA

View Full Version : Email Calculator




dergaderg
Dec 28, 2011, 12:28 AM
Today I whipped up a little program using java. if you send an email to "EmailCalculator@gmail.com" with "Calc 4times5" , "Calc 4over5", "Calc 4plus6" , "Calc 4minus6" , "Antipow 4x^5" , or "Pow 4x^7" in the subject line, it will send you back an answer in ~11 seconds ( just so i can leave it on and its not pinging the server to much).

Do any of you have any suggestions for adding functionality? im currently working on a weather service



miles01110
Dec 28, 2011, 12:43 AM
Do any of you have any suggestions for adding functionality?

Maybe this is a stupid question, but why would anyone want to wait 11 seconds for the answer to a simple calculation? It takes less time to put that into a Google search and get the answer in fractions of a second.

dergaderg
Dec 28, 2011, 01:39 AM
That was just something i set up to have the interface for sending an email to a computer and it processing what you sent it and having that processed data sent back, without any intervention.

I just added a Weather Function, Send the same email "Weather" then you zipcode in the email then it will send you the current temp and the forecast.

ghellquist
Dec 28, 2011, 05:25 AM
Hmm,
you might be the nicest person in the world, but ...

... but this could also be an invitation to collect mail adresses for later SPAM sendings.

// Gunnar

locust76
Dec 28, 2011, 05:41 AM
Just use your junk email address.

chown33
Dec 28, 2011, 10:03 AM
That was just something i set up to have the interface for sending an email to a computer and it processing what you sent it and having that processed data sent back, without any intervention.

I just added a Weather Function, Send the same email "Weather" then you zipcode in the email then it will send you the current temp and the forecast.

Why email? Considering the possible abuses, why not something simpler, like HTTP? It's still a server, and requests can be easily formed from text, like:
http://example.com/weather?90210

notjustjay
Dec 28, 2011, 10:28 AM
No need to be rude, guys. It's obviously a learning example and thought it may not be the most practical way to calculate things, it's a neat interface with lots of potential. I've always thought it would be cool if my house could respond to emails and tell me things like whether I left the garage door open (or maybe respond to a command to close it) or tell me what the thermostat's set to.

If you're afraid of spam then use your throwaway email address. If you don't have one... you ought to :)

maril1111
Dec 28, 2011, 10:44 AM
No need to be rude, guys. It's obviously a learning example and thought it may not be the most practical way to calculate things, it's a neat interface with lots of potential. I've always thought it would be cool if my house could respond to emails and tell me things like whether I left the garage door open (or maybe respond to a command to close it) or tell me what the thermostat's set to.

If you're afraid of spam then use your throwaway email address. If you don't have one... you ought to :)

Fair enough I may have been a bit rude... and i like the idea with the house responding to things like that, heck imagine cars and bikes could do that to :) although there is always the danger that the more electronics there are in a certain thing the higher the likeliness that something will go wrong.

Back to the post, I do think that do the http model chown says isn't a bad idea and i would like the o.p to follow it if possible, than i bet more people would try it out.

chown33
Dec 28, 2011, 11:06 AM
I've always thought it would be cool if my house could respond to emails and tell me things like whether I left the garage door open (or maybe respond to a command to close it) or tell me what the thermostat's set to.

These days, houses and garages have websites. Seriously. Home automation interfaces or gateways, at least some of them, use HTTP and/or HTTPS.

Email only makes sense when an email client is all you have. For example, early cell phones may have had passable email but very limited web browsing capabilities. So email would be a better interface choice in those cases. However, as soon as mobile browsers began to not suck, email doesn't look so good any more. HTTP gives you many more interaction options than email, and can be used from any device, not just the one configured with your email account info.

dergaderg
Dec 28, 2011, 12:25 PM
Why email? Considering the possible abuses, why not something simpler, like HTTP? It's still a server, and requests can be easily formed from text, like:
http://example.com/weather?90210



This sounds interesting, but I do not know how to set an http server up. do you know of any tutorials for doing so?

Consultant
Dec 28, 2011, 12:42 PM
So basically you are making a http://www.wolframalpha.com copy,
except that what you offer takes longer and collects email address

dergaderg
Dec 28, 2011, 05:11 PM
Why email? Considering the possible abuses, why not something simpler, like HTTP? It's still a server, and requests can be easily formed from text, like:
http://example.com/weather?90210

Well i fixed it. it's now running on a HTTP server. http://mdergosits.no-ip.info:8080/Weather94901

You can also play battleShip by typing http://mdergosits.no-ip.info:8080/Newgame

GorillaPaws
Dec 28, 2011, 06:25 PM
I think it would be more fun to duplicate Woz's dial-a-joke phone service via e-mail.

dergaderg
Dec 29, 2011, 02:52 PM
I think it would be more fun to duplicate Woz's dial-a-joke phone service via e-mail.

I couldn't find a text file full of jokes but i did find one for puns.

http://mdergosits.no-ip.info/pun