PropWare  3.0.0.229
C++ objects and CMake build system for Parallax Propeller
Classes | Typedefs | Functions | Variables
driver.h File Reference

Contains driver API for stdio devices. More...

+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  __driver
 Generic and customizable driver struct for stdio devices. More...
 

Typedefs

typedef struct __driver _Driver
 

Functions

int _null_read (FILE *fp, unsigned char *buf, int size)
 
int _null_write (FILE *fp, unsigned char *buf, int size)
 
int _term_read (FILE *fp, unsigned char *buf, int size)
 
int _term_write (FILE *fp, unsigned char *buf, int size)
 

Variables

_Driver_driverlist []
 Device driver array of __driver structs. More...
 

Detailed Description

Contains driver API for stdio devices.

Copyright (c) 2011-2012 by Parallax, Inc. All rights MIT Licensed.

Definition in file driver.h.

Typedef Documentation

◆ _Driver

typedef struct __driver _Driver

Typedef for the _Driver struct

This struct is used by stdio. It lets a program define custom devices.

See also
__driver for more information on custom devices.
Note
This structure is included by <stdio.h>, so we cannot pollute the namespace with definitions; use underscores in front of names

Definition at line 24 of file driver.h.

Function Documentation

◆ _null_read()

int _null_read ( FILE fp,
unsigned char buf,
int  size 
)

Use this when no other read function is applicable

◆ _null_write()

int _null_write ( FILE fp,
unsigned char buf,
int  size 
)

Use this when no other write function is applicable

◆ _term_read()

int _term_read ( FILE fp,
unsigned char buf,
int  size 
)

Uses getbyte function to do cooked I/O input

◆ _term_write()

int _term_write ( FILE fp,
unsigned char buf,
int  size 
)

Uses putbyte function to do cooked I/O output

Variable Documentation

◆ _driverlist

_Driver* _driverlist[]

Device driver array of __driver structs.

See also
Detailed Description in include/sys/driver.h

Definition at line 7 of file addfiledriver.c.