Introduction
Tektelic is a Canadian compagny that sell loraWAN gateways and a network server.
Network server configuration
First of all you need to create a specific data converter. Go in Data Converters menu and select the + to create a new one :
Fill the fields with these values:
Field | Value |
Name | PilotThings |
Type | Custom |
Decoder | see hereunder |
Encoder | see hereunder |
Decoder
var arr = [];
for (var i = 0; i < bytes.length; ++i){arr.push(bytes[i]);}
//return { "bytes": JSON.stringify(arr), "port": port, "payload length": bytes.length};
return { "bytes": toHexString(arr), "port": port, "payload length": bytes.length};
function toHexString(arr) {
var s = '';
arr.forEach(function(byte) {
s += ('0' + (byte & 0xFF).toString(16)).slice(-2);
});
return s;
}
Encoder
var bytes = [];
// if (port === 1) bytes[0] = object.led ? 1 : 0;
return bytes;
Step2 is to setup the integration. You must go to Applications menu and select an existing application or create a new one.
In your application select Manage Integrations and create a new one.
Fill the integration detail fields with:
Field | Value |
Name | Pilot Things integration |
Type | Http |
Data converter | PilotThings |
http URL path | |
Application Address |
For local installation : your Pilot Things IP address or DNS name For cloud : start.pilot-things.com |
port | 443 |
Base path |
For local installation : /ipe-tektelic/up-link For cloud : /network/http/tektelic |
Enable https | Yes |
Request Headers |
- Content-type = application/json - token = xxxx-xxxx-xx Ask your Pilot Things representative to get your security access token |
Ask contact@pilot-things.com to get your token.
Comments
0 comments
Please sign in to leave a comment.