Ignore:
Timestamp:
Feb 20, 2016, 10:43:32 PM (8 years ago)
Author:
coas-nagasima
Message:

インクルードのパス指定をContikiに合わせ変更。
整数型の型名をContikiに合わせ変更。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uKadecot/trunk/uip/net/ip/psock.c

    r157 r158  
    3737#include <string.h>
    3838
    39 #include "uipopt.h"
    40 #include "psock.h"
    41 #include "uip.h"
     39#include "net/ip/uipopt.h"
     40#include "net/ip/psock.h"
     41#include "net/ip/uip.h"
    4242
    4343#define STATE_NONE 0
     
    7474static void
    7575buf_setup(struct psock_buf *buf,
    76           u8_t *bufptr, u16_t bufsize)
     76          uint8_t *bufptr, uint16_t bufsize)
    7777{
    7878  buf->ptr = bufptr;
     
    8080}
    8181/*---------------------------------------------------------------------------*/
    82 static u8_t
    83 buf_bufdata(struct psock_buf *buf, u16_t len,
    84             u8_t **dataptr, u16_t *datalen)
     82static uint8_t
     83buf_bufdata(struct psock_buf *buf, uint16_t len,
     84            uint8_t **dataptr, uint16_t *datalen)
    8585{
    8686  if(*datalen < buf->left) {
     
    108108}
    109109/*---------------------------------------------------------------------------*/
    110 static u8_t
    111 buf_bufto(register struct psock_buf *buf, u8_t endmarker,
    112           register u8_t **dataptr, register u16_t *datalen)
    113 {
    114   u8_t c;
     110static uint8_t
     111buf_bufto(register struct psock_buf *buf, uint8_t endmarker,
     112          register uint8_t **dataptr, register uint16_t *datalen)
     113{
     114  uint8_t c;
    115115  while(buf->left > 0 && *datalen > 0) {
    116116    c = *buf->ptr = **dataptr;
     
    244244}
    245245/*---------------------------------------------------------------------------*/
    246 u16_t
     246uint16_t
    247247psock_datalen(struct psock *psock)
    248248{
     
    283283      PT_WAIT_UNTIL(&psock->psockpt, psock_newdata(psock));
    284284      psock->state = STATE_READ;
    285       psock->readptr = (u8_t *)uip_appdata;
     285      psock->readptr = (uint8_t *)uip_appdata;
    286286      psock->readlen = uip_datalen();
    287287    }
     
    311311      printf("Waited for newdata\n");
    312312      psock->state = STATE_READ;
    313       psock->readptr = (u8_t *)uip_appdata;
     313      psock->readptr = (uint8_t *)uip_appdata;
    314314      psock->readlen = uip_datalen();
    315315    }
Note: See TracChangeset for help on using the changeset viewer.