Thursday, July 7, 2016

How To Install Netbeast On Linux For Developing IoT Applications With Great Ease

http://linuxpitstop.com/netbeast-on-linux

Netbeast is the first open source platform to connect smart devices together regardless of their brand or technology for developing Internet of Things (IoT) applications for appliances. It’s an environment-agnostic platform that allows users to ignore details like wireless protocols, brand-specific public APIs, or device detection. One of Netbeast’s main goals is to help foster and develop an open source community in IoT. Netbeast is an environment agnostic platform that can run in most devices. Whether you choose a Linux embedded system or a Windows laptop, it will get your app connected to any and all devices, enabling you to build your own Internet of Things.
Following are its main features:
  • It connects all products in the smart home and allows to control the smart home through apps.
  • Developers can create apps for Netbeast and upload them to our marketplace.
  • Different apps can provide different uses and values, users can choose the ones that suit them best.
So in short we can define Netbeast as:
  • A Toolbelt that let’s you develop Internet of Things applications easier and faster.
  • A platform that hosts your applications and does the hard work of specifically talking to every device.

Netbeast Components

1- Dashboard:

This dashboard component for Netbeast is actually the platform for users to install applications and control smart products.

2- API:

Unique and simple interface to create applications and plugins that allow devices to communicate with each other.

Installing Node.JS

Netbeast is based entirely on Node.js and it is tested and guaranteed to support Node.js 0.12.x and later.
So, before moving to the Netbeast installation we are going to install Node.JS on Linux. If you want to install Node.js through the command line just type the following commands.
# curl -sL https://deb.nodesource.com/setup_4.x | sudo -E bash -
install Node.js
Node comes with npm installed so you should have a version of npm. Still, npm gets updated more frequently than Node does, so you’ll want to make sure it’s the latest version.
# apt-get install nodejs
install node.js
# node -v
v4.4.4
# npm install npm -g
Test: npm -v. The version should be higher than 2.1.8.
#npm -v
npm install

Installing Netbeast Dashboard

You can install Netbeast dashboard on your system easily; open your command line terminal and run the below command.
 npm install -g nb-dashboard
netbeast dashboard
If no error appears then you have installed the Netbeast Dashboard successfully. Now run the command to start netbeast dashboard on port 3000.
 nb-dashboard --port 3000
starting nb-dashboard
You can also use ‘git’ to clone ‘Netbeast’ dashboard on our computer by running the following command.
  git clone https://github.com/netbeast/dashboard
Once cloned, the core pre-requisite modules must be installed using below commands.
cd dashboard
npm install
When you have all the npm packages installed, run it as following.
npm run dev

Access Netbeast Dashboard

Now you can access Netbeast on a web browser to access the Dashboard using your custom port 3000. In case if you launched Netbeast on the default port then you have to specify the default port that is 800 on the URL instead of 3000.
 http://your_server_IP:3000
netbeast dashboard

Installing an Application

We are going to install an example app to see how it works.
Let’s go to the Dashboard and hit the install option, then select with git and use the following URL and click onto Install.
https://github.com/netbeast/padjs
installing app
After installing, go back to apps and you will be able to try out your brand new sampler pad! Just click onto the icon padjs to launch it.
Padjs app
Now you can install plugins which are applications that allows you to connect, communicate and control a device. You can install a plugin that will allow you to control lights by accessing the Dashboard and choose ‘explore’ where you will see all available apps and plugins to be installed and use.
Once installed, if you open bulb-plugin and the padjs app, you can see how playing the pad changes the bulb color.

Conclusion

Let’s Enjoy. You are now ready to start developing IoT apps and plugins. Netbeast has created an OS for routers that enables device interaction regardless of brand, technology or protocols. With Netbeast users can control smart devices through apps. Developers create IoT apps for smart devices without worrying about compatibility issues, and make money through them. So, in the end, there will be an internet of things. If you liked this article or have any questions, do let us know in comments or on our social network pages.

No comments:

Post a Comment