[openbeos] Re: dprintf help

>En réponse à Axel Dörfler  <axeld@xxxxxxxxxxxxxxxx>:
>
>> Eike Dehling <e.e.dehling@xxxxxxxxxxxxxxxxxx> wrote:
>> > I tried making a device driver for in the kernel, it works for 
some 
>> > parts, 
>> > but of course there are bugs ...
>> > I tried using dprintf (),  and then doing 'cat /dev/dprintf' ,but 
>> > nothing 
>> > seemed to happen.
>> > i first did "cat /dev/dprinf", and then ran my test program. The 
code
>> 
>> > i 
>> > used to do dprintf was like this:
>> 
>> I don't know if there are other ways, but you can do it like this:
>> - enable syslog output in the kernel settings file (~/config/
settings/
>> kernel/drivers/kernel), reboot
>> - open a terminal and do "tail -fname /var/log/syslog" and you'll 
see 
>> your debug output
>> 
>
>Right,
>AFAIK /dev/dprintf is intended to _send_ text from userland to the 
syslog.
>(which would be simpler to redirect to /var/log/syslog, but this way 
it 
>wouldn't appear on the serial port.
>
>François.

It is possible to see the debugging as it happens, I was given the 
following instructions to help me develop RAMDISK and it did work.

=======================================================================
================

Another useful hint from Carlos

From: Carlos Hasan
Sent: Sunday, May 14, 2000 11:03 PM
To: earlcp@xxxxxxxxxxx
Subject: Re: ram drive

Btw, if you don't have another PC to debug the driver through the 
serial line and dprintf(), do the following:

- Press F1 when you boot BeOS, and enable the output console
- Open a Terminal window and type:

        tail -f /var/log/syslog

You will see the messages printed with dprintf() in your Terminal.

Carlos

=======================================================================
================


           Earl Colby Pottinger

Other related posts: