Add JSON support. Buf fixes.
Merge pull request #50 from Tibo-lg/HomePortRefactored

Add JSON support. Bug fixes.