EasyManuals Logo

Texas Instruments TI-89 Developer's Guide

Texas Instruments TI-89
1398 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #1152 background imageLoading...
Page #1152 background image
1110
Appendix A: System Routines — Utilities
TI
-
89 / TI
-
92 Plus Developer Guide
Not for Distribution
Beta Version January 26, 2001
strtod
(continued)
See Also: strtol
Example:
void StrToList ( const char *str )
/* Create list of floats on estack from the string of floats */
{
Access_AMS_Global_Variables;
BCD16 num;
unsigned char * start_ptr, * end_ptr;
EStackIndex old_top, k;
end_ptr = (unsigned char *)str;
old_top = top_estack;
push_quantum (END_TAG);
while( *end_ptr )
{ /* stop when end of string or fail */
start_ptr = end_ptr; /* pt to next value to convert */
num = strtod((const char *)start_ptr, (char **)&end_ptr);
if( start_ptr == end_ptr )
break; /* conversion failed */
push_Float( num );
}
k = top_estack; /* point to last val */
push_reversed_tail (k); /* reverse the order */
delete_between (old_top, k); /* delete the old copy */
push_quantum (LIST_TAG); /* make it a list */
return;
}

Table of Contents

Other manuals for Texas Instruments TI-89

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Texas Instruments TI-89 and is the answer not in the manual?

Texas Instruments TI-89 Specifications

General IconGeneral
Display size (HxV)100 x 160 mm
Memory type639K FLASH ROM, 188K bytes RAM
Compatible operating systemsOperating System 2.09
Battery typeAAA

Related product manuals