[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.

Other related posts: