sio0/sio1 swap

Richard Williamson richard.williamson at u4eatech.com
Wed Dec 1 08:17:06 PST 2004


I'm top posting because no one answered the original post
(included below).  I guess this means I'm starting over.

Ok, so I 

set console=vidconsole
boot -h

in my /boot/loader.rc .  This prevents the console messages
from being dumped to the 16x2 LCD.  But I've now lost any
output to the LCD, including the status messages that I 
send specifically (like, "The box is up" for example).

Not optimum.

Also, I've got our cli going to com2 as it should, which is
great.  It outputs a 'FreeBSD blurb' before giving me the
cli login prompt.  Similar to "FreeBSD/i386 (FP2) (ttyp0)"
which is what is dumped if you telnet in.  How do I get
rid of those? Is this what im in the gettytab is for
(initial banner messages).  Assumption made, will test
on next iteration.  

But I'm still in the dark about how to get the LCD screen
to output anything.  Attempts similar to

echo "blah" > /dev/ttyd0 

have no effect.  Calling the ap that is specifically written
to out the control codes for controlling the LCD followed
by the data to be written (this:  /bin/ttyd0_lcd blah snarf 
to output blah on the first line and snarf on the second) has
no effect on the LCD.  (It doesn't appear on com2 either). 
Suggestions?

Regards,
Richard


At 10:54 30/11/2004, you wrote:
>Hello,
>
>I've got a network box.  The motherboard (adlink 2000) has three
>"com" ports (that is what the screen print on the board says:
>com1, com2, com3.
>
>The box I was given for development has com1 wired up to the
>9pin port on the back of the housing, helpfully screen printed
>with 'COM1'.  com2 is wired to a Densan 16x2 LCD front panel
>display.   
>
>Development happened.
>
>Comes time for testing, and it turns out that the box I have
>is "miswired" vis-a-vis the sio ports.  Every other box by
>this manufacturer is wired com1 -> LCD, com2 -> COM1.
>
>My kernel configuration had this:
>
>a) device               sio0    at isa? port IO_COM1 flags 0x10 irq 4
>a) device               sio1    at isa? port IO_COM2 irq 3
>a) device               sio2    at isa? disable port IO_COM3 irq 5
>a) device               sio3    at isa? disable port IO_COM4 irq 9
>
>So now I'm trying to swap the ports at the kernel level so that
>the LCD control characters and data which went to the mb port 
>com2 (sio1) go to com2 (sio0), and the console output moves 
>from com1 (sio0) to com1 (sio1).
>
>I've tried
>
>b) device               sio0    at isa? port IO_COM2 irq 3
>b) device               sio1    at isa? port IO_COM1 flags 0x10 irq 4
>b) device               sio2    at isa? port IO_COM3 irq 5
>b) device               sio3    at isa? disable port IO_COM4 irq 9
>
>and 
>
>c) device               sio0    at isa? port IO_COM2 irq 3
>c) device               sio1    at isa? port IO_COM1 flags 0x30 irq 4
>c) device               sio2    at isa? port IO_COM3 irq 5
>c) device               sio3    at isa? disable port IO_COM4 irq 9
>
>The b) lines resulted in no console output (bad), but serial login on 
>the 9pin COM1 housing port (good) but no LCD output (bad)
>
>the c) lines resulted in no console output, no serial login on
>COM1, and no LCD output (bad, bad, bad).
>
>Is this going to require more changes, elsewhere? And shouldn't
>the b (or c) lines do what I want (console output, serial login and
>LCD output)?  Help?
>
>TIA,
>rip
>
>
>_______________________________________________
>freebsd-questions at freebsd.org mailing list
>http://lists.freebsd.org/mailman/listinfo/freebsd-questions
>To unsubscribe, send any mail to "freebsd-questions-unsubscribe at freebsd.org"




More information about the freebsd-questions mailing list