Jump to content
  • Sky
  • Blueberry
  • Slate
  • Blackcurrant
  • Watermelon
  • Strawberry
  • Orange
  • Banana
  • Apple
  • Emerald
  • Chocolate
  • Charcoal

ben_mkiv

Members
  • Content Count

    41
  • Joined

  • Last visited

  • Days Won

    6

Reputation Activity

  1. Upvote
    ben_mkiv got a reaction from The Simon in GPS on microcontrollers   
    good job on that, started something similar once but got distracted... thanks for sharing
  2. Upvote
    ben_mkiv reacted to Log in GPS on microcontrollers   
    Program and library for building GPS network.
    https://github.com/DOOBW/OC-GPS
    Download:
    wget https://raw.githubusercontent.com/DOOBW/OC-GPS/master/usr/bin/gps.lua /bin/gps.lua
    wget https://raw.githubusercontent.com/DOOBW/OC-GPS/master/usr/lib/gps.lua /lib/gps.lua
    The functionality is the same as in the ComputerCraft.
    Additional command "flash" allows to upload firmware to EEPROM.
    When the coordinates are precisely determined, when flashing the position of the microcontroller can be omitted - at the first start it will determine its position from neighboring satellites and save on EEPROM.
    GPS network startup example.
     
  3. Like
    ben_mkiv got a reaction from Izaya in OCDevices (FlatPanel, Cases and external CardDock)   
    Features:
    FlatScreen Panel 
    frameless screen which can be configured to be "rotated/tilted" on the x/y axis and can render transparent (they work as normal Screens, Touchinput will be improved in the final release)
    CardDock 
    external housing for OpenComputer Cards which can be bound to any machine in the Network
    Cases
    additional Tier3 computer cases from ZefTheFox
     
    Download on curseForge for Minecraft 1.12.2
    https://minecraft.curseforge.com/projects/ocdevices
     



  4. Like
    ben_mkiv got a reaction from Log in OCDevices (FlatPanel, Cases and external CardDock)   
    Features:
    FlatScreen Panel 
    frameless screen which can be configured to be "rotated/tilted" on the x/y axis and can render transparent (they work as normal Screens, Touchinput will be improved in the final release)
    CardDock 
    external housing for OpenComputer Cards which can be bound to any machine in the Network
    Cases
    additional Tier3 computer cases from ZefTheFox
     
    Download on curseForge for Minecraft 1.12.2
    https://minecraft.curseforge.com/projects/ocdevices
     



  5. Like
    ben_mkiv got a reaction from Totoro in OCDevices (FlatPanel, Cases and external CardDock)   
    Features:
    FlatScreen Panel 
    frameless screen which can be configured to be "rotated/tilted" on the x/y axis and can render transparent (they work as normal Screens, Touchinput will be improved in the final release)
    CardDock 
    external housing for OpenComputer Cards which can be bound to any machine in the Network
    Cases
    additional Tier3 computer cases from ZefTheFox
     
    Download on curseForge for Minecraft 1.12.2
    https://minecraft.curseforge.com/projects/ocdevices
     



  6. Upvote
    ben_mkiv got a reaction from Matrix89 in OCDevices (FlatPanel, Cases and external CardDock)   
    Features:
    FlatScreen Panel 
    frameless screen which can be configured to be "rotated/tilted" on the x/y axis and can render transparent (they work as normal Screens, Touchinput will be improved in the final release)
    CardDock 
    external housing for OpenComputer Cards which can be bound to any machine in the Network
    Cases
    additional Tier3 computer cases from ZefTheFox
     
    Download on curseForge for Minecraft 1.12.2
    https://minecraft.curseforge.com/projects/ocdevices
     



  7. Upvote
    ben_mkiv got a reaction from ZefTheFox in OCDevices (FlatPanel, Cases and external CardDock)   
    Features:
    FlatScreen Panel 
    frameless screen which can be configured to be "rotated/tilted" on the x/y axis and can render transparent (they work as normal Screens, Touchinput will be improved in the final release)
    CardDock 
    external housing for OpenComputer Cards which can be bound to any machine in the Network
    Cases
    additional Tier3 computer cases from ZefTheFox
     
    Download on curseForge for Minecraft 1.12.2
    https://minecraft.curseforge.com/projects/ocdevices
     



  8. Upvote
    ben_mkiv reacted to ZefTheFox in [Replaced][Release] Custom Cases For OC   
    THIS MOD IS NO LONGER SERVICED, PLEASE DOWNLOAD THIS INSTEAD!!!
     
     
    A while ago there was a post on here about someone making custom cases, I am not that person but I do have a release.  This may be improved upon in the future but as of right now it is in a completely usable state.
    This is a client side replacement for opencomputers. Do not use with normal opencomputers. This will be updated to release versions of OC and will not be for 1.7.10
    Theoretically this should be usable as a client connecting to a server with normal opencomputers, this was not tested.
    To use this install this modified version of opencomputers, it includes a custom case with it. If you want a different case you can choose to install a resource pack, I have made 2 so far. If a resource pack says it is incompatible for any reason ignore it, it's a single number in the pack.mcmeta that has to be different for certain minecraft versions, it will not effect the pack.
    The default case that comes with the mod:

    1.10, OC version 1.7.3
    1.11, OC version 1.7.3
    1.12, OC version 1.7.3
    NZXT Case: download

    IBM 5150 Case: download

     
    Let me know of any issues, or any suggestions for future cases.
     
     
  9. Like
    ben_mkiv reacted to Fingercomp in make opencomputers processors faster   
    Yeah, there is a way to make it faster. In fact, way faster. One of the things that makes it slow is... gpu.setBackground. It's quite expensive in terms of perfomance (tier 3 GPUs consume 1/128 of the call budget when this method is called). Fortunately, your program only involves 4 colors, so it can be easily optimized.
    Actually, there are two ways to do it. A somewhat naive way would be to process all cells of one color first, then process all cells of another color, etc. That would solve the issue with gpu.setBackground, but there's another thing to worry about. The gpu.set method isn't free. In fact, that program does 160 × 50 = 8000 sets, assuming it's running on the max tier 3 resolution. And that is a lot.
    Fortunately, OC supports Unicode. In particular, there's a character in Unicode called a full block — █. On OC, I prefer to think of it as of an inverse of " " (a space). If the foreground and background colors are swapped, the space would look like the full block, and vice versa. And it can help us reduce amount of GPU calls significantly. Try replacing the loops with the following:
    -- i = 0 gpu.setBackground(0xff0000) gpu.set(1, 1, " ") -- i = 1 gpu.setBackground(0x00ff00) gpu.set(1, 2, " ") -- i = 2, 3 gpu.setForeground(0xffff00) gpu.setBackground(0x0000ff) local fullBlock = "\u{2588}" local oddRow = (" " .. fullBlock):rep(math.floor(mx / 2)) local evenRow = (fullBlock .. " "):rep(math.floor(mx / 2)) for y = 1, my do local x = 1 if y % 2 == 1 then if y == 1 then -- Shift the x by 2 to the right to avoid rewriting -- the first two characters. -- OC truncates everything that goes out of the screen bounds, -- so there's no need to worry about that. x = x + 2 end gpu.set(x, y, oddRow) else gpu.set(x, y, evenRow) end end I can't launch Minecraft to run the program and measure the render time, but I can calculate the amount of call budget consumed by the GPU. Assuming the program runs on a tier 3 GPU and screen, there are 4 gpu.setForeground/gpu.setBackground calls, and 52 gpu.set calls. We get (4 × 1 / 128) + (52 × 1 / 256) = 15 / 64 ≈ 0.23. This is enough even if you have a tier 1 processor (whose call budget is 0.5), and the program should be able to run at 20 FPS, though it doesn't really change each frame.
    Oh, I meant to say "T3" (tier 3), sorry. A tier 2 GPU can only perform 128 sets and 64 fills.
    https://github.com/MightyPirates/OpenComputers/blob/master-MC1.7.10/src/main/scala/li/cil/oc/server/component/GraphicsCard.scala#L55-L60
    Also, there's a comment a few lines above in that file, which reminds me of yet another reason OC makes indirect calls take 1 tick to run — synchronization. OpenComputers, very much unlike ComputerCraft, saves the state of running computers so that they can be resumed when the chunk is reloaded. Methods that interact with the world in some way (like moving items around) must perform synchronization with the Minecraft world to avoid, well, messing things up. The comment says it's especially important on world saves. Despite that, the GPU methods were made direct, although a "nasty trick" was needed to do this. Well, safe concurrency is hard to achieve.
  10. Upvote
    ben_mkiv reacted to Fingercomp in Guide to the Sound Card   
    The sound card is added by Computronics, a wonderful addon for OpenComputers. There are a few who actually know what it does. Even less people are able to use it. No one dares to understand how it works, or so I hope.
    Anyway, it appeared a few years (?) ago, and is still mostly undocumented. There is a page in the in-game manual, which fails to explain how great the card is. Of course it does! It has a heap of different methods, which you can use to cast many crazy magics to make the sound card sound, and it's impossible to teach someone to do magic by reading a single page.
    OK, I'm serious now. Last year I managed to understand how to use it, and even wrote a few posts about that. In Russian. Half a year later, I translated them to English. And now I thought of posting a topic here so that you could read them, too.
    Here's the link.
    The first two parts are all about basic things, like getting simple sounds, ADSR, and modulation. The third part features a little bit more complex things, like complex numbers and Fourier transforms. I tried to keep it simple, so I could get something wrong. If so, please leave a comment there pointing out the mistake. Grammar fixes are also highly appeciated.
  11. Like
    ben_mkiv got a reaction from Totoro in Hologram Editor   
    i've made another little change which adds a 2nd output file when saving the hologram. the format contains an table with subtables for each color with stroke instructions to use with the fill render method of the projector, for some usecases this is faster than setting the voxels one by one.
    the rendering function is at line 352 and can be used pretty easy in other projects. the outputfile has ".raw" suffix
    also this script uses the renderfunction, which can be changed in line 100
    https://pastebin.com/6EJV1CbX
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use and Privacy Policy.