The primary files that make up a project are as follows:
The project file (.TPR) lists all other files in the project, along with their types. There is also a second project file with the .TPRUSR extension that remembers the project state (breakpoints, opened files, cursor positions in files, etc.). This file is "expendable" — TIDE will (re)create it if it's not found.
Tibbo BASIC and C header files (.TBH and .TH by default) are included in other files and typically contain declarations of global variables, constants, defines, etc. The use of header files is options, and a project may contain multiple header files.
Note that just adding header files to the project tree is not enough: They will not be compiled unless you use the include statement.
Tibbo BASIC and C code files (.TBS and .TC by default) contain a project's actual source code. A project must have at least one file containing Tibbo BASIC or C code. Mixing Tibbo BASIC and C within a single project file is also allowed. Each code file in the project tree will be compiled unless there is a preventive condition.
HTML files (.HTML by default) may include blocks of executable code for generating dynamic HTML output (see Working With HTML). Using HTML files is optional: They are only needed if you want your device to function as a web server. A project may also contain more than one HTML file. Each HTML file in the project tree will be compiled unless there is a preventive condition. There are two types of HTML files, as defined by the file type: HTML files that allow including BASIC code and HTML files that allow including C code.
Finally, resource files are added into the .TPC binary without modification. Each resource file in the project tree is added to the compiled binary unless there is a preventive condition.
There are four types of resource files:
- Text files (.TXT, .CFG, and .INI by default) that can be edited from within TIDE
- Configuration files (.XTXT by default) that have associated configurators
- Image files (.BMP, .ICO, .PCX, .JPG, .PNG, and .GIF by default), which can be reference by HTML pages or, in the case of .BMP files, output to LCD displays via the lcd.bmp method
- Binary files (.BIN by default) that contain generic binary data that might be needed by your application (lookup tables, etc.)
Only the .TPR and .TPRUSR files have a fixed file extension. All other file types' extensions listed above are common default extensions that TIDE understands and have no direct bearing on how it treats them.
Rather than looking at the extension, TIDE memorizes each file's type as specified in the Add New File to Project and Add Existing File to Project dialogs. The file type can be changed at any time by right-clicking on the file and selecting Change Type.
Note that while TIDE doesn't care about file extensions, the outside world very often does. For example, a bitmap image with the .ABC extension will work with the lcd.bmp method, but referencing the file from an HTML page won't always work, as the browser might not know what to do with .ABC files.