Help please (by Ahmad sakr)
Could you please help me
After I compile sketch for arduino and opening the file.ino at arduino ide
If I want to write some if statements which depends on input, output and internal relay status in the arduino ide
I can do that for input and output
How to write if statement depends on internal relay status without giving me errors while compile at arduino ide?
I tried many times but gives me error was not declared in this scope
Like in the attachment program I want to write if statement for Rrelay
(no subject) (by Ahmad sakr)
Dear Ihor Nehrutsa
I don't have any problems in using ldmicro with arduino
My question is
If I used internal relay in ldmicro and I want to write something else in arduino ide depends on the internal relay status like if statement or while.
I can write if statement depends upon input and output pins status but can't do this with internal relay and this is my question,
As in the attachment I can write if(pin_up_Xstart) =high
But how to write if statement for the internal relay Rrelay
Sorry for my bad English but I hope that you understand me
Thanks very much for your reply
(no subject) (by Ihor Nehrutsa)
in nn.cpp
...
STATIC ldBOOL Ub_Rrelay = 0;
...
in nn.h
...
#define Read_Ub_Rrelay() Ub_Rrelay
#define Write_Ub_Rrelay(x) (Ub_Rrelay = x)
#define Write0_Ub_Rrelay() (Ub_Rrelay = 0)
#define Write1_Ub_Rrelay() (Ub_Rrelay = 1)
...
So
...
if( Read_Ub_Rrelay() ) {
//do something
}
(no subject) (by Ahmad sakr)
Dear sir
I make what you say
if( Read_Ub_Rrelay() gives error not declared
Also for if( Read_Ub_Rrelay(x) gives error macro passed 1 argument but takes just 0
Thanks