how to dye carpet in a RV
It’s probably polyester, as most auto carpets are poly.
I would buy a fabric dye made specifically for synthetics. Rit makes them.
Here's an article that can help: http://www.doityourselfrv.com/rv-carpet-upholstery-dyeing-alternative/
Be careful not to get it too wet, as your chip board underlayment could swell and warp. I would apply it lightly with a spray bottle, then put fans on it to dry it quick.
If you dab the color on, it will be uneven all over! Use chemical gloves and an old sponge.