I have 0x00 ...0xFF bytes(256) but I'd like to use them for 300 cases
like this:
switch(cmd)
{
case 1:
break;
......
case 300:
break;
}//end switch(cmd)
Can somebody tell me how to solve that problem?
Thanks for your help
Kabanga




Posted 11 June 2010 - 01:15 AM
switch(cmd)
{
case 1:
break;
......
case 300:
break;
}//end switch(cmd)
Posted 11 June 2010 - 04:18 AM
for (int i = 1; i <= 300; i++)
{
if (cmd == i)
{
// Logic goes here
}
}
Posted 11 June 2010 - 05:27 AM
switch(command)
{
case 1:
{
//switch on LED1
//send one byte acknowledgement to the host
break;
}//end case 1
.....
.....
case 300:
{
//switch on LED300
//send one byte acknowledgement to the host
break;
}//end case 300
}//end switch(command)
|
|
Query failed: connection to localhost:3312 failed (errno=111, msg=Connection refused).
|
