Skip to content

Commit

Permalink
Add support for NOAA-21 (and NOAA-22 yet not launched though)
Browse files Browse the repository at this point in the history
Signed-off-by: Adam.Dybbroe <[email protected]>
  • Loading branch information
Adam.Dybbroe committed Aug 21, 2023
1 parent 4c1b45a commit f7f55df
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 7 deletions.
12 changes: 9 additions & 3 deletions trollsched/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-

# Copyright (c) 2014 - 2019 PyTroll Community
# Copyright (c) 2014 - 2023 PyTroll Community

# Author(s):

Expand Down Expand Up @@ -31,8 +31,10 @@
# shortest allowed pass in minutes
MIN_PASS = 4

# DRL still use the name JPSS-1 in the TLEs:
NOAA20_NAME = {'NOAA-20': 'JPSS-1'}
# DRL still use the name JPSS-1 (etc) instead of NOAA-20 in the TLEs:
JPSS_TLE_NAMES = {'NOAA-20': 'JPSS-1',
'NOAA-21': 'JPSS-2',
'NOAA-22': 'JPSS-3'}

NUMBER_OF_FOVS = {
'avhrr': 2048,
Expand All @@ -56,12 +58,16 @@
'metopb': 'Metop-B',
'metopa': 'Metop-A',
'noaa20': 'NOAA-20',
'noaa21': 'NOAA-21',
'noaa22': 'NOAA-22',
'fengyun3d': 'FY-3D',
'fengyun3c': 'FY-3C'
}

INSTRUMENT = {'Suomi NPP': 'viirs',
'NOAA-20': 'viirs',
'NOAA-21': 'viirs',
'NOAA-22': 'viirs',
'Aqua': 'modis',
'Terra': 'modis',
'NOAA 19': 'avhrr',
Expand Down
8 changes: 4 additions & 4 deletions trollsched/satpass.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/env python
# -*- coding: utf-8 -*-

# Copyright (c) 2014 - 2019 PyTroll Community
# Copyright (c) 2014 - 2019, 2023 PyTroll Community
# Author(s):

# Martin Raspaud <[email protected]>
Expand Down Expand Up @@ -38,7 +38,7 @@
from pyorbital import orbital, tlefile
from pyresample.boundary import AreaDefBoundary

from trollsched import MIN_PASS, NOAA20_NAME, NUMBER_OF_FOVS
from trollsched import MIN_PASS, JPSS_TLE_NAMES, NUMBER_OF_FOVS
from trollsched.boundary import SwathBoundary

logger = logging.getLogger(__name__)
Expand Down Expand Up @@ -184,11 +184,11 @@ def __init__(self, satellite, risetime, falltime, **kwargs):
except KeyError as err:
logger.debug("Failed in PyOrbital: %s", str(err))
self.orb = orbital.Orbital(
NOAA20_NAME.get(satellite, satellite),
JPSS_TLE_NAMES.get(satellite, satellite),
line1=tle1,
line2=tle2)
logger.info("Using satellite name %s instead",
str(NOAA20_NAME.get(satellite, satellite)))
str(JPSS_TLE_NAMES.get(satellite, satellite)))

self._boundary = None

Expand Down

0 comments on commit f7f55df

Please sign in to comment.