#emc-devel | Logs for 2008-02-05

Back
[03:51:26] <CIA-21> EMC: 03cradek 07TRUNK * 10emc2/src/emc/rs274ngc/interp_read.cc:
[03:51:26] <CIA-21> EMC: add semicolon comment character: the semicolon and everything after it
[03:51:26] <CIA-21> EMC: on the line is disregarded.
[03:53:08] <SWPadnos> hmmm. what happens if there's a semicolon inside a () comment?
[03:56:23] <cradek> hmm
[03:57:10] <cradek> g0(;)x0 is an interesting case
[03:57:20] <SWPadnos> heh -yeah
[03:57:26] <cradek> what should it do?
[03:57:53] <SWPadnos> presumably, (msg, change tools; then hit START) would also give an error
[03:58:04] <SWPadnos> assuming that an unclosed () is an error
[04:00:22] <SWPadnos> "If more than one comment appears on a line, only the last one will be used; each of the other comments will be read and its format will be checked, but it will be ignored thereafter. It is expected that putting more than one comment on a line will be very rare."
[04:01:02] <cradek> ick
[04:01:05] <SWPadnos> that tells me that only the last comment will be executed (if it's a MSG or DEBUG), but multiples are supposed to be accepted, presumably intespersed with G-code wirds
[04:01:08] <SWPadnos> or words
[04:01:38] <SWPadnos> "If each group is kept in order or reordered without changing the meaning of the line, then the three groups may be interleaved in any way without changing the meaning of the line. For example, the line "g40 g1 #3=15 (foo) #4=-7.0" has five items and means exactly the same thing in any of the 120 possible orders (such as "#4=-7.0 g1 #3=15 g40 (foo)") for the five items."
[04:02:09] <SWPadnos> also from the MIST page
[04:02:12] <SWPadnos> ugh
[04:02:14] <SWPadnos> NIST
[04:03:25] <cradek> since ; was an illegal character I thought this was trivial
[04:03:31] <SWPadnos> heh
[04:03:53] <cradek> but (...;...) was not illegal and I changed its behavior
[04:04:37] <cradek> * cradek grumbles
[04:05:01] <SWPadnos> indeed. that's a tough one unless there's a "preprocessor" that removes comments
[04:05:12] <SWPadnos> in which case the semicolon code can go just after that
[04:06:17] <cradek> yeah maybe I just put it in the wrong place
[04:26:39] <cradek> I think I have the right fix now
[04:27:43] <cradek> can you also test it?
[04:27:57] <SWPadnos> um - unfortunately not at the moment
[04:28:02] <cradek> dang
[04:28:22] <SWPadnos> I should be able to boot up the latop pretty quickly though - hang on
[04:28:31] <cradek> I tried all the combinations I can think of, but it would be better if someone who doesn't know how the code works would try to break it
[04:30:09] <SWPadnos> my sledgehammer is booting, sim only
[04:30:11] <CIA-21> EMC: 03cradek 07TRUNK * 10emc2/src/emc/rs274ngc/ (rs274ngc.hh interp_read.cc interp_array.cc):
[04:30:11] <CIA-21> EMC: SWPadnos pointed out the trouble case G(;)0X1 in my previous attempt at
[04:30:11] <CIA-21> EMC: semicolon comments. I think this is a correct implementation now...
[04:32:01] <cradek> interesting: g()0x0 is an error, and it was before I messed with stuff
[04:32:09] <cradek> "bad number format"
[04:32:32] <SWPadnos> I think the parens are significant, even though they generate no actions
[04:32:45] <cradek> the thing after a G has to be a number
[04:32:55] <cradek> I guess you can't put comments anywhere. I did not know this.
[04:32:56] <SWPadnos> though it can be G#123
[04:33:10] <SWPadnos> it has to evaluate to a number, I guess
[04:33:22] <cradek> g0()x0 is fine, g()0x0 is not
[04:33:31] <SWPadnos> yeah, that is interesting - comments aren't as freeform as whitespace
[04:33:37] <cradek> yeah
[04:33:46] <SWPadnos> whereas most computer languages treat comments as whitespace for the most part
[04:33:48] <cradek> I don't like it, but I'm not going to fix it
[04:33:54] <SWPadnos> no, indeed
[04:35:00] <cradek> I'm 90% sure this is now as right as it can get
[04:35:24] <cradek> thanks for pointing out (msg,a;b) which is the way someone might have run into the bug I wrote
[04:35:31] <SWPadnos> hmmm
[04:35:57] <SWPadnos> nevermind - typo on my part
[04:35:58] <SWPadnos> sure
[04:36:21] <SWPadnos> I'm testing without having peeked at the last change, so I[m a little handicapped :)
[04:37:19] <cradek> that's great
[04:37:31] <cradek> g0x0;(msg,ignoreme)
[04:37:59] <cradek> g0x0(msg,pay attention; I'm important)
[04:38:14] <cradek> I tried this kind of stuff
[04:38:48] <SWPLinux> g0 x1 (msg, hi there; how's life?) y1
[04:41:11] <SWPLinux> ok, I've tried semicolons at the beginning and in the middle of a line, and inside comments
[04:41:32] <cradek> I tried inside []
[04:41:37] <SWPLinux> plus semicolon then comment (with or without semicolon), and comment (with or without semicolon) then semicolon
[04:41:51] <SWPLinux> ah - I haven't tried any equation stuff yet
[04:42:05] <SWPLinux> but it seems right now
[04:42:31] <cradek> some of the cases are probably very rare but it's good if they do the least surprising thing
[04:42:57] <SWPLinux> do you recall the format for printing variables/equations in messages?
[04:43:07] <SWPLinux> or was that taken out/never finished?
[04:43:22] <cradek> (debug,#1)
[04:43:33] <SWPLinux> ah, so that's debug :)
[04:44:38] <cradek> also (print,#1) for stdout (or is it stderr?)
[04:44:45] <SWPLinux> dunno
[04:44:53] <SWPLinux> also probe or log or something like that
[04:46:06] <cradek> it always takes me a few tries to figure out it's spelled atan[-1]/[-1]
[04:47:35] <cradek> if you don't find anything, I'm calling it good
[04:47:37] <SWPLinux> heh
[04:47:45] <SWPLinux> I haven't yet - looks good to me
[04:47:52] <cradek> thanks very much for looking
[04:48:00] <SWPLinux> sure. thanks for coding :)
[04:48:01] <cradek> it was a surprisingly hard change
[04:48:20] <SWPLinux> yeah - I figured it might be - that's why I was scared to do it :)
[04:48:28] <cradek> fools rush in
[04:48:32] <SWPLinux> heh
[04:48:54] <SWPLinux> I'vehad to deal with that kind of thing on an AVR (in assembly language) for a serial protocol
[04:48:58] <SWPLinux> not fun
[04:49:02] <cradek> bleah
[04:49:36] <cradek> the avr's interrupt-when-character-received-so-you-better-do-something-with-it-fast is a real challenge
[04:49:44] <SWPLinux> yeah
[04:50:14] <SWPLinux> though I think the serial port was polled in this case - the 1 KHz control interrupt was more important than the serial commands
[04:50:42] <cradek> just be glad you have a uart
[04:50:56] <SWPLinux> yes, with a one-byte buffer
[04:51:01] <cradek> I can't believe people still bit-bang serial on pics
[04:51:06] <SWPLinux> bit-banging is so much less fun
[04:51:17] <SWPLinux> not much choice, is there? ;)
[04:51:29] <cradek> well, the choice is don't use a pic
[04:51:37] <SWPLinux> oh, well there is that option
[04:51:48] <SWPLinux> that's the one I've used since the AVR appeared
[04:52:36] <cradek> I sure like gcc+avr more than writing assembler. I've done enough f8 and pic assembler for a whole lifetime
[04:52:37] <SWPLinux> I was so happy to see a microcontroller that knew how to use its carry bit
[04:52:59] <SWPLinux> F8 - I don't think I've used that one
[04:53:08] <cradek> it's very old
[04:53:23] <SWPLinux> I've heard of H8 and Z8, but not F8 :)
[04:53:44] <SWPLinux> Fairchild?
[04:53:49] <cradek> yes
[04:53:57] <SWPLinux> ok, that explains the F
[04:53:59] <cradek> production 1Q 1975
[04:54:06] <cradek> damn, it's almost as old as me
[04:54:22] <SWPLinux> heh
[04:54:49] <cradek> the best part was having no stack
[04:54:56] <SWPLinux> luvvly
[04:55:12] <cradek> two PCs, they swapped when you called a subr or an interrupt happened
[04:55:34] <cradek> if you have intrs and subrs (just one level of course) both, it's a bit tedious
[04:55:35] <SWPLinux> ouch - better be sure you only use one call level
[04:56:32] <SWPLinux> swapping register sets is somewhat better (but then communications between interrupt and foreground contexts become difficult)
[04:56:43] <cradek> you could manage two if you mask intrs while you shuffle around the return PCs
[04:57:06] <SWPLinux> was there a "load PC" command?
[04:57:11] <SWPLinux> other than call
[04:57:13] <cradek> I was pretty fluent - and now I sure appreciate gcc+avr
[04:57:17] <SWPLinux> heh
[04:57:26] <cradek> yes there's jmp
[04:57:48] <cradek> wonder if the instruction set is *anywhere* online
[04:57:50] <SWPLinux> I suppose I should actually use that combo some time, and also get gcc/ARM working sometime soon
[04:58:04] <cradek> you do avr but not with gcc?
[04:58:29] <SWPLinux> yep
[04:58:30] <cradek> http://www.nyx.net/~lturner/public_html/F8_ins.html
[04:58:32] <SWPLinux> assembler only
[04:58:39] <SWPLinux> I was just about to paste that ;)
[04:59:01] <cradek> I did a lot of projects without an assembler too... hand assembled
[04:59:22] <SWPLinux> eek - that's going a bit overboard if you ask me
[04:59:31] <cradek> for most stuff, I could program it directly in hex, typing into the eprom programmer's editor
[05:00:07] <SWPLinux> I've only done that a little on (a) an exidy sorceror (Z80) and the Heathkit HERO-1 robot (6809 I think)
[05:00:20] <cradek> wrote a f8 table for tasm later... luxury!
[05:00:50] <cradek> UHREADY!
[05:01:25] <cradek> (or was that a later HERO that talked?)
[05:01:39] <SWPLinux> heh
[05:01:49] <SWPLinux> this one talked, but you had to be careful
[05:02:20] <SWPLinux> we had a program that used the interrupt from the sonar sensor to trigger some speech
[05:02:38] <SWPLinux> unfortunately, we had forgotten a "I'm already talking" flag
[05:02:50] <cradek> my favorite F8 project is probably the wwvb clock on http://timeguy.com/cradek/clocks
[05:02:52] <SWPLinux> and the actualy speech was done in the interrupt routine
[05:03:14] <SWPLinux> but we were smart enough to clear the interrupt flag so we could be re-interrupted ...
[05:04:10] <SWPLinux> "Welcome to the Welcome to Welcome Welcome Welcome to the computer room to the computer room to the computer room the computer room computer room" ...
[05:04:17] <cradek> hahaha
[05:04:22] <cradek> close enough!
[05:04:26] <SWPLinux> yep
[05:04:37] <SWPLinux> we also realized at that point that people have two legs
[05:04:51] <SWPLinux> and the HERO is short ...
[05:04:55] <cradek> well the average number of legs is less than 2
[05:05:01] <SWPLinux> indeed
[05:05:03] <SWPLinux> same as arms
[05:05:33] <cradek> hey it's another leap year, I should fix that other clock I never quite got right...
[05:05:43] <SWPLinux> heh
[05:05:52] <SWPLinux> as long as you don't have to do F8 machine code
[05:06:06] <cradek> I made this other one in late '04 and '04 ran out before I fixed it
[05:06:26] <cradek> and I really didn't feel like setting up a wwvb signal emulator
[05:06:48] <SWPLinux> that's the timecode broadcast?
[05:06:53] <cradek> yes
[05:07:02] <cradek> a lot of my clocks receive and decode that
[05:07:11] <cradek> it's really nice to not have to set them
[05:08:02] <cradek> and if some genius changes the DST rules they just work
[05:08:34] <cradek> (but, so far I've hardcoded central timezone since they're not for sale)
[05:09:00] <LawrenceG> hi guys... been having fun with a pdf to gcode converter... http://filebin.ca/beeovj/map.ngc
[05:09:24] <cradek> LawrenceG: I saw your screenshot - pretty cool
[05:09:34] <fenn> is that Comic Sans on the CRT clock?
[05:09:38] <cradek> somehow pdf seems like a strange part description language though :-)
[05:09:49] <cradek> fenn: no, I digitized my own handwriting
[05:10:19] <LawrenceG> cradek: I sent the source to the pstoedit developer... hope it gets added
[05:10:26] <cradek> LawrenceG: neat
[05:10:44] <fenn> * fenn rtfwp's
[05:11:03] <LawrenceG> ps is wierd... not my kind of language... although it does resemble rpn
[05:11:55] <cradek> if you're an rpn fan, the new HP35S is not bad at all
[05:12:22] <cradek> I'd rather they had rereleased the 15C though... that would be great
[05:12:36] <SWPLinux> my 28S/28C seem to work fine
[05:12:36] <LawrenceG> still have my hp35....
[05:12:41] <SWPLinux> but a little slow
[05:13:13] <cradek> I have several 32sii - a very great calculator
[05:15:51] <cradek> I know what I should do - go to bed
[05:15:53] <cradek> goodnight
[05:18:29] <SWPLinux> good plan. good night all
[05:18:48] <LawrenceG> sweet dreams
[08:17:59] <alex_jon1> alex_jon1 is now known as alex_joni
[15:30:51] <CIA-21> EMC: 03jepler 07TRUNK * 10emc2/src/.swish_config: additional items to ignore
[18:46:48] <skunkworks_> logger_dev: bookmark
[18:46:48] <skunkworks_> Just this once .. here's the log: http://www.linuxcnc.org/irc/irc.freenode.net:6667/emcdevel/2008-02-05.txt
[22:10:12] <skunkworks_> heh Looking at the emc2 code base (under protest), it *might* be possible to build
[22:10:47] <skunkworks_> ....
[22:29:30] <alex_joni> skunkworks_: ?
[22:30:30] <alex_joni> (sorry my connection was down.. )
[22:30:36] <alex_joni> now I'm up to date with emails
[22:51:47] <CIA-22> EMC: 03flo-h 07TRUNK * 10emc2/src/emc/usr_intf/stepconf/ (stepconf.py stepconf.glade): set some labels which are not shown to untranslateable, so they dont show up in the .po file