Author Topic: Survey ft vs Intl ft  (Read 10707 times)

0 Members and 1 Guest are viewing this topic.

cadtag

  • Swamp Rat
  • Posts: 1152
Survey ft vs Intl ft
« on: December 14, 2011, 10:51:38 AM »
I'm not sure if this belongs here, or under the LISP forums.

Basically I'm wondering if the c3d setting for US Survey ft vs International ft is accessible through LISP.  I'm wondering if it's possible to run a routine in acaddoc.lsp that would flash a warning if the drwing being opened was set to Intl feet.

Anyone know? 
The only thing more dangerous to the liberty of a free people than big government is big business

Jeff_M

  • King Gator
  • Posts: 4096
  • C3D user & customizer
Re: Survey ft vs Intl ft
« Reply #1 on: December 14, 2011, 04:53:29 PM »
Yes, you can get this information with vlisp.
Code: [Select]
  (setq prod (vlax-product-key))
  (setq prodStr (strcat "AeccXUiLand.AeccApplication"
(cond ((vl-string-search "\\R17.0\\" prod)
       ".4.0");;2007
      ((vl-string-search "\\R17.1\\" prod)
       ".5.0");;2008
      ((vl-string-search "\\R17.2\\" prod)
       ".6.0");;2009
      ((vl-string-search "\\R18.0\\" prod)
       ".7.0");;2010
      ((vl-string-search "\\R18.1\\" prod)
       ".8.0");;2011
      ((vl-string-search "\\R18.2\\" prod)
       ".9.0");;2012
      (t ""))))
           (setq *acad* (vlax-get-acad-object))
   (setq C3D (vla-getinterfaceobject *acad* prodStr))
   (setq C3Ddoc (vla-get-activedocument C3D))

      (setq C3Dsets (vlax-get-property C3Ddoc 'Settings))
      (setq docSets (vlax-get-property C3Dsets 'Drawingsettings))
      (setq unitsandzone (vlax-get-property docsets 'unitzonesettings))
      (setq footflag (vlax-get-property unitsandzone 'foottometerconversionflag))
      ;; international foot = 1, US Survey foot = 2

BlackBox

  • King Gator
  • Posts: 3770
Re: Survey ft vs Intl ft
« Reply #2 on: December 14, 2011, 07:24:32 PM »
FWIW - 

Referenceing the AeccDbMgd.dll into a .NET solution for Civil 3D, will make accessible the Autodesk.Civil.Settings Namespace, which provides access to the Public Enum ImperialToMetricConversionType, and resultant InternationalFoot, and UsSurveyFoot Constants.

A (simple?) LispFunction Method will offer better performance than that of accessing the AeccXUiLand.AeccApplication's Interface Object via ACADDOC.lsp, and can still be called from your LISP application(s). I would code said LispFunction Method such that it may be called with no arguments, and return T or Nil... Pseudo code:

Code - Auto/Visual Lisp: [Select]
  1. (prompt "\n** ")
  2. (if (UsFoot-p)
  3.         "US FOOT ** "
  4.         "INTERNATIONAL FOOT ** "
  5.         )
"How we think determines what we do, and what we do determines what we get."

Jeff_M

  • King Gator
  • Posts: 4096
  • C3D user & customizer
Re: Survey ft vs Intl ft
« Reply #3 on: December 14, 2011, 07:51:47 PM »
RenderMan, I'd be curious to see the performance difference between the straight lisp vs combined lisp/.NET dll and (how I would do this if I needed such a thing) a pure .NET solution (look ma, no lisp! :-) ). For something such as this, I suspect it will be negligible. And for the user who asked about a lisp solution, I didn't see a need to bring up .NET since they probably aren't familiar with it anyway.

Here's a quick test lisp that takes almost no time to run (I couldn't find my old benchmark lisp to give any hard numbers).
Code: [Select]

(defun c:getflag (/ *ACAD* C3D C3DDOC C3DSETS DOCSETS FOOTFLAG PROD PRODSTR UNITSANDZONE)
  (vl-load-com)
  (setq prod (vlax-product-key))
  (setq prodStr (strcat "AeccXUiLand.AeccApplication"
(cond ((vl-string-search "\\R17.0\\" prod)
       ".4.0");;2007
      ((vl-string-search "\\R17.1\\" prod)
       ".5.0");;2008
      ((vl-string-search "\\R17.2\\" prod)
       ".6.0");;2009
      ((vl-string-search "\\R18.0\\" prod)
       ".7.0");;2010
      ((vl-string-search "\\R18.1\\" prod)
       ".8.0");;2011
      ((vl-string-search "\\R18.2\\" prod)
       ".9.0");;2012
      (t ""))))
     
  (if (and (setq *acad* (vlax-get-acad-object))
   (setq C3D (vla-getinterfaceobject *acad* prodStr))
   (setq C3Ddoc (vla-get-activedocument C3D))
   )
    (progn
      (setq C3Dsets (vlax-get-property C3Ddoc 'Settings))
      (setq docSets (vlax-get-property C3Dsets 'Drawingsettings))
      (setq unitsandzone (vlax-get-property docsets 'unitzonesettings))
      (setq footflag (vlax-get-property unitsandzone 'foottometerconversionflag))
      ;; international foot = 1, US Survey foot = 2
      (princ (strcat "This drawing is set to use the "
     (if (= footflag 1)
       "International foot"
       "US Survey foot"
       )
     " option."))
      )
    (vlax-release-object C3D)
    )
  (princ)
  )

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Survey ft vs Intl ft
« Reply #4 on: December 14, 2011, 08:51:43 PM »
I'm not sure if this belongs here, or under the LISP forums.

Basically I'm wondering if the c3d setting for US Survey ft vs International ft is accessible through LISP.  I'm wondering if it's possible to run a routine in acaddoc.lsp that would flash a warning if the drwing being opened was set to Intl feet.

Anyone know?
I'm wonderng why it would matter?
Given that the file was started in one unit or the other, what difference would it make, if you kept working in that same unit?
Be your Best


Michael Farrell
http://primeservicesglobal.com/

BlackBox

  • King Gator
  • Posts: 3770
Re: Survey ft vs Intl ft
« Reply #5 on: December 14, 2011, 09:58:13 PM »
Jeff,

First to your point of potential or lack of performance difference... I failed to consider the difference between the internal database of Civil 3D as compared to the external database of Land Desktop. In the latter case, I've personally experienced the performance lag, albeit on a previous 32-Bit system. Now I have a Win7, 64-Bit combined with the internal database of Civil 3D.

I happen to know Cadtag outside of the forums, so I know a bit more of his situation.

As for my LispFunction suggestion to begin with; I'm a LISP-er who's relatively new to .NET development. :p
"How we think determines what we do, and what we do determines what we get."

cadtag

  • Swamp Rat
  • Posts: 1152
Re: Survey ft vs Intl ft
« Reply #6 on: December 15, 2011, 10:57:00 AM »
]I'm wonderng why it would matter?
Given that the file was started in one unit or the other, what difference would it make, if you kept working in that same unit?

Will it matter?  generally not for work we've started, but most of my survey material is coming in from outside vendors/subs.  It would be nice to know if they've done something different than was expected.
The only thing more dangerous to the liberty of a free people than big government is big business

RANDOMXS

  • Guest
Re: Survey ft vs Intl ft
« Reply #7 on: December 29, 2011, 08:00:49 PM »
'Will it matter?  '

How big is your project and what is your desired precision?

999,998 US Survey feet = 304,800 Meters
1,000,000 International ft = 304,800 Meters
or 2 parts per million.

1,000,000 ft = 189+ miles.

caddcop

  • Guest
Re: Survey ft vs Intl ft
« Reply #8 on: December 29, 2011, 11:14:16 PM »
For example, the state of Maryland is not one of the larger states. The origin of its Nad83 coordinate system is somewhere down in West Virginia.
By the time you get near the top, right corner, where PA and DE come together, the difference can be somewhere near 40'. So the size of the project is not the issue - its the size of your coordinate system.

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Survey ft vs Intl ft
« Reply #9 on: December 30, 2011, 08:47:01 AM »
I think the last two posters misunderstood my question.

Quote
]I'm wondering why it would matter?
Given that the file was started in one unit or the other, what difference would it make, if you kept working in that same unit?

Taken out of context it would appear that I'm not aware of the difference in units of measure.
Placed back in context of my statement, it will not matter given that the drawing is set up on the right units from the start.
Be your Best


Michael Farrell
http://primeservicesglobal.com/

caddcop

  • Guest
Re: Survey ft vs Intl ft
« Reply #10 on: December 30, 2011, 03:41:20 PM »
As long as all files used with the project are also setup similarly, it should not. But when was the last time you had 100% control of all files used on a project.
In the Civil world, files need datums and units to ensure that multiple files line up correctly.

Dent Cermak

  • Guest
Re: Survey ft vs Intl ft
« Reply #11 on: January 19, 2012, 10:58:27 PM »
'Will it matter?  '

How big is your project and what is your desired precision?

999,998 US Survey feet = 304,800 Meters
1,000,000 International ft = 304,800 Meters
or 2 parts per million.

1,000,000 ft = 189+ miles.




While in one respect you are correct, surveyors using EDM’s can not measure a distance to a precision of 2ppm (or 0.002′ in 1000.00′), but that is not the issue. The REAL issue is when this 2ppm is applied to State Plane coordinates in the N2,000,000 and E6,000,000 range! This 2ppm literally moves a State Plane coordinate position 4 feet by 12 feet, using the coordinate values listed.

With more and more projects being based on State Plane coordinates, this issue is going to be more and more prevalent. Working on projects in many States, we are well aware of the problems presented when users mix Survey Foot and International Foot units. In nearly all cases it is simply user awareness, or a project that has not been setup correctly.

Imagine you complete a design in rural California, using State Plane coordinates based on International Foot units, which is subsequently passed on to a surveyor for staking. Surveyors are aware that California uses Survey Foot units.

Many survey software packages convert Foot units on the fly. Then imagine (or have a nightmare!) that your design is being constructed 4′ x 12′ out of position! You would quickly come to the realization that 2ppm matters!

In our practice, this is a HUGE issue, and I would find it hard to believe it has not affected others similarly. This topic is hot enough that, in my opinion, it deserves clarification.

mjfarrell

  • Seagull
  • Posts: 14444
  • Every Student their own Lesson
Re: Survey ft vs Intl ft
« Reply #12 on: January 21, 2012, 08:28:14 AM »
I am aware of the resulting positional error(s).
As stated earlier, my question about would it matter is considering that the file
or files were originally setup on whatever unit of measure the job was supposed to be conducted in there would be no issue.

Do I always have full control of the drawings?  No
Can I take a look at the drawing settings and verify the units and zone are set correctly in my file(s)?  Yes

Can I create and name templates that are named in a manner that allows users to easily select the correct template for the work at hand?  Yes

Do I know the difference between a Link, and a Rood?  Yes.

Be your Best


Michael Farrell
http://primeservicesglobal.com/

Dent Cermak

  • Guest
Re: Survey ft vs Intl ft
« Reply #13 on: January 21, 2012, 05:46:58 PM »
Such a positional error would make it very difficult to place the design on the ground if one was unaware of the error. Not being a surveyor, you are probably unaware that most state boards require the use og the US Foot on all work. All it takes is for one person to be on the wrong system to cause MAJOR problems. Especially when working on projects that have zero lot line setbacks.
This is generally a survey issue. Most Architects and Engineers do not understand the differances nor do they care. Design tolerances in architecture and general engineering, when it comes to positional tolerance, are no where near as tight as those the Surveyor is held to by state regulations.

Do I know the difference between a Link, and a Rood?  Yes.


Rood??  I know of links,inches, feet, yards, rods, miles, varas, chains, acres, hectares, poles, leagues, labors and perches, but "Rood" is a new one to me?
« Last Edit: January 21, 2012, 05:54:35 PM by Dent Cermak »

BlackBox

  • King Gator
  • Posts: 3770
Re: Survey ft vs Intl ft
« Reply #14 on: January 21, 2012, 06:41:22 PM »
Do I know the difference between a Link, and a Rood?  Yes.


Rood??  I know of links,inches, feet, yards, rods, miles, varas, chains, acres, hectares, poles, leagues, labors and perches, but "Rood" is a new one to me?

For completeness: Rood
"How we think determines what we do, and what we do determines what we get."