Author Topic: HELP WITH A PROGRAM FOR CAD..PLEASE.  (Read 13686 times)

0 Members and 1 Guest are viewing this topic.

AVCAD

  • Guest
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #45 on: December 20, 2004, 01:35:02 PM »
I havent forgotten about you guys!!! I am just pretty busy at work latley. I will be getting back to this.

Thanks for the Help!

AVCAD

  • Guest
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #46 on: December 22, 2004, 01:14:44 PM »
CAB (or anyone),

I tried to incorporate that code but I dont really understand it hence I have not gotten it to work. Can you post a working code or try to explain to me what I need to do to get it to work?

Thanks,

CAB

  • Global Moderator
  • Seagull
  • Posts: 10387
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #47 on: December 22, 2004, 03:54:37 PM »
AVCAD
Here is the updated lisp & DCL file.
ercc.zip

Please remove the smw.sld from the future zip file or better yet reduce it's size.
Also add the other rack_n.sld files to the zip.

I cleaned up the lisp a bit but did not add code for the panel information.
Be careful with key names in the DCL file as they are case sensitive.
You had "caster_b" in the lisp & "caster_B" in the DCL. They are not the same.
These should replace your existing lisp & dcl files.
I've reached the age where the happy hour is a nap. ()
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

AVCAD

  • Guest
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #48 on: December 22, 2004, 05:54:19 PM »
Good god, You guys are awsome at this stuff...

It worked! They way you re-organized the code helped me out a lot I sort of understand better how it works..the more i look at it the more start to understand it..Thanks!!

Now if the Pervious and next button and the insert button could actualy work, that would be great!

Previous and next are for the differant panels..I am sure you get the just of what I want here..If not I will explain more. Take a break guys!! I am !!! Hard year ending work is getting to me!

Merry Christmas and a Happy New year to everyone!!

I will probably get back to this after the new year....

here is the working files....

http://www.theswamp.org/screens/AVCAD/ercc.zip

Oh ya how do you decrease the file size of a SLD....or is there a differant type of file I can use???

Thanks!

CAB

  • Global Moderator
  • Seagull
  • Posts: 10387
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #49 on: December 23, 2004, 10:42:22 AM »
ercc3
Well I added code to handle Prev & Next.
I wish I had some time to explain it but it sometimes takes more time to explain that to do it.
I'm kinda busy right now so this will have to do. Just read through the code.

There are no rules implemented yet. Like clicking the 'Full Panel' button should dim the text
for center & right, so only Left could be entered.
Also there is code missing that limits the rack height as far as max panels.

Note, I revised the smw.sld file so save your old one if you extract this one.
It is much smaller in size.
I've reached the age where the happy hour is a nap. ()
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

AVCAD

  • Guest
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #50 on: December 27, 2004, 02:45:47 PM »
Hope guys had a great Xmas holiday!!!

Now its back to work!!!  :x

CAB - how did you reduce the Slide file image size...I noticed that he image looks differant. Is that cause they size was reduced?

For ease we will use the smaller SLD, for design and such. I have the larger on my end for the finial.

I changed some of the code...fixed the Preview Images so the correct SLD's are previewed depending on the check box selection...and removed the 4th line of the user input text (I believe I got all the code that pertained to it also).

Here is the file:

http://www.theswamp.org/screens/AVCAD/ercc.zip

There are still few items that need to be coded for the GUI...

1. Panel information: Is there away to have the Panel #'2 linked to the selection of the Rack Height.....so that if 25 Unit rack is selected there would only be 25 panels availble ( change the code for this one)....but if 45 Unit Rack is selected then there would be 45 panels availble, and so on for the other choices.

2. Related to #1: the Panel Height: is there a way of having that control the Panel #. So that if 1 RU is selected clicking the next button would bring up Panel #2 (as it does already)...But if say there 4 RU was selected then clicking the next button would bring up panel #5....(1+4=5), and so on for the rest of the selections. Reason being is that if the RU is 4 then the panel will take up panels 1,2,3 & 4 and the next availble panel for a new peice of equipment would be 5. This would need to work on all the levels...for example

Panel #1 - 1 RU
Panel #2 - 4 RU
Panel #3 - taken by panel#2
Panel #4 - taken by panel#2
Panel #5 - taken by panel#2
panel #6 - 2 RU
Panel #7 - taken by panel#6

If that doesnt explain it I will try again.

3. Type of Panel: there are 3 radio buttons here...each one needs to represent a differant set of options.....so if the Full Panel is selected then that panel will only have the Center text availble in the Text to display section. If 2 way is selected then the Left and Right shoul dbe availble and if 3 way is selected then all 3 need to availble.

4. Relevant to #2:

TEXT INPUT SELECTIONS:
IF PANEL HEIGHT IS = 1 THEN 1 TEXT LINE AVAILBLE
IF PANEL HEIGHT IS = OR > 2 THEN 2 TEXT LINE AVAILBLE
IF PANEL HEIGHT IS = OR > 3 THEN 3 TEXT LINE AVAILBLE
IF PANEL HEIGHT IS = OR > 4 THEN 4 TEXT LINE AVAILBLE

TEXT INPUT SELECTIONS: FOR 2 WAY SPLIT PANELS
IF PANEL HEIGHT IS = 1 THEN 1 TEXT LINE AVAILBLE (LEFT,RIGHT)
IF PANEL HEIGHT IS = OR > 2 THEN 2 TEXT LINE AVAILBLE (LEFT,RIGHT)
IF PANEL HEIGHT IS = OR > 3 THEN 3 TEXT LINE AVAILBLE (LEFT,RIGHT)
IF PANEL HEIGHT IS = OR > 4 THEN 4 TEXT LINE AVAILBLE (LEFT,RIGHT)

TEXT INPUT SELECTIONS: FOR 3 WAY SPLIT PANELS
IF PANEL HEIGHT IS = 1 THEN 1 TEXT LINE AVAILBLE (LEFT,CENTER,RIGHT)
IF PANEL HEIGHT IS = OR > 2 THEN 2 TEXT LINE AVAILBLE (LEFT,CENTER,RIGHT)
IF PANEL HEIGHT IS = OR > 3 THEN 3 TEXT LINE AVAILBLE (LEFT,CENTER,RIGHT)
IF PANEL HEIGHT IS = OR > 4 THEN 4 TEXT LINE AVAILBLE (LEFT,CENTER,RIGHT)

Actual height of 1 panel is 1.75" for each panel >1 just multiply 1.75 by that number

Sorry for the caps I copied it from a post I posted at the beginning of this thread.

I think that is it....I know its a lot of work though...Hopfully it will go smoothly..... :D

Thanks again...and happy holidays (their not over yet!)

CAB

  • Global Moderator
  • Seagull
  • Posts: 10387
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #51 on: December 27, 2004, 07:13:00 PM »
|->CAB - how did you reduce the Slide file image size...I noticed that he image
|->looks different. Is that cause they size was reduced?
I redrew the slide & used less objects & a simple hatch.

|->For ease we will use the smaller SLD, for design and such. I have the larger on
|->my end for the finial.
Good idea

|->I changed some of the code...fixed the Preview Images so the correct SLD's are
|->previewed depending on the check box selection...and removed the 4th line of the
|->user input text (I believe I got all the code that pertained to it also).
Not sure what code you changed.
preview slides look good now.
Why did you remove the 4th line of text? as you just posted there is a 4th line of
text allowed, right?



|->There are still few items that need to be coded for the GUI...

Added code to dim some choices as selections are made.
1. added code to set max number of panels.
2. added code to dim rows & columns. I did it different as far as the columns go
Left for one column, Left & Center for 2 Columns, etc.


The set up at this point is that a group of Ru's make up a Page. When you use next
you are on page 2 but it could be RU 2 or any number over that which was allocated
to the first Page.
I have not tested the Max Ru's to see if it needs more work.
Out of time & energy.
I've reached the age where the happy hour is a nap. ()
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

CAB

  • Global Moderator
  • Seagull
  • Posts: 10387
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #52 on: December 28, 2004, 09:24:45 AM »
ercc5
Ok, I revised the logic and the columns work as you requested.
I also revised the slides to display a little larger.
I've reached the age where the happy hour is a nap. ()
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

AVCAD

  • Guest
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #53 on: December 28, 2004, 09:47:56 AM »
Quote

|->I changed some of the code...fixed the Preview Images so the correct SLD's are
|->previewed depending on the check box selection...and removed the 4th line of the
|->user input text (I believe I got all the code that pertained to it also).
Not sure what code you changed.
preview slides look good now.
Why did you remove the 4th line of text? as you just posted there is a 4th line of
text allowed, right?


Yes I originially posted that but after I reviewed by blocks and such there really is no reason to have 4 lines on these. The discription very rearly even go past 2 lines.

I changed this section:

Code: [Select]

(get_tiles); gets variables set in DCL

  (cond
    ((and (= caster "1") (= scale "1") (= side_p "1"))
     (setq slide "rack_5")
    )
    ((and (= caster "1") (= side_p "1"))
     (setq slide "rack_4")
    )
    ((and (= caster "1") (= scale "1"))
     (setq slide "rack_3")
    )
    ((= caster "1")
     (setq slide "rack_2")
    )
    ((and (= side_p "1") (= scale "1"))
     (setq slide "rack_8")
    )
    ((= side_p "1")
     (setq slide "rack_7")
    )
    ((= scale "1")
     (setq slide "rack_6")
    )
    (t ; none checked
     (setq slide "rack_1")
    )
  )

  (start_image "rack")
  (fill_image 0 0 x y 0)
  (slide_image 0 -30 x y slide)
  (end_image) ; end image
) ; defun set_slide


I basically just had to rearrange the numbers...Also the

(slide_image 0 -30 x y slide)

The -30 part moves the slides up a bit to better center the image in the preview box.

I havent looked at the new files yet, but i will I too am out of energy expecially after the holiday's.

Thanks or getting to this so quickly though, I actually didnt expect anyone to follow up for a couple of days.

You guys rock!

CAB

  • Global Moderator
  • Seagull
  • Posts: 10387
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #54 on: December 28, 2004, 09:59:42 AM »
Yes I changed the slide order, but did not see the -30.
I added it to the current code but the file I posted does not have it.

I'll remove the 4th text line.
I've reached the age where the happy hour is a nap. ()
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

AVCAD

  • Guest
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #55 on: December 28, 2004, 10:12:42 AM »
I looked at the new ercc5 files and they lookk good...is there a differant program you use for making Slide files? I just use Mslide command in ACAD...

http://www.theswamp.org/screens/AVCAD/ercc6.zip

I changed little things like the -30 in the previous post...

Where is says Panle information under that is says page# I changed it to Panel #....

You can leave the 4th line in there its not a big deal...I didnt remove it from the code on this one.

little changes here and there...not much...but you should probably replace your files with these. well the only changes were in the LSP file.

The buttons work great exactlly what I was looking for!

The Panels were going up to 26 for all the differant rack units. In the code I change the p-max to 24 (not 25)....I guess since 0 is actually 1 then the p-max needs to be -1 from the actual max panels allowed.

the p-max isnt set for each rack...25, 30, 40,45....is there away of doing this?

and the panels need to be coded for a mathmatical equation i guess...so that if 2RU is selected when you hit next it will jump to 2 above that number ( panel 1 = 2RU *next* panel 3 (no panel 2 casue panel 1 is taking up that spot))

god its early! and I am sleepy!

CAB

  • Global Moderator
  • Seagull
  • Posts: 10387
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #56 on: December 28, 2004, 04:48:34 PM »
ercc7
Here is one that honers the max height & once you go to the next panel you can not
change the cabinet height. Also added a the number of unused Rack units.

Here is my take on the Panel question.
Each 'Panel' has 1 to 12 RU's [Rack Units]
Each cabinet can have a set number of Rack units 1.78 high. [25, 30, 35, 40, 45]
The number of panels is determined by the max RU's & the sizes of the panels.
In one of the examples you posted the cabinet was 45 RU's high and had 14 panels.
The largest panel had 11 rack units and 4 lines of text.
 
This is the way I understood the Panels.
So when you hit the next button you are looking at the next panel and it starts
at the next unused Rack Unit which may be 2 to 13 depending on how many you allocated
to the first panel.
Do you find it necessary to keep track of which Rack unit you are at?
I've reached the age where the happy hour is a nap. ()
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

AVCAD

  • Guest
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #57 on: January 03, 2005, 04:45:54 PM »
ok, Thanks again CAB. I will answer the question. And let me appologize now for the book that will follow.  :shock:

All of the Rack heights that are listed in the code are the correct numbers. the 25, 30, 35, 40, 45 rack heights are the actually number of "panels" that each should have.

Rack units or RU's is just a way of designating the height of a rack in the industry.

The height of each rack unit is actaually 1.75" this is the actual size. This is also the size of the blocks that will be used in this program. SO....

Rack Height:

25 = 25ru's
30 = 30ru's
35 = 35ru's
40 = 40ru's
45 = 45ru's

any combination of numbers that can add up to those numbers are the amount of Panels that can be in a rack.

A "panel" is basically just another name for the Rack units. But a panel can be 1-12 ru's in height.....I know its confusing...so...the least amount of panels that can be in a rack with the height being 25 is:

(2) 12 RU's and (1) 1 RU panel = 3 total panels

the most Panels in a rack with the height of 25 is:

(25) 1 RU = 25 total panels

anything can be added together that will create the rack height number is the amount of panels that can be in that rack.

For example:
2+4+2+3+5+6+1+2 = 25 total RU's = 8 total panels

9+4+6+6 = 25 total RU's = 4 total panels

5+6+8+1+1+3+1 = 25 total RU's = 7 total panels

Each RU is basically stacked ontop of each other. so by saying Panel #1 is 3 RU's you are actually saying that Panel #1 is basically (3) 1 RU's on top of eachother....but, they are combined and not seperate peices of equipment.

Typically a VCR in a Rack is 1 RU, same for a DVD player...this means there would be a VCR in one panel and then a DVD in the next panel. if you were putting in a (tower) CPU in a rack you need more RU's cause of the size so maybe it would be 10 RU's for a CPU a 1 RU for the keyboard and mouse and 11 RU's for a monitor (ofcourse depending on the size).

So that would mean that the 10 RU's are one panel the 1 RU is one panel and the 11 RU's is one panel....and if you are using a 30 unit rack you still have 8 RU's left....that are blank or are for future expansion for network devices and such.

The name panel doesnt mean that there is actually something there, there might be 1 RU panel that is blank or there might be a 12 RU panel that is blank but these still need to be accounted for when desiging a rack.

Quote

This is the way I understood the Panels.
So when you hit the next button you are looking at the next panel and it starts
at the next unused Rack Unit which may be 2 to 13 depending on how many you allocated
to the first panel.


Somewhat correct...it should be "So when you hit the next button you are looking at the next panel and it starts
at the next unused Rack Unit which may be 2 to 13 depending on how many you allocated to the previous panel."

Quote

Do you find it necessary to keep track of which Rack unit you are at?


If by Rack unit you mean Panel #, then yes..but this is already accomplished....so I am assuming you mean "RACK" as whole, the caseing and the panels included...then this would be No. Once the the set up is completed and you hit Insert the process will be done and if there is another "Rack" that is needed then the ercc will be ran again.

I hope that clearified this alittle more. If not please let me know.

Now, As I played with new files...here is what I noticed.

The RU balance is great I like it...but it updates immediatly...can it update after you hit next? I was a little confused when I first saw this cause I thought the numbers were adding up wrong but in fact they are correct. What was confusing me was that the balance was always -1 of the rack height when first selected not realizing that 1 RU was being selected already. Maybe if the selection block was blank instead of haveing the 1 RU being the default selection. I tried to just add a "" in the list but it would still subtract 1 form the balance.

Also, can the RU's be linked to the Panel # (what you have called out as Page #)...so that if for example:

Panel #1 = 3 RU's hitting the next button would jump to the next availbe panel. In this case it would be Panel # (page #) 4

Also the Panel #'s (again what you have as Page #) needs to stop at the correct number of units. For some reason they all go 1 past the limit. I tried to fixed this by changing the p-max to 24 instead of 25 but I am not sure this is a correct fix.

I really hope this all made sense....I think it did...atleast in my head it did.. :?

Uh...I think I just hurt my head!

CAB

  • Global Moderator
  • Seagull
  • Posts: 10387
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #58 on: January 03, 2005, 11:53:56 PM »
ercc8

I understand, no time right now but here is an example of how you can draw the racks.
I've reached the age where the happy hour is a nap. ()
Windows 10 core i7 4790k 4Ghz 32GB GTX 970
Please support this web site.

whdjr

  • Guest
HELP WITH A PROGRAM FOR CAD..PLEASE.
« Reply #59 on: January 04, 2005, 10:22:31 AM »
Quote from: AVCAD
Uh...I think I just hurt my head!

Probably because you guys have hit this prog around so much that its starting to hit back. :D