1

I'm very new to python and this is also my first post here, so please don't be angry if I make some mistakes. I'm trying my best to explain my problem :)

I wanted to track the ISS with 2 servos, so I downloaded the SatTrack library (more information about it here: https://devpost.com/software/sattrack) with Python 2.7.9. I installed all the other required librarys and installed the setup.py file. When I was done I typed in the command > python -m sattrack.interactive into the cmd as the instruction said and the visualsation of the current position of the ISS worked completly fine. Then I tiped in the code:

from sattrack import SatTrack                # Import the `SatTrack` class:  
s = SatTrack()                               # Instantiate class  
s.set_location(lat='0', lon='0', ele=100)    # Set observer location
s.get_tle('ISS')                             # Search CELESTRAK or AMSAT for satellite TLE data
s.begin_computing()                          # Start calculating topocentric coordinates 
s.show_location()                            # Start printing satellite data to console
s.visualize()                                # Start a server and visualize satellite on map in browser

into the IDLE and pressed on "Run Module", but I just received the error message from above. This programme does the same thing as the small command above (At least I think so), but it's needed for the servo control code. So, how do I fix this? :)

LUGG4S
  • 45
  • 5

1 Answers1

0

The page you found on "devpost.com" seems to be out of date. Generally, the GitHub repository will be the most up-to-date source of documentation on a project. The devpost.com page links to the repository, which is here:

https://devpost.com/software/sattrack

The current README shows no show_location() call, presumably because it has been removed and is no longer supported? It was removed in the most recent update to the repository, in March 2017:

https://github.com/hazrmard/SatTrack/commit/6eef1c921c7a64b4a777b9148aa076640627facf

Alas, there is no explanation of why the change is made, or why that method is no longer supported.

Brandon Rhodes
  • 83,755
  • 16
  • 106
  • 147
  • thank you so much, it solved the issue. But now I have a new one :(. When I type in the path to my .tle file into s.load_tle('file_location'), I just get the error: f = open(filename, 'rb') IOError: [Errno 22] invalid mode ('rb') or filename: ''. The error is longer, but it 's hard to post here. – LUGG4S Nov 21 '20 at 21:53
  • If it literally says `filename: ''` then that would mean, I think, that instead of a filename it's just trying to open the file with the empty string `''` as its name? – Brandon Rhodes Nov 22 '20 at 22:21