This is a Proof of Concept and software implementation (Simulator)
Implementation of Smart Home Application using Distributed Ledger Technology (DLT) IOTA in written in pure JavaScript using IOTA core libraries.
Note: Require NodeJS and NPM Installed on machines
The methods to run this in order to try and simplify its usage are:
STEP 1: Install three packages using the following commands in the root folder:
npm install @iota/mam.js
npm install moment
npm install iota.lib.js
STEP 2: Now go to the directory [./poc/]. Then run the following command
node humanPresence.js [value]
This value can be 'true' and 'false' representing humanPresence detected by PIR sensor data and then it will create a json file channelState.json'.
STEP 3: Open three respective terminal for each devices (./poc/smartLedLight/, ./poc/thermostat/, ./poc/airConditioner/) to see the effect.
(i) write following command in Smart Led Light Terminal:
node receivePIRdata.js
(ii) write following command in Thermostat Terminal:
node receivePIRdata.js
(iii) write following command in Air Conditioner Terminal:
node receiveThermostatData.js