Why does sendMediaStreamingVideoEnable () return bad parameter?


My Android APP for controlling Jumping Sumo could not receive onFrameReceived (), but always receive onFrameTimeout (). Today I found sendMediaStreamingVideoEnable () will return “bad parameter”, and after some check I luckily found that, if I wait a while before calling sendMediaStreamingVideoEnable () after start device controller, sendMediaStreamingVideoEnable () will success, and I may be able to receive frame. However if APP pauses and resumes the problem will come back again.
Is there a good way to fix this? Thanks for any help. :blush:


                         //wait a while, or following sendMedia... will return bad parameters
                         try {
                         } catch (InterruptedException e) {
                             // TODO Auto-generated catch block

                    ARCONTROLLER_ERROR_ENUM kerr;
                    kerr = deviceController.getFeatureJumpingSumo().sendMediaStreamingVideoEnable((byte)1);
                    if ( kerr != ARCONTROLLER_ERROR_ENUM.ARCONTROLLER_OK )
                       Toast.makeText(getApplicationContext(), kerr.toString (), Toast.LENGTH_SHORT).show();


Same problem here, any hints would be really useful.


You have to do it as it is done in the samples: wait for the state running before sending the command.