Obtain process info in QNX6 app like qnx_psinfo

I need to obtain basic process information on my running tasks from within my application. I found qnx_psinfo which is supported in QNX4. Does any one know what can be used in QNX 6?

I would think I could reference /proc but I am not sure what structures I could use to obtain process info.

I want to create a simple process that will monitor the rest of the tasks running. I would like to log the current running process in a log file and allow it to be dumped out a serial port to be viewed realtime.

thanks in advance for any help.

In QNXNTO you have to fopen the numerals in /proc.
After that you can send requests via devctl
devctl(proc_fd, DCMD_PROC_INFO, &process, sizeof(process), NULL) – this is process information, process is type procfs_info
devctl(proc_fd, DCMD_TIDSTATUS, &thread, sizeof(thread), NULL) – this is status information on Threads within the given process
there is also DCMD_PROC_MAPDEBUG_BASE wich requires a dinfo_s structure and is used for inforamtion as process_name (executing app), parent-process …

A very good start for this is to take a look into the sources of the migration compatibility library including qnx_psinfo