How to get total service time of all servers in Omnet++? -


               simtime_t servicetime= par("servicetime");                totalservicetime=totalservicetime+servicetime;                           ev<<"service time= "<<servicetime<<endl;                            ev<<"total service time= "<<totalservicetime<<endl; 

this code wrote give me total service time of servers. gives me accumulates service times of each server in same variable. don't know total service time of servers. initialized totalservicetime 0 in initialize(). thank you!

the way understand question have multiple server modules in simulation. way total service time of them using signals (described in omnet++ manual in chapter 4.14).

to need emit signals containing service time of each server. create separate module within network listens signals emitted servers , accumulates service time of them.


Comments

Popular posts from this blog

Retrieving ETA (estimated time of arrival) with Google Distance Matrix API and public transit as transport mode -

javascript - Confirm a form & display message if form is valid with JQuery -

ionic framework - Meteor - Error: Failed to execute 'insertBefore' on 'Node' -