0 Replies Latest reply on May 17, 2018 6:16 AM by David Mohnke

    Profile Manager's ProcessProfile() method returning "Bind Error"

    David Mohnke

      I've got a settings application that is trying to disable the WWAN Radio to simulate airplane mode.

       

      I'm using the following profile:

       

      <characteristic type="Profile">

          <parm name="ProfileName" value="WirelessMgrWWANProfile"/>

          <parm name="ModifiedDate" value="2018-04-04 12:00:00"/>

          <parm name="TargetSystemVersion" value="6.3"/>

          <characteristic type="WirelessMgr" version="6.1">

            <parm name="emdk_name" value="wm1"/>

            <parm name="WWANState" value="0"/>

          </characteristic>

       

      With the code snippet as follows:

       

              public void EnableWWAN(bool enable)

              {

                  var profileData = new[]

                  {

                      $"wm1.{WirelessManager.WWAN_STATE}={(enable ? WirelessManager.WWANState.TurnOn : WirelessManager.WWANState.TurnOff).ToString("d")}",

                  };

       

       

                  _profileManager.ProcessProfileAsync(WIRELESS_MANAGER_WWAN_PROFILE_NAME, ProfileManager.PROFILE_FLAG.Set, profileData);

              }

       

      What I'm seeing is that it works most of the time.  However, it will sometimes return "Bind Error" in the callback.  Is there something I can do to avoid this (i.e. what's the cause?).  Once the device (A TC56 running Marshmallow 6.0.1), the only way to clear the state seems to be either a factory reset or enterprise reset on the device.