Error: Xiron OS failed to create a process!

239 views
Skip to first unread message

Bodo

unread,
Apr 28, 2011, 2:59:51 AM4/28/11
to OpenNI
Hello!

I've got an issue with Xiron OS. The NIUserTracker compiles and runs
without errors. I'm using the copied code in my framework and receive
a different result. Maybe someone of you has an idea what to try or
how to deal with this:


XnStatus nRetVal = XN_STATUS_OK;

xn::EnumerationErrors errors;
nRetVal = g_Context.InitFromXmlFile(SAMPLE_XML_PATH, &errors);

=> At this point is nRetVal == 131205

if (nRetVal != XN_STATUS_OK) printf("Open failed: %s\n",
xnGetStatusString(nRetVal));

=> will result in:
Open failed: Xiron OS failed to create a process!


PS: I'm using Windows 7 and VisualStudio 2010

Niek

unread,
Apr 28, 2011, 3:53:10 AM4/28/11
to OpenNI
Bodo,

have you tried itterating over the errors and see what is in there. It
will often give you more information on what is wrong.

However it might be that errors is empty. I had that once and it meant
that he could not find the xml file that SAMPLE_XML_PATH indicates. A
nice piece of code to check this is:

#include <stdio.h>
#include <stdlib.h>

#define FILE_CHECK( file ) { \
std::FILE* tmp = std::fopen( file, "r" ); \
if ( tmp == NULL ) { \
std::cout << ""File \"" << file \
<< "\" does not exist!\n"; } \
fclose (tmp); } \


I have not checked whether this code works. If not than just copy the
code to method you need to check the path. But all in all
SAMPLE_XML_PATH in the examples contain "../../../Data/
SamplesConfig.xml" and that probably does not work for your project.

m.v.g.

Niek

Bodo

unread,
Apr 28, 2011, 4:08:46 AM4/28/11
to OpenNI
Hello Niek,

thanks for the quick response. I had trouble with the path earlier,
this gave me an error about missing xml file. In addition I tried your
code, it verified me, that the xml file is in its place and is found.

I found some additional details to my issue

- if NIUserTracker is started first it creates a process
(XnSensorServer.exe) which allows my program to run without error

maybe this helps to locate the error?

> have you tried iterating over the errors and see what is in there
is there a chance to print all error messages for the code 131205 or
is this error only for "Xiron OS failed to create a process" ?

Bodo

Niek

unread,
Apr 28, 2011, 4:32:17 AM4/28/11
to OpenNI
You can print every error by using the itteration functionality and
the ToString method in the EnumerationErrors class.

xn::EnumerationErrors::Iterator it;
i = 0;
for( it = errors.Begin(); it != errors.End(); it++, i++)
{
std::cout << i << ") " << xnGetStatusString((*it).Error()) <<
"\n ";

XnProductionNodeDescription pnd = (*it).Description();
std::cout << //print all the info in the production Node.
}

For the rest I don't think I can help you any further. With me it was
a path problem.

m.v.g.

Niek

Bodo

unread,
May 2, 2011, 5:00:13 AM5/2/11
to OpenNI
When I start XnSensorServer.exe from the PrimeSense/Sensor/Bin
directory the Server stays on for some seconds.

If my code is started within this time window it functions. If too
late, the server is down again.

Does anyone know command line options for the server? It would solve
my problem if there is an option not to shut down automatically.

Ziv Hendel

unread,
May 3, 2011, 2:26:17 AM5/3/11
to OpenNI
The timeout is located in this file:
"c:\Program Files\PrimeSense\Sensor\Data\GlobalDefaults.ini"

The parameter is called "ServerNoClientsTimeout"

Ziv.
Reply all
Reply to author
Forward
0 new messages