tomstewart89 / BasicLinearAlgebra

A library for using matrices and linear algebra on Arduino
MIT License
187 stars 38 forks source link

Examples not working #10

Closed Cabzx closed 7 years ago

Cabzx commented 7 years ago

Hello,

I am trying to run the examples as provided but I am getting some errors. My Arduino IDE version is 1.0.5-r2

In "HowToUse.ino" I get the following error on line 35:

  Matrix<3,3> B = {6.54, 3.66, 2.95,
                   3.22, 7.54, 5.12,
                   8.98, 9.99, 1.56};

Error message at compilation is

HowToUse.ino: In function 'void setup()': HowToUse:35: error: braces around initializer for non-aggregate type 'Matrix<3, 3, Array<3, 3, float> >'

Cabzx commented 7 years ago

I'll add that there are no errors on 1.8.3.

tomstewart89 commented 7 years ago

Yeah this library uses a bunch of C++11 features which aren't enabled by default in Arduino IDE 1.0.5. You can enable them manually, but the easiest thing to do would just be to use the later version of the IDE