#linuxcnc-devel | Logs for 2015-04-29

Back
[11:34:08] <jepler> found in a pdf for the SUN1999-based MIO5499A datasheet: "ECP / EPP / SPP / BPP modes work under Windows, and Linux driver only supports SPP mode."
[11:35:05] <seb_kuzminsky> i read that as "our hardware doesn't follow the de-facto standard, but we paper over the warts in our windows driver"
[11:35:19] <seb_kuzminsky> "and we won't tell you how to do it"
[11:36:18] <cradek> shame on me for assuming sun19xx would work right, when given the fact that sun18xx works right
[11:36:36] <cradek> it's not as if I'm new at this
[11:37:02] <seb_kuzminsky> we just need to convince pcw_home to take over all hardware design & manufacture in the world, then we won't have problems like this
[11:37:41] <cradek> but what if world domination corrupted him?
[11:42:36] <jepler> c:\>sundos -lpt2=spp
[11:42:36] <jepler>
[11:42:36] <jepler> Sunix IO card Uti1ity for DOS ver.1.00.00.006
[11:42:36] <jepler> Seting LPT2 to spp
[11:42:42] <CaptHindsight> I wonder is any of the broken EPP controllers are really just microcontrollers with bad firmware in a PCI LPT controller package
[11:42:45] <jepler> this is interesting, there's a DOS utility that can change the mode
[11:42:48] <CaptHindsight> is/if
[11:42:48] <jepler> -lpt Seting parallel mode to spp,ecp,epp,pff,bpp
[11:43:00] <jepler> anybody feel like reverse-engineering a 32kB DOS EXE?
[11:43:17] <CaptHindsight> like the fake FTDI USB adapter devices
[11:44:18] <CaptHindsight> jepler: post a link to the EXE please, maybe someone will take a stab at it
[11:44:30] <pcw_home> if you know the parallel port base address it's pretty easy to poke at the control registers to see if they make sense
[11:45:04] <pcw_home> (that is do the follow the IEEE1284 specs?)
[11:45:48] <pcw_home> they follow
[11:45:58] <seb_kuzminsky> if they did, the normal linux driver would work
[11:46:30] <jepler> the linux driver says there is no PCI BAR corresponding to the ECP registers (the ones often found at base + 0x400)
[11:47:29] <jepler> the linux driver seems to assume these go in their own BAR
[11:48:00] <pcw_home> yeah so need to find if there is an offset with a register that behaves as expected
[11:48:19] <jepler> right
[11:48:21] <pcw_home> is there any data on the chip around?
[11:48:28] <jepler> I haven't found any register docs
[11:48:44] <jepler> they state that the serial part is 16c950 compatible
[11:48:51] <pcw_home> who needs docs if you have a windows driver
[11:49:48] <pcw_home> whats the full part number?
[11:51:18] <pcw_home> nm SUN1999
[11:51:20] <jepler> I don't have the board, but the PCI if chip is apparently silkscreened SUN1999
[11:55:20] <pcw_home> hmm does sunix even make chips?
[11:58:27] <pcw_home> if they do it does not look like they sell to OEMs so maybe they why theres no detailed data
[11:58:29] <pcw_home> OTOH they claim to have a linux driver
[11:59:55] <pcw_home> which has source and a makefile!
[12:00:10] <jepler> snx_main.c: pp->base_hi = sb->bar_addr[sb->pb_info.port[k + sb->ser_port].bar2] + sb->pb_info.port[k + sb->ser_port].offset2;
[12:07:02] <jepler> // type bar1 ofs1 len1 bar2 ofs2 len2 intmask flags
[12:07:05] <jepler> { 'p', 1, 0, 8, 2, 0, 0, 0x0000, SUN1999_HWID },
[12:07:28] <jepler> len2 of 0 doesn't seem right
[12:07:37] <jepler> that's a VENID_SUN1999 card
[12:07:51] <jepler> { 'p', 0, 0, 8, 1, 0, 8, 0x0000, SUN1888_HWID },
[12:07:58] <jepler> a sun1888 entry has a len2 of 8
[12:08:05] <jepler> which is a lot less surprising
[12:08:52] <cradek> jepler: fwiw, I rebuilt our rtai kernel with that patch you found, and it made no difference, the card was still not detected by ppdev at boot
[12:14:40] <jepler> cradek: huh, I expected it to then be detected but not have a port_hi
[12:24:41] <cradek> the patch had a lot of serial port stuff, which this card doesn't have
[12:25:02] <cradek> lemme pull it and look at it
[12:26:19] <cradek> given a flood of water and a diamond burr, max has no trouble drilling and cutting glass 1/4" thick
[12:26:32] <cradek> I guess this shouldn't be a surprise but still, it's pretty neat
[12:27:10] <cradek> umm, the card says SUN1989, not 1999
[12:27:20] <cradek> sorry if I misreported
[12:27:40] <cradek> it also says "Gfeen Packing" 1316A008
[12:39:35] <andypugh> I wonder if any machine has more than 4 too carousels? (I wonder if any have more than one?)
[12:47:49] <cradek> lots of lathes have 2
[12:47:59] <cradek> well 2 turrets
[13:01:20] <seb_kuzminsky> i want a mill with a carousel that changes which toolchanger it's using
[13:03:37] <andypugh> seb_kuzminsky: Elaborate please?
[13:04:13] <andypugh> Is it better to call a function 3 times or to waste memory on a variable to hold the return value?
[13:04:58] <andypugh> I guess in the latter case the compiler can kep the value in a register, whereas it can’t know that the function will return the same value every time.
[13:22:30] <jepler> the first SUN1989 I found also says EPP doesn't work on Linux (http://www.sunix.com.tw/product/par5008a.html)
[13:30:56] <jepler> all I've pieced together from SUNDOS.EXE is that it does have standard-looking code to set an ECR-like register at base_hi+2
[13:33:02] <jepler> 1752: 8b 56 e8 mov -0x18(%bp),%dx
[13:33:02] <jepler> 1755: 83 c2 02 add $0x2,%dx
[13:33:02] <jepler> 1758: b0 95 mov $0x95,%al
[13:33:02] <jepler> 175a: ee out %al,(%dx)
[13:33:51] <jepler> but I know way too little to be sure which chips that even applies to
[13:39:12] <jepler> cradek: "modprobe parport_serial" ?
[13:42:14] <jepler> or get sundos.exe + td.exe (turbo debugger) and break on that 'out' instruction to find out what address it actually finds and uses :-P
[13:45:21] <jepler> even freedos debug.exe might suffice
[13:54:35] <cradek> jepler: did you see above that it's a 1989, not 1999?
[13:56:59] <jepler> cradek: yes
[13:57:05] <jepler> same dos utility
[13:57:13] <jepler> same "only spp on linux" caveat
[14:02:56] <jepler> https://edfries.wordpress.com/2015/03/13/fixing-computer-space-3/
[14:06:37] <jepler> oh wow the diode ROM is actually shaped like space ships https://edfries.files.wordpress.com/2015/03/031315_2128_fixingcompu36.png?w=1000
[14:08:48] <skunkworks> wow - that doesn't happen much today..
[14:12:47] <cradek> the sound is cool
[14:12:52] <cradek> I had never seen a video of it being played
[14:33:20] <skunkworks> http://electronicsam.com/images/house/Sully.JPG
[15:49:36] <seb_kuzminsky> skunkworks: sweet!
[17:48:02] <andypugh> For trial, my new semi-generic carousel driver: http://www.linuxcnc.org/index.php/english/forum/27-driver-boards/28765-another-qwhat-do-i-needq-thread-vmc-retrofit?start=90#58247
[17:50:24] <andypugh> Alll I need now is a Vismach carousel + mill