I am a simple person who does not have a clue how to start a web GUI - in Merlin or LuCI. I used just enough of your code to save to a database file. I don't mind getting the file from a shared location and importing into Excel. Maybe someday I will get fancy and write a *.conf file for the script to read.
One question
@Jack Yaz . The binary on Ookla's website is different than yours for Merlin. In particular, the -c option is missing now (custom config). In the Merlin version, you had the -c option pointing to some api on the web. was this to get things working with Merlin? With the new binary, you just install it and run it (./speedtest). It does everything automatic if you give no options.
Here is what I borrowed and fixed up to work for me (I kept your database reset in case I need it)
EDIT: OK, I guess not. The website won't let me post the finished product, but it works for me