Pages: [1]   Go Down
Author Topic: using TABS in IDE  (Read 456 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 35
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Sorry all, but still learning,

Has any one have an example sketch that show how to use tabs to make programming easy ?

The arduino Reference is a bit confusing, so if any one has a basic sketch that shows this it would be great or a link to one.

THX for any suguestions.
Logged

Norway
Offline Offline
Full Member
***
Karma: 0
Posts: 104
Have you thought it over before asking?
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Your best option is to use an external editor.
This makes programming easier than using the IDE, the IDE's functionality is rather limited.
I use the IDE only to compile and upload.
Logged

2B || !2B

... bonding electrons and bits!

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 614
Posts: 49343
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Using multiple tabs is done so that you can have multiple files open at once. This allows you to have more organized code. It is not done "to make programming easy".

If you have a specific question, we'd be happy to answer it.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 35
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ok then if  for example i have a basic sketch, on main tab that when i press a button moves a motor.

Then could i make the sketch for my next step in the program that counts how long the motor ran for in another tab.  so i could break the whole sketch into peices ?

Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 614
Posts: 49343
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

You can create additional files, with various extensions (.pde, .cpp, .h are two that I KNOW can be used).

You can put functions in any pde file that is in the same folder as the base pde file. All pde files will be merged into one file for compilation, with no need to #include anything.

Putting code in .cpp and declarations in .h file does require special handling.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 35
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

thanks for the info, now i understand, thanks again
Logged

Pages: [1]   Go Up
Jump to: