Questions about enum's, arrays and const's
hi, i'm pretty new arduino , got few questions.
my first 1 why can't that:
and difference between:
please explain carefuly
thanks in advance.
my first 1 why can't that:
code: [select]
enum params
{
char name[16],
int switchpin,
int ledpin
};
const buttons[][params]
{
{ "btnlivingroom", 2, 8 },
{ "btnbathroom", 3, 9 },
{ "btnbedroom", 4, 10 },
{ "btnkitchen", 5, 11 },
{ "btnparking", 6, 12 }
};
void setup() { ... }
void loop() { ... }
and difference between:
code: [select]
new const [] {...}
// or
const [] {...}
please explain carefuly

thanks in advance.
quote
my first 1 why can't that:because not enum for. looks more struct.
code: [select]
const [][params]
{
so, want variable, of type undefined, no name, constant , 2d array. no way, jose.
quote
and difference betweenone steaming pile of stinky crap , other stinky pile of steaming crap.
Arduino Forum > Using Arduino > Programming Questions > Questions about enum's, arrays and const's
arduino
Comments
Post a Comment