To see all the available channels, click on the “Show Advanced” checkbox :
More details are available here :
And the jar file if you’d like to test it out is available here :
I know some are going to say this is dumb as it’s something that is already documented and can be done other ways, but I figured since we’re all trying to wrap around the new MainUI I’d make the process for this a little easier.
Not sure if this will ever warrant a pull request to include in the OH releases as I’m not sure something redundant would ever be approved, but I figured I’d make it available to some people who might struggle with the method(s) that have been out there for years.
Under a linux based system it will default to /usr/bin/speedtest for the executable location, so there shouldn’t be much to configure other than how often you want to get the data.
I did, but I didn’t really think the method of testing for that was very easy for someone with little to no knowledge of a system or networking to setup. No offense at all to the creator/maintainer, I was going for more of a “plug it in” type approach.
I could have, but didn’t. Like I said, probably won’t bother with a PR on this, just did it for fun really as I saw a need. Friend of mine was trying to setup OH and asked about a speedtest, I pointed him to the Network binding and he messaged me about his struggles(what URL to use, how do I make an iso, etc… ). I made this. I clearly pointed out that this is likely redundant for some.
I’m personally planning on using it, as well as the Network binding. I just won’t be using the network binding speedtest.
It would be great if you could add some kind of server selection. My isp delivers 1GBit and most server quit on that, so i typically select the server manually.
As far as I could tell Ookla seemed to handle that, which is why I didn’t. They do provide the method to get a server list, so I could have added that but I was testing here and all the servers in the list they provided me were capable. I’m on 1Gbit here at home as well, though I am in an area where 1Gb is the norm, so maybe that’s why.
I can add that, though I’m not sure I can make it a drop down since the config is all set when you create the thing and the process isn’t configured at that point.
Let me think about that a bit and see if I can come up with something that’ll work.
Alright, so how about a simple text entry for the server id? If it’s got something in it I would use it when calling speedtest? I could provide a channel with the contents of “speedtest -L” so all the information is there without leaving the MainUI?
I was really trying to have it be completely in the GUI, none of the “go do this on the command line and enter it here” type of stuff. Unfortunately I’m not sure that I can add configuration parameters programmatically, seems as though you can adjust existing ones from the code, but I don’t see that I can add new ones(though I’m going to see if that’s possible later tonight).
I’ll have that done tonight and will post an update when it’s complete. I’ve tried various methods of doing this(even was going to try and trick the discovery process to showing available servers) but I think I’m going to settle on text entry for the server ID and a channel that will contain a list of the closest servers from the user.
I installed the speedtest-cli and the binding on openhabian on Raspi.
speedtest works manually from cli.
But the thing never gets any data.
Which user and how needs rights to execute speedtest?
Seems as though it misses the first test because of the license acceptance that it has to do. Should work after that without issues. I’ll see if I can work around that though it should work fine for you.
Just setup a fresh openHabian and installed both Ookla and the binding and that’s the only issue I see. I did not set anything but the refresh rate on the binding config.
@bhomeyer thanks for doing this. i started to use the network binding one and it definitely was cumbersome to setup vs just the commandline. in addition it’s missing something compared to the CLI (can’t remember now, haven’t looked at it in a week as i’m still working on other things related to the OH3 upgrade).
I’ve updated the binding to include the ability to select a server ID to test with. I couldn’t come up with a great way to display your options, so here is what I came up with.
Configure it as normal(auto detect) and on the first run it will check the list of closest servers. When that is done, it will fill it in the binding properties :
Just copy/paste one of those ID’s into the new field below it “Server ID”. If you want to put it back to defaults, just remove that setting.
I know they are not ordered correctly, and I have no idea why. It seems to be arbitrarily determine that somehow, but I couldn’t figure that out, I tried. Server List 1 is considered the closest by Ookla standards and it goes on from there.
And I know it’s sort of a hack to do it that way, but it was really the best I could come up with. I was going to put the list in a channel so you could just view it from the Model view, but OH doesn’t allow line feeds or carriage returns in the channel data for a label.
Cool, i doubt i’ll ever use the server list but someone will surely find it useful.
My items and graphs are once again working (came from the old method).