TI-BASIC:WhyTI-BASIC

From Learn @ Cemetech
Revision as of 18:34, 24 February 2016 by Maintenance script (talk | contribs) (Initial automated import)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

TI-Basic History

Texas Instruments has included TI-Basic support with each graphing calculator (starting with the TI-81), and the TI-Basic language has evolved along with the calculators (adding new features and functionality).

With the release of the TI-84+/SE calculators, TI-Basic was enriched with time and date commands that use the new built-in clock, as well as some additional Statistics commands.

TI-Basic is the built-in programming language of the TI graphing calculators. You can create TI-Basic programs on the computer using the Graph Link or TI Connect software, or on the calculator itself through the program editor (see the starter kit for more information).

Knowing TI-Basic is important because it is one of the main ways that people use their calculators; if you are unable to program in TI-Basic, you will not be able to effectively communicate with others concerning your calculator.

Advantages of TI-Basic

There are several advantages of programming your calculator in TI-Basic. First, and foremost, it is the most well known calculator programming language. With most high schools requiring TI graphing calculators for math and science classes, TI-Basic is often used by students to make small math or science programs. For many of these students, TI-Basic is the first programming language they have ever used.

Second, TI-Basic is extremely simple to learn. In TI-Basic, most of the commands are easily understood. The commands are written in plain English or easily comprehended abbreviations: Disp, Dec, etc. In addition, the commands are generally self-explanatory. For example, it is not very hard to recognize that the Pause command pauses a program.

Related to the simplicity of learning, the third advantage of TI-Basic is that it is the only language (so far) that can be programmed directly on the calculator. Assembly programs need to be written on a computer, and then converted into machine code with an assembler and several other programs. These programs are currently only available on computers.

The next advantage of TI-Basic is that it is very easy to do calculations in. Though TI-Basic can be used to write games as well, it's really useful for math programs. A math program in another language would probably have to call the same routines that TI-Basic uses anyway; this would be much more complicated, and wouldn't be an improvement in size or speed.

Lastly, if you mess up in TI-Basic (i.e., your program has an error), it just gives you an error message. If an assembly program has an error, however, the results wouldn't be as good. Depending on the severity of the error, you can cause your calculator's RAM to be cleared, or even leave your calculator in an endless loop, rendering it completely useless. TI-Basic does not have that problem, because no matter where you are in a TI-Basic program, you just have to press the ON key to stop execution.

Disadvantages of TI-Basic

TI-Basic does have some disadvantages. Its main disadvantage is its speed. Because TI-Basic is converted by the calculator into machine code before it is executed, it loses much of its speed. Doing anything involving calculations or Graphics is quite slow in TI-Basic. Really, the speed of TI-Basic comes nowhere close to the speed of assembly. You just need to play an assembly game (such as Super Mario) to see the great difference in speed.

The other disadvantage of TI-Basic is that it is does not have low-level access to the calculator's hardware. While this is intentionally done to prevent potential misuse, it has the result of limiting the quality of TI-Basic programs. This is mainly a problem with input (the GetKey command is limited to one key at a time) and graphics (the drawing functions are just simple pixels, lines, and circles).

The fact that the TI-Basic syntax is not very strict is also a disadvantage. Using TI-Basic-like optimizations in other programming languages, is not a very good idea. Optimize your calculator programs, but don't fall into bad programming habits!