Got an answer from Binero about how to create an online checking alarm-system thing. A site that checks each halfhour if a system on another place is online, connected to the internet and alive and well. Apperently they offer a service to schedule running of URLs. This is perfect. This means I just need to make a site that checks if the remote alarm is okay and if not, it sends email and sms.
The Raspberry pi updates a MySQL database every halfhour or 5 min.
The online server checks if the r-pi has reported that it's okay.
This way we do not need to worry about opening ports on a router. This is important if we encouter a customer with several routers and we probably never need to put effort in configuring a router.
So I focused on making a site to send email. I choose to use PHP since I'd like to have a little more experience on that. But later I think I maybe should have used javascript..well well.
I learned that the server on binero can be run just like a raspberry pi using SSH to connect. I had to do this to install PEAR for PHP to send email. Haven't got it to work yet, big trouble connecting in the right way.
Learned some more PHP on codecademy really great site!
Tomorrow I'll be trying to fix this even more and then go on to make a POST to cellsynt to send SMS.
Inga kommentarer:
Skicka en kommentar