Coder Social home page Coder Social logo

Comments (5)

jrobble avatar jrobble commented on July 1, 2024

SPAN uses the OLSR routing protocol to form the network. Essentially Device A will broadcast a HELLO messages that Device B will here if it's in range. The same thing happens in the opposite direction and they form a link.

We turn off the Wi-Fi in the Settings app because we work below the Android OS and turn on ad-hoc mode in the kernel. Android doesn't natively support ad-hoc mode. You should still be able to send data in your apps even if the WifiManager (http://developer.android.com/reference/android/net/wifi/WifiManager.html) tells you that there is no network.

Try and form a network with two devices and click on the "Routing Info" option in the MANET Manager app. Please include the output in your next reply.

from android-manet-manager.

wooof21 avatar wooof21 commented on July 1, 2024

Thank you for your replying, sir! I got the broadcast worked, but now the problem is, if want to send a unicast message to a device in the network, how I get that device IP? In your project, when a device join the network, in the visualizer it will automatic show the device IP, I don't know how you detect the other device IP address, can you also give a hint please?

from android-manet-manager.

jrobble avatar jrobble commented on July 1, 2024

The SPAN code pulls the IP address from the OLSR txtinfo plugin. You can use the SPAN API to get information about peers in the network. You need to use ManetHelper.sendPeersQuery(), which will invoke the callback ManetObserver.onPeersUpdated(). Refer to how the android-manet-ptt and android-manet-visualizer projects use those calls.

from android-manet-manager.

superdav815 avatar superdav815 commented on July 1, 2024

Hi I am new to android programming doing networking project application to run on nexus7 tablet, can you give beginner step by step details on how to get the IP addresses and nexthop address from OLSR routing table. I unable to understand how android-manet-ptt is doing it.

from android-manet-manager.

jrobble avatar jrobble commented on July 1, 2024

The Manet PTT app is using the Manet Manager Service. The Manet Manager Service pulls a text dump from the running olsrd process using the OLSR txtinfo plugin. Refer to this code:

https://github.com/ProjectSPAN/android-manet-manager/blob/master/AndroidManetManager/src/org/span/service/routing/OlsrProtocol.java

Specifically, look at the InfoThread and getPeers() method.

from android-manet-manager.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.