Devuan fork of gpsd
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

example_aiogps_run 651 B

1234567891011121314151617181920212223242526
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. # Copyright (c) 2019 Grand Joldes (grandwork2@yahoo.com).
  4. #
  5. # This file is Copyright (c) 2019 by the GPSD project
  6. #
  7. # SPDX-License-Identifier: BSD-2-clause
  8. # This code runs only under Python 3.x for x >= 6.
  9. """
  10. Script that runs the aiogps example. On Python versions that can not run the
  11. example it displays a message and exits.
  12. """
  13. import sys
  14. if __name__ == "__main__":
  15. # aiogps only available on Python >= 3.6
  16. if sys.version_info >= (3, 6):
  17. import example_aiogps
  18. example_aiogps.run()
  19. else:
  20. sys.exit("Sorry, aiogps is only available for Python versions >= 3.6")