You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm calling artnet.set() in a big (and nested in another for()) loop, and I can't see data output to the network (I'm using tcpdump to check), however a simple call effectively transmits data. I know we're not here to debug my own code, but could this be an sync/async issue, having the set() method being called when we're already outside the loop?
It looks to me that ArtNet is rather sequential and that async calls are not very suitable, so I'm simply wondering if using NodeJS for this is relevant, and if I should simply try to stick to a more primitive and sequential language.
Anyway, trying to figure out the logic behind some simple code like this without being able to output data to an ArtNet node:
for(leti=0;i<=maxval1;i++){// computing some numbersfor(letj=0;j<=maxval2;j++){/* computing some other numbers to make them available for outputting in an array */}artnet.set(0,1,data_array,function(err,res){console.log("never reaching this point");});}artnet.close();
Should I ensure that something is correctly done before calling set()?
The text was updated successfully, but these errors were encountered:
I'm calling
artnet.set()
in a big (and nested in anotherfor()
) loop, and I can't see data output to the network (I'm usingtcpdump
to check), however a simple call effectively transmits data. I know we're not here to debug my own code, but could this be an sync/async issue, having theset()
method being called when we're already outside the loop?It looks to me that ArtNet is rather sequential and that async calls are not very suitable, so I'm simply wondering if using NodeJS for this is relevant, and if I should simply try to stick to a more primitive and sequential language.
Anyway, trying to figure out the logic behind some simple code like this without being able to output data to an ArtNet node:
Should I ensure that something is correctly done before calling
set()
?The text was updated successfully, but these errors were encountered: