24,539 ARTICLES
ON THIS WIKI

Talk:OpenPeripheral


This was in the article, putting it here for now, as it is too messy to be in the main namespace: -- OstPavel (talk • contributions) 07:14, 28 May 2014 (CEST)

"pls someone clean this up: i have the world of issues with wiki editing. info should be solid tho.

Howto use, the quik techie stuffs

anny computer placed agianst a block that allow openperiph will show a openp directory stright in the root, here youll find a program "docs" that helps you figuring out what types and methodes you can use.. if this directory isnt here youll likely trying to connect to something that isnt openperiph /openp/docs front

if the readout scrolling out you can try a term.redirect(peripheral.wrap("yourmonitorside")) in the lua prompt to push output to a monitor

this would show you all the methods available to the device infront of turtle/computer getting an idea what parameters you supose to use be something like this: /openp/docs front getTankInfo

this would give further explanation howto use the tank commando. please note that only turtles can interact with inventorys, computers will not have the push/pullitem methodes listed

exsample of reading these vars using openp stright in a script. both exsamples do the same thing, read out a tank please consider some typo's right and left.

direct contact (no modem) net = peripheral.wrap("front") tank = net.getTankInfo("unknown") print (textutils.serialize(tank))

remote (with wiredmodem and/or perh proxy) -- make sure you rclick the modems to connect it -- need names of the devices connected net = peripheral.wrap("front") names = peripheral.getNamesRemote("front") -- this command cant be wraped. tank = net .remoteCall(names[1],"getTankInfo","unknown") -- chance the names[1] to get to the other devices you might have connected -- more parameters would just be apended with a , print (textutils.serialize(tank))

Note many blocks wont need the peripheralproxy and can be directly connected with wired modem holding shift.

hope this helps, purplemonday"