Second code has no closing bracket at the end, so I very much doubt anything is changing there. I asked you to post output where TX is changing together with f value:
Tx: TxValuewhichischanging
f: fValue
If you not going to, I don't think I can help.