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

Not finding a laptops #5

Open
lifeanddeath opened this issue Feb 26, 2016 · 18 comments
Open

Not finding a laptops #5

lifeanddeath opened this issue Feb 26, 2016 · 18 comments
Assignees
Labels

Comments

@lifeanddeath
Copy link

Hello bro, greetings from Turkey, I just try to run this project but as far as i see and understand , somehow, it doesnt find my laptops ,however, finds my all phones and tablets, why does it happen?

@dmashuda
Copy link
Owner

Off the top of my head, you could have a network configuration that was not accounted for in the scanner.
Could you post the following information to help me figure out what is going on?:

  • Scanner Device make/model
  • Scanner Device IP address
  • IP address of device found by scanner
  • IP address of device not found by scanner

@lifeanddeath
Copy link
Author

Browski ,
I have my own local network u know, this network consists of my laptop,my android phone,and my families other smart phones, one tablet and an another laptop. So I deliberately assigned my phones IP address to 192.168.1.25 and other devices have IPs like 192.168.1.2 , 192.168.1.3 and so on. SO at this point, my laptops IP is 192.168.1.5 and other laptop has the 192.168.1.9 but when I press the scan button, ıt shows everything but not laptops.

Actually I thought maybe, my firewall prevents me from this but when I use other apps, they still do discover laptop.However, funny part is I tried same project with my 2 different ffriends and in one of them it worked as its supposed to be but other one was the same like mine.
So it was long explain but It really drives me crazy so I just wanted to ask you about it.

And information about your question:

Scanner Device make and model : LG G2-D802
Scanner Device IP address: 192.168.1.25
IP address of device found by scanner:
192.168.1.1-------------> gateway router probably
192.168.1.3------------->samsung android phone
192.168.1.4--------------> tablet of mine
192.168.1.7-------------->another smart phone of home
192.168.1.25-------------->My Phone also I use it as Scanner

IP address not found by scanner= 192.168.1.5

Thanks in advance..

@dmashuda
Copy link
Owner

So under the hood, the scan is pretty simple. It pings the available range of IP addresses and if the device responds to a ping, then the scanner says that a device is at the IP address:
https://github.com/dmashuda/networkScanner/blob/master/app/src/main/java/com/unwind/netTools/DiscoverRunner.java

Does the device respond to a ping from another device?
What OS does the device not found run?

@lifeanddeath
Copy link
Author

I know I have been mingled with code quite much lately :D I understood how it works exactly and I congrulate you for your really nice work.

So I also just now tested to ping to my laptop from another laptop and it works.... My laptop runs Win10, and other is win7... they both can ping to each other whıch means that they re searchable ...
But thats not the case anyways.. Im not sure If u heard but there is a app called Fing, or just lots of apps like that exist anyway.When I try with them they detect these laptops .Only this project doesnt detect.. But I wanna fork and upgrade this project since it uses threads and more student level ..

Bro btw, I added u on facebook ıf u dont mınd, we can talk on there I'm also computer engineering student from Turkey :) So bottom line is, I dont know what to do more .. :(

u can just connect me via teamviewer and look for further implementation bro, if we contact

@dmashuda
Copy link
Owner

I'm glad the you have gotten into the code! I am a Computer Science student from the USA.

Have you tried upping the timeout for discovery?

https://github.com/dmashuda/networkScanner/blob/master/app/src/main/java/com/unwind/netTools/DiscoverRunner.java#L24

perhaps, that the laptops are not responding the the request quick enough?

Feel free to fork it and mess experiment; you are free to make whatever changes according the license: https://github.com/dmashuda/networkScanner/blob/master/LICENSE-2.0.txt

@lifeanddeath
Copy link
Author

Bro, I just set the timout 15000.result is still same :( Here takes so long to write , dıd u see my friendship request on facebook? or if u use skype we can talk more easily, I really dont know why it doesnt detect, we have to make a brain storm together:D

@dmashuda
Copy link
Owner

I don't have much time until Saturday, I'll touch base with you on Saturday to set up a time to troubleshoot this issue.

@lifeanddeath
Copy link
Author

Okey thanks so much .I appreciate it... U can contact me by then .

@lifeanddeath
Copy link
Author

bro when will we troubleshoot?

@dmashuda
Copy link
Owner

Unfortunately I am busier that I expected this weekend, and cannot troubleshoot with you.

I was able to investigate different methods of device discovery.
This app: https://github.com/rorist/android-network-discovery uses a raw ping instead of the InetAddress.isReachable.

If you could try and run that app on your network and let me know if it works or not?

if it does work for you, then I will put in an issue to refactor how we scan in this project.

@lifeanddeath
Copy link
Author

Hi bro, I also downloaded this project before too, it works absolutely fine .
The reason I wanted to study with yours is that its a lot simplier and readable code for me and more simple.Btw, I'm really sorry to bother u with all this mess but I really need your help..If u help me thanks so much really.SO what do we do now?

@dmashuda dmashuda added the bug label Feb 29, 2016
@dmashuda dmashuda self-assigned this Feb 29, 2016
@dmashuda
Copy link
Owner

I am going to implement a native ping option similar to: https://github.com/rorist/android-network-discovery/blob/master/src/info/lamatricexiste/network/Network/Ping.java. My impression is that InetAddress.isReachable() is not as reliable as a native ping option.

@lifeanddeath
Copy link
Author

Okey I'm tryna develop it too, I also added to program kind of vendor finder option too , I dont know how to use github exactly bro but when I'm done with project I guess I'll upload it all to here or on your wall here:D I dont know how its done but shouldnt be hard, just tryna finish project now for my thesis :)
Can u let me know ıf u handle this bug? with ur new way of solving pls?

@dmashuda
Copy link
Owner

dmashuda commented Mar 1, 2016

I will close this issue when it is fixed, you should get a notification automatically.

@lifeanddeath
Copy link
Author

hi bro, did u make any progress? I have been trying to fix this two days in a row but still no solid solution come out.

@lifeanddeath
Copy link
Author

hi, sir mashuda did u find any solution? ı couldnt still :D :(

@dmashuda
Copy link
Owner

I just pushed a modification to implement a native ping. ac42209

This should fix the issue that you have been having

@lifeanddeath
Copy link
Author

Hi bro, I just downlaoded latest update of project, but still aint working.. :(
I guess I should look to another scanners because maybe whole structure of thıs code is different than others. because other android apps that I downlaoded from github works absolutely find and finds my laptop but this still doesnt help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants