i am using these codes:
Client.js:
var client = require('./Client');
client.on("resourcefound",function(event){
//client.retrieve();
//client.update();
});
client.findResources();
Server.js:
var server=require('./Server');
server.register({
resourcePath:"/a/fan",
resourceTypes:[ "core.fan" ],
interfaces:["oic.if.baseline"],
discoverable: true,
properties:{on:false}
});
I am running these codes and nothing happened like a infinite loop in both terminals.
I am using Sakari's code and i get a lot of errors
Can anyone help me to understand if client discovers the resource and what can i do to see the request and response.
PS:i dont know if require is correct Sakari says require("oic")("client") for the client.js but i get error like oic not found.