svghmi/svghmi.js
branchsvghmi
changeset 2921 2670f5c53caf
parent 2920 3ee337c8c769
child 2942 b07ad97e6019
equal deleted inserted replaced
2920:3ee337c8c769 2921:2670f5c53caf
   234     send_blob([
   234     send_blob([
   235         new Uint8Array([0]),  /* setval = 0 */
   235         new Uint8Array([0]),  /* setval = 0 */
   236         new Uint32Array([index]),
   236         new Uint32Array([index]),
   237         tobinary(value)]);
   237         tobinary(value)]);
   238 
   238 
   239     cache[index] = value;
   239     // DON'T DO THAT unless read_iterator in svghmi.c modifies wbuf as well, not only rbuf
       
   240     // cache[index] = value;
   240 };
   241 };
   241 
   242 
   242 function apply_hmi_value(index, new_val) {
   243 function apply_hmi_value(index, new_val) {
   243     let old_val = cache[index]
   244     let old_val = cache[index]
   244     if(new_val != undefined && old_val != new_val)
   245     if(new_val != undefined && old_val != new_val)