#emc-devel | Logs for 2006-09-25

Back
[06:34:33] <alex_jon1> alex_jon1 is now known as alex_joni
[17:14:13] <alex_joni> hmm.. do we want 'deg' & 'rad' for angular units?
[17:16:43] <SWPadnos> deg, rad and grad
[17:17:12] <alex_joni> and what's the conversion between those?
[17:17:36] <SWPadnos> I think there are 100 grads per quadrant, so 400/full circle
[17:18:38] <SWPadnos> yep: http://en.wikipedia.org/wiki/Grad_(angle)
[17:19:51] <alex_joni> The international standard symbol for this unit today is "gon"
[17:21:59] <SWPadnos> it's not strictly necessary, but it should be easy if the infrastructure is generic
[17:22:18] <SWPadnos> I envision a table of words and their numerical equivalents
[17:22:50] <SWPadnos> then two functions, one to look up a value by name, and the other to get the name of a numeric value (+- some tolerance)
[17:22:50] <alex_joni> there are some #define's
[17:24:23] <SWPadnos> struct nameval {
[17:24:24] <SWPadnos> char *name;
[17:24:26] <SWPadnos> double value;
[17:24:27] <SWPadnos> } nameval_t;
[17:24:29] <SWPadnos> const angle_name_value_pairs[] = { { name="Degrees", value =1.0 }};
[17:24:31] <SWPadnos> ...
[17:24:40] <SWPadnos> corrected for syntax, obviously ;)
[17:25:06] <SWPadnos> you can then use the same functions to look up length units or any other constant
[17:25:30] <SWPadnos> (for which there's an appropriate table)
[17:25:44] <alex_joni> this can be extended ;)
[17:25:53] <alex_joni> to have the name an array of known definitions
[17:26:00] <SWPadnos> yes indeed - that's why I like it ;)
[17:26:04] <alex_joni> "Degrees", "degs", "degrees", etc
[17:26:36] <SWPadnos> sure, then you can also have a list of lists (or even a text file that gets loaded to look for definitions, so you don't have to recompile for new ones)
[17:26:46] <alex_joni> sounds like overkill
[17:26:55] <SWPadnos> it's good design, I think
[17:27:01] <alex_joni> I don't expect namings of units to change daily ;)
[17:27:08] <SWPadnos> and not much harder than the #define method
[17:27:18] <SWPadnos> oh yeah - the external table thing is overkill
[17:27:48] <SWPadnos> the naming of units may not change, but what if someone wants to add meters (or cm) to the list?
[17:28:00] <alex_joni> should be easy enough
[17:28:12] <SWPadnos> there's where an external file comes in handy
[17:28:24] <SWPadnos> it's like HAL for unit naming ;)
[17:28:45] <alex_joni> brb
[20:16:38] <rayh> Thought for the day from QNX
[20:16:44] <rayh> Many embedded systems must respond to external requests within milliseconds of a cold-boot. Depending on flash speed and other booting bottlenecks, an operating system can take many tens of milliseconds to cold boot.
[20:16:45] <rayh> So, what is a system designer to do? Rather than add extra hardware just to manage the external timing requirements, the Instant Device Activation TDK allows for the creation of ‘mini-drivers’ that can interact with external hardware before the operating system has booted. Hand-off from the mini-driver to the operating system driver is seamless and occurs with no loss of data. An exciting trend is that many general purpose CPUs include built-in
[20:16:45] <rayh> bus controllers (e.g. CAN, J1850, MOST). Using the Instant Device Activation TDK with these CPUs means that extra bus management hardware can be eliminated while preserving the required system timing responses.
[20:37:52] <SWPadnos> this kind of thing may be relatively easy with LinuxBIOS
[20:38:20] <SWPadnos> though it isn't compatible with all that many chipsets yet
[20:39:52] <jepler> TDK ? T---- Development Kit?
[20:40:30] <SWPadnos> Technology Development Kit
[20:40:51] <SWPadnos> perhaps
[20:50:31] <skunkworks> Yes, words are useless! Gobble-gobble-gobble-gobble-gobble!
[20:51:30] <SWPadnos> um, I think it's time for your afternoon pill
[20:52:06] <skunkworks> sorry - I was channeling Edna Mode.
[20:52:25] <SWPadnos> heh
[20:58:57] <alex_joni> lol