Back
[16:44:39] <SWPadnos> thanks
[16:44:59] <micges_work> np
[18:30:00] <skunkworks_> http://www.cnczone.com/forums/showpost.php?p=674323&postcount=8
[19:24:39] <CIA-7> EMC: 03cradek 07ss-wrapped-rotary * r061de904ff50 10/ (7 files in 3 dirs): make this properly configurable with an ini entry
[19:25:12] <cradek> I'm really close to merging this - does anyone want to have a look at it first?
[19:25:59] <cradek> jepler: I'd especially appreciate you looking at the Interp::unwrap_rotary and see if it's the best that can be done to not get bitten by FP problems
[19:27:07] <jepler> cradek: I'll have a look
[19:27:11] <cradek> thanks
[19:32:38] <jepler> cradek: c99 has signbit(x), maybe you want that instead of your construct with copysign
[19:34:49] <cradek> jepler: I saw that but preferred copysign because it didn't require a special compiler flag (according to my man pages)
[19:35:52] <jepler> cradek: fair enough
[19:37:50] <jepler> cradek: so for any commanded and current, there are two angles you can reach with a single absolute wrapped command
[19:38:05] <jepler> you contend that one is result and the other is either result+360 or result-360
[19:41:07] <cradek> yes, I think that's what I think
[19:42:24] <cradek> I changed my mind about it being ready to merge. If B is wrapped, a command G90 G0 B999 should be an error (>= 360)
[19:42:52] <jepler> and it's undefined what happens if current mod 360 == fabs(commanded)
[19:42:53] <jepler> ?
[19:43:15] <jepler> though it looks like this implementation will make it not move(?)
[19:43:41] <cradek> yes and I think that makes some intuitive sense. the only reasonable alternative would be to error I guess.
[19:45:17] <jepler> I don't spot anything in unwrap_rotary that makes me too uneasy
[19:45:39] <jepler> if(!neg && result < current) result = fabs(commanded) + ((d+1)*360);
[19:45:39] <jepler> if(neg && result > current) result = fabs(commanded) + ((d-1)*360);
[19:46:34] <jepler> ^^ the only thing I can think to fiddle with is this. When you've wound up to 12 trillion degrees or so it might let you retain a bit more precision
[19:47:42] <jepler> kinda for the same reason that a+a+a+a+a != a*5
[19:49:45] <SWPadnos> you guys wouldn't happen to know of a vegetarian restaurant in Omaha, would you?
[20:19:08] <cradek> SWPadnos: McFoster's
[20:19:20] <jepler> SWPadnos:
http://www.mcfosters.com/
[20:19:25] <SWPadnos> ok, that's the one Google says is good
[20:19:38] <cradek> yeah it's nice. try the lasagna if they have it
[20:19:46] <SWPadnos> ok, cool
[20:19:48] <jepler> though they're not 100% vegetarian, they're the most granola-crunching restaurant in town
[20:20:03] <SWPadnos> I think we might have enough time for dinner tomorrow night
[20:20:16] <SWPadnos> only one of us is a vegetarian, so having non-veg options is good
[20:20:21] <jepler> you're going to be in omaha?
[20:20:23] <SWPadnos> yep
[20:20:34] <cradek> is the other of you someone we know?
[20:20:40] <SWPadnos> well, flying to Omaha so I can go to Council Bluffs :)
[20:20:41] <SWPadnos> no
[20:20:45] <cradek> ah
[20:20:49] <SWPadnos> we're shooting the Creed concert there
[20:21:03] <jepler> should we come up and have dinner with you?
[20:21:08] <jepler> it's just an hour up the road
[20:21:20] <SWPadnos> that would be great, if you want to do it
[20:21:31] <SWPadnos> I'm getting in a few hours before my associated from Dallas
[20:21:34] <SWPadnos> associates
[20:22:11] <SWPadnos> I should arrive at 5:something PM
[20:23:26] <SWPadnos> err - 5:14PM
[20:25:12] <jepler> they're open 'till 10PM tomorrow, no music.
[20:25:31] <SWPadnos> huh -where did you find that
[20:25:35] <jepler> on the phone
[20:25:40] <SWPadnos> I was jus about to comment that they don't have their hours on the website
[20:25:42] <SWPadnos> oh
[20:25:56] <jepler> yeah, and recently Ingrid and I turned up at about 10:30AM for Sunday brunch
[20:25:57] <alex_joni> archaic means of communication
[20:25:59] <jepler> .. they didn't open until 11
[20:26:03] <SWPadnos> heh
[20:26:04] <jepler> so it was on my mind
[20:26:45] <SWPadnos> the Dallas contingent arrives at 8:00-ish, so I'll have time to kill
[20:27:33] <jepler> are you still at the same 802-233-xxxx number?
[20:27:37] <SWPadnos> yep
[20:27:51] <SWPadnos> I have KimK's number as well
[20:28:05] <cradek> it'd be neat to see him again too
[20:28:12] <cradek> heck, I'm in
[20:28:24] <SWPadnos> cool
[20:28:24] <jepler> I'm trying to find out if Ingrid is free..
[20:33:56] <jepler> cradek: I'm tempted to think that a different formulation would be better than if(wrapped) { ... } else { ... }
[20:33:59] <jepler> double get_rotary_end(bool wrapped, double sign_of, double commanded, double current) {
[20:34:02] <jepler> if(!wrapped) return commanded;
[20:34:04] <jepler> else return unwrap_rotary(sign_of, commanded, current);
[20:34:07] <jepler> }
[20:34:36] <jepler> then you'd write something like *AA_p = get_rotary_end(s->axis_wrapped, block->a_number, block->a_number - s->AA_origin_offset - s->AA_axis_offset, s->AA_current);
[20:35:21] <cradek> I agree that would save some lines
[20:35:55] <cradek> SWPadnos: is KimK coming for sure?
[20:36:19] <jepler> how did you try to find all the places that had to be changed?
[20:36:40] <cradek> I didn't have a system, I just kept thinking of more of them
[20:41:03] <SWPadnos> cradek, I haven't called him yet, so I don't know
[20:43:13] <jepler> cradek: I looked at the diffs and I think it looks fine
[20:44:26] <cradek> jepler: thanks
[20:46:35] <cradek> I'm a bit uneasy about what to write in the var file for G10 etc, but if the axis is modulo I suppose it doesn't really matter much
[20:47:12] <cradek> you could G10 L2 P1 A360000000 and what would it matter? it would just be a stupid thing to do.
[20:48:02] <cradek> hm, G92 A361 must be an error as well: there is no offset that can make A become 361
[20:50:15] <jepler> and G10 L20?
[20:51:09] <cradek> yep
[20:57:24] <jepler> SWPadnos: you'll be renting a car, I assume?
[20:57:32] <SWPadnos> nope
[20:57:48] <SWPadnos> there's a shuttle bus to the hotel, and the other guys are getting a car which we'll share
[21:00:20] <jepler> SWPadnos: wanting a ride to dinner, then?
[21:00:27] <SWPadnos> heh, sure
[21:00:35] <jepler> if there are 3 of us and 2 of you it'll be cramped in the blueberry, but nothing in omaha is far from anything else
[21:00:53] <jepler> but Ingrid's not committed yet
[21:00:55] <SWPadnos> when do you think you'd get to Omaha?
[21:01:25] <SWPadnos> I'm thinking it might be good for me to catch the hotel shuttle and dump my bags before dinner
[21:02:13] <jepler> well, if you want to say when we should pick you up, and work backwards from there..
[21:02:52] <SWPadnos> the plane arrives (hopefully) at 5:14, so I'd be at the hotel at roughly 6:00 I think (I have to check a bag)
[21:03:22] <jepler> what hotel is it?
[21:03:31] <SWPadnos> Hampton Inn, Council Bluffs
[21:03:48] <SWPadnos> it's just across the river, off I-80(?)
[21:04:37] <jepler> yeah
[21:04:51] <jepler> that should be no problem, we'd just have to get out of Lincoln by 4:45 or so
[21:05:19] <SWPadnos> OK - I was thinking that 6:00-6:30 would be about right for you guys, assuming you've got a normal workday tomorrow
[21:05:38] <jepler> yeah, Chris and I usually leave the office around 4
[21:06:34] <SWPadnos> oh right - early riser(s)
[21:09:43] <jepler> I'll give you a call if something comes up, or when we arrive at the hotel
[21:12:03] <jepler> bbl
[21:23:41] <cradek> we could take my car, but it's probably equally bad for 5
[21:29:41] <SWPadnos> ok, see you
[21:29:50] <SWPadnos> (sorry - wife got home soI was away)