Hey everyone its Spud again. Today I started a project I call CCB, or Computer Compiled Basic. Its pretty simple as far as syntax goes. But this allows for dynamically generated TI-BASIC code. Its pretty simple. Here's a syntax demo:
Code:
This will display Str1 but if you where to add an x and a y as the first 2 params you could also use it as an output coammand.
The main purpose of this utility is to generate dynamic basic code. This could be used for a TI-BASIC game maker or for easy updates to a basic program. people will no longer need to download new .8xp files anymore. with this simple program you can auto update your programs from you computer. Here's an example:
Code:
Now this doesn't not actually compile the code it just outputs the TI-BASIC equivalent. Heres a sample program that will build an equation solver:
Code:
So that's a simple overview of what it does and how you could use it for something usefull. If you have any suggestions please post them below! Thanks! -Spud2451
Code:
import ccb
ccb.echo(var['srt1'])
This will display Str1 but if you where to add an x and a y as the first 2 params you could also use it as an output coammand.
The main purpose of this utility is to generate dynamic basic code. This could be used for a TI-BASIC game maker or for easy updates to a basic program. people will no longer need to download new .8xp files anymore. with this simple program you can auto update your programs from you computer. Here's an example:
Code:
import ccb
#somehow download the TI-BASIC code from your site
comptype = input("for 83+/84+/SE or for 84+CSE")
if comptype == "84+CSE":
#compile accordingly
else:
#compile accordingly
Now this doesn't not actually compile the code it just outputs the TI-BASIC equivalent. Heres a sample program that will build an equation solver:
Code:
import ccb
promptvars = input("vars to prompt (separate by commas):")
equation = input("equation:")
# the add code command is used to input raw basic code
ccb.comp.add_code("Prompt "+promptvars)
ccb.echo(equation)
print(ccb.comp.code)
So that's a simple overview of what it does and how you could use it for something usefull. If you have any suggestions please post them below! Thanks! -Spud2451