jisotalo / ads-client

Unofficial Node.js ADS library for connecting to Beckhoff TwinCAT automation systems using ADS protocol.
https://jisotalo.fi/ads-client/
MIT License
80 stars 17 forks source link

write variable type BOOL #124

Closed runtimevic closed 11 months ago

runtimevic commented 11 months ago

Hello, How can I write a binary variable of type BOOL;

{attribute 'qualified_only'}
VAR_GLOBAL
   output1 : BOOL;
END_VAR
const res = await this.client.writeSymbol( "GVL_Test.output1", "0")
const res1 = await this.client.writeSymbol( "GVL_Test.output1", "true")

it doesn't work for me... thank you, Víctor.

runtimevic commented 11 months ago

solution: const res = await this.client.writeSymbol( "GVL_Test.output1", 1)

merry christmas 2023