00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00021 #include <windows.h>
00022 #include <windowsx.h>
00023
00025 #define DBG_USERMODE
00026
00028 #define DBG_DLL
00029
00031 #define DBG_PROGNAME "OPENCBM.DLL"
00032
00034 #define DBG_IS_DEBUG_C
00035
00036 #include "debug.h"
00037
00038 #include <winioctl.h>
00039 #include "cbmioctl.h"
00040
00041 #include <stdlib.h>
00042
00044 #define DLL
00045 #include "i_opencbm.h"
00046 #include "archlib.h"
00047
00048 #include "arch.h"
00049 #include "vice_comm.h"
00050
00051
00052 static void
00053 DbgOut(const char * const Format, ...)
00054 {
00055 va_list arg_ptr;
00056 int n;
00057
00058
00059
00060
00061 char buffer[2048];
00062
00063 va_start(arg_ptr, Format);
00064
00065
00066
00067
00068
00069 n = _vsnprintf(buffer, sizeof(buffer) - 1, Format, arg_ptr);
00070
00071
00072
00073
00074
00075 if (n<0)
00076 n = sizeof(buffer);
00077
00078 if (n < sizeof(buffer))
00079 buffer[n++] = '\n';
00080
00081 buffer[n] = 0;
00082
00083 va_end(arg_ptr);
00084
00085 OutputDebugString(buffer);
00086 }
00087
00088 static void
00089 DbgLineStatus(const unsigned char Value)
00090 {
00142
00167
00212
00244
00269
00301
00359
00429
00482
00549
00577
00605
00643
00682
00719
00760
00770
00793
00840
00882
00937
00965
01002
01075