10 posts
Posted 03 December 2013 - 10:16 AM
I have a few questions about the rednet that I haven't been able to find any answers to on the wiki/forum.
1: I read trough the guide at
http://www.computercraft.info/forums2/index.php?/topic/3088-how-to-guide-gps-global-position-system/- In the thread mention above it's said that the range of the gps system increases with the height, what's the range at the highest possible position?
- To extend the range would I have to make another gps cluster somewhere else, or would it be enough to set up a computer running the gps.host function at startup?
2: When using the command rednet.open, will the turtle be assigned a id like any computer and how could I find this id?
- On the tekkit lite wiki it's stated that the range of the modem is 64 blocks, is there a way to increase this?
I think that's it for now, I might update the thread with more related questions as I find them.
8543 posts
Posted 03 December 2013 - 10:22 AM
The low-altitude and high-altitude ranges are configurable, but they default to 64 and 384 blocks, respectively.
You would need another cluster. 374 blocks between clusters will provide full coverage down to bedrock IIRC.
Rednet uses computer ID numbers. Use os.computerID(), os.getComputerID(), or the id program.
See the first answer.
10 posts
Posted 04 December 2013 - 05:36 AM
I see.
As a followup question.
If I have a turtle A, computer B and C, and they are set up like this:
A—-50blocks—-B—-50blocks—-C
If I were to send messages from the turtle to computer C, would this go automaticly through computer B or would I need a program to relay the messages from B to C?
Edit:
And when extending the range of GPS clusters, do I need to give them a position or would it be enough to run gps.host() on startup?
Edited on 04 December 2013 - 04:38 AM
7508 posts
Location
Australia
Posted 04 December 2013 - 05:38 AM
No, computers and turtles definitely do not act as repeaters, you have to make this functionality yourself (or use one of the various user made APIs of course).
Edited on 04 December 2013 - 04:38 AM
7083 posts
Location
Tasmania (AU)
Posted 04 December 2013 - 07:44 AM
That is to say that they can, but won't unless you tell them to.
Every system acting as part of your GPS network needs to know where they are before they can act as servers. Assuming every system you add to that network is in range of at least four other systems that already know where they are, that means said new additions can be made to run a script that works out what their own position is, then start acting as a GPS server themselves. Again, this is a case of "it can be done, but it isn't done automatically".
For eg, you could have a turtle wander along up in the air planting computers + modems as it goes. Next to each computer it plants a disk drive, inserts a disk with a startup script, then it boots the computer.
The computer boots off the code you put on the disk, which tells it to use gps.locate() to determine its position, write a new startup script to its own internal drive (one which incorporates the information you pulled with "locate" in order to run "gps host"), then send a message to the turtle (which in response harvests the disk drive, reboots the computer, then goes off to set up the next one).
You could also write your own version of the "gps" script in order to have it provide repeater services as well.
Depending on the distances and system counts involved, it may be easier to just run long-range communications via eg disks pushed into then pulled from ender chests.