403896 (2) [Avatar] Offline
First of all
I would like to thank you for providing us with such a great book(one of the best books i have ever bought ). The book explains every thing we need about the technology and provide us with the reason behind choosing the used technologies , as I am a beginner it gave me the confident to go more deeply and haven't found any problem to understand the technology used in the book. I have read 7 chapters with out practicing (usually i read twice , so the second round i will write the codes)
My question is
can i rewrite the same examples using Meteor (as the Meteor build on top of node.js)?
Is there some different package i have to use or still the same ?
do i have to install some special package on Pi 3 for this purpose ?

thanks again
domguinard (69) [Avatar] Offline
First, sorry about the slow reply, we were finalizing the book (which was now sent for printing!!) and that took most of our time!

Then a big thank you for the nice compliments, it was really motivating to read your post!

Now, in terms of Meteor on the Pi. This could be a nice idea but Meteor was not meant with embedded computers in mind. It is targeting the x86 architecture (i.e., Intel or the CPU on your laptop/computer). The Pi, like most embedded linux devices, runs an ARM architecture.

This means that some of the binaries of Meteor will not work out of the box as they will not find the CPU architecture they expect. However, there is a fork of Meteor built specifically for ARM CPUs, we haven't tried it (yet) but you can find it here: https://github.com/4commerce-technologies-AG/meteor

Hope that helps and good luck for the rest of your WoT journey!
431450 (10) [Avatar] Offline
I intend to use Hapi.js instead of Express.js. Hapi is a great framework for working with large project.
Is that a suitable one for WoT? It have some great feature like plugin and could I write some plugin replacing 'onoff', 'node-dht-sensor' package?
domguinard (69) [Avatar] Offline

hapi.js is indeed an interesting framework and you should be able to make it work on the Pi (it might be a bit heavier than Express).

We picked Express because it is the most popular one but any framework that supports REST/HTTP, WebSocket will do to create a WoT server!

Good luck, let us know how that works!
431450 (10) [Avatar] Offline
I tried pattern 3 in chapter 7, cloud gateway but the code not work. Although I have run the setup.sh file but server just hanging and not updating thng properties. I tried to build my own with local mqtt server but It cant be accessed by web browser. Could you give me some clue how to build something like evrythng? How to build a server resolving both mqtt and http request?
domguinard (69) [Avatar] Offline
this is a different question I re-posted it to: https://forums.manning.com/posts/list/0/39557.page

Please always use a new thread for a new and unrelated question, thanks a lot.