Hi,Eric,
Here is the some information for setting .
I still waiting more information.
Regards,
Tony
----- Original Message -----
From:
"Eric Malkowski" <EMalkowski@xxxxxxxxxxxxxxx>
To:
"Eric Malkowski" <EMalkowski@xxxxxxxxxxxxxxx>, "Tony Pridopia"
<tony@xxxxxxxxxxxxxx>
Cc:
Sent:
Wed, 1 Dec 2010 21:59:15 -0500
Subject:
RE: Mi-PCI-03 issues
Tony-
The card I brought home works fine on a windows laptop with the
windows driver.
This is good news as at least we know the hardware is good.
I tried typing chars between two hyperterminal windows on ports 1
and 2 with them jumpered for RS-422 on the overall board
RS422/RS485 jumper selection (same as factory default) and I set
the jumpers for PORT_1_RT and PORT_2_RT for "RS422" (all makes
logical sense).
With the ports wired loopback pins like this:
1 <-> 3
2 <-> 4
3 <-> 1
4 <-> 2
I'm able to do my typing tests at both 9600 bps and 460800 bps
(our target speed)
Tomorrow I'll make sure the board can talk at 460800 to our
embedded hardware and then we'll know the hardware should be fine.
The concern is using this with linux.
I'm hoping the manufacturer (your guys in Taiwan or the people
from sysbas who make the UART chip) has any pointers to better
linux drivers. Or -- is it possible they could send me a snippet
of the sourcecode for the windows driver that actually initializes
the chip -- I'm guessing there may be some things that need to be
done in the option register to get the chip to transmit and
generate interrupts properly. Again I'm surprise the standard
linux serial driver won't work.
In the meantime I've downloaded the datasheet from sysbas for the
SB16C1052 PCI chip.
I may try to make the necessary mods to make it work with the
standard linux serial driver -- that would really be the best
situation as the main serial driver is at least maintained by the
linux kernel folks... I'm also going to send an e-mail to the
linux-serial@xxxxxxxxxxxxxxx <mailto:linux-serial@xxxxxxxxxxxxxx>
mailing list to see if anyone on there has made a sysbas UART work
with linux at all or any other tips they could offer.
Thanks for looking into this. I'll hold on to the hardware for
now and keep working at this as I'm confident it should work...
it may take me a while, but I can't imagine there are that many
extra things that need to be done beyond a standard UART to use
this thing!
-Eric Malkowski
-----Original Message-----
From: Eric Malkowski
Sent: Wed 12/1/2010 6:24 PM
To: Tony Pridopia; Eric Malkowski
Subject: Re: Mi-PCI-03 issues
Yes -- I'm going to try the card in a windows laptop tonight at
home. I
don't really have a windows setup I can try it in at work.
I'll try to send come characters from one port to the other with a
RS422
Null type setup and a couple of hyperterminal windows or something.
It would certainly be good to at least know I have good hardware to
start with!!!!
I have some more test information on the linux side -- with a scope,
there is simply no data coming out of any pins 1-4 on the DB-9
cable.
We're using 2 channels on a scope to look for the differential
voltage
between Tx+ and Tx- pins 1 & 2. We checked pins 3 & 4 just in
case the
manual was wrong.
The only activity we can get out of this is to put the board into
RS-485
mode (both jumper blocks -- the 3 x jumper pins for each port set to
"485" per the manual for PORT1_RT and PORT2_RT and then the 4 x
jumper
pins we place those two jumpers on the middle two which say RS485
on the
board). If we run a small application program that sends
characters at
9600 bps, we get nothing. Then we kill the application and run it
again, and on the 2nd run we get a single trigger on the scope
where it
drives the line the opposite of idle (like one single bit!) and then
shortly it goes back to idle. It's almost like it tries to take the
RS485 bus and then not transmit anything.
Anyway -- this is not very useful as we want to do RS-422 Point to
Point
no echo mode (4 wire full duplex), but we were trying in
desperation to
get ANYTHING to come out on the pins
So I built up the 2.6 kernel driver with my 2.6 setup which is
designed
for somewhere around kernel 2.6.19 but I'm running 2.6.28.4 so I
had to
port some of the data structure changes.
The 2.6 kernel driver actually identifies both ports as RS-422
Point to
Point with no echo -- clearly the 2.4 driver doesn't identify the
board
right. Makes wonder what else is wrong.
But -- when I tried to transmit, the kernel was crashing -- I found
there were some locking primitives that were removed in the newer
2.6
kernel, so I remove the equivalent ones in their driver and it
doesn't
seem to work right. Perhaps my porting efforts aren't quite right
-- it
doesn't even think it's transmitting characters (the counters in
/proc/tty/driver/multiport don't increase). So I wasn't able to
have
any further success with the 2.6 driver other than seeing it seem to
identify the ports correctly when jumpered for RS422PTP no echo -- I
don't really have time to try and debug why that driver won't even
think
characters are transmitted.
I'm willing to use a functioning 2.4 driver for this that is
systembase's custom driver, but it would be even better if the
standard
serial driver could work with this board.
The registers are 16550 compatible at the PCI address space (there
are 2
banks of 8 registers for the 2 ports that are standard 16550 set
of 8
registers (Tx/Rx, LCR, MCR, FCR etc. etc.). I'm surprised they went
through the trouble of re-inventing the linux serial driver when the
standard driver should work! I'd be curious to hear if they have
any
idea if the board can work with the standard serial driver -- I
originally made some quick mods to get the standard driver to
detect the
UARTs as 16650 STARTECH style UARTs, but when trying to transmit
data,
no interrupts would occur indicating perhaps one can only use their
proprietary global interrupt register to deal with IRQs from the
board... this is disappointing.
Anyway -- I'll let you know the results of trying this on windows.
If they don't work on windows, I'll need to send the boards back
so you
or your folks in Taiwan can test them!
Lastly -- if systembase has and "newer" more current linux drivers
that
are tested and verified to work with your hardware, I would like
to get
my hands on those.
I'm not convinced these linux drivers have ever worked properly with
your hardware!
Thanks -- I'm trying really hard here to make this work and would
really
like to use your boards over the other ones I've found, but again
it's
not looking very good!
-Eric Malkowski
Tony Pridopia wrote:
> Sorry about your problem, we pass all your problem to
manufacture, I am waiting their response. Sorry for the late..
>
> Can you find one laptop with mini pci slot, and test this card
in windows first, make sure no problem first.
>
> Regards,
> Tony
>
> Sent from my iPhone
>
> On 30 Nov 2010, at 22:31, Eric Malkowski
<emalkowski@xxxxxxxxxxxxxxx <mailto:emalkowski@xxxxxxxxxxxxxxx>>
wrote:
>
> >> Hi Tony-
>>
>> I received the 2 Mi-PCI-03 serial boards.
>> I set the PORT1_RT and PORT2_RT jumpers for "422" as I want
RS-422 full duplex (4 wire mode), I do NOT want RS485 multidrop 2
wired mode as shown in the manual.
>> I left the jumpers that select RS422 or RS485 mode (not
documented in the manual!) set for RS422 as they are from the
factory (this is a row of 8 pins where the "outer most" two are
populated with jumpers).
>>
>> By the way -- what does this thing do if the PORT1_RT and
PORT2_RT are set to the "NONE" position? As you can see below I
tried that position in desperation.
>>
>> I built the 2.4 linux kernel driver for my 2.4.29 target kernel.
>> When the driver loads, the first part that seems wrong is the
following:
>>
>> ==============================================
>> MultiPorts/PCI Board Installation version: 3.0
revision: 2009-06-22
>> email : <tech@xxxxxx <mailto:tech@xxxxxx>>
==============================================
>> 2 board(s) installed. 4 ports availabe.
>> Board No.0 Multi-2 PCI (rev b0) ttyMP0 ~ ttyMP1 using IRQ9
>> 1 port --- RS422 and Point to Point mode
>> 2 port --- RS232
>> Board No.1 Multi-2 PCI (rev b0) ttyMP2 ~ ttyMP3 using IRQ11
>> 1 port --- RS422 and Point to Point mode
>> 2 port --- RS232
>>
>> It's claiming the second port on each board is setup for RS-232
mode -- not sure why -- that is really wrong.
>> I'm using your cables that came with the boards and made an
RS-422 null modem by wiring the DB-9 pins with a simple loopback
setup as follows:
>>
>> Pin 1 TxD+ to Pin 3 RxD+
>> Pin 2 TxD- to Pin 4 RxD-
>> Pin 3 RxD+ to Pin 1 TxD+
>> Pin 4 RxD- to Pin 2 TxD-
>>
>> The driver reports the application trying to send data, but no
matter what no data is received (and I'm not sure if it's actually
transmitting as I haven't put a scope on there yet, I won't get to
that until tomorrow).
>> The Driver shows the following:
>>
>> / # cat /proc/tty/driver/multiports
>> *** MultiPorts Information :1.1 driver:3.0 revision:2009-06-22
>> 0: Multi-2 PCI(rev b0) uart:SB16C1050 port:1400 irq:9
osc:14.7456Mhz baud:9600 tx:56 rx:0 RTS|CTS|DTR|DSR|CD|RI
>> 1: Multi-2 PCI(rev b0) uart:SB16C1050 port:1408 irq:9
osc:14.7456Mhz tx:0 rx:0 RTS|CTS|DTR|DSR|CD|RI
>> 2: Multi-2 PCI(rev b0) uart:SB16C1050 port:1480 irq:11
osc:14.7456Mhz baud:9600 tx:56 rx:0 RTS|CTS|DTR|DSR|CD|RI
>> 3: Multi-2 PCI(rev b0) uart:SB16C1050 port:1488 irq:11
osc:14.7456Mhz tx:0 rx:0 CTS|DSR|CD|RI
>>
>> I have been trying port 1 on the first board (line #0 from
above) to port 1 on the second board (line #2 from above) since
the driver reports the first port on each board as RS422 point to
point mode.
>> I also tried having just ports 1 and 2 on the first board talk
w/o the second board installed
>> I tried configuring for 485 mode and all permutations of the
jumpers in case they weren't documented right -- still no luck --
it thinks it's transmitting (the 56 bytes from above) but nothing
comes in
>>
>> I also tried having my application do the proprietary ioctl(fd,
TIOCSPTPNOECHO, NULL) after opening the port thinking that maybe
the systembase chip needs to be told to do RS422 point to point w/
no echo in software -- the ioctl call is accepted, but still
cannot get data to be received.
>>
>> Have you had anyone successfully use this board in RS-422 point
to point (4 wire) mode with the 2.4 linux kernel driver as
delivered on the CD from systembase?
>>
>> Tomorrow I may try to build up the 2.6 kernel module against a
different setup of our software (we have a 2.6 kernel setup for
another project, but I really need this board for the 2.4 project)
just to see if that driver is plagued with the same problems. If
that one works, then I will certainly compare how the UARTs are
being handled in the 2.6 stuff versus 2.4 -- perhaps systembase's
2.4 driver is flawed -- just by the output above from inserting
the kernel module where it things the 2nd port is RS232 is a
pretty good indication this thing has serious problems!
>>
>> I'll also get an oscilloscope on there to see if anything is
coming off the pins. It's not looking very good...
>>
>> As a last resort I'll put one of the boards in a windoze laptop
and try the windoze driver to see if I can get ports 1 and 2 to
talk to each other. This will at least be a baseline that the
hardware actually works.
>> I'm not really convinced these boards work unfortunately.
>>
>> Is there anyone from systembase you can put me in touch with to
try and get this to work???
>> Any other info would be greatly appreciated... I've been very
thorough about this -- I'm losing confidence quickly
unfortunately. I've made many many serial boards work on linux
(PCI, ISA, USB, etc. etc.) and never had such difficultly was this
one is presenting.
>>
>> I'll get back to you tomorrow, but I'm hoping you might have
some info by the time the first half of your day over in the UK is
over.
>> I'm really hoping I can get this to work -- my only other
option is a board that has only 16550 UARTs which may not work
very well at 460800 bps.
>>
>> --
>> Eric Malkowski
>> MagneMotion, Inc.
>>
>>
------------------------------------------------------------------------