- To run Agile IoT Platform you need
- docker version 1.10.0 at least
- docker-compose version 1.10.0 at least
- To run Watson interworking you need
- Node.JS 6.4.1 at least
- To run Watson Analytics you need
- JAVA 1.7 at least
- Apache Maven 3 at least
Clone the project from Github.
- The project is tructured as follow:
- Agile: updated version of Agile IoT platform including a dummy device measuing pollution and temperature.
- Watson-interworking: interworking proxy component that discover devices from Agile platform and pushing data to Watson IoT Platform
- Watson-analytics: analytics module subscribing to data from Watson IoT platform and puishing it to Watson Machine Learning service to measure trends and calculate deviation. Deviation are stored back into Watson IoT Platform for triggering alerts when needed.
- Open the Agile platform project available on folder watson-interworking
- Move to folder agile-cli
- Run the agile platform
./agile start
- Check Agile web interface: http://127.0.0.1:3000/login
- Open the Watson interworking project available on folder watson-interworking
- Move to folder src
- Install the Node required libraries
npm install request
npm install ws
npm install ibmiotf
4 Configure the interworking using the file config.js
const config = {
agile: {
host: '127.0.0.1',
port: 8080,
pollingPeriod: 15000,
log: "[AGILE]:"
},
watson: {
orga: 'XXXXXXXXX',
domain : 'internetofthings.ibmcloud.com',
application: {
key: 'XXXXXXXXX',
token: 'XXXXXXXXXX',
id: 'agile-watson-ipe'
},
log: "[WATSON]:"
}
};
5 Run the project
node app.js
- Open the Watson interworking project available on folder watson-interworking
- Go to folder src
- Install the Node required libraries
npm install request
npm install ws
npm install ibmiotf
4 Run the project
node app.js
- Open the Watson Analytics project available on folder watson-analytics
- Build the project using the following command. The binary and config files are generated under the folder "target"
$ mvn clean install
- Configure the project using the file config.ini
# MQTT parameters
MQTT_TOPICS = iot-2/type/+/id/+/evt/event/fmt/+
MQTT_SERVER_URI = ssl://XXXXXXXX.messaging.internetofthings.ibmcloud.com:8883
#Watson IoT Platform parameters
APP_ID = XXXXXXXXXXXXXX
API_KEY = XXXXXXXXXXXXXX
AUTH_TOKEN = XXXXXXXXXXXXXX
#Prediction parameters
PREDICTION_CYCLE = 10
ZSCORE_WINDOW = 10
PREDICTIVE_SERVICE_URL = https://ibm-watson-ml.eu-gb.bluemix.net/pm/v1/score/nocycle20rebuid50?accesskey=XXXXXXXXXXXXXX
- Run the project using the following command
$ mvn exec:java
This project uses open source components. You can find the source code of their open source projects below. We acknowledge and we are grateful to these developers for their contributions to open source.
- org.apache.spark
- com.google.guava
- Github ibm-watson-iot/predictive-analytics-samples
- org.eclipse.paho
- org.apache.commons
- log4j
- org.apache.httpcomponents
- args4j
- org.apache.wink
- org.scala-lang