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

Search the Community

Showing results for tags 'error'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • OpenComputers
    • Announcements
    • Feedback
    • IRC
  • Code Central
    • Support
    • Showcase
    • Tutorials
  • Addons & More
    • Addons Mods
    • Architectures
    • OpenEngineering Task Force
  • General
    • Lounge
    • Forum Games
    • Showcase
    • Servers
  • Archives
    • Public Archives

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Minecraft


GitHub


IRC


Fediverse ID


Location


Interests

Found 6 results

  1. So, I've been playing around with OC, but I keep running into this issue. Every time I install the OS, and the computer reboots, it's fine. But the next time it restarts, I get an error, "Unrecoverable Error: Computer Halted" I've looked everywhere for this error but I haven't found anything, so I figured I'd ask here. I can wipe the HDD by crafting it by itself, and everything is fine and dandy again, just gotta reinstall the OS, but it's not very practical since the computer will just crash again, causing me to wipe the HDD again. Any advice would be most welcome. If you need more information, please just let me know. I've included the error's, HDD and EEPROM info, and the analyzer feedback.
  2. I'm trying to make a program, but isn't working: Here is the code: Here is the error that shows up when starting the program If somebody can say me what I'm doing wrong, I will thank it a lot.
  3. When you have a OC Beta 1.6 on MC 1.8.9 You can't install MineOS but that work on OpenOS 1.5 . I solved that problem and little edited the OC .jar file. ...And simply install the MineOS Link to mineOS:https://oc.cil.li/index.php?/topic/711-mineos-beautiful-gui-to-standard-shell There is a link to .jar file : https://drive.google.com/open?id=0B3E7_SawdD6RT21WU3FZWk9fMms
  4. Content Introduction Reproducing an Error Error Messages Debug Output Appendix List of Error Messages Using a Debugger Ad alert: cbrowse Introduction Writing code is one thing, making it work is a completely different story. More often than not something is not working as intended and sometimes your program just crashes the instant you run it. This can be fun and inspiring but most often it is just frustrating. This guide is meant to introduce you to several useful debugging techniques with the primary focus being OpenComputers and Lua. I could use your help to improve this guide. If you spot an error or miss some content: Please tell me! Reproducing an Error Even with maxed out debugging skills you are going to have a hard time fixing a bug if you can't see it. So step one in debugging is finding a way to reproduce the bug. This is something that does not necessarily require programming. You can even do that as a user! It is very good manners to add a step by step instruction to your bug report: Write down every step of what you did to reach the bug. Test this instruction yourself and try to find ways to make it as short as possible. Maybe the work you did before opening *this* file did not have anything to do with your bug. Also try some variations to find out if this bug needs a specific setup or if it happens in a more general use case. If the program had no trouble on a T3 screen but crashes on a T1 screen there might be something involving the resolution or color depth. Does it work with a T2 screen? This makes it very easy to see the bug in action. Even if it is just 1 in 10 times. It helps. Beware of the Heisenbug which only appears when you are not watching it! ;-) Error Messages Debug Output Appendix List of error messages Syntax Error: detected when loading code syntax error near 'x' 'x' expected near 'y' 'a' expected (to close 'b' at line c) near 'c' Most of the time it's just a missing 'end' or bracket. That's easy to see if you use indentation. Sometimes it is a bit harder to find, but b()=2 clearly is not correct. <eof> means the end of file Runtime Error: detected when the code is executed Runtime errors aren't as easy. They can hide in rarely used code and there is a variety of them: bad argument #1 to 'func' ('type' expected, got 'wrongType') You called a function but one of the parameters you've given has the wrong type. You should check the functions documentation and compare to how you use it in your program. attempt to index local/global/field 'name' (a 'type' value) attempt to index a 'type' value You tried to access a table field but there actually was no table you could access. (but nil, a number, a function etc.) Check the return value/variable you are using and work backwards to find out where a check has failed, the value has been overwritten or not written. table index is NaN/nil You tried to access a table using an invalid index. Everything is allowed to be an index except nil and NaN. attempt to call local/global/field 'name' (a 'type' value) attempt to call a 'type' value The return value/variable you tried to call as a function hasn't been a function or a value with a __call metamethod. Using a Debugger In other environments it is possible to use an external program to help debugging, a 'debugger'. This would display and modify the values of variables and would allow to stop the program at previously defined breakpoints. After stopping it is possible to step through the program line by line to check what it is doing. Just to be clear: This is possible in normal Lua but OpenComputers already occupies the same feature to limit execution time. Ad Alert: cbrowse You can easily add advanced debug in/output by installing my program cbrowse. The debug interface works by calling this: local a, b, c = 1, "A", {test = true} require"cbrowse".view(a, b, c) Tables can be manipulated. If you want to change the value of a variable you have to temporarily use a table and manually export the result back to the local variable. local a = 1 local _t = {a = a} require"cbrowse".view(_t) a = _t.a But there is one drawback: None of the events happening while cbrowse runs reach your event.pull in your program. Event listeners work though.
  5. This is my first time using OpenComputers and I seem to have a strange issue. I put in the OS floppy to a robot and booted it up. To my surprise, the interface screen was completely unreadable. There are a few pictures attached. Any thoughts on how to fix this? Thanks!
  6. Hi!(again) My program for robot(flashed in eeprom) dont work and causes error i typed in topic title. Here is the code: robot = component.proxy(component.list("robot")()) rs = component.proxy(component.list("redstone")()) function getBatteryPercent () local percent = computer.energy() * 100 / computer.maxEnergy() return percent end function wait(seconds) local begin = os.time() repeat computer.pullSignal(0.05) until os.time() - begin >= seconds end while true do robot.turn(true) robot.turn(true) robot.move(1) while robot.compare() ~= true do robot.move(3) if robot.detect(5) == true then robot.turn(false) robot.swing() robot.turn(true) end if robot.detect(4) == true then robot.turn(true) robot.swing() robot.turn(false) end end robot.turn(true) robot.move(0) robot.turn(true) while true do if redstone.getInput(1) > 0 then if getBatteryPercent() < 20.0 then rs.setOutput(0, 15) else rs.setOutput(0, 0) end wait(60) else robot.move(3) end end end
×
×
  • Create New...

Important Information

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