|
Revision 25, 0.8 kB
(checked in by sven, 3 years ago)
|
|
Clean up of repository before renaming the whole project
to
old media project
since we will shortly add punch card support to the whole
project.
-- sven @ workstation
|
| Line | |
|---|
| 1 | |
|---|
| 2 | |
|---|
| 3 | |
|---|
| 4 | |
|---|
| 5 | |
|---|
| 6 | |
|---|
| 7 | |
|---|
| 8 | |
|---|
| 9 | #include "backend.h" |
|---|
| 10 | |
|---|
| 11 | #include <stdio.h> |
|---|
| 12 | #include <stdlib.h> |
|---|
| 13 | #ifdef __WIN32__ |
|---|
| 14 | #define usleep(x) Sleep((x) / 1000) |
|---|
| 15 | #else |
|---|
| 16 | #include <unistd.h> |
|---|
| 17 | #endif |
|---|
| 18 | |
|---|
| 19 | PuncherBackend* puncher_backend_new(int debug_flag) { |
|---|
| 20 | PuncherBackend *c = malloc(sizeof(PuncherBackend)); |
|---|
| 21 | fprintf(stderr, "[dummy backend] initialisation...\n"); |
|---|
| 22 | return c; |
|---|
| 23 | } |
|---|
| 24 | |
|---|
| 25 | int puncher_backend_write_byte(PuncherBackend* c, unsigned char byte) { |
|---|
| 26 | fprintf(stderr, "[dummy backend] punching 0x%x\n", byte); |
|---|
| 27 | usleep (20*1000); |
|---|
| 28 | return 0; |
|---|
| 29 | } |
|---|
| 30 | |
|---|
| 31 | int puncher_backend_destroy(PuncherBackend* c) { |
|---|
| 32 | fprintf(stderr, "[dummy backend] finishing backend...\n"); |
|---|
| 33 | return 0; |
|---|
| 34 | } |
|---|