Count airplane pro receiver by click event google maps

Are you having problems with using or developing a plugin? Let me know here.
Post Reply
provedance
Posts: 6
Joined: Tue Feb 02, 2016 7:45 pm

Count airplane pro receiver by click event google maps

Post by provedance » Tue Feb 02, 2016 7:54 pm

Hi, i am working on custom content for me and some friends receivers.
i made locations markers.circles for the different receivers.
They have an click event with some static (string) details about location receiver , antenna used, antenna height , etcetera.
Is it possible to count aircraft which each receiver see's to put it as content to an click showinfo event?
Can it be done by only using google maps API or do i need to use the virtual radar api too.



Regards
Pascal

agw
Posts: 2248
Joined: Fri Feb 17, 2012 3:20 am

Re: Count airplane pro receiver by click event google maps

Post by agw » Tue Feb 02, 2016 10:34 pm

The easiest way is probably to ask for the receiver's aircraft list and then count the number of aircraft that come back for it. Note that if the receiver is marked as merge only or hidden then you won't be able to get an aircraft list for it.

You will need to know the numeric identifier for the receiver. You can get a list of all visible receivers by fetching ServerConfiguration.json:

http://www.virtualradarserver.co.uk/Doc ... ation.aspx

The specification for the aircraft list call is here:

http://www.virtualradarserver.co.uk/Doc ... tList.aspx

You can probably just get away with the basic call, e.g. for a receiver whose ID is 7:

http://127.0.0.1/VirtualRadar/AircraftList.json?feed=7

Then either report the totalAC figure or acList.length (totalAC is unaffected by filters, acList only contains aircraft that passed the filter - if you don't ask for a filter then they should be the same value).

provedance
Posts: 6
Joined: Tue Feb 02, 2016 7:45 pm

Re: Count airplane pro receiver by click event google maps

Post by provedance » Wed Feb 03, 2016 9:50 am

Thanks ! just the answers i need !
:D

Post Reply