Final changes (total devices still processed incorrectly)