docs: user_scripts: cleanup; reformat script functions; add user defined functions.
docs: user_scripts: cleanup; reformat script functions; add user defined functions.

flit/pyOCD,pyocd/pyOCD,flit/pyOCD,pyocd/pyOCD