Skip to content

Radar Filter

Using cna.radarfilter.* enables to modify the filer settings for radar tracks (requires option RAD). The following settings are available, whereas all variable can be read or written, provided the opposite is not stated below. In case an option is not set with doXXX, the respective values XXX are not evaluated (e.g. without doFilterDate the setting filterDateStart has no effect).

  • isActive (de-)activates the entire filter. With the filter deactivated the listed options have no effect.
  • doFilterDate (de-)activates the date filtering, and: filterDateStart enables access to the start date, filterDateEnd to the end date, while the data type is a string using format "DD.MM.YYYY". Only read access is possible for filterDateStartYear, filterDateStartMonth, filterDateStartDay, filterDateEndYear, filterDateEndMonth andfilterDateEndDay.
  • doFilterMonth (de-)activates the month filtering, filterMonth can be used to toggle single months on/off. This makes use of a bit-field where the i-th bit represents the i-th month. Explanation of the bit-field see below.
  • doFilterWeekday (de-)activates the filter for days of the week, filterWeekday is again a bit-field, toggling single days on/off.
  • doFilterHour (de-)activates the hour filtering, filterHour is a bit-field toggling single hours on/off. (The hour 0 reaches from midnight to 1:00 o‘clock.).
  • doFilterType (de-)activates the filter for approaches or departures only, filterType 0 is for departures, 1 for approaches
  • doFilterRunway (de-)activates the filter for runways, filterRunway returns the runway‘s name as a string (e.g. "07R").
  • doFilterAircraftType (de-)activates the filter for aircraft classes, filterAircraftType returns the ID of aircraft class
  • doFilterRoute (de-)activates the filter for air routes, filterRoute returns the routes‘ name as a string.
  • doFilterCondition (de-)activates the filter using a Regular Expression (see Table-Object), filterCondition returns the expression

Explanation Bit-Field

The data type for a bit field is an integer value, where each bit in binary code represents a state on or off for an entry in a list (array). The binary of the number 6 is 110, so the state for index 0 is „off“, and „on“ for indexes 1 and 2. For example, using filterWeekday, this means that only Tuesday and Wednesday are selected.

Manipulation of bit-fields is covered by the LUA library "bit" (see http://bitop.luajit.org), see this examples for weekly days:

-- activate all days, note one based indices must be decremented by one to address the correct bit!
for i=1, 7, 1 do
bitfield = bit.bor(bitfield, bit.lshift(1,(i-1))) -- bitfield | (1 << (i-1))
end

Test:

assert(bitfield == 127) -- expected value of bitfield is 127 = 2^8 - 1

Table 1: Identifiers for accessing table objects cna.tables

German identifier English identifier English identifier long Comments
Bplan bpl -
FQ ar_src area_source
FV vert_ar_src vertical_area_source
Kreuzung cross crossing
LQ li_src line_source
PPL p_lot parking_lot
PQ pt_src point_source
Richtw dir directivity
Schiene track -
Strasse road -
Tennis tennis -
Imm imm receiver
Screen3d scrn_3d screen_3d
Bebauung built_up_ar built_up_area
Bewuchs foliage -
Bodenabs grnd_abs ground_absorption
Bruecke bridge -
Bruchkante li_fault line_of_fault
Hoehenlinie li_cont contour_line
Hoehenpunkt h_pt height_point
Haus building -
Hausbeurt bld_eval building_evaluation
Schirm scrn screen
Wall emb embankment
Zyl cyl cylinder
Ausschnitt range -
Bitmap bmp bitmap
Div div auxiliary_polygon
Nutz ar_lnd area_of_land_use
Pegelrahmen level_box -
Textrahmen text_box -
Rgeb ar_calc calculation_area
Symb symb symbol
LibAlf lib_alf lib_absorptions Absorption Library
LibL lib_l lib_soundlevels Sound Levels Library
LibR lib_r lib_reductionindices Reductions Library
Aircraft aircraft -
Flugplatz airport -
Flugstrecke air_route -
Textbaustein text_block - local text blocks only
Stationierung km stationing Station
LibStrtyp roadtype road_type Road Type
Radar radar radar_track Radar-Track