Files are suddenly Read Only?

Some options off the top of my head…

If you have moved the USB stick, it will get a new mount point.
If you unplug and plug in the stick without unmounting first, Linux can get grumpy.

Both could lead to a read only file mount.

Here is a good thread on how to use Node-RED to call the unmount API.