Fredholm operators and essential S-spectrum in the quaternionic setting