GLaDOS (Portal) voice pack for Roborock / Xiaomi vacuums

I stumbled onto this one as well and there is actually a quite easy fix for it, however I didn’t give it a try using the app, as I don’t understand how it works :smiley:

When logging into the robot remotely via ssh, you’ve already found that the files in /mnt/resources are read only. This is where you can dig just a little deeper:

[root@rockrobo ~]# mount
...
/dev/nandh on /mnt/resources/audio_bit type squashfs (ro,relatime)
/dev/nandj on /mnt/resources/audio_custom type squashfs (ro,relatime)
/dev/nandi on /mnt/resources/audio_default type squashfs (ro,relatime)

You should find the audio files are mounted in as read-only from the various /dev/nand*s.

While you cannot remount with rw, what you can do is unmount… :wink:

As I just wanted the GLaDOS sounds, I copied the content of the /mnt/resources/audio_default directory into /mnt/data/custom_sounds, then I grabbed a copy of the glados sounds, converted them into ogg files and overwrote the files that are already in the audio_default/sounds/ folder.

Finally I modified the /mnt/reserve/_root.sh so it waits until an existing file from /dev/nandi becomes available, then unmounts that device and mounts my folder from /mnt/data in its place, it currently looks like this, I added the last 5 lines in the if statement:

#!/bin/bash
if [[ -f /mnt/data/valetudo ]]; then
        mkdir -p /mnt/data/miio/

        if grep -q -e "cfg_by=tuya" -e "cfg_by=rriot" /mnt/data/miio/wifi.conf; then
                sed -i "s/cfg_by=tuya/cfg_by=miot/g" /mnt/data/miio/wifi.conf
                sed -i "s/cfg_by=rriot/cfg_by=miot/g" /mnt/data/miio/wifi.conf
                echo region=de >> /mnt/data/miio/wifi.conf
                echo 0 > /mnt/data/miio/device.uid
                echo "de" > /mnt/data/miio/device.country
        fi

        # Delete useless cleanup logs on each boot to enable Valetudo to update itself
        rm -r /mnt/data/rockrobo/rrlog/*REL

        VALETUDO_CONFIG_PATH=/mnt/data/valetudo_config.json /mnt/data/valetudo >> /dev/null 2>&1 &

        while [[ ! -f /mnt/resources/audio_default/power_on.ogg ]]; do sleep 1; done
        sleep 1
        umount /dev/nandi
        sleep 1
        mount /mnt/data/custom_sounds/audio_default /mnt/resources/audio_default

fi

This should get you going… :slight_smile: