I want to add one to my website!<br><br>Wrote a little program in the only programming language I ever learned, Commodore BASIC.<br><br>Here is the listing:<br><br>---------------------<br><br><br><br>1 REM Band dimensions for Thera Band Gold<br><br>5 PRINT “What is your draw length in cm ?“<br>10 INPUT A<br><br>16 REM This calculates the band length (1:3 to 1:5.48)<br>15 PRINT “How far do you want to stretch the bands?” <br>17 PRINT “1 = max band life, 9 = max power”<br>20 INPUT B <br>30 IF B=1 THEN C=A/3+3<br>40 IF B=2 THEN C=A/3.31+ 3<br>50 IF B=3 THEN C=A/3.62+3<br>60 IF B=4 THEN C=A/3.93+3<br>70 IF B=5 THEN C=A/4.24+3<br>80 IF B=6 THEN C=A/4.55+3<br>90 IF B=7 THEN C=A/4.86+3<br>100 IF B=8 THEN C=A/5.17 + 3<br>110 IF B=9 THEN C=A/5.48 + 3<br><br>119 REM This calculates the tapering factor (1:1 to 1:2.5)<br>120 PRINT “How much tapering do you want?” <br>121 PRINT “1 = max band life, 9 = max power”<br>122 INPUT O<br>130 IF O=1 THEN D=1<br>140 IF O=2 THEN D=1.19<br>150 IF O=3 THEN D=1.38<br>160 IF O=4 THEN D=1.56<br>170 IF O=5 THEN D=1.75<br>180 IF O=6 THEN D=1.94<br>190 IF O=7 THEN D=2.13<br>195 IF O=8 THEN D=2.31<br>200 IF O=9 THEN D=2.5<br><br>204 REM This calculates the ammo weight.<br>205 PRINT “ What is the diameter of your ammo in mm?”<br>210 INPUT E <br>215 E=E/10<br>220 PRINT “Material please - Steel = 1, Lead = 2, Marbles = 3”<br>230 INPUT M<br>235 IF M=1 THEN N=E*E*E*3.14159/6*7.8: GOTO 300<br>240 IF M=2 THEN N=E*E*E*3.14159/6*11.3: GOTO 300<br>250 IF M=3 THEN N=E*E*E*3.14159/6*2.2: GOTO 300<br>260 GOTO 205 <br><br>290 REM This calculates the draw weight. Factor is 0.6kg per gramm. 2 kg to 18 kg range<br>300 F=N*0.6<br>310 IF F>18 THEN F=18<br>320 IF F<2 THEN F=2<br>400 G=F/1.30<br>410 H=(G/(D+1))*D<br>420 I=G–H<br>430 IF G>10 THEN J=3: GOTO 460<br>440 IF G>6 THEN J=2: GOTO 460<br>450 J=1<br>460 K=H/J<br>462 L=I/J<br><br>510 REM This rounds the output values to just two decimals after the dot. <br>511 N=N*100 <br>512 N=INT(N) <br>513 N=N/100<br>514 C=C*100<br>515 C=INT(C)<br>516 C=C/100<br>517 K=K*100<br>518 K=INT(K)<br>519 K=K/100<br>520 L=L*100<br>521 L=INT(L)<br>522 L=L/100<br><br>529 REM This ist he output information.<br>530 PRINT “Your ammo weighs” N “gramms.”<br>532 PRINT “Cut the bands”; C; “cm long.”<br>535 PRINT “Band width at the fork is”; K; “cm.”<br>540 PRINT “Band width at the pouch is”; L; “cm.”<br>550 PRINT “You need”; J; “bands per side.” <br><br>600 REM A = Draw length<br>610 REM B = Band life preference<br>620 REM C= Band length<br>630 REM D= Tapering factor <br>640 REM E = Diameter ammo<br>650 REM F = Draw weight<br>660 REM G = Raw Band width<br>670 REM H = Raw Band width Fork<br>680 REM I = Raw band width pouch<br>690 REM J = Number of bands per side<br>700 REM K = Band width fork<br>710 REM L = Band width pouch<br>720 REM M = Material of ball<br>730 REM N = Weight of ammo<br>740 REM O = Tapering preference<br><br><br>---------------------------<br><br>You can download CBM BASIC here:<br><br><a href="http://theslingshotforum.forumotion.com/" class="postlink">http://www.pagetable.com/?p=48</a><br><br>You can simply use copy and paste to "insert" the listing into the BASIC window. Start the program with the command RUN (upper case please). <br><br>Let me know what you think! This will of course have to be optimised, and translated into Java or so.
Hi Jörg,<br><br>would love to test this but the link redirects me to this forums front page.<br><br>Tried to google for CBM BASIC, couldn't find anything.<br><br>Could you give us another link?
like this?<br><a href="http://www.slingshotchannel.com/band_calc.html" target="_blank" rel="nofollow">http://www.slingshotchannel.com/band_calc.html</a>
It will be really cool if there was an app of band dimension calculator, be shure I will download it and will be really usefull indeed!
<table width="90%" cellspacing="1" cellpadding="0" border="0" align="center"> <tr><td><span class="genmed"><b>stej wrote:</b></span></td></tr> <tr><td class="quote">Why do you need that? You need to use it offline?</td></tr> </table> <span class="postbody"><br><br>for the case, that my internet connection doesn't work while i want to cut <br>my bands, i made myself a offline html file out of the html/javascript <br>code from jörgs website. it's reduced to a minimum (which means, i'm not<br> sure what else i can delete without destroing it) so it needs only <br>about 5 kb disk space.<br><br>simply copy this text into an editor and save it as a *.html file. <br>this two cool smilies <img src="http://illiweb.com/fa/i/smiles/icon_cool.gif" alt="Cool" longdesc="6"> should be replaced into "8" and ")" the browser will open it without the need of a internet connection:<br><br><font color="blue"><html><head><br><br><script type="text/javascript"><br><br>function slingshot_calc() {<br><br>// Begin converted code from Joerg Sprave's original BASIC version<br><br>A = document.ss_calc.var_a.value;<br>B = document.ss_calc.var_b.selectedIndex + 1;<br>O = document.ss_calc.var_o.selectedIndex + 1;<br>E = document.ss_calc.var_e.value / 10;<br>M = document.ss_calc.var_m.selectedIndex + 1;<br><br>if (B==1) C=A/3+3;<br>if (B==2) C=A/3.31+ 3;<br>if (B==3) C=A/3.62+3;<br>if (B==4) C=A/3.93+3;<br>if (B==5) C=A/4.24+3;<br>if (B==6) C=A/4.55+3;<br>if (B==7) C=A/4.86+3;<br>if (B==<img src="http://illiweb.com/fa/i/smiles/icon_cool.gif" alt="Cool" longdesc="6"> C=A/5.17 + 3;<br>if (B==9) C=A/5.48 + 3;<br><br>if (O==1) D=1;<br>if (O==2) D=1.19;<br>if (O==3) D=1.38;<br>if (O==4) D=1.56;<br>if (O==5) D=1.75;<br>if (O==6) D=1.94;<br>if (O==7) D=2.13;<br>if (O==<img src="http://illiweb.com/fa/i/smiles/icon_cool.gif" alt="Cool" longdesc="6"> D=2.31;<br>if (O==9) D=2.5;<br><br>if (M==1) N=E*E*E*3.14159/6*7.8;<br>if (M==2) N=E*E*E*3.14159/6*11.3;<br>if (M==3) N=E*E*E*3.14159/6*2.2;<br><br><br>// This calculates the draw weight. factor is 0.4kg per gramm, + 6,2 kg (fixed).<br>F=0.4*N+6.2;<br>G=F/1.30;<br>H=(G/(D+1))*D;<br>I=G-H;<br><br><br>J=1;<br>if (G>10) J=3;<br>if (G>6) J=2;<br><br>K=H/J;<br>L=I/J;<br><br>// This rounds the output values to just two decimals after the dot.<br><br><br>J=1;<br>if (G>6) J=2;<br>if (G>10) J=3;<br><br><br>K=H/J;<br>L=I/J;<br><br>// This rounds the output values to just two decimals after the dot.<br>N=N*100 ;<br>N=Math.round(N) ;<br>N=N/100;<br><br>C=C*100 ;<br>C=Math.round(C) ;<br>C=C/100;<br><br>K=K*100 ;<br>K=Math.round(K) ;<br>K=K/100;<br><br>L=L*100 ;<br>L=Math.round(L) ;<br>L=L/100;<br><br><br><br>// This ist he output information.<br><br>document.getElementById("outputline1").innerHTML = "Your ammo weighs " + N + " gramms." ;<br>document.getElementById("outputline2").innerHTML = "Cut the bands " + C + " cm long." ;<br>document.getElementById("outputline3").innerHTML = "Band width at the fork is " + K + " cm." ;<br>document.getElementById("outputline4").innerHTML = "Band width at the pouch is " + L + " cm." ;<br>document.getElementById("outputline5").innerHTML = "You need " + J + " bands per side." ;<br><br>// End converted code from Joerg Sprave's original BASIC version<br><br>}<br><br></script><br><br></head><br><body><br><center><br><br><br><table><br><tbody><br><br><tr><br><br><td><br><br><br><br><br><hr><br><br><form name="ss_calc"><br><br><table><br><tbody><tr><br><td>What is your draw length in cm?</td><br><td><input name="var_a" value="120" size="12" maxlength="12" type="text"></td><br></tr><br><tr><br><td>How far do you want to stretch the bands?</td><br><br><td><br><select name="var_b" onchange="slingshot_calc()" ;=""><br><option selected="selected"> 1 = max band life<br></option><option> 2<br></option><option> 3<br></option><option> 4<br></option><option> 5<br></option><option> 6<br></option><option> 7<br></option><option> 8<br></option><option> 9 = max power<br></option></select><br><br></td><br></tr><br><tr><br><td>How much tapering do you want?</td><br><br><td><br><select name="var_o" onchange="slingshot_calc()" ;=""><br><option selected="selected"> 1 = max band life<br></option><option> 2<br></option><option> 3<br></option><option> 4<br></option><option> 5<br></option><option> 6<br></option><option> 7<br></option><option> 8<br></option><option> 9 = max power<br></option></select><br><br></td><br></tr><br><tr><br><td>What is the diameter of your ammo in mm?</td><br><td><input name="var_e" value="12" size="12" maxlength="12" type="text"></td><br></tr><br><br><tr><br><td>Material please</td><br><br><td><br><select name="var_m" onchange="slingshot_calc()" ;=""><br><option selected="selected"> Steel<br></option><option> Lead<br></option><option> Marbles<br></option></select><br><br></td><br></tr><br><br><br><br><tr><br><td colspan="4"><p></p></td><br></tr><br><br><tr><br><br><td><input value="Calc" onclick="slingshot_calc()" ;="" type="button"></td><br></tr><br><br><br><tr><br><td></td><td colspan="3"><div id="outputline1"></div></td><br></tr><br><tr><br><td></td><td colspan="3"><div id="outputline2"></div></td><br></tr><br><tr><br><td></td><td colspan="3"><div id="outputline3"></div></td><br></tr><br><tr><br><td></td><td colspan="3"><div id="outputline4"></div></td><br></tr><br><tr><br><td></td><td colspan="3"><div id="outputline5"></div></td><br></tr><br><br><br><br></tbody></table><br></form></td><br></tr><br><br><tr><br><br></tr></tbody><br></table><br></center><br><br><br></body></html></font></span>
measurements are bit off though. It lists 4,7g for 16mm marbles, but I have weighed them twice and they weigh 5,3g (10 marbles at 53g)
<div>It work cool!! Nice job guys! I´ll could never make something like this at myselfe Thanks</div><div class="clear"></div><div class="signature_div"> <br><img src="http://illiweb.com/fa/i/smiles/icon_biggrin.png" alt="Very Happy" longdesc="1"><img src="http://illiweb.com/fa/i/smiles/icon_biggrin.png" alt="Very Happy" longdesc="1"><i><strong>!! SÜDBADNER !! </strong></i> <img src="http://illiweb.com/fa/i/smiles/icon_biggrin.png" alt="Very Happy" longdesc="1"><img src="http://illiweb.com/fa/i/smiles/icon_biggrin.png" alt="Very Happy" longdesc="1"> </div>
Hello MaddyMax,<br>I used your script on my forum. I had some issues at the begining because i don' t have any experience in computer stuff. I finally managed to make it work and, most imporant, translate it in french. After succeeding, i realized that in fact it was easy to do with a little bit of logical thinking.<br>I PM' ed Joerg to ask him if he allows me to use it on my forum, if he don' t agree i will just erase it.<br>You can see the result by clicking on my forum link in my signature. Tell me what you think about it and if i have to change something, please.<br>Thanks very, very much for the code mate.<br>Red.
<table width="90%" cellspacing="1" cellpadding="0" border="0" align="center"> <tr><td><span class="genmed"><b>mhpr262 wrote:</b></span></td></tr> <tr><td class="quote">measurements are bit off though. It lists 4,7g for 16mm marbles, but I have weighed them twice and they weigh 5,3g (10 marbles at 53g)</td></tr> </table> <span class="postbody"><br><br>that's what you easily can change by playing 'round with the entered ammo size. use dots instead of commas. i also had marbles with the same diameter but different density.<br><br><br>@toksick:<br><br>i know nothing about javascript besides where it begins and where it ends in a html source code. i just stole it from jörgs brother who translated it from BASIC to JS.<br><br><a href="http://www.servimg.com/image_preview.php?i=11&u=17552695" class="postlink" target="_blank" rel="nofollow"><img src="http://i17.servimg.com/u/f17/17/55/26/95/credit10.png" border="0" alt=""></a></span>
<table width="90%" cellspacing="1" cellpadding="0" border="0" align="center"> <tr><td><span class="genmed"><b>tokSick wrote:</b></span></td></tr> <tr><td class="quote">You can see the result by clicking on my forum link in my signature. <br>Tell me what you think about it and if i have to change something, <br>please.</td></tr> </table> <span class="postbody"><br><br>i don't speak french either, but i found the calc in your forum. seems to work great. still you have to ask the sprave brothers.<br><br>i'm trying to add the new tbg and other kinds of bands and other ammo types to the calc for myself. just curious if i can do it.</span>
Thank for checking.<br>About other bands and ammo calculator that would be great.<br>I' ve put Joerg and Hartmut Sparve in the description of the band calc. on my forum, " Give to Caesar what is Caesar's"...
<table width="90%" cellspacing="1" cellpadding="0" border="0" align="center"> <tr><td><span class="genmed"><b>tokSick wrote:</b></span></td></tr> <tr><td class="quote">" Give to Caesar what is Caesar's"...</td></tr> </table> <span class="postbody"><br><br><img src="http://illiweb.com/fa/i/smiles/icon_biggrin.png" alt="Very Happy" longdesc="1"> right. but it sounds like someone hit you with the bible. <img src="http://illiweb.com/fa/i/smiles/icon_twisted.gif" alt="Twisted Evil" longdesc="13"></span>
No chance... I will be atheist until i die. <img src="http://illiweb.com/fa/i/smiles/icon_evil.gif" alt="Evil or Very Mad" longdesc="12">
That is not the bible, unles I am mistaken ... more like these:<br><br><a href="http://www.amazon.de/History-Biography-Historiography-Illustrated-ebook/dp/B005WO8GG4/ref=sr_1_6?s=books-intl-de&ie=UTF8&qid=1355927377&sr=1-6" target="_blank" rel="nofollow">http://www.amazon.de/History-Biography-Historiography-Illustrated-ebook/dp/B005WO8GG4/ref=sr_1_6?s=books-intl-de&ie=UTF8&qid=1355927377&sr=1-6</a>
<table width="90%" cellspacing="1" cellpadding="0" border="0" align="center"> <tr><td><span class="genmed"><b>mhpr262 wrote:</b></span></td></tr> <tr><td class="quote">That is not the bible, unles I am mistaken ... more like these:<br><br><a href="http://www.amazon.de/History-Biography-Historiography-Illustrated-ebook/dp/B005WO8GG4/ref=sr_1_6?s=books-intl-de&ie=UTF8&qid=1355927377&sr=1-6" target="_blank" rel="nofollow">http://www.amazon.de/History-Biography-Historiography-Illustrated-ebook/dp/B005WO8GG4/ref=sr_1_6?s=books-intl-de&ie=UTF8&qid=1355927377&sr=1-6</a> </td></tr> </table> <span class="postbody"><br><br>i entered jesus caesar into google and this was the seventh search result:<br><br><a href="http://bible.cc/mark/12-17.htm" target="_blank" rel="nofollow">http://bible.cc/mark/12-17.htm</a><br><br>sorry. i hate to be right. heheh <img src="http://illiweb.com/fa/i/smiles/icon_twisted.gif" alt="Twisted Evil" longdesc="13"></span>
Are the recommended band dimensions just the stretched part of the band or does it include the part that is used in attaching to fork and pouch? I seem to not see where this is discussed. Thanks much, Cobble