+ Reply to Thread
Results 1 to 9 of 9

Thread: 32x32 Ranger Scanner

  1. #1
    Wire Amateur NIR_Fluff's Avatar
    Join Date
    Apr 2007
    Posts
    35

    Default

    Been done a few times but noone seems to have made a post about theirs so heres one for ya: (pics later)

    N@Scanner[Beta]
    I@Pulser Range Button
    O@Ticktime Xs Ys Gs Xr Yr Run Percent
    Ticktime=0.08
    Button == 0 & Tick == 0 -> Run = 0;
    Button == 1 | Tick > 0 -> Run = 1;
    Gs=255-Range
    Ys=Y
    Xr=(Xs/16)-1
    Yr=(Ys/16)-1
    Xs=31+(Tick-(32*Ys))
    Percent = floor((Tick/1024)*100)
    Run == 1 ->
    ~Pulser&Pulser -> Tick+=1;
    Tick > 0 & Tick <= 32 -> Y=1;
    Tick > 32 & Tick <= 64 -> Y=2;
    Tick > 64 & Tick <= 96 -> Y=3;
    Tick > 96 & Tick <= 128 -> Y=4;
    Tick > 128 & Tick <= 160 -> Y=5;
    Tick > 160 & Tick <= 192 -> Y=6;
    Tick > 192 & Tick <= 224 -> Y=7;
    Tick > 224 & Tick <= 256 -> Y=8;
    Tick > 256 & Tick <= 288 -> Y=9;
    Tick > 288 & Tick <= 320 -> Y=10;
    Tick > 320 & Tick <= 352 -> Y=11;
    Tick > 352 & Tick <= 384 -> Y=12;
    Tick > 384 & Tick <= 416 -> Y=13;
    Tick > 416 & Tick <= 448 -> Y=14;
    Tick > 448 & Tick <= 480 -> Y=15;
    Tick > 480 & Tick <= 512 -> Y=16;
    Tick > 512 & Tick <= 544 -> Y=17;
    Tick > 544 & Tick <= 576 -> Y=18;
    Tick > 576 & Tick <= 608 -> Y=19;
    Tick > 608 & Tick <= 640 -> Y=20;
    Tick > 640 & Tick <= 672 -> Y=21;
    Tick > 682 & Tick <= 704 -> Y=22;
    Tick > 704 & Tick <= 736 -> Y=23;
    Tick > 736 & Tick <= 768 -> Y=24;
    Tick > 768 & Tick <= 800 -> Y=25;
    Tick > 800 & Tick <= 832 -> Y=26;
    Tick > 832 & Tick <= 864 -> Y=27;
    Tick > 864 & Tick <= 896 -> Y=28;
    Tick > 896 & Tick <= 928 -> Y=29;
    Tick > 928 & Tick <= 960 -> Y=30;
    Tick > 960 & Tick <= 992 -> Y=31;
    Tick > 992 & Tick <= 1024 -> Y=32;
    Tick > 1024 -> Tick = 0;;
    #End


    Had to post quickly for "various" reasons



    "Powered and kept alive by TeamNIR"
    http://TeamNIR.org

  2. #2
    Wire Amateur Deco Da Man's Avatar
    Join Date
    Jun 2007
    Posts
    93

    Default

    Nice, but it could e done without all those &#39;Tick comaprestuffhere -> Y=somenumber&#39;s.
    I&#39;ll write one with intervals or schedules when it&#39;s not 4AM.

  3. #3
    Wire Amateur NIR_Fluff's Avatar
    Join Date
    Apr 2007
    Posts
    35

    Default

    i know its not exactly the best code in the world, its still in beta
    but i had to "push" a release because of [sK]Danny using a nail exploit to steal a dupe of it and then claiming it was his until i totally pwnt him with shit loads of proof...

    Anyway.. if you want to wire it up:

    Xs, Ys and Gs all represent outputs for the screen
    Xr and Yr are outputs to the ranger to change its focus point
    The button needs to be non toggled
    Ticktime can be up to you.. but this is a good balance between speed and quality
    percent-shows how far into a scan you are
    Run is to the pulser

    well you get the idea.. its not too difficult



    "Powered and kept alive by TeamNIR"
    http://TeamNIR.org

  4. #4
    Wire Sofaking Shandolum's Avatar
    Join Date
    Apr 2007
    Location
    Europe -> Denmark
    Posts
    887

    Default

    Code:
    N@SH Camera
    I@Button Range
    O@Xr Yr Xs Ys Gs Run Percent
    interval(50)
    
    Button -> Run = 1;
    Run & clk() ->
    X = (X<=32?X+1:0),
    Y += (X == 0? 1:0),
    Y > 32 -> Run = 0, X = 0, Y = 0;,
    Gs = clamp(255-Range,0,255);
    
    Xr = (X/16)-1
    Yr = (Y/16)-1
    Xs = X-1
    Ys = Y-1
    Percent = (Y*32+X)/1024*100
    Everything can be improved upon. Nothing is Perfect.
    The only way to move forward, is to surpass what has already been done.
    Creator of many things.

  5. #5
    Wire Amateur NIR_Fluff's Avatar
    Join Date
    Apr 2007
    Posts
    35

    Default

    lol, nice code but then im not that godly at wiremod

    i just try to keep up with the baiscs, and i should probably try and learn the more advanced parts too

    better get started



    "Powered and kept alive by TeamNIR"
    http://TeamNIR.org

  6. #6
    Wire Sofaking Shandolum's Avatar
    Join Date
    Apr 2007
    Location
    Europe -> Denmark
    Posts
    887

    Default

    The main difference is that you only used 1 loop, while I used 2.
    And also I used the internal clock while you used an external pulser.
    Everything can be improved upon. Nothing is Perfect.
    The only way to move forward, is to surpass what has already been done.
    Creator of many things.

  7. #7
    Wire Amateur NightReaper's Avatar
    Join Date
    Jun 2007
    Location
    St.Awful
    Posts
    68

    Default

    This is my code for a scanner that does a cube and outputs to an emitter. you can alter the size of that cube with the max value. it uses a hydralic mechanism to move the ranger
    <div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-spacere;overflow:auto'>n@scanner
    I@Clk Start Reset Max Ranger
    O@X Y Z Working
    Start==1 -> Working=1;
    Clk==1 -> Z=Ranger/Max X+=1;
    X>=Max -> Y+=1 X=0;
    Y>=Max -> Working=0;
    Reset==1 -> Working=0 X=0 Y=0 Z=0;</div>
    "Equality only works if everyone has it" - NR, aka BLE

  8. #8
    Wire Amateur Hyrsky's Avatar
    Join Date
    Jun 2007
    Posts
    56

    Default

    <div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-spacere;overflow:auto'>N@Camera
    I@Timer On Dist
    O@ScrX ScrY ScrG RangX RangY Run Reset
    On==1->Run=1,Reset=0;Timer>=64->Run=0,Reset=1;
    ScrX=floor(Timer%2*16)
    ScrY=floor(Timer%64/2)
    ScrG=1000-Dist
    RangX=ScrX/16-1
    RangY=ScrY/16-1</div>

    (\_/) <- Bunny
    (O.ô) Copy Bunny into your sig to help
    (> <) him on his way to world domination.

  9. #9
    Wire Noob FewKinG's Avatar
    Join Date
    Jul 2007
    Posts
    1

    Default

    <div class='codetop'>CODE
    <div class='codemain' style='height:200px;white-spacere;overflow:auto'>N@Camera
    I@Timer On Dist
    O@ScrX ScrY ScrG RangX RangY Run Reset
    On==1->Run=1,Reset=0;Timer>=64->Run=0,Reset=1;
    ScrX=floor(Timer%2*16)
    ScrY=floor(Timer%64/2)
    ScrG=1000-Dist
    RangX=ScrX/16-1
    RangY=ScrY/16-1</div>

    [/b][/quote]

    I used this code to build a scanner that outputs its findings through an emitter. i used the internal clock (interval) to make it faster and I added some other code so that it can be way more accurate (if you for example use very small units for the ranger beam&#39;s movement you get a very detailed image through the emitter, though it takes very long then).

    my only problem still is that the ranger outputs the distance in a kind of circle around itself, and if you put that to the emitter which draws the whole thing rectangular, the image is a bit unproportional. for example the plain ground very close to the ranger seems to be a high mountain in the emitted image...
    i tried to compensate this effect with the use Pythagoras&#39; theorem, but the problem is that the ranger&#39;s direction is not using the same values (units) as the distance does. the ranger&#39;s movement is controlled by values from -1 to +1 if i got that right, therfore you can&#39;t get the needed values to calculate the distance correctly. can anyone help me out in this point?

+ Reply to Thread

Similar Threads

  1. 32x32 prop screen.
    By Aut in forum Finished contraptions
    Replies: 16
    Last Post: 03-13-2009, 01:07 AM
  2. Wire Mod Ranger Scanner help needed !!!
    By BombShell |PH| in forum Installation and Malfunctions Support
    Replies: 0
    Last Post: 09-05-2008, 11:18 AM
  3. 3D holographic Scanner (WIP)
    By Bean in forum Finished contraptions
    Replies: 9
    Last Post: 07-30-2008, 11:31 AM
  4. A Holographic Scanner with CPU
    By Fizyk in forum Finished contraptions
    Replies: 9
    Last Post: 07-08-2008, 02:20 PM
  5. 32x32 Camera
    By Jok in forum Finished contraptions
    Replies: 5
    Last Post: 05-12-2007, 03:54 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
proceed-collector
proceed-collector
proceed-collector
proceed-collector
linguistic-parrots
linguistic-parrots
linguistic-parrots
linguistic-parrots