Hello Guest it is April 17, 2024, 10:25:52 PM

Author Topic: VB defines/header file?  (Read 4656 times)

0 Members and 1 Guest are viewing this topic.

VB defines/header file?
« on: April 27, 2009, 01:42:34 PM »
Hi,
I'm started to write some more macros and triggered my strong dislike for magic numbers in source code.
I'd just as soon use a set of names that are already in common use rather than invent names.

I think I remember seeing a post with a reference to a header file that defines names for all the mach DROS, LEDs etc. - but dang if I can find it now...

Is there a header file which is already in comon usage?
Can someone point me to such a critter?

Dave
 
Re: VB defines/header file?
« Reply #1 on: April 28, 2009, 06:52:08 PM »
I do not know of one. There was a recent list of all the DROs posted, but its only a list with descriptive names, not useable variable names
Re: VB defines/header file?
« Reply #2 on: April 28, 2009, 08:00:36 PM »
Wow, that surprises me.  :o 
OK, I guess I'll roll my own list of constants to use in macros.
Thanks for the response.
Dave
Re: VB defines/header file?
« Reply #3 on: April 30, 2009, 10:09:13 AM »
When you finish naming , please post the results here, at least there will be 2 people with same code names !
Re: VB defines/header file?
« Reply #4 on: May 04, 2009, 12:20:48 PM »
When you finish naming , please post the results here, at least there will be 2 people with same code names !

Hi,
the best source of "already typed in" magic numbers I have found is at
http://www.machsupport.com/forum/index.php/topic,6657.0.html

I have decided to give up on making a master header that defines all the constants. The reason is that the full set of defined constants is so long that it annoys me to have to skip over it before I can see the actual code I am working on. Instead, for my personal macros, I'm using the names from the XLS sheet referenced above, and just including the ones I am using.

Dave