ofxEtherdream icon indicating copy to clipboard operation
ofxEtherdream copied to clipboard

reconnect example?

Open jeffcrouse opened this issue 9 years ago • 3 comments

Is it possible to see an example of how to use the bAutoConnect and/or checkConnection(true) function? I am getting periodic write timeouts from my etherdream, but neither of these thing seems to help. Any other suggestions would also be greatly appreciated. Thanks for the awesome addon.

jeffcrouse avatar Jun 20 '15 11:06 jeffcrouse

In you main loop, you should call to this function on each loop.

if (etherdream.checkConnection()){
     ildaFrame.update();
     etherdream.setPoints(ildaFrame);
}

To avoid unconnection you can try different thing :

  • running on cat5 or cat6 cable
  • lowering the pps and pointCount

I did also change a bit the checkConnection function to manage other connection issue that just shutdown :

bool ofxEtherdream::checkConnection(bool bForceReconnect) {
    if(device->state == ST_SHUTDOWN || device->state == ST_BROKEN || device->state == ST_DISCONNECTED) {
        if(bForceReconnect) {
            kill();
            setup(true, idEtherdreamConnection);
        }
        return false;
    }
    return true;
}

You can find my modified ofxEtherdream on my github, which also allow to connect to multiple etherdream. Should I do a pull request memo?

pach avatar Jun 20 '15 11:06 pach

Thanks pach! I am using your branch now. I am using a cat6 cable, which presumably is better. Have you found that cat5 is better for some reason? Or just worth a try?

jeffcrouse avatar Jun 20 '15 14:06 jeffcrouse

@jefftimesten unfortunately I'm not sure why this happens. I too have found that when it starts to flicker - that's a sign that connection might be lost, manually dropping the point count helps. The problem isn't directly related to the pps, but the shape being drawn as well. I know a lot of people who are having this problem, but the developer of the etherdream himself said he hasn't encountered the problem. So I'm not sure if it's an issue in the ofxEtherdream version or in the firmware itself. I have heard that there might be a new firmware which addresses the issue, but unfortunately I haven't been able to test it yet.

Thanks for the updates @Pach.

memo avatar Jun 26 '15 16:06 memo