cloudFPGA (cF) API
1.0
The documentation of the source code of cloudFPGA (cF)
|
Functions | |
def | num_to_char (num) |
def | str_static_gen (size) |
def | str_rand_gen (size) |
def | getFpgaIpv4 (args) |
def | getFpgaPort (args) |
def | getResourceManagerIpv4 (args) |
def | getResourceManagerPort (args) |
def | getInstanceId (args) |
def | restartApp (instId, ipResMngr, portResMngr, user_name, user_passwd) |
def | pingFpga (ipFpga) |
def | display_throughput (byteCount, elapseTime) |
Variables | |
int | ACM_OK = 0 |
int | ACM_KO = 1 |
int | MTU = 1500 |
int | MTU_ZYC2 = 1450 |
int | IP4_HDR_LEN = 20 |
int | TCP_HDR_LEN = 20 |
tuple | ZYC2_MSS = (MTU_ZYC2 - 92) & ~0x7 |
int | UDP_HDR_LEN = 8 |
tuple | UDP_MDS = (MTU_ZYC2 - IP4_HDR_LEN - UDP_HDR_LEN) & ~0x7 |
int | RECV_MODE_LSN_PORT = 8800 |
int | XMIT_MODE_LSN_PORT = 8801 |
int | BIDIR_MODE_LSN_PORT = 8802 |
int | ECHO_MODE_LSN_PORT = 8803 |
int | IPERF_LSN_PORT = 5001 |
int | IPREF3_LSN_PORT = 5201 |
def tc_utils.display_throughput | ( | byteCount, | |
elapseTime | |||
) |
Display the throughput in human readable form. :param byteCount: The number of bytes transferred. :param elapseTime: The duration of the transfer. :return: Nothing
Definition at line 211 of file tc_utils.py.
def tc_utils.getFpgaIpv4 | ( | args | ) |
Retrieve the IPv4 address of the FPGA module. :param args The options passed as arguments to the script. :return The IPv4 address as an 'ipaddress.IPv4Address'.
Definition at line 95 of file tc_utils.py.
def tc_utils.getFpgaPort | ( | args | ) |
Retrieve the UDP listen port of the FPGA. :param args The options passed as arguments to the script. :return The UDP port number as an integer.
Definition at line 113 of file tc_utils.py.
def tc_utils.getInstanceId | ( | args | ) |
Retrieve the instance Id that was assigned by the cloudFPGA Resource Manager. :param args The options passed as arguments to the script. :return The instance Id as an integer.
Definition at line 153 of file tc_utils.py.
def tc_utils.getResourceManagerIpv4 | ( | args | ) |
Retrieve the IPv4 address of the cloudFPGA Resource Manager. :param args The options passed as arguments to the script. :return The IP address as an 'ipaddress.IPv4Address'.
Definition at line 124 of file tc_utils.py.
def tc_utils.getResourceManagerPort | ( | args | ) |
Retrieve the TCP port of the cloudFPGA Resource Manager. :param args The options passed as arguments to the script. :return The TCP port number as an integer.
Definition at line 142 of file tc_utils.py.
def tc_utils.num_to_char | ( | num | ) |
Function to map a number to a character.
Definition at line 70 of file tc_utils.py.
def tc_utils.pingFpga | ( | ipFpga | ) |
Ping an FPGA. :param ipFpga: The IPv4 address of the FPGA. :return: Nothing
Definition at line 199 of file tc_utils.py.
def tc_utils.restartApp | ( | instId, | |
ipResMngr, | |||
portResMngr, | |||
user_name, | |||
user_passwd | |||
) |
Trigger the role of an FPGA to restart (i.e. perform a SW reset of the role) :param instId: The instance Id to restart. :param ipResMngr: The IPv4 address of the cF resource manager. :param portResMngr: The TCP port number of the cF resource manager. :param user_name: The user name as used to log in ZYC2. :param user_passwd: The ZYC2 password attached to the user name. :return: Nothing
Definition at line 174 of file tc_utils.py.
def tc_utils.str_rand_gen | ( | size | ) |
def tc_utils.str_static_gen | ( | size | ) |
Returns an encoded static string of length 'size'.
Definition at line 79 of file tc_utils.py.
int tc_utils.ACM_KO = 1 |
Definition at line 36 of file tc_utils.py.
int tc_utils.ACM_OK = 0 |
Definition at line 35 of file tc_utils.py.
int tc_utils.BIDIR_MODE_LSN_PORT = 8802 |
Definition at line 65 of file tc_utils.py.
int tc_utils.ECHO_MODE_LSN_PORT = 8803 |
Definition at line 66 of file tc_utils.py.
int tc_utils.IP4_HDR_LEN = 20 |
Definition at line 40 of file tc_utils.py.
int tc_utils.IPERF_LSN_PORT = 5001 |
Definition at line 67 of file tc_utils.py.
int tc_utils.IPREF3_LSN_PORT = 5201 |
Definition at line 68 of file tc_utils.py.
int tc_utils.MTU = 1500 |
Definition at line 38 of file tc_utils.py.
int tc_utils.MTU_ZYC2 = 1450 |
Definition at line 39 of file tc_utils.py.
int tc_utils.RECV_MODE_LSN_PORT = 8800 |
Definition at line 63 of file tc_utils.py.
int tc_utils.TCP_HDR_LEN = 20 |
Definition at line 41 of file tc_utils.py.
int tc_utils.UDP_HDR_LEN = 8 |
Definition at line 43 of file tc_utils.py.
tuple tc_utils.UDP_MDS = (MTU_ZYC2 - IP4_HDR_LEN - UDP_HDR_LEN) & ~0x7 |
Definition at line 44 of file tc_utils.py.
int tc_utils.XMIT_MODE_LSN_PORT = 8801 |
Definition at line 64 of file tc_utils.py.
tuple tc_utils.ZYC2_MSS = (MTU_ZYC2 - 92) & ~0x7 |
Definition at line 42 of file tc_utils.py.