[IDEA] Include moodecfg.txt on ISO - Printable Version +- Moode Forum (https://moodeaudio.org/forum) +-- Forum: moOde audio player (https://moodeaudio.org/forum/forumdisplay.php?fid=3) +--- Forum: Feature requests (https://moodeaudio.org/forum/forumdisplay.php?fid=8) +--- Thread: [IDEA] Include moodecfg.txt on ISO (/showthread.php?tid=2715) |
Include moodecfg.txt on ISO - normand - 06-28-2020 This might sound stupid but include a default boot/moodecfg.txt file on the downloaded ISO. This would save the user a few steps before first run. Just edit an existing file before inserting into pi. Might also eliminate a few errors as well. Also the info is deceiving in https://github.com/moode-player/moode/blob/master/www/setup.txt " 3. AUTO-CONFIGURE AT BOOT NOTE: This works only on a fresh image that has never been booted! NOTE: To start AP mode at boot set wlanssid to blank e.g., wlanssid= a) Change values in the file below b) Paste contents into /boot/moodecfg.txt c) sudo reboot d) Join AP SSID if using AP mode, then http://hostname.local or http://172.24.1.1 " sudo reboot would only work after system is booted, but note says never been booted RE: Include moodecfg.txt on ISO - Tim Curtis - 06-28-2020 The challenge is that the presence of the file in /boot will trigger auto-config. lol, tru about #3. I'll edit. RE: Include moodecfg.txt on ISO - normand - 06-28-2020 (06-28-2020, 02:25 PM)Tim Curtis Wrote: The challenge is that the presence of the file in /boot will trigger auto-config. Yes but only on first boot as I understand it. MoOde must have an initial config for first boot, just put those defaults into the config.txt. If user wants custom config on first boot, they would just have to edit existing file before inserting into pi RE: Include moodecfg.txt on ISO - Tim Curtis - 06-28-2020 Right but auto-config initiates a reboot after it completes then it deletes moodecfg.txt file. What this means is that for a stock moOde image on first boot there would be an unnecessary reboot. RE: Include moodecfg.txt on ISO - TheOldPresbyope - 06-28-2020 Maybe there's a middle ground here. What if the ISO included a "moodecfg.txt.dist" flle in the boot partition filesystem? If the user ignored it, then moOde would go through its first boot with the parameter values already built into the code. If the user copied it (or renamed it) to moodecfg.txt and edited it, then moOde incorporate the parameter values from the file as it goes through the first boot. Used or not, the file(s) could be deleted after the first boot, as is done now, to avoid confusion later on. This compromise would require little additional work on @Tim Curtis's part while, it seems to me, providing the boost to the user that @normand is looking for. What I like best about this scheme is that it would make more visible any changes which might occur in future moOde releases to the structure or content of the moodecfg.txt file without me having to go find the prototype in the rootfs or in the repo. Just a thought. Regards, Kent RE: Include moodecfg.txt on ISO - bitlab - 06-28-2020 I like the @TheOldPresbyope variant with the template file available. It will improve the self support of users. RE: Include moodecfg.txt on ISO - Tim Curtis - 06-28-2020 I'll add to the TODO list. RE: Include moodecfg.txt on ISO - normand - 06-28-2020 That's a good solution. RE: Include moodecfg.txt on ISO - audiophonics - 01-28-2021 Is there a way to keep a custom parameter into /boot/config.txt even if customer change for example the DAC setting ? It seem the whole file is always overwritten. RE: Include moodecfg.txt on ISO - Tim Curtis - 01-28-2021 The file is manipulated with sed commands. Have a look at the two source files below. https://github.com/moode-player/moode/blob/develop/www/inc/playerlib.php https://github.com/moode-player/moode/blob/develop/www/command/worker.php |