Changeset 1690c6b in rtems for c/src/lib/libbsp/i386


Ignore:
Timestamp:
Jul 21, 1995, 8:10:49 PM (25 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
2f2a597
Parents:
9e738b65
Message:

after testing go32 and cvme961

Location:
c/src/lib/libbsp/i386/go32/timer
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/i386/go32/timer/timer.c

    r9e738b65 r1690c6b  
    4141#else /* pentium */
    4242rtems_isr timerisr();
     43
     44#define TIMER_ISR_US  10000
     45
    4346#endif /* pentium */
    4447
     
    7578       WAIT();
    7679
    77        /* load timer for 250 microsecond period */
     80       /* load timer for TIMER_ISR_US microsecond period */
    7881       outport_byte( TIMER_MODE, TIMER_SEL0|TIMER_16BIT|TIMER_RATEGEN );
    79        outport_byte( TIMER_CNTR0, US_TO_TICK(250) >> 0 & 0xff);
    80        outport_byte( TIMER_CNTR0, US_TO_TICK(250) >> 8 & 0xff);
     82       outport_byte( TIMER_CNTR0, US_TO_TICK(TIMER_ISR_US) >> 0 & 0xff);
     83       outport_byte( TIMER_CNTR0, US_TO_TICK(TIMER_ISR_US) >> 8 & 0xff);
    8184    }
    8285
     
    102105    inport_byte( TIMER_CNTR0, msb );
    103106    clicks = msb << 8 | lsb;
    104     total = Ttimer_val + (250 - TICK_TO_US( clicks ));
     107    total = (Ttimer_val * TIMER_ISR_US) + (TIMER_ISR_US - TICK_TO_US( clicks ));
    105108#endif /* pentium */
    106109
  • c/src/lib/libbsp/i386/go32/timer/timerisr.s

    r9e738b65 r1690c6b  
    2828
    2929SYM (timerisr):
    30         addl    $250,_Ttimer_val   # another 250 microseconds
     30        addl    $1,_Ttimer_val   # another tick
    3131        push    edx
    3232        push    eax
Note: See TracChangeset for help on using the changeset viewer.