/// <summary>
        /// Gets the current workout state for a specified location
        /// </summary>
        /// <param name="serialNumber">The serial number</param>
        /// <returns>The current workout state</returns>
        private WorkoutState?GetWorkoutState(string serialNumber)
        {
            ICommandList commands = _commandListFactory.Create();

            commands.Add(new GetWorkoutStateCommand());
            commands.Prepare();

            try
            {
                _pmCommunicator.Send(serialNumber, commands);
            }
            catch (Exception e)
            {
                _logger.LogWarning(e, "Error occurred while checking workout state prior to polling");
                return(WorkoutState.WaitingToBegin);
            }

            return(commands.FirstOrDefault()?.Value);
        }