Added stats gathering for analog in and ambient sensor