ctrlx-datalayer
v2.4.1
Published
Bosch Rexroth ctrlX Data Layer API
Downloads
317
Maintainers
Readme
Bosch Rexroth ctrlX Data Layer Node.js API
This is the ctrlX Data Layer API for Node.js.
Based on Node.js N-API accessed by module node-addon-api
https://github.com/nodejs/node-addon-api
nan
: C++-based abstraction between Node and direct V8 APIs.Node-API
: C-based API guaranteeing ABI stability across different node versions as well as JavaScript engines. (Node-API was previously known as N-API.)node-addon-api
: header-only C++ wrapper classes which simplify the use of the C-based Node-API.
This also uses Node.js native addon build tool node-gyp as native compiler toolchain
https://github.com/nodejs/node-gyp
The API project has been initially generated by generator-napi-module
https://www.npmjs.com/package/generator-napi-module
https://github.com/digitalinfinity/generator-napi-module/blob/master/README.md
Usage
Quick Overview
This library enables read and write access to the ctrlX Data Layer of ctrlX AUTOMATION devices from Bosch Rexroth. It provides interfaces and classes written in Typescript to create ctrlX Data Layer clients and providers.
Install
npm install ctrlx-datalayer --save
Usage
The following code snippet demonstrates how to create a client and read a value from a ctrlX Data Layer node:
async function main() {
// Create DatalayerSystem and start
const system = new DatalayerSystem('');
await system.start(false);
// Build remote
const cred = {
user: 'boschrexroth',
password: 'boschrexroth',
ip: '192.168.1.1'
};
let remote = Remote.build(cred);
// Create a client
const client = await system.createClient(remote);
// Read value
const variant = await client.read('framework/metrics/system/cpu-utilisation-percent');
console.log(variant);
}
main();
Samples
It might be helpful to have a look at the README Node.js Apps @ ctrlX document to find implementations of the different use-cases.
Support
This repository is provided and maintained by Bosch Rexroth.
Developer Community
Feel free to check out and be part of the ctrlX AUTOMATION Community. Get additional support, e.g. related to Bosch Rexroth Devices, Apps, SDKs and Services, or leave some ideas and feedback.
SDK Forum
Please join the discussions in the SDK Forum ctrlX AUTOMATION:
Issues
To report bugs, request changes and discuss new ideas you may also have a look at the issue tracker of this repository: https://github.com/boschrexroth/ctrlx-automation-sdk/issues
License
SPDX-FileCopyrightText: Bosch Rexroth AG SPDX-License-Identifier: MIT
Terms and Conditions for the Provision of Products of Bosch Rexroth AG Free of Charge
See LICENSES/tc_for_provision_of_products_free_of_charge.pdf inside this package. Please download the latest version from https://www.boschrexroth.com. Navigate to Legal Notice (footer) -> Terms and Conditions for the Provision of Products Free of Charge
See LICENSES/*.fossinfo.xml for used open source software licenses.
About
Please note that any trademarks, logos and pictures contained or linked to in this Software are owned by or copyright © Bosch Rexroth AG and not licensed under the Software's license terms.
Bosch Rexroth AG
Bgm.-Dr.-Nebel-Str. 2
97816 Lohr am Main
GERMANY