<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div>Can you also post the actual error message? </div><div><br></div><div>I have a small suspicion that including <ns3/packet.h> will solve the problem, but cannot be sure without  a little bit more context.<br><br>---<div>Alex</div></div><div><br>On Apr 18, 2013, at 6:58 PM, 王宁 <<a href="mailto:wnbupt9@gmail.com">wnbupt9@gmail.com</a>> wrote:<br><br></div><blockquote type="cite"><div><div dir="ltr"><div><div>the following  is my code : <br></div><div><br>  1. //generate CA_Packet<br><br>      ndn::CAHeader caheader;<br>      NameComponents name=header->GetName();<br>      caheader.SetName(&name);<br>
      caheader.SetScope(0xFF);<br>      caheader.SetCA_TTL(0);<br>      caheader.SetNonce(0);<br>      caheader.SetNack(0);<br>      Ptr<Packet>packet = Create<Packet>();<br>      packet->AddHeader (caheader);<br>
      NS_LOG_DEBUG ("Sending CA packet for"<<header ->GetName());<br><br></div>2.//send CA_PACKET<br><br>        Ptr<L3Protocol> ndn = this->GetObject<L3Protocol> ();<br>      for (uint32_t faceNum = 0; faceNum < ndn->GetNFaces (); faceNum++)<br>
      {<br>        Ptr<Face> face = ndn->GetFace (faceNum);<br>        face->Send(packet);<br>     }<br><br><br></div>when i use the following code  to send packet ,the packet type can be resolved:<br><br><div>
      BOOST_FOREACH(const fib::FaceMetric &metricFace,pitEntry->GetFibEntry ()->m_faces.get<fib::i_metric> ())<br>      {<br>         metricFace.m_face->Send(packet);<br>      }<br><br><div><br></div></div>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/4/19 Alex Afanasyev <span dir="ltr"><<a href="mailto:alexander.afanasyev@ucla.edu" target="_blank">alexander.afanasyev@ucla.edu</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word"><div>I'm not quite sure what is the relation between ndn->GetNFaces() and new type of packet you created.  Would it be possible if you post some code, so I can check what is going wrong?</div>
<div><br></div><div>---</div><div>Alex</div><div class="im"><br><div><div>On Apr 18, 2013, at 2:09 AM, 王宁 <<a href="mailto:wnbupt9@gmail.com" target="_blank">wnbupt9@gmail.com</a>> wrote:</div><br><blockquote type="cite">
<div dir="ltr">hi,thank you for your answers . Since i define a new packet,so when i use 'ndn->GetNFaces ()'  sending to all faces,   when the node recevice the packet ,it cannot  get the type of my new packet, i define the new packet in ndn-header-helper.cc  ndn-header-helper.h  , so what should i do ? </div>

<div class="gmail_extra"><br><br><div class="gmail_quote">2013/4/18 Alex Afanasyev <span dir="ltr"><<a href="mailto:alexander.afanasyev@ucla.edu" target="_blank">alexander.afanasyev@ucla.edu</a>></span><br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">

<div style="word-wrap:break-word"><div>Is there a reason for not adding information about forwarding to the node's neighbor to the FIB?  FIB suppose to be just a database for all available paths to where you can send Interests for specific (or all) prefixes, maintaining data plane performance characteristics for each face.</div>

<div><br></div><div>If you really want to do that, it is still possible if you write a custom strategy (<a href="http://ndnsim.net/fw.html#writing-your-own-custom-strategy" target="_blank">http://ndnsim.net/fw.html#writing-your-own-custom-strategy</a>). You may also want to check this conversation <a href="http://www.lists.cs.ucla.edu/pipermail/ndnsim/2012-December/000030.html" target="_blank">http://www.lists.cs.ucla.edu/pipermail/ndnsim/2012-December/000030.html</a>  with an example how to send out interests to faces not listed in the FIB.</div>

<div><br></div><div>---</div><div>Alex</div><div><br><div><div><div>On Apr 17, 2013, at 6:27 AM, 王宁 <<a href="mailto:wnbupt9@gmail.com" target="_blank">wnbupt9@gmail.com</a>> wrote:</div><br></div><blockquote type="cite">

<div><div dir="ltr">hi,i want to know if the node's neighbor<span></span>  is not in FIB,but i want to send interest to all neighbor. what should i do ?<br></div></div></blockquote></div></div></div></blockquote></div>
</div></blockquote></div><br></div></div></blockquote></div><br></div>
</div></blockquote></body></html>