Skip to content
Snippets Groups Projects
Commit d4040e7e authored by Jonathan Hanks's avatar Jonathan Hanks
Browse files

Added more error checking to the standalone_edcu

parent 866365f9
No related branches found
No related tags found
No related merge requests found
......@@ -554,7 +554,11 @@ edcuCreateChanList( const char* daqfilename, const char* edculogfilename )
printf( "CRC data length = %d\n", xferInfo.crcLength );
chid chid1;
ca_context_create( ca_enable_preemptive_callback );
if (ca_context_create( ca_enable_preemptive_callback ) != ECA_NORMAL)
{
fprintf(stderr, "Error creating the EPCIS CA context\n");
exit(1);
}
for ( i = 0; i < daqd_edcu1.num_chans; i++ )
{
......@@ -583,6 +587,11 @@ edcuCreateChanList( const char* daqfilename, const char* edculogfilename )
(void*)&(daqd_edcu1.channel_status[i]),
0,
&chid1 );
if (status != ECA_NORMAL)
{
fprintf(stderr, "Error creating connection to %s\n",
daqd_edcu1.channel_name[ i ]);
}
status = ca_create_subscription( DBR_FLOAT,
0,
chid1,
......@@ -590,6 +599,11 @@ edcuCreateChanList( const char* daqfilename, const char* edculogfilename )
subscriptionHandler,
(void*)&(daqd_edcu1.channel_value[i]),
0 );
if (status != ECA_NORMAL)
{
fprintf(stderr, "Error creating subscription for %s\n",
daqd_edcu1.channel_name[ i ]);
}
}
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment