Package se.sics.cooja

Examples of se.sics.cooja.COOJARadioPacket


      /* Remove ESB header and CRC footer */
      byte[] packetData = new byte[dataLength];
      System.arraycopy(decodedData, ESB_HEADER_LENGTH, packetData, 0,
          dataLength);

      return new COOJARadioPacket(packetData);
    }

    logger.fatal("Error when converting emulated to application level, returning null packet");
    return null;
  }
View Full Code Here


  public RadioPacket getAccumulatedConvertedCoojaPacket() {
    byte[] dataArrayByte = new byte[accumulatedConversionDataArray.length];
    for (int i = 0; i < accumulatedConversionDataArray.length; i++) {
      dataArrayByte[i] = (byte) accumulatedConversionDataArray[i];
    }
    return new COOJARadioPacket(dataArrayByte);
  }
View Full Code Here

  public RadioPacket getAccumulatedConvertedCoojaPacket() {
    byte[] dataArrayByte = new byte[accumulatedConversionDataArray.length];
    for (int i=0; i < accumulatedConversionDataArray.length; i++) {
      dataArrayByte[i] = (byte) accumulatedConversionDataArray[i];
    }
    return new COOJARadioPacket(dataArrayByte);
  }
View Full Code Here

    }

    /* New transmission */
    int size = myMoteMemory.getIntValueOf("simOutSize");
    if (!isTransmitting && size > 0) {
      packetFromMote = new COOJARadioPacket(myMoteMemory.getByteArray("simOutDataBuffer", size));

      if (packetFromMote.getPacketData() == null || packetFromMote.getPacketData().length == 0) {
        logger.warn("Skipping zero sized Contiki packet (no buffer)");
        myMoteMemory.setIntValueOf("simOutSize", 0);
        mote.requestImmediateWakeup();
View Full Code Here

TOP

Related Classes of se.sics.cooja.COOJARadioPacket

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.