Skip to content

Loading…

Allow user to specify their location for local radio #4

Open
kingosticks opened this Issue · 2 comments

2 participants

@kingosticks
Owner

Add a config setting to specify the location to use for "local" radio. TuneIn supports a latlon parameter containing a comma separated latitude-longitude pair i.e. http://opml.radiotime.com/Browse.ashx?c=local&latlon=37,118.

@kingosticks kingosticks self-assigned this
@kingosticks
Owner

The config parameter could take a location name and we can look up the latitude/longitude using https://developers.google.com/maps/documentation/geocoding/?csw=1#GeocodingRequests.
i.e. http://maps.googleapis.com/maps/api/geocode/json?address=London,uk&sensor=false gives

{
   "results" : [
      {
         "address_components" : [
            {
               "long_name" : "London",
               "short_name" : "London",
               "types" : [ "locality", "political" ]
            },
            {
               "long_name" : "United Kingdom",
               "short_name" : "GB",
               "types" : [ "country", "political" ]
            }
         ],
         "formatted_address" : "London, UK",
         "geometry" : {
            "bounds" : {
               "northeast" : {
                  "lat" : 51.6723432,
                  "lng" : 0.148271
               },
               "southwest" : {
                  "lat" : 51.38494009999999,
                  "lng" : -0.3514683
               }
            },
            "location" : {
               "lat" : 51.508515,
               "lng" : -0.1254872
            },
            "location_type" : "APPROXIMATE",
            "viewport" : {
               "northeast" : {
                  "lat" : 51.6723432,
                  "lng" : 0.148271
               },
               "southwest" : {
                  "lat" : 51.38494009999999,
                  "lng" : -0.3514683
               }
            }
         },
         "types" : [ "locality", "political" ]
      }
   ],
   "status" : "OK"
}
@kingosticks kingosticks added this to the v0.2 - Customisation milestone
@kingosticks kingosticks removed their assignment
@yonailo

I am running the latest version of the plugin, but my local radio entry is empty, do you know why ? how can I fix it ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.