Ignore:
Timestamp:
Apr 14, 2011, 12:47:57 PM (14 years ago)
Author:
george
Message:
  • Modified: MicroThreading replaced by TListedThread classic thread implementation.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • PinConnection/UPacketBurst.pas

    r171 r231  
    77uses
    88  Classes, UCommPin, SyncObjs, UStreamHelper, UCommon, SysUtils,
    9   UMicroThreading, DateUtils;
     9  DateUtils;
    1010
    1111type
    1212  TPacketBurst = class;
    1313
    14   TPacketBurstSendThread = class(TMicroThread)
     14  TPacketBurstSendThread = class(TThread)
    1515    PacketBurst: TPacketBurst;
    1616    procedure Execute; override;
     
    2222  private
    2323    FActive: Boolean;
    24     SendThreadEvent: TMicroThreadEvent;
     24    SendThreadEvent: TEvent;
    2525    SendThread: TPacketBurstSendThread;
    2626    SendStreamLock: TCriticalSection;
     
    3131    procedure SetActive(const AValue: Boolean);
    3232  public
    33     SendPeriod: TDateTime;
     33    SendPeriod: Integer;
    3434    SendBurstSize: Integer;
    3535    PacketSinglePin: TCommPin;
     
    5050  PacketBurstPin := TCommPin.Create;
    5151  PacketBurstPin.OnReceive := PacketBurstReceive;
    52   SendThreadEvent := TMicroThreadEvent.Create;
    53   SendPeriod := OneMillisecond;
     52  SendThreadEvent := TSimpleEvent.Create;
     53  SendPeriod := 1;
    5454end;
    5555
     
    9393    SendThread.FreeOnTerminate := False;
    9494    SendThread.PacketBurst := Self;
    95     SendThread.Name := 'PacketBurst';
     95    //SendThread.Name := 'PacketBurst';
    9696    SendThread.Start;
    9797  end else begin
Note: See TracChangeset for help on using the changeset viewer.