opto coupler is used for the isolation between the input high voltage side and the low output side.
it controls the tiny swithching frequency.the output of the opto is connected to the EN pin of the TNY.the output current of the photo opto coupler,ie the current through the output diode of opto is controlled by the input voltage of the opto,ie nothing but the voltage fed back from the output.
thus the feed back voltage controls the current in the opto-output,the current drawn from the EN pin of TINY,which inturn controls the switching frequency.
can refer the application notes given in www.powerint.com