Angle entry format in decimal DMS

I’m working on a deed sketch and looking for a way to enter 55d45’23” as 55.4523. This format is known by surveyors as decimal DMS.

Comments

  • CADontheBrain
    edited August 14

    https://help.bricsys.com/en-us/document/bricscad/civil-tools/transparent-commands-in-bricscad?version=V25&id=170202661311

    That was not very searchable in the online help but I found my answer sort of. The Bearing and Distance transparent command accepts that format (decimal DMS). I would like to use this angle format in a script exported from an excel spreadsheet. I like doing the data entry in a spreadsheet because deed descriptions are sometimes hard to follow and require edits to correct errors. It would be nice to run a script to do the data entry in BCAD.

    2025-08-14 update. Turn ON OSNAPZ (set to 1). Turn OFF running Entity Snap. Angular units set to decimal degrees or Surveyor's Units does not seem to matter. When I had running Entity Snap on I got erroneous results. The end of the line seem to find a Civil Point and snap to it while in the Transparent command for Bearing and Distance. No, I did not RTFM. Would that have made a difference?

  • In a lisp you can do what you want. it looks at what is input, 55.4523 you can rearrange it.

    The lisp has functions like those built in to Bricscad.

    ;
    (defun rtd (a)
    (/ (* a 180.0) pi)
    )

    (setq ang_ans ""ans_deg ""
    ans_min ""
    char_found ""
    ans_secs "")

    (setq ang_ans (getstring "\nEnter bearing angle in Deg.MMSS :"))

    (setq ans_len (strlen ang_ans))

    (setq x 0)
    (while (/= char_found ".")
    (setq x (+ x 1))
    (setq ans_deg (strcat ans_deg char_found))
    (setq char_found (substr ang_ans x 1))
    (if (= x 9)(setq char_found "."))
    )
    (setq x (+ x 1))
    (setq ans_min (substr ang_ans x 2))
    (setq x (+ x 2))
    (setq ans_secs (substr ang_ans x 2))

    (if (= ans_min "")(setq ans_min "0"))
    (if (= ans_secs "")(setq ans_secs "0"))

    (setq ang (dtr (+ (atof ans_deg)(/ (atof ans_min) 60.0)(/ (atof ans_secs) 3600.0))))


    My current version uses this front end.

  • Richard Sands
    edited June 26

    Alan thats very neat


    as a surveyor what CADontheBrain put forward would be brilliant for a Bricscad routine. If I'm reading his request correctly.

    To be able to edit the input and rerun would greatly streamline the process.

    Imagine entering a lengthy description with lots of lines, getting to the end and having that sinking feeling when it doesn't plot correctly due to input error or deed description error.

    my survey software has such. A simple text file, can be edited, rerun, bearing rotation and or a scale factor applied. Egs


    TR,1,334.5320,165.790,2,"IPipe"
    Which is from point 1, 334°53'20" for 165.790 to point 2 and that has a description of IPipe.
    A Bricscad version could just have 334.5320 Enter 165.790 Enter and it carries on from end of last line.
    Hope that makes sense

  • If your talking survey then you can read a text file normally a csv and string points. This was drawn using a CSV file and a TIN was made also. It is something I am working on. I have attached sample file for your info. The program I called spaghetti as if you get it wrong that's what your line work looks like.

    Have a look at file it uses a description and a string code a 01EB will not join to 02EB, edge of bitumen. The points with no string are treated as points, which may have a block placed on them based on description name.

    Just a comment have a look at "Stringer" it runs on top of Bricscad. https://stringersurvey.com.au/

  • Thanks AlanH and Richard Sands. I tested a script file and that worked well. I started data entry in Excel then exported to .csv. I edited the .csv to use spaces as hard returns. As a side note I asked MS Copilot to extract a metes and bounds description from a deed in pdf format and format it as a spreadsheet. It worked pretty well. I just did a copy/paste to excel and edited from there. I also asked MS Copilot to draw a sketch of a section breakdown to mark the SW corner of the SE 1/4 of the SE 1/4 of Section 18. Copilot promised the world and delivered nothing instead. I was very very specific with my instructions. Copilot could textually comprehend the solution but it is incapable of drawing the sketch or admitting that it could not.

  • Tom Foster
    edited June 27

    Yes, these AIs have no conception of spacial instructions, especially 3D space - left, up, slope, closer, diagonal, end, 3m. All they do is produce 2D images like something they've seen somewhere frequently associated with certain words. They haven't a clue what the image is, still less what 3D thing it's representing.

  • I guess the strategy for now is generate a script and create geometry by running the script.

  • Lisp has function angtof with option 1 -- Degrees/minutes/seconds

  • Its_alive yes much easier. I use a dcl normally with separate boxes for values.

  • Cadonthebrain " I started data entry in Excel then exported to .csv."

    You can read Excel directly no need for a csv. You open the "Application" then read Excel cells eg "A1" or "1 1", second method is easier as its rows and columns. If you want code just ask.

  • Hi ALANH, yes I would like to test your spaghetti app. Thanks

  • Cadonthebrain that is 2 items, which do you want. Or both ?

    Read Excel

    String points.

  • Also this. Can do say 10 rows of info. Can check before pressing Ok.

  • Alan can I suggest Bearing first, Distance second. 
    It's way we work here in Oz, surveying input ie. 
    Not sure what Cadonthebrain prefers so don't take my call as requisite as I'm observing with interest from the sidelines. Just a comment. 

    Might sound pedantic, but when you've been doing this for a long time you can rattle off a series of B's & D's in very quick succession without looking at the keyboard. 

  • Hi ALANH, both please. I like doing data entry in Excel. Like Richard Sands, I can work the number pad fairly quickly without looking at the keyboard. Adjacent parcels with common sides will have the same M & B in their description. Copy/Paste to reduce data entry effort works well in Excel. Bearing first, distance second is my preferred sequence of data entry. The Traverse Editor in Civil 3D allows me to pick a polyline to populate the bearing and distance of each segment in the editor. That's a nice time saver. I have not looked for a feature like that in BricsCAD but if you know of one please point me in that direction. Thanks

  • Richard Sands
    edited July 2

    I'll follow on this with the pick line for direction and same for distance if needed, is very useful feature.

    A comment re "pick line" is the need (for my program) to pick the end of line that defines the bearing direction. Is important and so mention incase any of this sees the light of day. A line might be reversed in direction so that's important.

    Damien from SOFOCO Tools wrote a brilliant application for Bricscad that did bearing and distance and annotated lines surveying style. For us Aussie surveyors.

  • ALANH
    edited July 3

    Ok I cheated on the DCL I have a make a DCL program you feed it what you want shown. It could be one row like tick Yes or No.

    Here is the programs you are welcome to use them I have swapped the Brg and Dist. Yes I am in AUS, you could also do once press Ok what is misclose. Obviously a open series of lines will have a misclose.

    Look at commented out at top of code has what I posted. use the Load 1st.

    Thinking more it may be better to reorganise the dcl so have columns rather than rows, malke brg on top with length below, press tab and it will jump to next. If you think that is better let me know will redo the dcl code. You are limited with a dcl to say screen width that may limit how many lines can be entered. I think maybe ten.

    I am a Civil Engineer understand title work. A quick one often a brg needs +180 to work so enter brg as a -ve and 180 will be added. -45 = 225

    You can also do radial points etc separate code.

    Nice being Aussie we dont have the US, N45 S67 etc. Just 0-360.

    Multi same segments maybe 4x123.45 in length. so final result is 4 lines.

  • I redid a dcl you enter brg press Tab and it goes to next dist, press tab and so on. You may be able to enter more than 9 entries it depends on the screen size.

    ; A dcl entry of bearings and distances
    ; By AlanH July 2025

    (defun wow ( / y fo fname x key_lst keynum lst2 brgdlst)
    (setq y 0)
    (setq fo (open (setq fname (vl-filename-mktemp "" "" ".dcl")) "W"))
    (write-line "ddgetvalAH2V : dialog {" fo)
    (write-line " label = "Enter BRG & Dist " ;" fo)
    (write-line " : column {" fo)
    (write-line " width =18;" fo)
    (repeat 9
    (write-line "spacer_1 ;" fo)
    (write-line ": edit_box {" fo)
    (setq keynum (strcat "key" (rtos (setq y (+ Y 1)) 2 0)))
    (write-line (strcat " key = " (chr 34) keynum (chr 34) ";") fo)
    (write-line " label = "BRG " ;" fo)
    (write-line " edit_width = 15 ;" fo)
    (write-line " edit_limit = 14 ;" fo)
    (write-line " is_enabled = true ;" fo)
    (write-line " allow_accept=true ;" fo)
    (write-line " }" fo)
    (write-line ": edit_box {" fo)
    (setq keynum (strcat "key" (rtos (setq y (+ Y 1)) 2 0)))
    (write-line (strcat " key = " (chr 34) keynum (chr 34) ";") fo)
    (write-line " label = "DIST " ;" fo)
    (write-line " edit_width = 15 ;" fo)
    (write-line " edit_limit = 14 ;" fo)
    (write-line " is_enabled = true ;" fo)
    (write-line " allow_accept=true ;" fo)
    (write-line " }" fo)
    )
    (write-line "spacer_1 ;" fo)
    (write-line "ok_cancel;}" fo)
    (write-line " }" fo)
    (close fo)
    (setq dcl_id (load_dialog fname))
    (if (not (new_dialog "ddgetvalAH2V" dcl_id))
    (exit)
    )
    (setq x 0)
    (setq y 0)
    (setq brgdlst '() key_lst '())
    (repeat 18
    (setq keynum (strcat "key" (rtos (setq y (+ Y 1)) 2 0)))
    (setq key_lst (cons keynum key_lst))
    (set_tile keynum "")
    )
    (mode_tile "key1" 2)
    (action_tile "accept" "(mapcar '(lambda (x) (setq brgdlst (cons (get_tile x) brgdlst))) key_lst)(done_dialog)")
    (action_tile "cancel" "(setq ah:cancel "Yes")(done_dialog)")
    (start_dialog)
    (unload_dialog dcl_id)
    (setq lst2 '())
    (setq x 0)
    (repeat 9
    (if (= (nth (+ 1 x) brgdlst) "")
    (princ)
    (progn
    (setq lst2 (cons (list (atof (nth x brgdlst)) (atof (nth (+ 1 x) brgdlst)) ) lst2))
    (setq x (+ 2 x))
    )
    )
    )
    (setq lst2 (reverse lst2))
    (princ)
    )
    (wow)