Go Down

Topic: Is HIGH = 1 and is pin in pinMode a char? (Read 2017 times) previous topic - next topic


Hi fellow programmers,

I just started working on arduino. It's fantastic. On the other hand, my past experience using C is haunting me over the following issues:
1) Where are the definitions of all the constants like HIGH? Is it a unsigned char or else and is its value 1?

2) How about datatypes of the standard functions' arguments like the pin in the pinMode(pin, HIGH)? Is it a char, or int, signed or not?

Where do I find these things? I need some of the above for proper calculations. Thanks.

Serial LCD keypad panel,phi_prompt user interface library,SDI-12 USB Adapter


"Data is not information, information is not knowledge, knowledge is not understanding, understanding is not wisdom."
~ Clifford Stoll


Your main tab of a script is automatically granted an invisible #include <WProgram.h> and all your functions in all tabs are automatically and invisibly prototyped so you don't have to fuss with header files quite as much.  The compiler includes headers from your Arduino's ./hardware/cores/arduino folder. Hope that helps your research.


Thanks BroHogan. I'm still reading the reference hoping to find the last bit of useful info. I guess I will start to read the user manual for more.

Thanks halley. I found all I wanted are included in the wiring.h. Like the HIGH is just a macro defined as 0x1 and the pin in the pinMode(unsigned char pin, unsigned char HIGH). Peace in mind now  ;D
Serial LCD keypad panel,phi_prompt user interface library,SDI-12 USB Adapter

Go Up