diff --git a/bin/com/ameliaWx/soundingViewer/unixTool/RadiosondeWrapper.class b/bin/com/ameliaWx/soundingViewer/unixTool/RadiosondeWrapper.class index 1beb967..b19b8c7 100644 Binary files a/bin/com/ameliaWx/soundingViewer/unixTool/RadiosondeWrapper.class and b/bin/com/ameliaWx/soundingViewer/unixTool/RadiosondeWrapper.class differ diff --git a/bin/com/ameliaWx/soundingViewer/unixTool/nwp/ModelDerived.class b/bin/com/ameliaWx/soundingViewer/unixTool/nwp/ModelDerived.class index 9e09b38..53adbb9 100644 Binary files a/bin/com/ameliaWx/soundingViewer/unixTool/nwp/ModelDerived.class and b/bin/com/ameliaWx/soundingViewer/unixTool/nwp/ModelDerived.class differ diff --git a/src/com/ameliaWx/soundingViewer/unixTool/RadiosondeWrapper.java b/src/com/ameliaWx/soundingViewer/unixTool/RadiosondeWrapper.java index 01abbf5..0990d13 100644 --- a/src/com/ameliaWx/soundingViewer/unixTool/RadiosondeWrapper.java +++ b/src/com/ameliaWx/soundingViewer/unixTool/RadiosondeWrapper.java @@ -112,8 +112,16 @@ private static void doGuiCurrHist(int currHistOption) { if (site.getFourLetterCode().length() > 0) { RadiosondeWrapper.displayCurrentSounding(site); } else { + JFrame init = new JFrame("Getting GFS data, this may take a few seconds..."); + init.setSize(500, 0); + init.setLocationRelativeTo(null); + init.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE); + init.setVisible(true); + Sounding gfs = ModelDerived.getGfsSounding(site.getLatitude(), site.getLongitude()); + init.dispose(); + new SoundingFrame(site.locationString() + " GFS-Derived", gfs, DateTime.now(DateTimeZone.UTC), 33, -96.5); diff --git a/src/com/ameliaWx/soundingViewer/unixTool/nwp/ModelDerived.java b/src/com/ameliaWx/soundingViewer/unixTool/nwp/ModelDerived.java index 088b805..1670e98 100644 --- a/src/com/ameliaWx/soundingViewer/unixTool/nwp/ModelDerived.java +++ b/src/com/ameliaWx/soundingViewer/unixTool/nwp/ModelDerived.java @@ -45,13 +45,21 @@ public static Sounding getGfsSounding(double lat, double lon) { System.out.println("after aligning: " + now); Sounding gfsSounding = null; - while(true) { + for(int i = 0; i < 3; i++) { try { gfsSounding = getGfsSounding(lat, lon, now, 0); break; } catch (IOException e) { System.err.println("GFS not found for " + now + ", rolling back 6 hours"); now = now.minusHours(6); + + try { + Thread.sleep(3000); + } catch (InterruptedException e1) { + // TODO Auto-generated catch block + e1.printStackTrace(); + } + continue; } }