📄 routing_state_cr.m
字号:
function states =routing_state_cr(res)USE_BYTE_OR_N_ENTRY = 1; %=1: use byte, =0: use number of entriesNEXT_HOP_COST = 2; % 2 bytes to store a nexthop entryBYTE_PER_PCR = 2+1+NEXT_HOP_COST; %byte per each pcr routing entry%dest:2, scope:.5, seq:.5, nexthop:2 //no hops needed if use%certain optimizationBYTE_PER_BEACON = 2+1+1+NEXT_HOP_COST;n_beacon = length( res.beacons );if USE_BYTE_OR_N_ENTRY states = res.cluster_cr*BYTE_PER_PCR... + repmat(n_beacon*(BYTE_PER_BEACON), length(res.cluster_cr),1);else states = res.cluster_cr;end
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -