Thanks to everyone for the help and your patience with me spamming the thread.
For TinyCoreLinux and piCorePlayer, the script works from the shelf, if:
- Paho-mqtt is installed in the environment, which requires to install it everytime with bootup anew, because the content of the environment folders is in RAM. We did this with a shell script placed in /home/tc that starts paho-mqtt in the background. The shell script is started fom bootlocal.sh and includes 30 seconds delay in order to have an active internet connection before pip attempts to install the script.
- The tonecontrol script is loaded in the environment and run in the background, done with an entry in the same shell script as paho-mqtt.
- Node can be installed as a binary from nodejs.org to /home/tc, which is not a clean tinycore approach, because it is much data loaded into RAM. But it works. Due to whatever reason, npm does not start from the uncompressed directory, while Node does. So we delete the folder, uncompress the tarball, install it and move it to /usr/local each time, before starting it (Maybe moving it again to /usr/local is enough, need to check this). Done from bootlocal.sh.
- zigbee2mqtt can be saved to /home/tc and is started with a shell script, that has the same delay to wait for the installation of the other components. The shell script is started from bootlocal.sh.
- mosquitto is used via an extension loaded from the armv7 tinycore repository. The configuration file can be supposedly be changed via mosquitto -c ..., and we did, but it is not reflected in the console. It works though.
- Obviously, the tonecontrol.py script must contain the IP of the Pi and the ID of the knob.
This is how it works. I would however love to have the tonecontroll script behave differently. If the actions brightness_step_up and brightness_step_down could be used for i.e. treble and color_temperature_step_up and color_temperature_step_down could be used for bass, there is no chance to mix them up, ass the latter requires to turn-press. The action toggle could then be used to reset values to 0. With this configuration, a blind use of the knob is reliable, as after resetting the value to zero it is easy to change bass and treble precisely, without needing to know its current value and whether the knob is toggled to bass or treble manipulation. However, the scripts function revolves around the category tone_db_change whose effect is controlled via the changing of a value via toggle. So I don't know how to to it at the moment, this requires to understand camilladsp classes and python.