mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-06 01:50:40 +02:00
ctb server: simulator effects, increased fpga reset time from 1 to 2 seconds
This commit is contained in:
parent
29141ac1a6
commit
17f745b45d
Binary file not shown.
@ -1523,7 +1523,7 @@ int configureMAC(uint32_t destip, uint64_t destmac, uint64_t sourcemac, uint32_t
|
||||
memset(cDestIp, 0, MAX_STR_LENGTH);
|
||||
sprintf(cDestIp, "%d.%d.%d.%d", (destip>>24)&0xff,(destip>>16)&0xff,(destip>>8)&0xff,(destip)&0xff);
|
||||
FILE_LOG(logINFO, ("1G UDP: Destination (IP: %s, port:%d)\n", cDestIp, udpport));
|
||||
if (setUDPDestinationDetails(cDestIp, udpport) == FAIL) {
|
||||
if (setUDPDestinationDetails(0, cDestIp, udpport) == FAIL) {
|
||||
FILE_LOG(logERROR, ("could not set udp 1G destination IP and port\n"));
|
||||
return FAIL;
|
||||
}
|
||||
@ -2146,7 +2146,7 @@ int startStateMachine(){
|
||||
// 1 giga udp
|
||||
if (!enableTenGigabitEthernet(-1)) {
|
||||
// create udp socket
|
||||
if(createUDPSocket() != OK) {
|
||||
if(createUDPSocket(0) != OK) {
|
||||
return FAIL;
|
||||
}
|
||||
// update header with modId, detType and version. Reset offset and fnum
|
||||
@ -2265,9 +2265,9 @@ void readandSendUDPFrames(int *ret, char *mess) {
|
||||
FILE_LOG(logDEBUG1, ("Reading from 1G UDP\n"));
|
||||
|
||||
// validate udp socket
|
||||
if (getUdPSocketDescriptor() <= 0) {
|
||||
if (getUdPSocketDescriptor(0) <= 0) {
|
||||
*ret = FAIL;
|
||||
sprintf(mess,"UDP Socket not created. sockfd:%d\n", getUdPSocketDescriptor());
|
||||
sprintf(mess,"UDP Socket not created. sockfd:%d\n", getUdPSocketDescriptor(0));
|
||||
FILE_LOG(logERROR, (mess));
|
||||
return;
|
||||
}
|
||||
@ -2276,14 +2276,14 @@ void readandSendUDPFrames(int *ret, char *mess) {
|
||||
while(readFrameFromFifo() == OK) {
|
||||
int bytesToSend = 0, n = 0;
|
||||
while((bytesToSend = fillUDPPacket(udpPacketData))) {
|
||||
n += sendUDPPacket(udpPacketData, bytesToSend);
|
||||
n += sendUDPPacket(0, udpPacketData, bytesToSend);
|
||||
}
|
||||
if (n >= dataBytes) {
|
||||
FILE_LOG(logINFO, (" Frame %lld sent (%d packets, %d databytes, n:%d bytes sent)\n",
|
||||
udpFrameNumber, udpPacketNumber + 1, dataBytes, n));
|
||||
}
|
||||
}
|
||||
closeUDPSocket();
|
||||
closeUDPSocket(0);
|
||||
}
|
||||
|
||||
|
||||
|
@ -6,7 +6,7 @@
|
||||
#define MIN_REQRD_VRSN_T_RD_API 0x181130
|
||||
#define REQRD_FRMWR_VRSN 0x190402
|
||||
|
||||
#define CTRL_SRVR_INIT_TIME_US (1 * 1000 * 1000)
|
||||
#define CTRL_SRVR_INIT_TIME_US (2 * 1000 * 1000)
|
||||
|
||||
/* Struct Definitions */
|
||||
typedef struct ip_header_struct {
|
||||
|
@ -5,6 +5,6 @@
|
||||
#define APILIB 0x190405
|
||||
#define APIRECEIVER 0x190405
|
||||
#define APIGUI 0x190405
|
||||
#define APICTB 0x190528
|
||||
#define APIEIGER 0x190531
|
||||
#define APIJUNGFRAU 0x190531
|
||||
#define APICTB 0x190603
|
||||
|
Loading…
x
Reference in New Issue
Block a user