Search the Community

Showing results for tags 'script'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • Frontpage, Forum Information and General LEGO Discussion
    • Frontpage News
    • Forum Information and Help
    • General LEGO Discussion
    • The Embassy
  • Themes
    • LEGO Licensed
    • LEGO Star Wars
    • LEGO Historic Themes
    • LEGO Action and Adventure Themes
    • LEGO Pirates
    • LEGO Sci-Fi
    • LEGO Town
    • LEGO Train Tech
    • LEGO Technic and Model Team
    • LEGO Mindstorms and Robotics
    • LEGO Scale Modeling
    • LEGO Action Figures
    • Special LEGO Themes
  • Special Interests
    • Minifig Customisation Workshop
    • LEGO Digital Designer and other digital tools
    • Brick Flicks & Comics
    • LEGO Mafia and Role-Play Games
    • LEGO Media and Gaming
  • Eurobricks Community
    • Hello! My name is...
    • LEGO Events and User Groups
    • Buy, Sell, Trade and Finds
    • Community
    • Culture & Multimedia

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start



What is favorite LEGO theme? (we need this info to prevent spam)

Which LEGO set did you recently purchase or build?



Website URL








Special Tags 1

Special Tags 2

Special Tags 3

Special Tags 4

Special Tags 5

Special Tags 6

Country flag

Found 4 results

  1. based on this script i improved it for creating a .ldr template from online database we just need to enter something like sdlBrt templatefrompeeronwebsite.sdlbas 293-1 and then the script downloads the respective webpage ( in this case - i'm only using peeron for now, it seems far easier for extracting information ), extracts the parts inventory information from there, creates a .ldr file, and opens LeoCad with that curl (for downloading the webpage, weirdly wget doesn’t work) and grep (for "cleaning" the html page) are needed as dependency (on Ubuntu and Debian, grep comes preinstalled, curl needs to be installed, like from "sudo apt install curl") - cat and rm are very known gnu-tools! ;) model$="210-1" '- default model used when no model is added in the command line argument if argv(2)<>"" then: model$=argv(2):end if shell("curl"+model$+" > tmp1.html") shell("cat tmp1.html | grep td | grep href | grep part > tmp2.html") shell("rm tmp1.html") finp$="tmp2.html" function lstinf$(a$,b$,c$) adra=1:adrb=1:blngt=len(b$):d$="" while adrb<=blngt if mid$ (a$,adra,1)=mid$ (b$,adrb,1) then:adrb+=1:end if adra=adra+1 end while while mid$(a$,adra,1)<>left$(c$,1) d$=d$+mid$(a$,adra,1):adra=adra+1 end while lstinf$=d$ end function fout$=model$+".ldr" open finp$ for input as #1:open fout$ for output as #2 dst=100:vamt=0 while eof(1)=0 setcaption(finp$+"line:"+str$(vamt)) file input #1,trln$ trln$="> "+trln$+" 0 0 0 " amnt$=lstinf$(trln$,"><td>","<td>") prtn$=lstinf$(trln$,"><td><td><td><a>","<a>") clrk$=lstinf$(trln$,"><td><td><td><a><a><td><td>","<td>") v2=val(amnt$) '----- this list is still way incomplete '----- old solid colours: 0..2,4,7,14..15, if lcase$(clrk$)="black" then:clrk$="0":end if if lcase$(clrk$)="blue" then:clrk$="1":end if if lcase$(clrk$)="green" then:clrk$="2":end if if lcase$(clrk$)="red" then:clrk$="4":end if if lcase$(clrk$)="grey" then:clrk$="7":end if if lcase$(clrk$)="oldgray" then:clrk$="7":end if if lcase$(clrk$)="lightgray" then:clrk$="7":end if if lcase$(clrk$)="yellow" then:clrk$="14":end if if lcase$(clrk$)="white" then:clrk$="15":end if if lcase$(clrk$)="multi" then:clrk$="15":end if '----- translucent colours: 33..47,52,54,57, if lcase$(clrk$)="transdarkblue" then:clrk$="33":end if if lcase$(clrk$)="trdkblue" then:clrk$="33":end if if lcase$(clrk$)="transgreen" then:clrk$="34":end if if lcase$(clrk$)="trgreen" then:clrk$="34":end if if lcase$(clrk$)="transbrightgreen" then:clrk$="35":end if if lcase$(clrk$)="trbtgreen" then:clrk$="35":end if if lcase$(clrk$)="transred" then:clrk$="36":end if if lcase$(clrk$)="trred" then:clrk$="36":end if if lcase$(clrk$)="transdarkpink" then:clrk$="37":end if if lcase$(clrk$)="trdkpink" then:clrk$="37":end if if lcase$(clrk$)="transneonorange" then:clrk$="38":end if if lcase$(clrk$)="trneonorange" then:clrk$="38":end if if lcase$(clrk$)="transverylightblue" then:clrk$="39":end if if lcase$(clrk$)="transblack" then:clrk$="40":end if if lcase$(clrk$)="trblack" then:clrk$="40":end if if lcase$(clrk$)="smoke" then:clrk$="40":end if if lcase$(clrk$)="transmdediumblue" then:clrk$="41":end if if lcase$(clrk$)="trmdblue" then:clrk$="41":end if if lcase$(clrk$)="transneongreen" then:clrk$="42":end if if lcase$(clrk$)="trneongreen" then:clrk$="42":end if if lcase$(clrk$)="translightblue" then:clrk$="43":end if if lcase$(clrk$)="trltblue" then:clrk$="43":end if if lcase$(clrk$)="translightpurple" then:clrk$="44":end if if lcase$(clrk$)="trltpurple" then:clrk$="44":end if if lcase$(clrk$)="transpink" then:clrk$="45":end if if lcase$(clrk$)="trpink" then:clrk$="45":end if if lcase$(clrk$)="transyellow" then:clrk$="46":end if if lcase$(clrk$)="tryellow" then:clrk$="46":end if if lcase$(clrk$)="transparent" then:clrk$="47":end if if lcase$(clrk$)="transclear" then:clrk$="47":end if if lcase$(clrk$)="trclear" then:clrk$="47":end if if lcase$(clrk$)="clear" then:clrk$="47":end if if lcase$(clrk$)="transpurple" then:clrk$="52":end if if lcase$(clrk$)="trpurple" then:clrk$="52":end if if lcase$(clrk$)="transneonyellow" then:clrk$="54":end if if lcase$(clrk$)="trneonyellow" then:clrk$="54":end if if lcase$(clrk$)="transorange" then:clrk$="57":end if if lcase$(clrk$)="trorange" then:clrk$="57":end if '----- recent solid colours: 3,5..6,8..13,16..20,22..23,25..31,92, if lcase$(clrk$)="darkturquoise" then:clrk$="3":end if if lcase$(clrk$)="dkturquoise" then:clrk$="3":end if if lcase$(clrk$)="darkpink" then:clrk$="5":end if if lcase$(clrk$)="dkpink" then:clrk$="5":end if if lcase$(clrk$)="brown" then:clrk$="6":end if if lcase$(clrk$)="darkgray" then:clrk$="8":end if if lcase$(clrk$)="dkgray" then:clrk$="8":end if if lcase$(clrk$)="lightblue" then:clrk$="9":end if if lcase$(clrk$)="ltblue" then:clrk$="9":end if if lcase$(clrk$)="brightgreen" then:clrk$="10":end if if lcase$(clrk$)="btgreen" then:clrk$="10":end if if lcase$(clrk$)="lightturquoise" then:clrk$="11":end if if lcase$(clrk$)="ltturquoise" then:clrk$="11":end if if lcase$(clrk$)="salmon" then:clrk$="12":end if if lcase$(clrk$)="pink" then:clrk$="13":end if if lcase$(clrk$)="maincolour" then:clrk$="16":end if if lcase$(clrk$)="lightgreen" then:clrk$="17":end if if lcase$(clrk$)="ltgreen" then:clrk$="17":end if if lcase$(clrk$)="lightyellow" then:clrk$="18":end if if lcase$(clrk$)="ltyellow" then:clrk$="18":end if if lcase$(clrk$)="tan" then:clrk$="19":end if if lcase$(clrk$)="lightviolet" then:clrk$="20":end if if lcase$(clrk$)="ltviolet" then:clrk$="20":end if if lcase$(clrk$)="purple" then:clrk$="22":end if if lcase$(clrk$)="darkblueviolet" then:clrk$="23":end if if lcase$(clrk$)="dkblueviolet" then:clrk$="23":end if if lcase$(clrk$)="orange" then:clrk$="25":end if if lcase$(clrk$)="magenta" then:clrk$="26":end if if lcase$(clrk$)="lime" then:clrk$="27":end if if lcase$(clrk$)="darktan" then:clrk$="28":end if if lcase$(clrk$)="dktan" then:clrk$="28":end if if lcase$(clrk$)="brightpink" then:clrk$="29":end if if lcase$(clrk$)="btpink" then:clrk$="29":end if if lcase$(clrk$)="mediumlavender" then:clrk$="30":end if if lcase$(clrk$)="mdlavender" then:clrk$="30":end if if lcase$(clrk$)="lavender" then:clrk$="31":end if '----- more recent solid colours: 68..?..92, if lcase$(clrk$)="verylightorange" then:clrk$="68":end if if lcase$(clrk$)="reddishbrown" then:clrk$="70":end if if lcase$(clrk$)="redbrown" then:clrk$="70":end if if lcase$(clrk$)="flesh" then:clrk$="92":end if '----- more recent solid colours: 100..?..503, if lcase$(clrk$)="lightsalmon" then:clrk$="100":end if if lcase$(clrk$)="ltsalmon" then:clrk$="100":end if if lcase$(clrk$)="mediumlime" then:clrk$="115":end if if lcase$(clrk$)="mdlime" then:clrk$="115":end if if lcase$(clrk$)="lightlime" then:clrk$="120":end if if lcase$(clrk$)="ltlime" then:clrk$="120":end if if lcase$(clrk$)="rust" then:clrk$="216":end if if lcase$(clrk$)="brightlightyellow" then:clrk$="226":end if if lcase$(clrk$)="btltyellow" then:clrk$="226":end if if lcase$(clrk$)="maerskblue" then:clrk$="313":end if if lcase$(clrk$)="darkorange" then:clrk$="484":end if if lcase$(clrk$)="dkorange" then:clrk$="484":end if if lcase$(clrk$)="verylightgray" then:clrk$="503":end if '----- special colours: 21,24, if lcase$(clrk$)="glowindarkopaque" then:clrk$="21":end if if lcase$(clrk$)="unknown" then:clrk$="24":end if '----- unknown if lcase$(clrk$)="mdstone" then:clrk$="24":end if '----- for l2=1 to v2 stou$="1 "+clrk$+" "+str$(vamt*dst)+" -24 "+str$((l2-1)*dst)+" 1 0 0 0 1 0 0 0 1 "+prtn$ print #2,stou$ next vamt=vamt+1 wend close #1:close #2 shell("rm tmp2.html") shell("leocad "+model$+".ldr") of course the script needs to be improved a lot! :D - but it is really a "productivity booster" for me, and all lego-cad developers are welcome on including it (or something like or far better than it! :D ) as feature or plugin, since the result is really a huge time saver! ;)
  2. i made a small sdlBasic converter, from parts list (like from ) to .ldr file a list like: 3005 2 Red 3065 5 White 3002 4 Blue would result into: 1 4 0 0 100 1 0 0 0 1 0 0 0 1 3005 1 4 0 0 200 1 0 0 0 1 0 0 0 1 3005 1 15 100 0 100 1 0 0 0 1 0 0 0 1 3065 1 15 100 0 200 1 0 0 0 1 0 0 0 1 3065 1 15 100 0 300 1 0 0 0 1 0 0 0 1 3065 1 15 100 0 400 1 0 0 0 1 0 0 0 1 3065 1 15 100 0 500 1 0 0 0 1 0 0 0 1 3065 1 1 200 0 100 1 0 0 0 1 0 0 0 1 3002 1 1 200 0 200 1 0 0 0 1 0 0 0 1 3002 1 1 200 0 300 1 0 0 0 1 0 0 0 1 3002 1 1 200 0 400 1 0 0 0 1 0 0 0 1 3002 the code is: finp$="test.list.txt" function lstinf$(a$,b$,c$) adra=1:adrb=1:blngt=len(b$):d$="" while adrb<=blngt if mid$ (a$,adra,1)=mid$ (b$,adrb,1) then:adrb+=1:end if adra=adra+1 end while while mid$(a$,adra,1)<>left$(c$,1) d$=d$+mid$(a$,adra,1):adra=adra+1 end while lstinf$=d$ end function fout$=finp$+".ldr" open finp$ for input as #1:open fout$ for output as #2 dst=100:vamt=0 while eof(1)=0 setcaption(finp$+"line:"+str$(vamt)) file input #1,trln$ trln$="> "+trln$+" 0 0 0 " q1$=lstinf$(trln$,"> "," ") q2$=lstinf$(trln$,"> "," ") q3$=lstinf$(trln$,"> "," ") v2=val(q2$) '----- if lcase$(q3$)="black" then:q3$="0":end if if lcase$(q3$)="blue" then:q3$="1":end if if lcase$(q3$)="green" then:q3$="2":end if if lcase$(q3$)="red" then:q3$="4":end if if lcase$(q3$)="grey" then:q3$="7":end if if lcase$(q3$)="oldgray" then:q3$="7":end if if lcase$(q3$)="lightgray" then:q3$="7":end if if lcase$(q3$)="yellow" then:q3$="14":end if if lcase$(q3$)="white" then:q3$="15":end if if lcase$(q3$)="multi" then:q3$="15":end if '----- if lcase$(q3$)="transparent" then:q3$="47":end if if lcase$(q3$)="clear" then:q3$="47":end if if lcase$(q3$)="transclear" then:q3$="47":end if if lcase$(q3$)="trgreen" then:q3$="35":end if if lcase$(q3$)="transgreen" then:q3$="35":end if if lcase$(q3$)="trred" then:q3$="36":end if if lcase$(q3$)="transred" then:q3$="36":end if if lcase$(q3$)="tryellow" then:q3$="46":end if if lcase$(q3$)="transyellow" then:q3$="46":end if '----- if lcase$(q3$)="darkturquoise" then:q3$="3":end if if lcase$(q3$)="darkpink" then:q3$="5":end if if lcase$(q3$)="brown" then:q3$="6":end if if lcase$(q3$)="darkgray" then:q3$="8":end if if lcase$(q3$)="lightblue" then:q3$="9":end if if lcase$(q3$)="brightgreen" then:q3$="10":end if if lcase$(q3$)="lightturquoise" then:q3$="11":end if if lcase$(q3$)="salmon" then:q3$="12":end if if lcase$(q3$)="pink" then:q3$="13":end if if lcase$(q3$)="maincolour" then:q3$="16":end if if lcase$(q3$)="lightgreen" then:q3$="17":end if if lcase$(q3$)="lightyellow" then:q3$="18":end if if lcase$(q3$)="tan" then:q3$="19":end if if lcase$(q3$)="lightviolet" then:q3$="20":end if if lcase$(q3$)="purple" then:q3$="22":end if if lcase$(q3$)="darkblueviolet" then:q3$="23":end if if lcase$(q3$)="orange" then:q3$="25":end if if lcase$(q3$)="brightlightyellow" then:q3$="226":end if if lcase$(q3$)="verylightgray" then:q3$="503":end if '----- for l2=1 to v2 stou$="1 "+q3$+" "+str$(vamt*dst)+" -24 "+str$((l2-1)*dst)+" 1 0 0 0 1 0 0 0 1 "+q1$ print #2,stou$ next vamt=vamt+1 wend close #1:close #2
  3. I have this Siemens MC35i (RS232 GSM Modem) witch i want to send a message, when the robot want's it send a message to the computer witch then send message to the GSM Module. you can erad about the SM Module here: http://extremeelectr...oller-tutorial/ The entire setup is because i have to make my mindstorms send me a text message, when there is a problem in the setup. It's for a city-layout in a LEGO Exhabition. as alternative i can use a net "SMS-service" - that will require the PHP script "GET". I really hope someone is able to help me - i'm stuck in the project right now.