Page 1 of 2
Building a really realtime website
Posted: Sat Oct 13, 2012 11:22 pm
by Digit
Hi,
Today I finally made some time to have a look at a way to make my website REALLY realtime.
Not the x second interval Ajax polling anymore, but the real deal - instantly seeing new information being displayed in your web pages!
Once you've figured it out, it's soo easy... much easier than I imagined that it would be, actually.
I wrote a post about it on my weblog so if you wanna know more about how to do it, read it.
It's still in a 'Proof of Concept' status with working examples right now, but it looks very promising
http://blog.hekkers.net/2012/10/13/real ... socket-io/
Re: Building a really realtime website
Posted: Tue Oct 16, 2012 9:06 am
by RDNZL
Nice stuff, I noticed the code sample on the site are not error free, or my Node.js installation is not correct yet, need some more time to tinker with it.
Re: Building a really realtime website
Posted: Tue Oct 16, 2012 11:02 am
by Willem4ever
I'm working on an apache plugin which allows you to subscribe to a mosquito broker thru mosquitto-1.0.js using websockets. First tests are looking good !
Re: Building a really realtime website
Posted: Tue Oct 16, 2012 11:47 am
by Digit
RDNZL wrote:I noticed the code sample on the site are not error free
Ron, if you mail me the errors maybe I can help. Had some myself too

Re: Building a really realtime website
Posted: Tue Oct 16, 2012 3:09 pm
by RDNZL
I have it working now.
It was because i'm on Linux, and was struggling to get node.js and MQTTjs to work together.
Re: Building a really realtime website
Posted: Tue Oct 16, 2012 9:21 pm
by Digit
Willem4ever wrote:I'm working on an apache plugin which allows you to subscribe to a mosquito broker thru mosquitto-1.0.js using websockets.
That would be even better, very nice!

Re: Building a really realtime website
Posted: Sun Oct 28, 2012 6:04 pm
by Digit
I've got my smart meter online now; online as in the smart meter data being displayed in real-time
It doesn't get any better than this
With the help of Willems Apache module,which works great!
View the real-time web page here:
http://www.hekkers.net/domotica/Smartmeter.aspx
PS: IE doesn't support it; Chrome, Firefox, iPad should all be OK.
Re: Building a really realtime website
Posted: Sun Oct 28, 2012 6:50 pm
by RDNZL
Nice.
Willem is your apache module code online somewhere?
Would links to test with it too.
Re: Building a really realtime website
Posted: Sun Oct 28, 2012 7:10 pm
by Willem4ever
Not yet Ron, I have to prepare some instructions to make it suitable for the general public and it comes with no guarantees

Last night I added an additional option to prevent publishing thru the websocket interface - I can email you what I currently have which seems to work on OSX (Mountain Lion), Centos 6.3 and Fedora 17. Send me your email address by PM and I will forward the source with very basic instructions to you. For every one else, stay tuned on
Github
Re: Building a really realtime website
Posted: Fri Nov 09, 2012 8:28 pm
by Willem4ever
Check here for my realtime online smart meter
Re: Building a really realtime website
Posted: Fri Nov 09, 2012 8:53 pm
by Akatar
alleen maar vraagtekens...
Re: Building a really realtime website
Posted: Fri Nov 09, 2012 8:58 pm
by Willem4ever
Forgot to mention, it is based on webs sockets which is currently not supported nu IE, Safari / Chrome / Firefox / iPhone with IOS 6 should work fine.
Re: Building a really realtime website
Posted: Fri Nov 09, 2012 10:22 pm
by Digit
Willems page still works fine for me.. except for the certificate...?
Since yesterday (late in the evening) my Opentherm Gateway information is 'real time' available the same way my smart meter info is.
The only thing left to do is making a web page.
Re: Building a really realtime website
Posted: Fri Nov 09, 2012 10:44 pm
by Willem4ever
Yeah, it is signed by my personal CA ... for the geeks, the page is available on IPv4 and IPv6 and connects to the broker using IPv6 ....
Re: Building a really realtime website
Posted: Thu Nov 29, 2012 7:29 pm
by Willem4ever
The apache handler is uploaded to
Github. It includes a simple webpage which allows you to play with MQTT using the mosquitto web socket interface. Sofar it is confirmed to work on Ubuntu 11.04 (Thanks Ron !) , Centos/Redhat 6 and OSX 10.8, Test are undergoing to get it working with a Raspberry PI.

- screen-capture.jpg (149.48 KiB) Viewed 12100 times