這是我的工作酸甜苦辣,與大家分享,希望彼此都有收穫:) This is my working experience in my life. It is good to share with you :)
Tuesday, March 14, 2017
Thursday, October 27, 2016
Monday, June 27, 2016
strcat() like in AWK language
str_var = "abc"
str_var = str_var "your new string"
Please refer to
http://www.unix.com/unix-for-dummies-questions-and-answers/12459-awk-question.html
str_var = str_var "your new string"
Please refer to
http://www.unix.com/unix-for-dummies-questions-and-answers/12459-awk-question.html
Sunday, June 26, 2016
Friday, April 1, 2016
OMNeT++/OMNEST priority schedule for the event at the same time
In OMNeT++/OMNEST, sometimes two events may arrive at the same time. However, the OMNeT++/OMNEST can only handle both events in sequence based on the arrival time of each event. If we hope to always handle a event before the other event, we can use the following function to handle this problem.
where p is the priority, the smaller number of p has higher priority.
refer to.
https://omnetpp.org/doc/omnetpp/api/classcMessage.html#a205278b4eaf8a54a901537f6e6cfae59
Examples:
cMessage *timer1 = new cMessage("tiemr1");
cMessage *timer2 = new cMessage("tiemr2");
timer1->setSchedulingPriority(1); // lower priority
timer1->setSchedulingPriority(-1); // high priority
send(timer1, Gate);
send(timer2, Gate);
setSchedulingPriority(short p)
where p is the priority, the smaller number of p has higher priority.
refer to.
https://omnetpp.org/doc/omnetpp/api/classcMessage.html#a205278b4eaf8a54a901537f6e6cfae59
Examples:
cMessage *timer1 = new cMessage("tiemr1");
cMessage *timer2 = new cMessage("tiemr2");
timer1->setSchedulingPriority(1); // lower priority
timer1->setSchedulingPriority(-1); // high priority
send(timer1, Gate);
send(timer2, Gate);
Thursday, March 24, 2016
查詢當下linux folder中資料夾的大小
請下這個指令
du -B M . --max-depth=1 | sort -g
http://nathanmint.pixnet.net/blog/post/178733376-linux---du%E6%8C%87%E4%BB%A4-:-%E6%AA%A2%E6%9F%A5%E5%90%84%E5%80%8B%E8%B3%87%E6%96%99%E5%A4%BE%E7%9A%84%E6%AA%94%E6%A1%88%E5%A4%A7%E5%B0%8F%EF%BC%9B
du -B M . --max-depth=1 | sort -g
http://nathanmint.pixnet.net/blog/post/178733376-linux---du%E6%8C%87%E4%BB%A4-:-%E6%AA%A2%E6%9F%A5%E5%90%84%E5%80%8B%E8%B3%87%E6%96%99%E5%A4%BE%E7%9A%84%E6%AA%94%E6%A1%88%E5%A4%A7%E5%B0%8F%EF%BC%9B
Thursday, March 10, 2016
Source Insight無法讀取.cc檔
當你load檔時,發現缺少.cc的載入怎麼辦
照著這個步驟
1. 打開Options -> Document Options,
2. 在Document Type選擇C++ Source File
3. 在File Filter中加入 ;*.cc
在sync一次應該就出現拉XD
照著這個步驟
1. 打開Options -> Document Options,
2. 在Document Type選擇C++ Source File
3. 在File Filter中加入 ;*.cc
在sync一次應該就出現拉XD
Subscribe to:
Posts (Atom)