newlib_device_t Struct Reference

#include <newintf.h>

Data Fields

int valid
int ident
char tag [8]
BOOL is_tty
void *(* open )(struct _reent *r, const char *name, int flags, int mode)
int(* close )(struct _reent *r, int fd)
off_t(* lseek )(struct _reent *r, int fd, off_t pos, int whence)
long(* read )(struct _reent *r, int fd, void *buf, size_t cnt)
long(* write )(struct _reent *r, int fd, const void *buf, size_t cnt)
int(* stat )(struct _reent *r, const char *file, struct stat *pstat)
int(* fstat )(struct _reent *r, int fd, struct stat *pstat)
int(* link )(struct _reent *r, const char *old, const char *n)
int(* unlink )(struct _reent *r, const char *file)

Detailed Description

The interface between newlib and any user devices to be accessed with stdio.


Field Documentation

int(* newlib_device_t::close)(struct _reent *r, int fd)
int(* newlib_device_t::fstat)(struct _reent *r, int fd, struct stat *pstat)

Identifier (Don't touch this)

TRUE if this device is a TTY, FALSE otherwise

int(* newlib_device_t::link)(struct _reent *r, const char *old, const char *n)
off_t(* newlib_device_t::lseek)(struct _reent *r, int fd, off_t pos, int whence)
void*(* newlib_device_t::open)(struct _reent *r, const char *name, int flags, int mode)
long(* newlib_device_t::read)(struct _reent *r, int fd, void *buf, size_t cnt)
int(* newlib_device_t::stat)(struct _reent *r, const char *file, struct stat *pstat)

The tag for the device filenames (tag:/path/to/file)

int(* newlib_device_t::unlink)(struct _reent *r, const char *file)

Don't touch this

long(* newlib_device_t::write)(struct _reent *r, int fd, const void *buf, size_t cnt)

The documentation for this struct was generated from the following file:
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines
Generated by  doxygen 1.6.3