Do you have the same versions of the rest of the software?
One UI version 2.1
Android version 10
Build number QP1A.190711.020.T830XXU4CTF5
Software version: T830XXU4CTF5 / T830OXM4CTF5
It was hardware issue.
Replacing the S-Pen solved the problem.
In my opinion it was loss of pressure sensitivity or pressure sensor damage.
There is no connection with the "Direct pen input" menu item - just coincidence in time.