Advertisement
shadowkat1010

micrOS docs

Oct 1st, 2014
204
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.59 KB | None | 0 0
  1. Primatives:
  2. stdout_write(msg)
  3. Outputs msg to the console
  4. stdin_read(rchar)
  5. Reads input from the console, optionally replacing the characters written to the console with rchar
  6.  
  7. Filesystem:
  8. fs_mount(address, index)
  9. Mounts drive with UUID address to the FS table with index
  10. fs_proxy(index)
  11. Returns the proxy for the drive in the FS table with index
  12. fs_get_drive()
  13. Returns the letter of the active drive
  14. fs_set_drive(index)
  15. Sets the active drive to the index drive in the filesystem table.
  16. fs_open(path,mode)
  17. Opens the file path in access mode mode. Mode defaults to "r"
  18. fs_write(handle, data)
  19. Writes data to the file descriptor handle.
  20. fs_read(handle,length)
  21. Reads data from a file descriptor. Length is optional, defaults to infinite, however that doesn't quite work as filesystems have a max size.
  22. fs_close(handle)
  23. Closes a file descriptor
  24. fs_exists(path)
  25. Checks whether a file exists
  26. fs_is_dir(path)
  27. Checks whether a file is a directory
  28. fs_mkdir(path)
  29. Creates a directory
  30. fs_list(path)
  31. Lists files in a directory. Defaults to /
  32. fs_remove(path)
  33. Deletes a file
  34. fs_move(path)
  35. Moves a file.
  36.  
  37. Component
  38. component_list(type)
  39. Wrapper for component.list
  40. component_type(addr)
  41. Returns the type of a component
  42. component_proxy(addr)
  43. Returns a proxy of a component
  44. component_methods(addr)
  45. Returns the methods of a component.
  46.  
  47. To boot to sked:
  48. At the prompt, usually after a memory usage notification, type 'load', followed by 'sked.lua'
  49. That will get you to sked, shadowkat editor, my really basic line editor. I need to update the docs, but you can find them here: http://pastebin.com/gXtc0nze
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement