Option assignment question

Hello, probably a silly question but i gotta ask it anyways

I bought some nvidia stock, and sold a call option, now after some time my option is in the money

The question that i have now:
i sold the call for 200 usd
and on ibkr the money is collected when you buy back the share for a better price

but what if the above mentioned happens, that 200 usd option is now worth 600 and it shows my position is at -400 unrealized P&L

when the option time runs out and i get assigned will those -400 usd turn into 200 usd since it got assigned and i will get the whole worth of the option? (The 200 usd what it was worth when i sold it)

Can someone please help me understand this
Thanks