Re: icad.unt

#16
Thank very much. I think we area closer to the solution, but not yet.
I applied your suggestions, and this is the result: The solution works adding my path to the beginning of the support paths, but only, if I delete the original icad.unt form the CMS IntelliCAD folder.
So, still need manual (or human) intervention.
You can make a test doing the following:
  • Make a copy of your original icad.unt
  • Paste the file in to your personal folder
  • Open the new file and add this (2) lines at the end of the file:
*sqmile
=2589988.110336 meter^2
  • open CMS IntelliCAD and add your folder at the beginning of the list as you suggested.
  • Close and open CMS IntelliCAD and do this test:
  • copy/paste the following instruction to the command line and hit the enter key.
(cvunit 500 "acre" "sqmile")

if 0.781250 shows, is working.
if not, rename the original icad.unt to icad.unt.org located in the CMS IntelliCAD folder, and try again.

Re: icad.unt

#17
I've spent a little while this morning trying a few things, nothing has worked.

No matter what the CMS folder is the primary search folder for Icad.unt file.

In the help file it refers to CVUNIT as a lsp file,.
So my thoughts turned to finding this file, could you make a duplicate & rename? nothing on my PC.
Next up was Google, however google failed to find a copy on the internet.

Maybe write a lsp to piggyback CVUNIT, adding in your conversion??
I've run out of ideas atm.
CMS INTELLICAD 12.1.243.153262.PE+.VC16.x64.CMS121

i9-12900k / 64gb-3200 - NVIDIA GeForce TRX 3060 Ti 8Gb Windows 11 Pro
www.stylemarkdesigns.co.uk

Re: icad.unt

#18
Add here too :
ScreenShot_20240418114824.jpeg
ScreenShot_20240418114824.jpeg (74.52 KiB) Viewed 214 times
Verify below in read only :
ScreenShot_20240418115001.jpeg
ScreenShot_20240418115001.jpeg (84.88 KiB) Viewed 214 times
Patrick Depoix
Architecte D.P.L.G. & Historien-chercheur en histoire de l'Architecture

Re: icad.unt

#20
Yes I have it in my app folder.

I mean for his problem he must install his lisp folder in a script folder in my CMS documents like that (no right to write here ! ) :
ScreenShot_20240418141630.jpeg
ScreenShot_20240418141630.jpeg (51.3 KiB) Viewed 202 times

Code: Select all

; Fundamental units are defined in terms of five fundamental physical
; constants, expressed in AI units.  From the CRC Handbook,
; pp. F189-F190:
;
;   c : The vacuum speed of light
;         2.9979250E+08 m/sec
;
;   e : Electron charge
;         1.6021917E-19 C (coulombs)
;
;   h : The Planck Constant
;         6.626196E-34  kg-m^2/sec
;
;   k : The Boltzmann Constant
;         1.380622E-23 kg-m^2/sec^2-K (K=degrees kelvin)
;
;   m : Electron rest mass (kg)
;         9.109558E-31 kg
;
; A line defining a unit in fundamental form has the form
;
;   x1,x2,x3,x4,x5,f,a
;
; The "x" terms are (integer) exponents of the five fundamental
; constants; "f" is a factor; "a" is an additive term (used only in
; temperature).  They define a value as follows (where ^ denotes
; exponentiation and * multiplication):  If we have U of the units
; being defined, the AI equivalent is
;
;   (c^x1 * e^x2 * h^x3 * k^x4 * m^x5) * (U*f + a)
;
; Notice that the factor composed of the fundamental constants defines
; a "fundamental unit" that is some multiple of the corresponding
; AI unit.  If we have U of the units we're defining, we therefore
; have U*f+a "fundamental units".  To convert this to some other unit,
; we seek U', where U'*f'+a' = U*f+a, or
;
;   U' = (U*f+a-a')/f'
;
; For all but temperature, a and a' are zero reducing this to
;
;   U' = U*f/f'
;
; Because of the way we're combining the fundamental constants to
; produce a specific type of unit via dimensional analysis (length,
; mass, speed, etc.), all fundamental definitions of the same type have
; the same set of exponents (x1-x5).  Here are the formats of some of
; the basic types (along with their "fundamental units" in AI units,
; using the CRC values):
Patrick Depoix
Architecte D.P.L.G. & Historien-chercheur en histoire de l'Architecture

Re: icad.unt

#21
InGeomatics wrote:
Wed Apr 17, 2024 2:17 pm
  • Make a copy of your original icad.unt
  • Paste the file in to your personal folder
  • Open the new file and add this (2) lines at the end of the file:
*sqmile
=2589988.110336 meter^2
Developper help files:
"The units of measurement are found in the icad.unt file.
For more information on customizing this file, see Chapter 17, “Customizing IntelliCAD,” in the IntelliCAD User Guide."
These words make reference to create lisp file to customized IntelliCAD:
if you need :
(cvunit 500 "acre" "sqmile")
you must change your code to :
(Dvptools_unit 500 "acre" "sqmile")
with a new lisp function "Dvptools_unit" !

because it's difficult to overwrite cvunit of IntelliCAD in lisp:
https://emacs.stackexchange.com/questio ... l-function

or
You can make that: add your conversion to the ICAD.unt with your LISP code , may be, if IntelliCAD gives you the right :
(setq n (open "C:\\Program Files\\CMS\\CMS IntelliCAD 12.1 Premium Edition Plus\\ICAD.unt" "a")
(append n '(*sqmile \n =2589988.110336 meter^2F)) )
and then call :
(cvunit 500 "acre" "sqmile")
Patrick Depoix
Architecte D.P.L.G. & Historien-chercheur en histoire de l'Architecture
cron