Move files out of root into core, dos, and utils
[profile/ivi/syslinux.git] / memdump / ymsend.h
1 #ifndef YMSEND_H
2 #define YMSEND_H
3
4 #include "mystuff.h"
5
6 struct serial_if {
7   int port;
8   void *pvt;
9   void (*read)(struct serial_if *, void *, size_t);
10   void (*write)(struct serial_if *, const void *, size_t);
11 };
12
13 struct file_info {
14   const char *name;
15   size_t size;
16   void *pvt;
17 };
18
19 void send_ymodem(struct serial_if *, struct file_info *,
20                  void (*)(void *, size_t, struct file_info *, size_t));
21 void end_ymodem(struct serial_if *);
22
23 int serial_init(struct serial_if *sif);
24 void serial_read(struct serial_if *sif, void *data, size_t n);
25 void serial_write(struct serial_if *sif, const void *data, size_t n);
26
27 #endif /* YMSEND_H */