SCAN LOGIC