Go Down

Topic: C++ Standard Template Library (STL) with iostreams (Read 7100 times) previous topic - next topic


I ported the original SGI standard template library (STL) with some stream support from libstdc++ to AVR during a few free days over the festive period:


Basically you get:

  • All containers. The limited memory on the AVR platform will make it hard to find practical uses for the associative containers backed by the rb-tree structure (set, multiset, hash_set, hash_multiset, map, multimap, hash_map, hash_multimap etc.). However vector (especially the efficient specialisation vector<bool>), string, bitset, list are all perfectly viable in practice.
  • All algorithms and functions. Sorting, searching, iterating et. al.
  • iostreams backed by strings, iterators, hardware serial and the LiquidCrystal character LCD display. i.e. << and >> stream operators on to these devices.

Have fun, but keep an eye on your memory usage  ;)

Go Up