[How to guide] GPS Global Position System
#21
Posted 20 November 2012 - 09:04 AM
I am working on a way to allow an Airship to move via the Cartesian Coordinate system and it came to me that perhaps a Computer from Computer Craft would be able to talk to a GPS system to do so. IE: the computer asks for a target location via XYZ coordinates, then calculates it's current location and then slowly move (the only way you can move with Frame Motors) from point A to point B.
1) Do you think that is possible?
2) What would be the best way to implement said system?
I assume that we would need to set up at least 1 GPS system, if not more then one... say about 4. Each station with a full 4 rig setup and have them talk to each other via the RedNet system already in the world. With at least one full on HOST system setup in the GPS Ring. Looking at the above image of the overlapping GPS rings would show how a multiple GPS system would allow for longer distances to be reached/mapped.
I understand that it would take some time to program this... in fact I already have a working check list started on this very subject. I would welcome any input you could provide. Thank you in advance for your time & assistance on this matter.
KelticRaven
#22
Posted 20 November 2012 - 10:07 AM
in the case of an air ship it would probably be better to have a turtle in the ship flying it and that turtle storing its location in a file inside the turtle. Turtles return true if they have moved and false if they haven't this can be harnessed to make a turtle fly blind with out GPS cluster set up if you tell it its starting location. I would have one GPS cluster just as a point of reference if something goes wrong you will know where you are because of the cluster. as for making the ship go places if there is no obstacle then a simple move on Z then move on Y then Move on Z program should do it. If you want to avoid obstacle then a more complex program would be needed but I'm guessing you want to stay hight above the ground.
To summarize:
A turtle flying the ship storing its location and changing that every time it moves. the smart move API might be of assistance I haven't worked with it but it should have a tracking system for turtle movement. It would get its starting location from the GPS cluster but from then on would not require to be in range This would allow you to fly any ware you want and not worry about range to clusters.
#23
Posted 20 November 2012 - 02:58 PM
#24
Posted 20 November 2012 - 04:18 PM
#25
Posted 21 November 2012 - 12:50 AM
Lyqyd, on 20 November 2012 - 02:58 PM, said:
tiin57, on 20 November 2012 - 04:18 PM, said:
#26
Posted 13 December 2012 - 03:29 PM
#27
Posted 29 December 2012 - 04:45 PM
My computer controls several transmiters that control the engine of the ship. 6 for the 6 axis movement.
It uses a bundleded cable output to acheive this.
As for the GPS system, I must warn you, it can go out of range pretty quick, so you will need to scatter GPS towers around where you want to travel.
Also make sure to have a world anchor on your ship so it will not have problems on unloaded chunks.
(horrible things can happen to your ship if you don't have that, I found my ship slashed in 2 and separated by 8 blocks)
I have several ways to control the ship. with multiple remote controls, from docking stations (airports), from on board.
So to answer your questions:
1) Do you think that is possible?
Yes is possible
2) What would be the best way to implement said system?
I used a computer (not a turtle as suggested earlier), using bundled cables, controlling transmitters.
As for the GOTO program. I have a GoToXZ function where I provide the final destination, and it will start looping pulses to the engine until it reaches the destination. A normal computer can read its own location using gps.locate() same as the turtles.
The fun part is to make everything stick into panels.
#28
Posted 30 December 2012 - 02:48 AM
leftyisgod, on 13 December 2012 - 03:29 PM, said:
I've set up 4 computer modems for the GPS signal. There is a computer on the quarry with also a modem attached.
My code is not yet finished, but I'm able to do 'goto x y z' and then it requests it current position, substracts that from the destination coordinates, and the result of that is how many blocks it needs to move.
So that result, is the count for the for loop.
Here is the (simple, not yet finished) code:
#29
Posted 30 December 2012 - 05:42 AM
http://en.wikipedia....i/Trilateration
#30
Posted 01 January 2013 - 09:45 PM
BigSHinyToys, on 29 August 2012 - 11:50 AM, said:
GPS builder turtle program.
This program sends a turtle up as far as it can go then builds a GPS cluster
Instructions < Reed
[WARNING] This is experimental code there are probably bugs and errors in it you may loose items when using this. I give no Warner to this code. use at your own risk
if you already have working GPS in your world DON'T USE THIS it will cause you a Big problems
I would recommended tying this out in a New creative world before using it in a real survival world so you know what is does.
place a turtle can be mining or normal WIFI not required.
place turtle with a clear path to the sky (no trees or obstacle above it)
add 600 fuel (one bucket of lava is 1200)
add 4 computers to slot 1
add 4 wifi modems to slot 2
If you are using a Mining turtle then you only need one disk drive in slot 3 and you will get it back. if you are not using a mining turtle then you will need four disk drives in slot 3
place a BLANK disk in slot 4
RUN this program.
press Enter when you have it set up correctly and it will fly up into the sky place Computers turn them on and comeback down.
There is no back door into the computers so ounce they are up there they are staying there you can edit there code after this.
all going well your turtle returns with the disk to ground level. Report bugs here and I will hunt them down.
#31
Posted 02 January 2013 - 12:59 AM
http://pastebin.com/gLTwfr8V
#32
Posted 03 January 2013 - 07:40 AM
But isn't the Y coordinate the vertical coordinate?
Then this would make Z north to south...
#33
Posted 04 January 2013 - 12:41 PM
http://pastebin.com/kiSuDf0Z
#34
Posted 05 January 2013 - 04:20 PM
usmc3891, on 04 January 2013 - 12:41 PM, said:
http://pastebin.com/kiSuDf0Z
just tried this Pastebin I am not sure where its going wrong it starts to launch after fuel filling it up etc it just moved 2 blocks forward and places a computer and then backs up places a modem on the grass and then sits there.
i am in a mystcraft age if this matters or not?
Edit: himm must have been because it was raining i re-ran this a 3rd time in sunshine daytime and it worked.
#35
Posted 05 January 2013 - 05:50 PM
#36
Posted 06 January 2013 - 02:20 AM
Great guide though, it's very easy to follow and I got my GPS system up and running quickly.
#37
Posted 06 January 2013 - 08:04 PM
ill post a suggestion to fix it later
#38
Posted 07 January 2013 - 08:13 PM
One observation with the GPS program, I think there may be an offset error with z (vertical):
I launched the turtle from a level where my feet position (y) shows as level 64. However once I've seeded the gps and place a computer/turtle at the same place I launched from, I get a z-coord of 65. If I go down to the lowest bedrock level (i.e only one bedrock block between me and void) feet loc shows as 1 whereas GPS z shows as 2.
Either this is an offset error, or the feet pos in the minecraft debug gives the coord of the block below the feet.
#39
Posted 07 January 2013 - 10:35 PM
DrCeph, on 07 January 2013 - 08:13 PM, said:
One observation with the GPS program, I think there may be an offset error with z (vertical):
I launched the turtle from a level where my feet position (y) shows as level 64. However once I've seeded the gps and place a computer/turtle at the same place I launched from, I get a z-coord of 65. If I go down to the lowest bedrock level (i.e only one bedrock block between me and void) feet loc shows as 1 whereas GPS z shows as 2.
Either this is an offset error, or the feet pos in the minecraft debug gives the coord of the block below the feet.
GPS Builder ALPHA v0.2 http://pastebin.com/gLTwfr8V
#40
Posted 07 February 2013 - 11:50 PM
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users











