DIAdem

cancel
Showing results for 
Search instead for 
Did you mean: 

2's complement in diadem script

I'm trying convert one  of my channels to 2's Complement. I've attached the script i wrote.   I pretty much know how it should be done:
 
Channel(x)  = Not Channel(x) + 1
 
But i can't get it to work. 
 
Any help will be greatly appreciated.
 
The channel i'm trying to convert is Channel(69) "El Position". 
 
Thanks!
Matt
 
 
0 Kudos
Message 1 of 4
(3,454 Views)

Hi Matt,

I looked into the attached file and found the code for a DataPlugin. I couldn't see any reference to a 2's complement. Could you please provide some more detail ? Would it be possible to send the file you are trying to read so that I can see what is not working ?

Andreas

0 Kudos
Message 2 of 4
(3,444 Views)

I just found out that we don't need to implement 2's complement in this DataPlugin.  But thanks for helping. 

what i was trying to do is perform 2's complement in the data plugin.  the value in Channel(x) for example, 16 bit value.  and i was just wondering if I could perform 2's complement on it.  But, not necessary anymore.  Sorry for taking up your time.

 

Matt

 

0 Kudos
Message 3 of 4
(3,418 Views)

Hi Matt,

Thanks for letting me know.

Andreas

0 Kudos
Message 4 of 4
(3,413 Views)