Hi All,
I wanted to share my steps here so that anyone in the need of similar can use this as a guide:
I wanted to add the moxa driver library (in RPI normally found here: lib/firmware/moxa) to the homeassistant OS image
I took my SD-CARD out of the RPI3 and put it in my ubuntu PC where I noticed that the partition with the linux file system got mounted as /sdb3
I then ran “unsquashfs /dev/sdb3” to unpack the read-only file system locally on my pc.
I copied the missing moxa folder into the unpacked lib/firmware directory
I compressed the file system using: “mksquashfs squashfs-root/ live.squashfs -noappend- always-use-fragments”
I unmounted dev/sdb3 by calling “umount /dev/sdb3”
I copied my new filesystem over by calling “cat live.squashfs > /dev/sdb3”
Voila now I have a working USB to RS485 converter
Yours truly
Lasse