Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • shivaraj.kandhasamy/advligorts
  • gerritkuehn/advligorts
  • ezekiel.dohmen/advligorts
  • michael.thomas/advligorts
  • christopher.wipf/advligorts
  • erik.vonreis/advligorts
  • keith-thorne/advligorts
  • jonathan-hanks/advligorts
  • jameson.rollins/advligorts
  • rolf.bork/advligorts
  • cds/software/advligorts
11 results
Show changes
Commits on Source (3)
......@@ -4,6 +4,7 @@ Changes for NEXT
- Fixed bug in ADC read when IOP rate was slower than ADC rate.
- Fixed virtualIOP parameter. Virtual IOPs now build and run.
- Fixed bug that leads to incorrect ordering of calculations, adding unneeded latency.
- Awgtpman now fails gracefully if there's an IOP mbuf version mis-match or the IOP is not running.
==================================================================================================
Changes for 4.2.3
==================================================================================================
......
......@@ -375,6 +375,11 @@ CDS_HARDWARE cdsPciModules;
printf( "mem_data_rate is %u\n", ioMemData->mem_data_rate );
printf( "iodata index=%d\n", ll );
printf( "IO_MEM_DATA_SIZE=%d\n", sizeof( IO_MEM_DATA ) );
if(ioMemData->mem_data_rate <= 0)
{
fprintf(stderr,"*** WARNING: IOP data rate was not detected.\n"
"\tEither the IOP is not running, or there is a version mismatch betwen the IOP and awgtpman\n");
}
}
else
{
......
......@@ -367,7 +367,7 @@ unsigned int curDaqBlockSize;
}
else
{
printf("Using IOP timng\n");
printf("Using IOP timing\n");
}
/* assign default ISR if argument is NULL */
......@@ -524,13 +524,15 @@ unsigned int curDaqBlockSize;
printf("waiting to sync %d\n", *ioMemDataCycle);
// Spin until cycle 0 detected in first ADC buffer location.
int spin_cnt = 0;
do {
struct timespec cycle_wait={0, 1000000}; //1 msec
while (*ioMemDataCycle != 0) {
nanosleep(&cycle_wait, 0);
spin_cnt++;
if (spin_cnt >= 1000000000) {
sleep(10);
spin_cnt = 0;
if (spin_cnt >= 10000) {
fprintf(stderr, "Timed out waiting for cycle counter to return to zero.\n");
_exit(3);
}
} while (*ioMemDataCycle != 0);
}
// Get GPS seconds from MASTER
int timeSec = *ioMemDataGPS;
......@@ -538,6 +540,21 @@ unsigned int curDaqBlockSize;
printf("TimeSec=%d; cycle=%d\n", timeSec, *ioMemDataCycle);
int samples_per_second = *ioMemDataRate_sps;
int wait_rate=0;
printf("samples_per_second=%d\n", samples_per_second);
while(samples_per_second <= 0)
{
if(wait_rate >= 30)
{
fprintf(stderr, "Timed out waiting for the IOP data rate\n");
_exit(2);
}
sleep(1);
++wait_rate;
samples_per_second = *ioMemDataRate_sps;
printf("samples_per_second=%d\n", samples_per_second);
}
int samples_per_cycle = samples_per_second / DAQ_NUM_DATA_BLOCKS_PER_SECOND;
while (1) {
......
......@@ -345,7 +345,7 @@ static char *versionId = "Version $Id$" ;
#ifndef _TP_DAQD
// do we know the time yet?
if(! (ioMemDataRate_sps || *ioMemDataRate_sps))
if((!ioMemDataRate_sps || !*ioMemDataRate_sps))
{
return 0;
}
......