MCPcopy Create free account
hub / github.com/EIPStackGroup/OpENer / GetPriorityForSocket

Function GetPriorityForSocket

source/src/cip/cipqos.c:91–112  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

89}
90
91CipUsint GetPriorityForSocket(ConnectionObjectPriority priority) {
92
93 CipUsint priority_value = dscp_explicit;
94 switch (priority) {
95 case kConnectionObjectPriorityLow:
96 priority_value = dscp_low;
97 break;
98 case kConnectionObjectPriorityHigh:
99 priority_value = dscp_high;
100 break;
101 case kConnectionObjectPriorityScheduled:
102 priority_value = dscp_scheduled;
103 break;
104 case kConnectionObjectPriorityUrgent:
105 priority_value = dscp_urgent;
106 break;
107 default:
108 priority_value = dscp_explicit;
109 break;
110 }
111 return priority_value;
112}
113
114void InitializeCipQos(CipClass *class) {
115 CipClass *meta_class = class->class_instance.cip_class;

Callers 2

CreateUdpSocketFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected