mode toggle LED indicator function added