Changeset b1481d8 in multiio


Ignore:
Timestamp:
Aug 13, 2009, 8:49:38 PM (10 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
master
Children:
ec4156f
Parents:
1b7aa5a
Message:

2009-08-13 Joel Sherrill <joel.sherrill@…>

  • main_pcmmio_irq.c, mio_io.h, mio_io_rtems.c: Add ADCs confirmed to work using the dac command. Both single voltages and a pattern were written.
Location:
pcmmio/original
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • pcmmio/original/ChangeLog

    r1b7aa5a rb1481d8  
     12009-08-13      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * main_pcmmio_irq.c, mio_io.h, mio_io_rtems.c: Add ADCs confirmed to
     4        work using the dac command. Both single voltages and a pattern were
     5        written.
     6
    172009-08-12      Joel Sherrill <joel.sherrill@oarcorp.com>
    28
  • pcmmio/original/main_pcmmio_irq.c

    r1b7aa5a rb1481d8  
    4646  int                 elapsed;
    4747  int                 interrupts;
     48  unsigned long long  timestamp;
    4849
    4950  /*
     
    162163  interrupts = 0;
    163164
     165  flush_buffered_ints();
    164166  while (1) {
    165167    sc = 0;
    166168   
    167169    if ( do_din == true ) {
    168       sc = wait_dio_int_with_timeout(milliseconds);
     170      sc = wait_dio_int_with_timestamp(milliseconds, &timestamp);
    169171    } else if ( do_dac == true ) {
    170172      sc = wait_dac_int_with_timeout(dac, milliseconds);
     
    176178      interrupts++;
    177179      if ( do_din == true )
    178         printf( "%d %s irq pin %d\n", elapsed, irq, sc );
     180        printf( "%d %s irq pin %d @ %llx\n", elapsed, irq, sc, timestamp );
    179181      else
    180182        printf( "%d %s irq\n", elapsed, irq );
  • pcmmio/original/mio_io.h

    r1b7aa5a rb1481d8  
    198198  );
    199199
     200  void flush_buffered_ints(void);
    200201  int wait_adc_int_with_timeout(int adc_num, int milliseconds);
    201202  int wait_dac_int_with_timeout(int dac_num, int milliseconds);
    202203  int wait_dio_int_with_timeout(int milliseconds);
    203 #endif
    204 
     204  int wait_dio_int_with_timestamp(
     205    int                 milliseconds,
     206    unsigned long long *timestamp
     207  );
     208#endif
     209
  • pcmmio/original/mio_io_rtems.c

    r1b7aa5a rb1481d8  
    383383}
    384384
    385 int wait_dio_int_with_timeout(int milliseconds)
     385int wait_dio_int_with_timestamp(
     386  int                 milliseconds,
     387  unsigned long long *timestamp
     388)
    386389{
    387390  int i;
     
    398401    return sc;
    399402
    400   i = get_buffered_int(NULL);
     403  i = get_buffered_int(timestamp);
    401404
    402405  return i;
    403406}
    404407
     408int wait_dio_int_with_timeout(int milliseconds)
     409{
     410  return wait_dio_int_with_timestamp(milliseconds, NULL);
     411}
     412
    405413int wait_dio_int(void)
    406414{
    407   return wait_dio_int_with_timeout(0);
     415  return wait_dio_int_with_timestamp(0, NULL);
    408416}
    409417
     
    548556)
    549557{
     558  /* reset discrete interrupt input counters */
     559  flush_buffered_ints();
     560
    550561  /* hardware configuration information */
    551562  base_port = _base_port;
     
    793804}
    794805
     806void flush_buffered_ints(void)
     807{
     808  inptr = 0;
     809  outptr = 0;
     810}
     811
    795812int get_buffered_int(
    796813  unsigned long long *timestamp
Note: See TracChangeset for help on using the changeset viewer.