##### Synopsis

    #include <cross_studio_io.h>
    DEBUG_FILE *debug_fopen(const char *filename, const char *mode);

##### Description

debug_fopen opens the named file and returns a stream or NULL if the open fails. The mode is a string containing one of:

- r — open file for reading
- w — create file for writing
- a — open or create file for writing and position at the end of the file
- r+ — open file for reading and writing
- w+ — create file for reading and writing
- a+ — open or create text file for reading and writing and position at the end of the file

The mode should then include either “t” or “�strong/strong�” to specify if carriage return, linefeed combinations are translated into newline characters e.g. “rt”, “a+b”.

##### Portability

debug_fopen is an extension provided by CrossWorks C.