[Bug]: refuses to play wav files
Describe the bug
i was trying to play a wav file but it instantly stops broadcast
To Reproduce
botwave › dl https://filebin.net/4vsrawciyfibqs61/fart.wav [FILE] Downloading WAV file from https://filebin.net/4vsrawciyfibqs61/fart.wav... [FILE] Downloaded! [##############################] 100.0% Complete [FILE] Downloaded! [##############################] 100.0% Complete [OK] File fart.wav downloaded successfully to /opt/BotWave/uploads/fart.wav
botwave › start fart.wav 76 [OK] Started broadcasting /opt/BotWave/uploads/fart.wav on 76.0MHz
[INFO] Playback finished, stopping broadcast...
OS
raspbian
Version
idk
Machine (Hardware)
rpi4
Additional context
No response
Hello, thanks for opening this issue. Could you try running this command: set talk true and run the start command again? Then send the output on this issue. I think it might be a frequency issue, since the backend is designed to run on 87.5-108 mhz
botwave › start fart.wav 87.5 [DEBUG] Validating environment... [DEBUG] Discovering backends... [DEBUG] Selected backend: bw_custom [INFO] Using bw_custom backend (76.0-108.0MHz, with RDS) [INFO] PiWave initialized - Frequency: 87.5MHz, PS: BotWave, Loop: False [DEBUG] File is already WAV, skipping conversion [DEBUG] Running command: ffprobe -i /opt/BotWave/uploads/fart.wav -show_entries format=duration -of csv=p=0 -v debug [OK] Started broadcasting /opt/BotWave/uploads/fart.wav on 87.5MHz
botwave › [ERR] Could not determine duration for /opt/BotWave/uploads/fart.wav [INFO] Playback finished, stopping broadcast... botwave › [INFO] Cleanup completed
it plays ss.wav on your server fine on 76 mhz but my file doesnt play
Ok thanks, I think I might know why. filebin.net shows a warning (on first visit), which gets downloaded by the program (instead of the actual .wav file). Can you confirm it by running this command ?
< file /opt/BotWave/uploads/fart.wav
If it doesn't shows WAVE audio, that's the issue. To fix it the easiest way is just to use another host
yes it shows up as html but i tried a lot of sites for the filen and none of them worked
Interesting, I'll try to search a solution. For the moment what you can do is:
< wget https://filebin.net/4vsrawciyfibqs61/fart.wav -O /opt/BotWave/uploads/fart.wav
It looks like it bypasses the warning. Does it work (just run the file command again to check)?
it works
thanks
Glad it works! Additionally, if you'd want to keep the integrated tools, you can do this:
# in a regular shell
bw-update -l # to update to the latest version, it's not released yet
# in a botwave shell
set download_ua "Wget/1.21.4 (linux-gnu)"
dl https://filebin.net/4vsrawciyfibqs61/fart.wav
It should completely fix the issue. To make it permanant, create a .env file with this content:
download_ua="Wget/1.21.4 (linux-gnu)"
Thanks again for using BotWave! :D