<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Recent changes to 26: master mode broken for tnt4882 ISA cards</title><link>https://sourceforge.net/p/linux-gpib/bugs/26/</link><description>Recent changes to 26: master mode broken for tnt4882 ISA cards</description><atom:link href="https://sourceforge.net/p/linux-gpib/bugs/26/feed.rss" rel="self"/><language>en</language><lastBuildDate>Sun, 02 Jul 2006 15:42:59 -0000</lastBuildDate><atom:link href="https://sourceforge.net/p/linux-gpib/bugs/26/feed.rss" rel="self" type="application/rss+xml"/><item><title>master mode broken for tnt4882 ISA cards</title><link>https://sourceforge.net/p/linux-gpib/bugs/26/</link><description>&lt;div class="markdown_content"&gt;&lt;p&gt;ISA cards, (NI ISA tnt4882 evaluation board, tnt4882 on&lt;br /&gt;
custom board on ISA bus) fail to operate in master mode&lt;br /&gt;
with &lt;/p&gt;
&lt;p&gt;master = yes&lt;/p&gt;
&lt;p&gt;in gpib config.&lt;/p&gt;
&lt;p&gt;PCI tnt5004 boards work correctly as master in the same&lt;br /&gt;
machine, only the isa tnt4882 cards do not work as&lt;br /&gt;
master. (an old pcIIa in this machine also works&lt;br /&gt;
properly as master)&lt;/p&gt;
&lt;p&gt;This was tested with a PCI tnt5004 card (working as&lt;br /&gt;
master) and a tnt4882 NI eval board (not working as&lt;br /&gt;
master) on a Pentium 150 ISA/PCI board. The addr, irq,&lt;br /&gt;
DMA of the ISA cards are set correctly since these&lt;br /&gt;
boards work properly as slaves.&lt;/p&gt;
&lt;p&gt;Here is the detail information (as per the email sent&lt;br /&gt;
recently)&lt;/p&gt;
&lt;p&gt;For some reason I cannot get the master GPIB board to&lt;br /&gt;
work properly.&lt;/p&gt;
&lt;p&gt;Despite that master=yes in the gpib.conf of the master,&lt;br /&gt;
I keep getting the&lt;br /&gt;
following output in ibtest:&lt;/p&gt;
&lt;p&gt;r&lt;br /&gt;
enter maximum number of bytes to read [1024]: 12&lt;br /&gt;
trying to read 12 bytes from device...&lt;br /&gt;
InternalReceiveSetup: command failed&lt;br /&gt;
received string: ''&lt;br /&gt;
number of bytes read: 39&lt;br /&gt;
gpib status is:&lt;br /&gt;
ibsta = 0x8000  &amp;lt; ERR &amp;gt;&lt;br /&gt;
iberr= 1&lt;br /&gt;
ECIC 1: Board not controller in charge&lt;/p&gt;
&lt;p&gt;ibcnt = 39&lt;br /&gt;
You can:&lt;br /&gt;
w(a)it for an event&lt;br /&gt;
write (c)ommand bytes to bus (system controller&lt;br /&gt;
only)&lt;br /&gt;
send (d)evice clear (device only)&lt;br /&gt;
change remote (e)nable line (system controller&lt;br /&gt;
only)&lt;br /&gt;
(g)o to standby (release ATN line, system&lt;br /&gt;
controller only)&lt;br /&gt;
send (i)nterface clear (system controller only)&lt;br /&gt;
ta(k)e control (assert ATN line, system&lt;br /&gt;
controller only)&lt;br /&gt;
get bus (l)ine status (board only)&lt;br /&gt;
go to local (m)ode&lt;br /&gt;
change end (o)f transmission configuration&lt;br /&gt;
(q)uit&lt;br /&gt;
(r)ead string&lt;br /&gt;
perform (s)erial poll (device only)&lt;br /&gt;
change (t)imeout on io operations&lt;br /&gt;
request ser(v)ice (board only)&lt;br /&gt;
(w)rite data string&lt;/p&gt;
&lt;p&gt;A write attempt loks like this:&lt;br /&gt;
: w&lt;/p&gt;
&lt;p&gt;enter a string to send to your device: ggfd&lt;br /&gt;
sending string: ggfd&lt;/p&gt;
&lt;p&gt;gpib status is:&lt;br /&gt;
ibsta = 0x8000  &amp;lt; ERR &amp;gt;&lt;br /&gt;
iberr= 1&lt;br /&gt;
ECIC 1: Board not controller in charge&lt;/p&gt;
&lt;p&gt;Pretty much the same happens on most of the other&lt;br /&gt;
commands in ibtest.&lt;/p&gt;
&lt;p&gt;Doing "runtest" with ssh gives the following result:&lt;/p&gt;
&lt;p&gt;./runtest --pad 3&lt;br /&gt;
Password:&lt;/p&gt;
&lt;p&gt;==========&lt;br /&gt;
Output of master run:&lt;br /&gt;
==========&lt;br /&gt;
option: pad 3&lt;br /&gt;
option: run as bus master&lt;br /&gt;
Finding board...OK&lt;br /&gt;
master_read_write_test...FAILED: libgpib_test.c line&lt;br /&gt;
228, ibsta 0x8000, iberr&lt;br /&gt;
1, ibcntl 0&lt;br /&gt;
loop 0&lt;/p&gt;
&lt;p&gt;==========&lt;br /&gt;
Output of slave run:&lt;br /&gt;
==========&lt;br /&gt;
option: pad 3&lt;br /&gt;
option: run as slave&lt;br /&gt;
Finding board...OK&lt;br /&gt;
slave_read_write_test...FAILED: libgpib_test.c line&lt;br /&gt;
275, ibsta 0xc100, iberr&lt;br /&gt;
6, ibcntl 0&lt;br /&gt;
loop 0&lt;br /&gt;
root@i586-OE-MACHINE:/usr/share/gpib/test-tools#&lt;/p&gt;
&lt;p&gt;Configuration files:&lt;/p&gt;
&lt;p&gt;gpib.conf of master:&lt;/p&gt;
&lt;p&gt;root@i586-OE-MACHINE:/usr/share/gpib/test-tools# cat&lt;br /&gt;
/etc/gpib.conf&lt;br /&gt;
interface {&lt;br /&gt;
minor = 0&lt;br /&gt;
board_type = "ni_isa_accel"&lt;br /&gt;
name = "GPIB"&lt;br /&gt;
pad = 6&lt;br /&gt;
sad = 0&lt;br /&gt;
eos = 0&lt;br /&gt;
set-reos = no&lt;br /&gt;
set-xeos = no&lt;br /&gt;
set-eot = yes&lt;br /&gt;
base = 0x240&lt;br /&gt;
irq = 5&lt;br /&gt;
dma = 6&lt;br /&gt;
master = yes&lt;br /&gt;
timeout = T10s&lt;br /&gt;
}root@i586-OE-MACHINE:/usr/share/gpib/test-tools#&lt;/p&gt;
&lt;p&gt;gpib.conf of slave:&lt;/p&gt;
&lt;p&gt;root@i586-OE-MACHINE:/usr/share/gpib/test-tools# cat&lt;br /&gt;
/etc/gpib.conf&lt;br /&gt;
interface {&lt;br /&gt;
minor = 0&lt;br /&gt;
board_type = "ni_isa_accel"&lt;br /&gt;
name = "GPIB"&lt;br /&gt;
pad = 1&lt;br /&gt;
sad = 0&lt;br /&gt;
eos = 0&lt;br /&gt;
set-reos = no&lt;br /&gt;
set-xeos = no&lt;br /&gt;
set-eot = yes&lt;br /&gt;
base = 0x240&lt;br /&gt;
irq = 5&lt;br /&gt;
dma = 6&lt;br /&gt;
master = no&lt;br /&gt;
timeout = T10s&lt;br /&gt;
}root@i586-OE-MACHINE:/usr/share/gpib/test-tools#&lt;/p&gt;
&lt;p&gt;(the same problem exists with board_type = "ni_isa")&lt;/p&gt;
&lt;p&gt;General configuration:&lt;br /&gt;
Kernel 2.6.16&lt;br /&gt;
Both GPIB boards are NI ISA tnt4882 boards.&lt;br /&gt;
linux-gpib-3.2.06+cvs20060604 (which I think is more or&lt;br /&gt;
less the same&lt;br /&gt;
like .07)&lt;/p&gt;
&lt;p&gt;I started to debug the library and the driver, not&lt;br /&gt;
entirely succesful. From&lt;br /&gt;
what I could see it seems that the master board does&lt;br /&gt;
not get set master or&lt;br /&gt;
CIC properly, even with master=yes in the gpib.conf. I&lt;br /&gt;
could not easily find&lt;br /&gt;
the place in the driver code where a tnt4882 chip is&lt;br /&gt;
being made CIC, it also&lt;br /&gt;
seems that the NI documentation for the tnt4882 lacks&lt;br /&gt;
most of the information&lt;br /&gt;
on how to make this chip master. I understand that the&lt;br /&gt;
tnt4882 is handled&lt;br /&gt;
like a nec7210, with something called page-in to make&lt;br /&gt;
it look like a true&lt;br /&gt;
nec7210.&lt;br /&gt;
The interesting thing that I found (with a logic&lt;br /&gt;
analyser on the isa bus) is&lt;br /&gt;
that if the master board reads ADSR bit7 (which is&lt;br /&gt;
supposed to indicate CIC,&lt;br /&gt;
I believe) it is clear, as a consequence then leading&lt;br /&gt;
to "ECIC 1: Board not&lt;br /&gt;
controller in charge".&lt;/p&gt;
&lt;p&gt;Did anybody see similar problems? That "ECIC 1: Board&lt;br /&gt;
not controller in&lt;br /&gt;
charge" thing with the ni_isa or ni_isa_accel driver?&lt;/p&gt;
&lt;p&gt;Any help is very much appreciated!&lt;/p&gt;&lt;/div&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Christopher Lang</dc:creator><pubDate>Sun, 02 Jul 2006 15:42:59 -0000</pubDate><guid>https://sourceforge.net21f5c0837dd74a09010b9f818f1e7d62d44096a0</guid></item></channel></rss>