void ServiceResetActivity()
        {
            using (var eeLog = new Logging.EnterExitTrace(Log))
            {
                LPMSim.State lpmState = lpmSimPart.PublicState;
                IActiveToPassivePinsState a2pPinsState = lpmState.InputsState.GetE84InputsBits(pioSelect);
                if (!a2pPinsState.IsIdle)
                {
                    lastSetA2PPins = new ActiveToPassivePinsState();
                    lastSetA2PPins.IFaceName = PartID;
                    lastSetA2PPins.XferILock = true;
                    IBasicAction clearPinsAction = lpmSimPart.CreateSetE084ActivePins(pioSelect, lastSetA2PPins);
                    clearPinsAction.Run();
                    if (clearPinsAction.ActionState.Failed)
                    {
                        Log.Error.Emit("Reset failed: unable to clear E084 pins:{0}", clearPinsAction);
                        SetCurrentActivity(ActivitySelect.Offline, "Reset failed: unable to clear E084 A2P pins");
                        return;
                    }
                }

                Spin(TimeSpan.FromSeconds(0.5));

                lpmState = lpmSimPart.PublicState;
                a2pPinsState = lpmState.InputsState.GetE84InputsBits(pioSelect);
                IPassiveToActivePinsState p2aPinsState = lpmState.OutputsState.GetE84OutputBits(pioSelect);

                if (!p2aPinsState.IsSelectable)
                    SetCurrentActivity(ActivitySelect.WaitForPinsReady, Utils.Fcns.CheckedFormat("Reset complete with E84 P->A pins not selectable [{0}]", p2aPinsState));
                else if (!a2pPinsState.IsIdle)
                    SetCurrentActivity(ActivitySelect.WaitForPinsReady, Utils.Fcns.CheckedFormat("Reset complete with E84 A->P pins not idle [{0}]", a2pPinsState));
                else
                    SetCurrentActivity(ActivitySelect.Ready, "Reset complete and Ready for select");
            }
        }
        bool SetA2PPins(ActiveToPassivePinsState pinsState)
        {
            lastSetA2PPins = pinsState;
            lastSetA2PPins.IFaceName = PartID;
            lastSetA2PPins.XferILock = true;    // so that log messages do not complain

            IBasicAction setPinsAction = lpmSimPart.CreateSetE084ActivePins(pioSelect, pinsState);
            setPinsAction.Start();

            for (; ; )
            {
                if (setPinsAction.ActionState.Succeeded)
                    return true;

                if (setPinsAction.ActionState.Failed)
                {
                    SetCurrentActivity(ActivitySelect.Offline, Utils.Fcns.CheckedFormat("{0}[{1}] failed: unable to set E084 Active pins to '{2}'", currentActivity, privateState.TransferProgressStr, pinsState));
                    return false;
                }

                if (!Spin())
                    return false;
            }
        }
        protected override string PerformGoOfflineAction()
        {
            SetBaseState(UseState.Offline, "GoOffline Action has been performed", true);

            SetCurrentActivity(ActivitySelect.Offline, "Performing GoOffline Action");

            nextActivitySelect = ActivitySelect.None;
            lastSetA2PPins = new ActiveToPassivePinsState();
            lastSetA2PPins.IFaceName = PartID;
            lastSetA2PPins.XferILock = true;
            lpmSimPart.CreateSetE084ActivePins(pioSelect, lastSetA2PPins).Start();

            privateState = new E084ActiveTransferSimEngineState() { StateStr = "Offline" };

            PublishPrivateState();

            return String.Empty;
        }