PIC&MIX - SR latch with comparator (PIC12F1840)