none
Geosense for Windows not working RRS feed

  • Question

  • I am unable to get the Geosense for Windows sensor to work continously and I am not sure if there is something stopping it from working. Since there no forums or documentation for it I thought I might try asking here to see if anyone had any ideas?

    Details

    Google's ability to get my address seems fine as the HTML 5 Geolocation demo works fine in Firefox, which I believe does the same as GFW.

    Using the sensor diagnostic tool the SENSOR_PROPERTY_STATE is No Data. The LatLong has the Data as: Error: No Data with the message: The pipe is being closed. (Exception from HRESULT: 0x800700E8).

    The log from the sensor diagnostic tool is:

    <?xml version="1.0" encoding="utf-8"?>
    <SensorDiagnosticTool version="0.1">
    	<SensorData>
    		<SensorProperties>
    			<SensorProperty name="WPD_OBJECT_ID" value="GS1" />
    			<SensorProperty name="WPD_OBJECT_PERSISTENT_UNIQUE_ID" value="GS1" />
    			<SensorProperty name="WPD_OBJECT_PARENT_ID" value="DEVICE" />
    			<SensorProperty name="WPD_OBJECT_NAME" value="GS1" />
    			<SensorProperty name="WPD_OBJECT_FORMAT" value="30000000-ae6c-4804-98ba-c57b46965fe7" />
    			<SensorProperty name="WPD_OBJECT_CONTENT_TYPE" value="99ed0160-17ff-4c44-9d98-1d7a6f941921" />
    			<SensorProperty name="WPD_OBJECT_CAN_DELETE" value="False" />
    			<SensorProperty name="SENSOR_PROPERTY_TYPE" value="SENSOR_TYPE_LOCATION_GPS" />
    			<SensorProperty name="SENSOR_PROPERTY_STATE" value="No Data" />
    			<SensorProperty name="SENSOR_PROPERTY_MIN_REPORT_INTERVAL" value="0" />
    			<SensorProperty name="SENSOR_PROPERTY_CURRENT_REPORT_INTERVAL" value="0" />
    			<SensorProperty name="SENSOR_PROPERTY_PERSISTENT_UNIQUE_ID" value="acdc57ce-4556-4d4d-a2f5-9fe8b87757ec" />
    			<SensorProperty name="SENSOR_PROPERTY_MANUFACTURER" value="Within Network, LLC" />
    			<SensorProperty name="SENSOR_PROPERTY_MODEL" value="GS1" />
    			<SensorProperty name="SENSOR_PROPERTY_SERIAL_NUMBER" value="GS1" />
    			<SensorProperty name="SENSOR_PROPERTY_FRIENDLY_NAME" value="Geosense Sensor" />
    			<SensorProperty name="SENSOR_PROPERTY_DESCRIPTION" value="Geosense Sensor" />
    			<SensorProperty name="SENSOR_PROPERTY_CONNECTION_TYPE" value="1" />
    			<SensorProperty name="WPD_FUNCTIONAL_OBJECT_CATEGORY" value="Location" />
    			<SensorProperty name="SENSOR_PROPERTY_DEVICE_ID" value="\\?\root#sensor#0000#{ba1bb692-9b7a-4833-9a1e-525ed134e7e2}\{ba1bb692-9b7a-4833-9a1e-525ed134e7e2}" />
    		</SensorProperties>
    		<SensorDataFields>
    			<SensorDataField name="SENSOR_DATA_TYPE_TIMESTAMP" value="-2147024846" />
    			<SensorDataField name="SENSOR_DATA_TYPE_LATITUDE_DEGREES" value="-2147024846" />
    			<SensorDataField name="SENSOR_DATA_TYPE_LONGITUDE_DEGREES" value="-2147024846" />
    			<SensorDataField name="SENSOR_DATA_TYPE_ALTITUDE_SEALEVEL_METERS" value="-2147024846" />
    			<SensorDataField name="SENSOR_DATA_TYPE_ERROR_RADIUS_METERS" value="-2147024846" />
    			<SensorDataField name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 23" value="-2147024846" />
    			<SensorDataField name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 24" value="-2147024846" />
    			<SensorDataField name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 25" value="-2147024846" />
    			<SensorDataField name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 28" value="-2147024846" />
    			<SensorDataField name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 26" value="-2147024846" />
    			<SensorDataField name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 27" value="-2147024846" />
    		</SensorDataFields>
    		<SensorEvents>
    			<SensorEvent data="2010-05-03T23:56:14.4867451+02:00 State Changed event to state NoData" />
    		</SensorEvents>
    		<SensorDataCollection>
    			<DataReport>
    				<Field name="SENSOR_DATA_TYPE_TIMESTAMP" value="-2147024846" />
    				<Field name="SENSOR_DATA_TYPE_LATITUDE_DEGREES" value="-2147024846" />
    				<Field name="SENSOR_DATA_TYPE_LONGITUDE_DEGREES" value="-2147024846" />
    				<Field name="SENSOR_DATA_TYPE_ALTITUDE_SEALEVEL_METERS" value="-2147024846" />
    				<Field name="SENSOR_DATA_TYPE_ERROR_RADIUS_METERS" value="-2147024846" />
    				<Field name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 23" value="-2147024846" />
    				<Field name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 24" value="-2147024846" />
    				<Field name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 25" value="-2147024846" />
    				<Field name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 28" value="-2147024846" />
    				<Field name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 26" value="-2147024846" />
    				<Field name="055c74d8-ca6f-47d6-95c6-1ed3637a0ff4, 27" value="-2147024846" />
    			</DataReport>
    		</SensorDataCollection>
    	</SensorData>
    	<SensorData>
    		<SensorEvents>
    			<SensorEvent data="2010-05-03T23:56:14.4997458+02:00 Status Changed event for location to status Error" />
    		</SensorEvents>
    		<LocationDataCollection>
    			<DataReport type="CivicAddressReport">
    				<Field name="AddressLine1" value="" />
    				<Field name="AddressLine2" value="" />
    				<Field name="City" value="" />
    				<Field name="CountryOrRegion" value="ZA" />
    				<Field name="DetailLevel" value="CountryOrRegion" />
    				<Field name="PostalCode" value="" />
    				<Field name="SensorID" value="682f38ca-5056-4a58-b52e-b516623cf02f" />
    				<Field name="StateOrProvince" value="" />
    				<Field name="Timestamp" value="2010-05-03T21:56:14.4940000" />
    			</DataReport>
    		</LocationDataCollection>
    	</SensorData>
    </SensorDiagnosticTool>

    Robert MacLean - www.sadev.co.za
    Monday, May 3, 2010 9:59 PM

All replies

  • Some more info on this - I tested four scenarios and two work and two don't.

    • Connecting to the internet using tethering on my phone (ISP in this case is MTN) + WiFi is off: Does not work at all. No data can be found.
    • Connecting to the internet using a 3G dongle (ISP in this case is Vodacom)  + WiFi is off: Does not work at all.
    • Plugging into the office network + WiFi is off: Works, but address is wrong - I suspect it is the ISP who owns the IP range's address. Close enough that I am not concerned.
    • While plugged in to office network, turn on wifi: Works and address is very close.

    It seems there is something specific to the wireless/3g providers which do not provide any info or block the info GFW needs. Anyone have any insight on this?


    Robert MacLean - www.sadev.co.za
    Tuesday, May 4, 2010 9:16 AM
  • Looks like this has to do with how the location data is retrieved from the backend depending on what access points or network connections are used. According to the log above, the driver does not have any location data to provide to the platform.

    Have you posted this comment on http://www.istartedsomething.com/20100301/geosense-for-windows-location-released/ to see if the developers have any thoughts ?

    Wednesday, May 5, 2010 12:54 AM
    Moderator
  • Thanks  - I hadn't seen those comments. I am weary of posting on a blogs comments but I did find an email address and have emailed them asking to check this page.
    Robert MacLean - www.sadev.co.za
    Wednesday, May 5, 2010 6:22 AM
  • Hi Robert,

    I wrote the driver.

    First off, I'm curious... where did you download Geosense for Windows from? I find it odd that you missed the feedback links right on the main product page (http://www.geosenseforwindows.com). Too much Scotch? (If you got it from elsewhere, we'd like to know as we don't allow redistribution.)

    Anyway, as Arvind suggested, the driver can't connect to the Google Location Services hub to determine your position.

    To determine if we're connected, we defer to Windows using the InternetGetConnectedState API. This API "caches" your online state for a hard-coded amount of time and has other weird oddities...

    ... so a few questions:

    • What version of Geosense are you using? (add/remove, version column)
    • How long are you waiting after disconnect/reconnect in your testing?
    • Are you "Working Offline" in any applications, like Internet Explorer?
    • Does Geosense start working  on the "non-working" devices after restarting the System Event Notification Service ?
    Wednesday, May 5, 2010 7:01 AM
  • Hi,

    I did get it from the website, I missed the link completely when I looked over the site (could be too much scotch :P).

    The InternetGetConnectedState solves one problem, because the route via cellphone I tried does not flip that bit. Even though there is internet, it is not detected.

    Still doesn't solve the 3G dongle route though which does get detected correctly.

    Answers to questions:

    • 1.2
    • ~30 seconds. I did however try a few with full reboots between them and that didn't change anything.
    • Nope
    • Haven't tried that yet, will try that now and feedback.

    Robert MacLean - www.sadev.co.za
    Wednesday, May 5, 2010 9:31 AM
  • Restarting the service didn't help. I am sure it is something with the connection and not the Geolocation stuff. I wrote a bit of code (below) to check the difference between InternetGetConnectedState when I'm on the network and when I am on 3g.

    Both times it returns true for connected, but I get different flags in the description:

    • Network (working): Value 18, flags: INTERNET_CONNECTION_LAN, INTERNET_CONNECTION_RAS_INSTALLED
    • 3g (not working) Value 81, flags: INTERNET_CONNECTION_MODEM, INTERNET_CONNECTION_RAS_INSTALLED, INTERNET_CONNECTION_CONFIGURED

    Not sure if that could be adding to the issue.

    class Program
      {
        [DllImport("wininet.dll")]
        private extern static bool InternetGetConnectedState(out InternetGetConnectedStateFlags Description, int ReservedValue);
    
        static void Main(string[] args)
        {
          InternetGetConnectedStateFlags Description;
          Console.WriteLine(InternetGetConnectedState(out Description, 0));
          Console.WriteLine(Description);
        }
      }
    
      [Flags]
      enum InternetGetConnectedStateFlags
      {
        INTERNET_CONNECTION_MODEM = 0x01,
        INTERNET_CONNECTION_LAN = 0x02,
        INTERNET_CONNECTION_PROXY = 0x04,
        INTERNET_CONNECTION_RAS_INSTALLED = 0x10,
        INTERNET_CONNECTION_OFFLINE = 0x20,
        INTERNET_CONNECTION_CONFIGURED = 0x40
      }

    Robert MacLean - www.sadev.co.za
    Wednesday, May 5, 2010 10:42 AM
  • Does the API return FALSE when connected via 3G, despite the fact you can access the Internet? Perhaps we should add more code to the driver, utilizing InternetCheckConnection.
    Wednesday, May 5, 2010 2:24 PM
  • Nope it is returning true when connected via 3G - just the description out parameter is different compared to when on the network.
    Robert MacLean - www.sadev.co.za
    Wednesday, May 5, 2010 2:53 PM
  • Welcome to Sensor API beta testing ;)

     

    Rafael: The only sure way to check if you are connected is to actually try the connection. If it works, you are connected. If it fails, you are not.

     


    Michael
    Tuesday, May 18, 2010 8:03 PM
  • Some feedback - I tried this in Durban (about 500km from where I stay/work) and it worked fine. I am guessing it is something on the cellular networks in Jo'burg that is interferring with GeoSense's identification of being online and/or GeoSense's ability to speak to Google.


    Robert MacLean - www.sadev.co.za
    Wednesday, May 19, 2010 9:09 AM
  • Hi Robert, Thank you for this post, after a lot of struggle I have the exact same problem. Also on 3g and also in Johannesburg. Any solution on how to resolve this issue?

     

    Thanks

     

    Morne

    Monday, February 6, 2012 5:43 PM
  • 2 years later, wow.

    Hey Morne, sorry about the trouble. Due to renewed interest in Geosense for Windows, I'm actually working on a new version that should resolve some long standing issues. I can't promise an actual release date, but keep an eye on http://geosenseforwindows.com.

    Monday, February 6, 2012 6:12 PM
  • I have used GeoSense now for a bunch of talks both in Joburg, Durban & Cape Town and in now days it just works both on MTN & Vodacom. It is pretty damn slow the first time you use it, so what I do with it is have a small console app that I start before my talk which goes out and starts to request the data, by the time I get to the demo for Geosense it works almost instantly.

    I have found that firewalls, in particular Squid with basic authentication, cause huge headaches and also to have WiFi on, regardless if you are using it or not (in fact best case is to have 3g & wifi on and be connected to 3g)


    Robert MacLean - www.sadev.co.za

    Tuesday, February 7, 2012 5:13 AM
  • Rafael, I haven't tested but does GFW work with Windows 8 or is that on the list of issues?

    Robert MacLean - www.sadev.co.za

    Tuesday, February 7, 2012 5:14 AM
  • Haven't tried it yet. But we'd have to test that, yep.
    Tuesday, February 7, 2012 5:15 AM