What I can imagine is that the task description calls for a completely different solution: An LED where the intensity is controlled by a PWM signal. To turn the LED slowly on or off, the duty cycle of the PWM needs to be controlled automatically (e.g. by a ramp). Is this what you are looking for?
The principle is shown here:
The blue line is the ramp signal: slow turn-on, stay on for some time, slow turn-off.
The triangular signal (not shwon in the diagram) would be a fast triangle wave with a frequency e.g. >100Hz to make the resulting flicker of the LEDs invisible to the human eye.
The comparator creates the PWM with 'automatically changing duty cycle' to turn the output power slowly on or off.
I suspect this is homework or an assignement (given the task description in your last post). I will therefore:
- Move the thread to the homework section
- Not diclose the complete circuit. From the above principle, design your own circuit. Show us your effort and we'll gladly help you fill in the gaps.