Commit a6ba8861 authored by Andreas Schmidt's avatar Andreas Schmidt
Browse files

+= expose additional paces via Cython

parent 4e8f2461
Loading
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -12,7 +12,7 @@

#define PROBE_GAIN 1.1
#define DRAIN_GAIN 0.9
#define RTpropFilterLen 10000000    //10s
#define RTpropFilterLen 2000000    //10s
#define BBRHighGain ((((float)2885) / 1000) + 1)
#define BBRGainCycleLen 8
#define ProbeRTTDuration 200000 //200ms
+7 −2
Original line number Diff line number Diff line
@@ -161,11 +161,13 @@ class PrrtPace:
        return self.internal + self.external - self.dependent

class PrrtPaces:
    def __init__(self, appSend, prrtTransmit, prrtReceive, appDeliver):
    def __init__(self, appSend, prrtTransmit, prrtReceive, appDeliver, peerPace, networkPace):
        self.appSend = appSend
        self.prrtTransmit = prrtTransmit
        self.prrtReceive = prrtReceive
        self.appDeliver = appDeliver
        self.peerPace = peerPace
        self.networkPace = networkPace

cdef class PrrtSocket:
    cdef cprrt.PrrtSocket* _c_socket
@@ -238,7 +240,10 @@ cdef class PrrtSocket:
                                  cprrt.PrrtSocket_get_sock_opt(self._c_socket, "appDeliver_pace_dependent") * 0.000001,
                                  cprrt.PrrtSocket_get_sock_opt(self._c_socket, "appDeliver_pace_external") * 0.000001)

            return PrrtPaces(appSend, prrtTransmit, prrtReceive, appDeliver)
            peerPace = cprrt.PrrtSocket_get_sock_opt(self._c_socket, "recv_peer_btl_pace") * 0.000001
            networkPace =  cprrt.PrrtSocket_get_sock_opt(self._c_socket, "nw_pace") * 0.000001

            return PrrtPaces(appSend, prrtTransmit, prrtReceive, appDeliver, peerPace, networkPace)

    property nw_pace:
        def __get__(self):
+1 −1

File changed.

Contains only whitespace changes.

+8 −8

File changed.

Contains only whitespace changes.