scanData in google-maps-device-locator

I'm using the google-maps-device-locator library to sense mac addresses & signal strength/quality on my P2. I intend to send those addresses to a Boron for cellular communication to the cloud so I can determine location in areas I don't have password access to the available wifi networks.

In my logs I have a recurring entry where scanData = an array of mac addresses, strengths and quality. It's the exact data that I'm looking for. But I haven't been able to use scanData to define a new variable or intentionally reproduce the addresses in the log.

The error I get is scanData was not defined in this scope, but I see it as a part of the library in the .cpp file.

The scanData is a local variable so you won't be able to access it.

You could call the scan() method which is what returns scanData. Basically just do this in your code:

const char *scanData = locator.scan();

Replace locator with whatever you named your GoogleMapsDeviceLocator global variable in your code.

that worked great, thank you.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.