1 /* Copyright 2011 Adam Green (http://mbed.org/users/AdamGreen/)
3 Licensed under the Apache License, Version 2.0 (the "License");
4 you may not use this file except in compliance with the License.
5 You may obtain a copy of the License at
7 http://www.apache.org/licenses/LICENSE-2.0
9 Unless required by applicable law or agreed to in writing, software
10 distributed under the License is distributed on an "AS IS" BASIS,
11 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 See the License for the specific language governing permissions and
13 limitations under the License.
15 /* Definition of _sys_*() functions and associated constants implemented in mbed/capi.ar */
25 /* Types used by functions implemented in mbed.ar */
26 typedef int FILEHANDLE
;
29 /* File openmode values for mbed _sys_open() */
32 #define OPENMODE_PLUS 2
37 /* Functions implemented in mbed.ar */
38 FILEHANDLE
_sys_open(const char* name
, int openmode
);
39 int _sys_close(FILEHANDLE fh
);
40 int _sys_write(FILEHANDLE fh
, const unsigned char* buf
, unsigned len
, int mode
);
41 int _sys_read(FILEHANDLE fh
, unsigned char* buf
, unsigned len
, int mode
);
42 int _sys_seek(FILEHANDLE fh
, long pos
);
43 long _sys_flen(FILEHANDLE fh
);
44 int _sys_istty(FILEHANDLE fh
);
50 #endif /* _MBEDSYS_H_ */