Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
RingBuffer.h
00001 /* 00002 * mbed library for RingBuffer 00003 * Copyright (c) 2010 Hiroshi Suga 00004 * Released under the MIT License: http://mbed.org/license/mit 00005 */ 00006 00007 #ifndef RingBuffer_H 00008 #define RingBuffer_H 00009 00010 #include "mbed.h" 00011 00012 class RingBuffer { 00013 public: 00014 RingBuffer (int p_size); 00015 ~RingBuffer (); 00016 00017 int put (char); 00018 int put (char *, int); 00019 int get (char &); 00020 int get (char *, int); 00021 void clear (); 00022 int available (); 00023 int use (); 00024 00025 private: 00026 char *buf; 00027 int size; 00028 int addr_w, addr_r; 00029 }; 00030 00031 #endif
Generated on Tue Jul 12 2022 18:49:37 by
1.7.2