Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mp3guy/sunandmoon
Script to calculate the times you can catch a solar or lunar rise or set for a location and direction.
https://github.com/mp3guy/sunandmoon
Last synced: 17 days ago
JSON representation
Script to calculate the times you can catch a solar or lunar rise or set for a location and direction.
- Host: GitHub
- URL: https://github.com/mp3guy/sunandmoon
- Owner: mp3guy
- License: mit
- Created: 2023-03-24T23:18:49.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-04-28T17:01:43.000Z (over 1 year ago)
- Last Synced: 2024-10-30T03:44:33.316Z (2 months ago)
- Language: Python
- Homepage:
- Size: 10.7 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# sunAndMoon
Script to calculate the times you can catch a solar or lunar rise or set for a location and direction.Requires astral, ics and tzlocal, all in pip. Find the parameters you need on e.g. suncalc.org.
All events will be printed to the screen while an iCalendar file, `sun_moon_events.ics`, will be output in the current directory containing all events in a format you can import into e.g. Google Calendar.
Usage:
```
$ python sunAndMoon.py -h
usage: sunAndMoon.py [-h] --loc LOC --lat LAT --lon LON --year YEAR --astart ASTART --aend AENDSun and Moon Set and Rise Calculator
options:
-h, --help show this help message and exit
--loc LOC Location name (default: None)
--lat LAT Latitude in degrees (default: None)
--lon LON Longitude in degrees (default: None)
--year YEAR Year (default: None)
--astart ASTART Azimuth start in degrees clockwise from North (default: None)
--aend AEND Azimuth end in degrees clockwise from North (default: None)
```For example:
```
python sunAndMoon.py --loc Beach --lat 63.79913 --lon -20.88370 --year 2023 --astart 140 --aend 269
Sun rising at 01/01/23 11:10:52
Sun setting at 01/01/23 15:43:24
Sun rising at 02/01/23 11:09:52
Sun setting at 02/01/23 15:45:21
Sun rising at 03/01/23 11:08:46
...
```