Civil3D : FEMA Floodplain and EPA Watershed Dynamo Scripts

 Civil3D : FEMA Floodplain and EPA Watershed Dynamo Scripts

Written by Andy Carter,PE | December 29, 2020



Download the Script

Download the Civil3D Dynamo scripts from my GitHub repository. 

https://github.com/andycarter-pe/Civil3D_WebService_Dynamo/archive/main.zip




Video Walkthrough (3 minutes)





Web Services for Drainage

There are several federal web services that are currently providing geospatial data that is essential for your design projects.  As a civil engineer that specializes in hydrologic and hydraulic design, I need to know the watershed delineation for the site  as well as the limits of the FEMA regulated floodplains.

For watershed delineations, the EPA WATER's service (Watershed Assessment, Tracking & Environmental Results System) provides for the request and delivery of pre-calculated watersheds and stream centerlines for the continental United States.


When you need FEMA floodplain limits on and adjacent to your subject site, most folks these days use FEMA's National Flood Hazard Layer (NFHL).  Typically, this is ingested through an image overlay map service that is used in either Google Earth, ArcGIS Pro or QGIS.



Dynamo: Getting AutoCAD Linework

I have created a couple of Dynamo scripts that makes a web request to these federal servers to get the needed AutoCAD linework for your drawing.  Here is a rough breakdown of what is going on:

  1.  User sets up a Civil3D drawing in the desired Coordinate Reference System (CRS)
  2.  User draws and selects ACAD item for spatial input
  3.  Dynamo converts items coordinates to Latitude/Longitude
  4.  Dynamo builds a URL to request the data from the REST endpoint as JSON
    1. Example  https://hazards.fema.gov/gis/nfhl/rest/services/public/NFHL/MapServer/27/query?&geometry=-97.786,30.352,-97.782,30.356&f=pjson
    2. Example  https://ofmpub.epa.gov/waters10/NavigationDelineation.Service?pNavigationType=UT&pStartComid=5781811&pOutputFlag=BOTH&pAggregationFlag=TRUE
  5.  JSON data is parsed with Dynamo to get linework
  6.  Lat/Long coordinates converted to local CRS 
  7.  Linework drawn inside AutoCAD / Civil3D

Stop (Collaborate and Listen)!

Prior to even thinking about using this script, you will need to install the Civil3DToolkit package for Dynamo.  This package is provided by Autodesk and provides functionality necessary for my scripts to work.



Download the Script

Download the Civil3D Dynamo scripts from my GitHub repository. 

https://github.com/andycarter-pe/Civil3D_WebService_Dynamo/archive/main.zip









Some Warnings

The scripts are "as is" and are provided without warranty of any kind.  You can modify any script but, if you do, know that you are required to provide me proper credit.

Please comment below if you have questions or issues.  While I can't provide support, I would like to know what issues y'all are seeing.