jeroen1602 / lighthouse_pm

A Flutter app for controlling the power state of Valve Index® lighthouses
Other
158 stars 8 forks source link

Cannot add 1.0 Base Stations - Will not accept ID #105

Open ghost opened 3 years ago

ghost commented 3 years ago

I cannot add my 1.0 base stations, as the app keeps saying the last digits do not match what it's looking for. The ID on either of my base stations does not match the last 5 of what the app says it should be. These are the only base stations in my house and I live far enough away from people that I know it's not picking up some other base station somewhere.

Screenshot_20210419-123140 IMG_20210419_123155 IMG_20210419_123224 Screenshot_20210419-123427 Screenshot_20210419-123405

jeroen1602 commented 3 years ago

So when I made this feature I made the assumption that the last few digits of the id matched the last few digits from the device name.

I did this because all the devices of the volunteers that I used that was the case. So you're the odd one out. I will change it to say should probably match ***** and remove the validation for it and only validate the length.

I also see now that I didn't take the correct sub string since the end it should check against is 4 digits not 5.

ghost commented 3 years ago

Thanks! I do want to note I bought these used on eBay so I don't know their history. They may have been warranty replacements or something.

jeroen1602 commented 3 years ago

Maybe they program in the old ids for the new devices so you don't have to re-pair them? Or maybe the id and name being the same-ish is only for newer devices. It also looks like that your lighthouses are named HTC BS-****** while the ones I tested with were named HTC BS ******.

Anyways the items to change for this fix are:

jeroen1602 commented 3 years ago

I have fixed the issue. I will add a link to a website where I have have the web version of lighthouse pm hosted so you can test it!

jeroen1602 commented 3 years ago

If you want to test it out go to https://jeroen1602.github.io/lighthouse_pm/ The web Bluetooth api is still very young though so only a few browser work. On Android:

On Window 10:

On Windows versions before 10:

On Linux:

On macOS:

ghost commented 3 years ago

Hi,

I tested this today and it seems like I can get the base stations to sleep successfully but not wake up. It does not seem to report their status either (says status unknown). Further testing seems to indicate that it does not really matter what I put in the base station ID field, it will sleep them but not wake them up. That makes me think the ID number on the back of these units is not matching what is internally the ID number. However, I'm not sure if there is another way to get the "correct" ID of these base stations if the sticker doesn't have the right number.

ghost commented 3 years ago

Alright, I did a little more troubleshooting to see if I could confirm the ID numbers are correct. I found that the device ID number stickers are indeed correct as they match what the SteamVR system report generates.

I unplugged one base station and powercycled the other one (to make sure I was not accidentally typing the ID for base station 1 into base station 2). I then reset all the saved base station IDs and cleared base stations, reloaded the webpage and re-paired with bluetooth. I typed the correct ID but it still had the same effect of saying state unknown.

Putting the base station to sleep seems to turn it off (no status light) and it will not turn back on. I also repeated all the aforementioned steps with "use standby instead of sleep" toggled but it was the same result - telling the base station to sleep turns off the LED light and it will not turn back on until I disconnect power from the base station and plug it back in.

jeroen1602 commented 3 years ago

Thanks for testing it!

I haven't figured out a way yet to read the current state of the Vive base stations so they always show up as Unknown. The best way to combat having to do too many actions is throwing both your Vive base stations into a group and toggling the group as a whole.

But I have no idea why it won't let you turn them back on!? Maybe it's a problem with the web implementation? I'll create an apk version that you can side load onto your device to test it

jeroen1602 commented 3 years ago

Here is an apk version. Just in case here is a tutorial on how to sideload apps.

lighthouse_pm-1.3.0-beta+8.arm.arm64.zip

ghost commented 3 years ago

I installed the APK and it seems to be working the same as the web version - the base stations will go to sleep but will not turn back on. It almost seems like they are off since the LED light is totally off, but they still show up in the app. I tried pressing both "sleep" and "on" but neither will wake up the base station.