V1/Toolbox.NETMF.Hardware.Port/PortHeartbeatBroker.cs
/// <summary>
/// Calculate the hightest count to be used
/// for looping the subscription array
/// </summary>
Calculate the hightest count to be used
for looping the subscription array
Calculate the hightest count to be used for looping the subscription array
private void RecalcCount()
        {
            lock (this._semaphore)
            {
                int optCount = 0;
                for (int i = MaxSubscribers - 1; i >= 0; i--)
                {
                    if (this._subscriptions[i] != null)
                    {
                        optCount = i + 1;
                        break;
                    }
                }
                this._optimizedCount = optCount;
                this.IsEnabled = optCount > 0;
            }
        }
private void RecalcCount ( ) { lock ( this . _semaphore ) { int optCount = 0 ; for ( int i = MaxSubscribers - 1 ; i >= 0 ; i -- ) { if ( this . _subscriptions [ i ] != null ) { optCount = i + 1 ; break ; } } this . _optimizedCount = optCount ; this . IsEnabled = optCount > 0 ; } }
Calculate the hightest count to be used
for looping the subscription array
Calculate the hightest count to be used for looping the subscription array
//enable the master clock only  //if there's something to manage