IR sensor proximity

dear sir
please i need help

i'm working on a project : i want switch on led 1second and switch off even IR sensor still active
for example : when IR sensor detect obstacle turn led on 1 sencond and turn led off even the obstacle still

thanks