code: public static String get2BitCrid(String str) {
           if (str != null) {
               String crid = LookupCodes.lookupCode("CRID", str, "DSSAT");
               if (crid.equals(str) && crid.length() > 2) {
                   crid = def2BitVal;
               }
              return crid.toUpperCase();
          } else {
              return def2BitVal;
          }
  //        if (str == null) {
  //            return def2BitVal;
  //        } else if (str.length() == 2) {
  //            return str;
  //        }
  //        String ret = crids.get(str);
  //        if (ret == null || ret.equals("")) {
  //            return str;
  //        } else {
  //            return ret;
  //        }
      }
docs: get 2-bit version of crop id by given string
  
  @param str input string of 3-bit crid
  @return 2-bit version of crop id