Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[REQUEST] UI for easier management :) #35

Open
skynet01 opened this issue Mar 9, 2020 · 10 comments
Open

[REQUEST] UI for easier management :) #35

skynet01 opened this issue Mar 9, 2020 · 10 comments
Labels
enhancement New feature or request

Comments

@skynet01
Copy link
Contributor

skynet01 commented Mar 9, 2020

LOVE your app! It really made the setup of the monitor simple! Improvement suggestion:

I know monitor script discoveres devices all the time. It would be awesome to have some GUI or alternatively using some predefined parameters to add new Bluetooth aliases automatically into the config?

Use case scenario: The user has a guest that comes to the house. When Arrival scan is triggered monitor script detects that along with the owner there is a new bluetooth address (it detects that it's an Apple or Android device) and adds those Bluetooth addresses to the config.

If there is a GUI then we can show a list of new users and an ability to rename them. If there is none they can just be added as guest1, guest2 and it's up to the owner to rename them later.

I know there are a few caveats here like detecting neighbor's Bluetooth devices etc. Which we can probably tweak later (like adding them to a blacklist). However, I do believe that this can really be useful for adding guests to the "allowed" list of the house quickly.

@Odianosen25
Copy link
Owner

@skynet01 thanks for using the app.

I do like the suggestion and yes it is possible to create a GUI, could use the AD dashboard for that. Now this is how I think it could work, based on the scenario. Do tell me if it didn’t cover what you asking for.

  • The nodes will report the environment, using the -e flag, so it reports every Bluetooth devices it sees
  • The app picks them all up, check does that are known devices and processes them as it is now
  • Those that are not known devices, will be stored locally and displayed in the dashboard
  • From the dashboard, the user can then view all MAC addresses and as you said add them to known devices and rename them
  • So each time the nodes or the entire monitor system reboots or something, that known devices will load up

Now the things is, these guest you need to know their MAC addresses anyway, before adding them. Unless you want to use the RSSI values to know that guest is definitely in the house before adding them. My advise is still to check the users MAC address before adding it.

How does that sound?

@skynet01
Copy link
Contributor Author

skynet01 commented Mar 10, 2020

Pretty much. I tweaked your sentences to include the fact that we filter for device's manufacturer id based on Bluetooth mac address... So the process is this

  1. During the arrival scan or upon manual scan request (with -e flag) the node checks for all devices that it sees.
  2. The app picks them all up, check for known devices and processes them as it is now
  3. Those that are not known devices, will be stored locally and displayed on the dashboard. Filtering can be set up to only show Android or Apple devices based on name string that's included in the scan. (This way it's a lot more likely that the new device people are seeing on the list is a phone).
  4. From the dashboard, the user can then view all MAC addresses and add them to known devices and rename them.
  5. So each time the nodes or the entire monitor system reboots or something, that known devices will load up

We can use the RSI values and show them as signal strength bar. We can also maybe show how many times this address been seen.
...This should make the decision of picking the mac address blindly easier. But yes I agree the best is verifying with the actual phone if the address matches.

I think in the real-life situation though you will only have 1-3 new devices max (in a noisy place) when a new guest arrives. If I see that it's an apple device, has a good RSSI strength I can safely assume it's my friend's and add them to the list.

Another cool part about this is that it will make the initial set up faster too. I just install the HACS addon, do a manual scan using GUI then add the devices.

Maybe, later on, there could even be a smarter auto-add logic. Like if device is Apple and it has certain RSI range and it's been detected 3 times (friend visits often) then add them to the list...

Thanks so much for considering all this btw :)

@Odianosen25
Copy link
Owner

@skynet01 its alright, I am always up to a little challenge. Just that I am not really into GUI stuffs, but will see how best I can put it into dashboard. I forgot to mention that there will not be any RSSI value, unless the device been paired to the node first.

When I get around to the GUI stuff, will be important to be able to pair from a GUI really.

Regards

@skynet01
Copy link
Contributor Author

Oh i didn't think about RSI being paired. I am actually a designer myself I can mockup the UI for you if that will help?

@Odianosen25
Copy link
Owner

@skynet01, oh that’s be nice if you could help with that. I assume it’s gonna be dashboard? Or you want to make a standalone web interface? As AD now supports the ability for apps to serve custom web interfaces using the “app” route on the same port (dev only for now). We added this to support such ventures like this.

Anyways when ready, we could discuss your approach so as you build that, I could jump on the backend. If using dashboard (which I think is gonna be easier being inbuilt), I suggest the following:

  • 3 input select, 1 for remote nodes, 1 for populating the known devices and the other for unknown devices
  • For nodes this will allow for stuffs like to pair it against a selected known device, restart it, or modify how the script runs within it. I like the idea of being able to edit all nodes from a single GUI 😉
  • Known devices, will be to remove or rename them
  • Unknown devices, the above and to add to known devices
  • Some buttons for different things like those said above, which will control based on selected options
  • Some general buttons like if wanting to run arrival/depart scan manually

Just initial thoughts, so let me know what you think. In the mean time, I will turn the above stuffs into service calls in the app, so all the dashboard will do is to call the right service and voila. It should work.

Regards

@Odianosen25 Odianosen25 added the enhancement New feature or request label Apr 8, 2020
@skynet01
Copy link
Contributor Author

skynet01 commented Aug 10, 2020

@Odianosen25 hey sorry for the delay on this. I got the first draft of the design ready:
https://invis.io/XMYDM6UPTR3#/428112230_No_Nodes_Yet
You can click around in the prototype above (navbar) and it will take you to appropriate pages, or you can also click left / right arrows

I tried to make it very simple for development so no fancy design here. I also didn't include a lot of fancy details or options, as we can add that later.

  • For example, each person can show additional information from the scan, etc.
  • On initial run Known People tab is disabled until at least one node is added so that there is a place to push those MAC addresses :)
  • Not sure if we can scan the network and pick up found nodes if we can't I can remove that design.
  • The edit icons show up on hover.
  • Also don't know if you are gonna use modals or not, for now, I just designed it so when you click on a tile it expands.
  • If there are any limitations let me know and I can adjust accordingly

Let me know if you want to add some functionality to combine devices into a single person since I know there is a ticket for that already. I just wasn't sure you wanted to do it all at once :)

@Odianosen25
Copy link
Owner

Wow this is really nice, how did you build that? With that, its as easy as service calls into AD using Websockets. i will need to add the other service calls to support things like running command line stuffs. Been busy with other projects so will see what I can muscle out this week.

@skynet01
Copy link
Contributor Author

Used sketch to draw it out. If you click on the "</>" icon in the bottom right you can see some of the css parameters for items. You should be able to build this pretty easily using a Bootstrap framework or even from scratch.

@Odianosen25
Copy link
Owner

GUI I have been so lazy to learn, but I really want to. Took me so much time to even decide to learn AD dashboard, I am that bad. Will try it

@skynet01
Copy link
Contributor Author

Let me know if there is any other way i can help :)

@skynet01 skynet01 changed the title [REQUEST] Easier addition of new guest bluetooth devices [REQUEST] UI for easier management :) Aug 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants