5555+

Dependencies:   RingBuffer

Fork of iSerial by BE@R lab

Revision:
4:b38ef9675d39
Parent:
3:d5353b68105f
Child:
5:d83fc550ccbc
--- a/iSerial.h	Sat Sep 01 12:28:28 2012 +0000
+++ b/iSerial.h	Mon Sep 03 09:15:34 2012 +0000
@@ -16,64 +16,30 @@
 class iSerial : public Serial {
   protected:
 
+    const int txbufsize;
+    const int rxbufsize;
     RingBuffer txbuf;
     RingBuffer rxbuf;
+    char* str;
 
     void tx_handler(void);
     void rx_handler(void);
 
-
   public:
 
     enum TERMINL_CODES { CR=0x0D, LF=0x0A };
 
-    /*
-     *  void init_sci(void)
-     *
-     *@ƒ|[ƒg‰Šú‰»ŠÖ”DDDD‚·‚ׂĂÌI/O‚̐ݒè‚ðs‚Á‚Ä‚¢‚éD
-     *
-     *@@ˆø”F‚È‚µ
-     *@@–ß‚è’lF‚È‚µ
-     *
-     */
     iSerial(PinName _tx, PinName _rx, const char *_name=NULL, int _txbufsize=100, int _rxbufsize=100);
-
-    /*
-     *  ƒVƒŠƒAƒ‹“ü—Í‚É•¶Žš‚ª‚ ‚é‚©‚Ç‚¤‚©ƒ`ƒFƒbƒN
-     *  •Ô’lF    ‚O@@F•¶Žš‚ª‚È‚¢
-     *            ‚OˆÈŠOF•¶Žš‚ª—ˆ‚Ä‚¢‚é
-     */
-    int readable(void);
+    virtual ~iSerial();
     
-    /*
-     *  ƒVƒŠƒAƒ‹‚©‚çˆê•¶Žš“ü—Í
-     */
-    int getc(void);
-    
-    /*
-     *@ƒVƒŠƒAƒ‹‚ֈꕶŽšo—Í
-     */
-    void putc(short ch);
-    
-
-    /*
-     *@ƒVƒŠƒAƒ‹‚Ö•¶Žš—ñ‚ðo—Í
-     *@@’Fˆê‰ñ‚̍ő啶Žš”‚ÍLINESIZE
-     *@@’F•¶Žš—ñ‚̏I‚í‚è‚ɂ̓kƒ‹•¶Žš‚ª•K—vD
-     *
-     *@@ˆø”F•¶Žš—ñ‚ւ̃|ƒCƒ“ƒ^
-     *@@•Ô’lFo—Í‚µ‚½•¶Žš”
-     */
     short int putstr(const char* s);
 
-    /*@void outs(char* s)
-     *@ƒVƒŠƒAƒ‹‚Ö•¶Žš—ñ‚ðˆêso—Í
-     *@@’FÅŒã‚ɉüsƒR[ƒh‚𑗂鑼‚Íoutstr‚Æ“¯‚¶
-     *
-     *@@ˆø”F•¶Žš—ñ‚ւ̃|ƒCƒ“ƒ^
-     *@@•Ô’lFo—Í‚µ‚½•¶Žš”
-     */
+    int readable(void);
+    int getc(void);
+    void putc(short ch);
     short int puts(const char* s);
+    //void printf();
+    char* printf(const char* format, ...);
 };