Use 'ao-dbg' instead of 's51' to communicate with TeleMetrum
[fw/sdcc] / sim / ucsim / s51.src / serialcl.h
index f4a375bdd8e6bf805f07c27c9f841aa422649e8b..859d618a771405e81931738ad93b912e11cec4eb 100644 (file)
@@ -38,22 +38,27 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
 class cl_serial: public cl_hw
 {
 protected:
+  class cl_address_space *sfr;
   bool there_is_t2, t2_baud;
-  class cl_cell *sbuf, *pcon, *scon;
+  class cl_memory_cell *sbuf, *pcon, *scon;
+#ifdef HAVE_TERMIOS_H
   struct termios saved_attributes_in; // Attributes of serial interface
   struct termios saved_attributes_out;
-  FILE *serial_in;     // Serial line input
-  FILE *serial_out;    // Serial line output
-  uchar s_in;          // Serial channel input reg
-  uchar s_out;         // Serial channel output reg
-  bool  s_sending;     // Transmitter is working
-  bool  s_receiving;   // Receiver is working
-  int   s_rec_bit;     // Bit counter of receiver
-  int   s_tr_bit;      // Bit counter of transmitter
-  int   s_rec_t1;      // T1 overflows for receiving
-  int   s_tr_t1;       // T1 overflows for sending
-  int   s_rec_tick;    // Machine cycles for receiving
-  int   s_tr_tick;     // Machine cycles for sending
+#endif
+  class cl_optref *serial_in_file_option;
+  class cl_optref *serial_out_file_option;
+  FILE *serial_in;      // Serial line input
+  FILE *serial_out;     // Serial line output
+  uchar s_in;           // Serial channel input reg
+  uchar s_out;          // Serial channel output reg
+  bool  s_sending;      // Transmitter is working
+  bool  s_receiving;    // Receiver is working
+  int   s_rec_bit;      // Bit counter of receiver
+  int   s_tr_bit;       // Bit counter of transmitter
+  int   s_rec_t1;       // T1 overflows for receiving
+  int   s_tr_t1;        // T1 overflows for sending
+  int   s_rec_tick;     // Machine cycles for receiving
+  int   s_tr_tick;      // Machine cycles for sending
   uchar _mode;
   uchar _bmREN;
   uchar _bmSMOD;
@@ -66,10 +71,10 @@ public:
 
   virtual void new_hw_added(class cl_hw *new_hw);
   virtual void added_to_uc(void);
-  virtual t_mem read(class cl_cell *cell);
-  virtual void write(class cl_cell *cell, t_mem *val);
+  virtual t_mem read(class cl_memory_cell *cell);
+  virtual void write(class cl_memory_cell *cell, t_mem *val);
 
-  //virtual void mem_cell_changed(class cl_mem *mem, t_addr addr);
+  //virtual void mem_cell_changed(class cl_m *mem, t_addr addr);
 
   virtual int  serial_bit_cnt(void);
   virtual void received(int c);
@@ -78,7 +83,7 @@ public:
   virtual void reset(void);
   virtual void happen(class cl_hw *where, enum hw_event he, void *params);
 
-  virtual void print_info(class cl_console *con);
+  virtual void print_info(class cl_console_base *con);
 };