CSMAP: Deploy custom coordinate systems to server using CS-MAP

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

CSMAP: Deploy custom coordinate systems to server using CS-MAP

Clement Bouscasse

Hi,

 

My company uses CS-Map for coordinate transformations and I need to add custom coordinate system definitions to the standard coordinate system library. I have successfully created  new entries using AutoDesk Civil 3D on my machine, and have located the corresponding “Category.csd” and “Coordsys.csd” files autocad generated for me.

 

I am stuck when trying to deploy these to our server running cs-map: I do not want to overwrite the existing “Category.csd” and “Coordsys.csd” files there for obvious reasons.

 

Looking online for information on how to achieve this, I came across this RFC:

https://trac.osgeo.org/csmap/wiki/CsMapRfc6

 

Which is quite old, and marked as “adopted” but not implemented… Is anyone able to tell me tell me how to proceed to get my server side csmap deployment to recognise my custom entries?

 

Thanks!

 

 

Clément Bouscasse
Software Developer
RES

D  +44 (0)1923 299 431
M  +44 (0)7881 092 496
[hidden email]
www.res-group.com


RES
Beaufort Court
Egg Farm Lane
Kings Langley
Hertfordshire WD4 8LR
United Kingdom



Renewable Energy Systems Limited, registered in England and Wales with Company Number 1589961
Registered Office: Beaufort Court, Egg Farm Lane, Kings Langley, Hertfordshire WD4 8LR
P Please consider the environment - do you really need to print this email?

 


CONFIDENTIALITY NOTICE: This e-mail, including any attachments, contains information that may be confidential, and is protected by copyright. It is directed to the intended recipient(s) only. If you have received this e-mail in error please e-mail the sender by replying to this message, and then delete the e-mail. Unauthorised disclosure, publication, copying or use of this e-mail is prohibited. Any communication of a personal nature in this e-mail is not made by or on behalf of any RES group company. E-mails sent or received may be monitored to ensure compliance with the law, regulation and/or our policies.

_______________________________________________
MetaCRS mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/metacrs
Reply | Threaded
Open this post in threaded view
|

Re: CSMAP: Deploy custom coordinate systems to server using CS-MAP

CsMap Contractor

Hello Clement . . .

 

RFC -6 was indeed implemented, just not marked as have been so.  The only documentation I am aware of, however, is the RFC-6 document itself.  Presumably, if your work in Civil 3D produced two .csd files in a directory somewhere, you should be able to copy those two files in a similarly situated directory on your server and use the CS_usrdir() API to inform CS-MAP where it is.  Note: If your server is not a little endian machine (i.e. is not the same as the machine your Civil 3D is running on), you might encounter a byte swap problem.

 

Actually, it turns out that the API is CS_usrdr ().  It is defined in CS_general.c at line 151:

 

/**********************************************************************

**     int result = CS_usrdr (usr_dir);

**

**     char *usr_dir;                           the directory where to store all custom definitions in.

**                                                     Note, that this directory isn't required to contain

**                                                     any CSD files (yet).

**                                                     Must be less than (MAXPATH - 1) characters.

**                                                     If NULL or empty, the user dictionary path will be unset.

**                                                     That is, all user defined definitions will be written

**                                                     into the CSD files found in the directory specified

**                                                     in [cs_dir].

**

**     result                                   0 if successfull, -1 otherwise

**

**     Note, that this method can only be called, if cs_Protect is >= 0. That is,

**     the protection scheme for 'system' definitions must be somehow enabled.

**********************************************************************/

 

If you have built CS_MAP from source code, you also have the option of adding your custom definition to the coordsys.asc and category.asc files in the Dictionary folder and simply recompile the dictionaries (CS_Comp.exe or equivalent).   You would then need to make sure your custom definition does not get erased by an update somewhere along the line.

 

Hope this helps.

 

Norm

--

Norm Olsen

7931 S Broadway, PMB 102

Littleton, CO  80122-2710

303-263-4995

[hidden email]

 

From: MetaCRS [mailto:[hidden email]] On Behalf Of Clement Bouscasse
Sent: Monday, March 07, 2016 3:41 AM
To: [hidden email]
Subject: [MetaCRS] CSMAP: Deploy custom coordinate systems to server using CS-MAP

 

Hi,

 

My company uses CS-Map for coordinate transformations and I need to add custom coordinate system definitions to the standard coordinate system library. I have successfully created  new entries using AutoDesk Civil 3D on my machine, and have located the corresponding “Category.csd” and “Coordsys.csd” files autocad generated for me.

 

I am stuck when trying to deploy these to our server running cs-map: I do not want to overwrite the existing “Category.csd” and “Coordsys.csd” files there for obvious reasons.

 

Looking online for information on how to achieve this, I came across this RFC:

https://trac.osgeo.org/csmap/wiki/CsMapRfc6

 

Which is quite old, and marked as “adopted” but not implemented… Is anyone able to tell me tell me how to proceed to get my server side csmap deployment to recognise my custom entries?

 

Thanks!

 

 

Clément Bouscasse
Software Developer
RES

D  +44 (0)1923 299 431
M  +44 (0)7881 092 496
[hidden email]
www.res-group.com


RES
Beaufort Court
Egg Farm Lane
Kings Langley
Hertfordshire WD4 8LR
United Kingdom



Renewable Energy Systems Limited, registered in England and Wales with Company Number 1589961
Registered Office: Beaufort Court, Egg Farm Lane, Kings Langley, Hertfordshire WD4 8LR
P Please consider the environment - do you really need to print this email?

 


CONFIDENTIALITY NOTICE: This e-mail, including any attachments, contains information that may be confidential, and is protected by copyright. It is directed to the intended recipient(s) only. If you have received this e-mail in error please e-mail the sender by replying to this message, and then delete the e-mail. Unauthorised disclosure, publication, copying or use of this e-mail is prohibited. Any communication of a personal nature in this e-mail is not made by or on behalf of any RES group company. E-mails sent or received may be monitored to ensure compliance with the law, regulation and/or our policies.


_______________________________________________
MetaCRS mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/metacrs