pectrainer


Namepectrainer JSON
Version 1.0.0 PyPI version JSON
download
home_page
SummaryTrain PEC for Celestron mounts
upload_time2023-05-25 05:41:11
maintainer
docs_urlNone
author
requires_python>=3.7
licenseMIT License Copyright (c) 2023 Frank Freestar8n Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords pec celestron autoguide
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # PECTrainer
`PECTrainer` is a python tool to train Periodic Error Correction (PEC) on Celestron telescope mounts.  It is similar to the earlier PECTool but with some additional features.  It works together with an autoguider to record and average multiple worm cycles of the mount behavior to provide a reliable table of corrections to improve tracking.

![Sample view](https://www.dropbox.com/s/gcejvwrzxgkxq34/PECTrainerView.png?raw=1)

## Caveats
- Only works with Celestron mounts and only those that support PEC
- Only works with computer connection through the handcontrol (not directly into the mount's USB port)
- Does not work when connecting to the mount through CPWI as the ASCOM driver
- Requires an autoguider (app, device, or human making corrections) to guide on a star

## Requirements
- Python 3.7+
- Most likely requires Windows currently

## Installation
- Execute `python -m pip install pectrainer` at a command line
- (If you are familiar with python environments you may create one specifically for `PECTrainer` or choose an existing one)

## Preparation for use
- Connect the computer to the mount through the handcontrol
- Start and align the mount using the handcontrol
- Make sure the mount is polar aligned to within a few arc-minutes (nothing crazy)
- Prepare the autoguider so it is able to guide, but don't start guiding yet
- Use the handcontrol to find the PEC index (recommended at this point but can be done later)

## Performing the PEC training
- Use the command line to go to a directory where you want to run and store PEC logs
- Start `pectrainer` at a command line by typing the command `pectrainer`
- Connect to the mount's ASCOM driver (probably `Celestron Telescope Driver`)
- Select the number of cycles to train (the average of all cycles will be automatically loaded to the mount when the cycles complete)
- Confirm the `Seek index` is checked.  If not, click the checkbox to have the mount move a bit in RA to find the index and approximately return - hence the recommendation to do it immediately after aligning the mount
- Choose a star to guide on and enable autoguiding with the guiding app or device (or manually guide with either the handcontrol or the ASCOM slew controls set to 0.5x sidereal rate)
- Press `Start training` to begin the training
- While the first cycle is recorded no graph will be shown but the progress gauge will begin to increase
- At the end of each cycle the graph will be updated with all previous curves, plus the current average in black
- Each worm period will take a few minutes - with time dependent on the type of mount
- When complete the average curve will automatically be uploaded to the mount
- To start playback of the recorded PEC curve, press `Enable mount PEC playback`, or enable playback using the handcontrol
- You are now done and can exit
- The PEC graph may be displayed either as a normal PE curve in arc-sec, or as a changing rate over time in arc-sec/s.  Here is a view as rate.  Note that the gearbox term shows clearly as a sinusoid with approximately 21 second period.  Other mounts will show different periods

![View of PE curve as rate](https://www.dropbox.com/s/ybo1dvb07nixf1b/PECTrainerRateView.png?raw=1)

## Additional features
- You may download and view the current PEC curve in the mount using `Download from mount`
- A new `PEC_*.json` file is created in the current directory every time you press `Start training` and it is updated with data for each cycle as it comes in
- The stored `PEC*.json` files may be loaded and viewed later, and optionally uploaded to the mount
- You may press `Stop training` if the accumulated curves look good enough and press `Upload` to manually load the current average to the mount

## For best results
- Polar align the mount well, but no need for perfection.  Within a few arc-minutes is fine.
- Autoguide on a star high up but reasonably near the equator - within 20 degrees perhaps.  You want to be close to the equator so the star is moving across the sky quickly, and high up so the seeing is better.
- Use a short guide period of 1 second or so if possible.  [MetaGuide](https://www.smallstarspot.com/) works well for this.  Each PEC measurement is a few seconds long, and for a mount such as the `CGX-L` the gearbox terms around 21 seconds long are in phase on each cycle.  This means the PEC table can capture and correct such fast terms, but only if the guide exposures are short enough and the guide corrections happen around once per second.
- For best results record and average 6 or more cycles on a night with good seeing.
- The [Celestron StarSense Autoguider](https://www.celestron.com/products/starsense-autoguider) should also work well for PEC training because it makes rapid guide corrections.
- If the mount has gearbox terms that have the same phase on each cycle, they will stack on top of each other and show clearly in the average.  This is good and it means the PEC can smooth out the gearbox term.
- ... But in contrast, if the gearbox terms are not in phase they will be different in each cycle and they won't stack in the average.  This means you should average many cycles so that the gearbox terms average out.  The PEC won't be able to smooth out the gearbox term - but at the same time the PEC curve won't have a residual gearbox term that would make tracking worse.

## Notes
- Make sure your mount is Celestron and has support for PEC
- Behavior on SynScan mounts is unknown, but it may work
- Once the mount is trained you can use the mount normally and you don't need to connect through the handcontrol.  You can also remove the handcontrol and use a different alignment app such as CPWI
- There are issues with knowing if PEC playback is currently enabled, so the state is not displayed in the GUI.  When done with training, make sure the PEC playback is really happening by enabling it with the handcontrol or CPWI
- Any drift in the PEC curves will be removed from the displayed plot and from the curve loaded to the mount
- Declination guide corrections have no impact on the recorded curve
- Some mounts don't guide well when PEC playback is enabled, but for Celestron mounts it can greatly improve guiding - particularly if the gearbox term is smoothed out

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "pectrainer",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.7",
    "maintainer_email": "",
    "keywords": "pec,celestron,autoguide",
    "author": "",
    "author_email": "Frank Freestar8n <freestar8n@yahoo.com>",
    "download_url": "https://files.pythonhosted.org/packages/2d/d7/df1615de51bfa887087fddbf0c04edacbc92d54e152c4472d0f155bd1255/pectrainer-1.0.0.tar.gz",
    "platform": null,
    "description": "# PECTrainer\r\n`PECTrainer` is a python tool to train Periodic Error Correction (PEC) on Celestron telescope mounts.  It is similar to the earlier PECTool but with some additional features.  It works together with an autoguider to record and average multiple worm cycles of the mount behavior to provide a reliable table of corrections to improve tracking.\r\n\r\n![Sample view](https://www.dropbox.com/s/gcejvwrzxgkxq34/PECTrainerView.png?raw=1)\r\n\r\n## Caveats\r\n- Only works with Celestron mounts and only those that support PEC\r\n- Only works with computer connection through the handcontrol (not directly into the mount's USB port)\r\n- Does not work when connecting to the mount through CPWI as the ASCOM driver\r\n- Requires an autoguider (app, device, or human making corrections) to guide on a star\r\n\r\n## Requirements\r\n- Python 3.7+\r\n- Most likely requires Windows currently\r\n\r\n## Installation\r\n- Execute `python -m pip install pectrainer` at a command line\r\n- (If you are familiar with python environments you may create one specifically for `PECTrainer` or choose an existing one)\r\n\r\n## Preparation for use\r\n- Connect the computer to the mount through the handcontrol\r\n- Start and align the mount using the handcontrol\r\n- Make sure the mount is polar aligned to within a few arc-minutes (nothing crazy)\r\n- Prepare the autoguider so it is able to guide, but don't start guiding yet\r\n- Use the handcontrol to find the PEC index (recommended at this point but can be done later)\r\n\r\n## Performing the PEC training\r\n- Use the command line to go to a directory where you want to run and store PEC logs\r\n- Start `pectrainer` at a command line by typing the command `pectrainer`\r\n- Connect to the mount's ASCOM driver (probably `Celestron Telescope Driver`)\r\n- Select the number of cycles to train (the average of all cycles will be automatically loaded to the mount when the cycles complete)\r\n- Confirm the `Seek index` is checked.  If not, click the checkbox to have the mount move a bit in RA to find the index and approximately return - hence the recommendation to do it immediately after aligning the mount\r\n- Choose a star to guide on and enable autoguiding with the guiding app or device (or manually guide with either the handcontrol or the ASCOM slew controls set to 0.5x sidereal rate)\r\n- Press `Start training` to begin the training\r\n- While the first cycle is recorded no graph will be shown but the progress gauge will begin to increase\r\n- At the end of each cycle the graph will be updated with all previous curves, plus the current average in black\r\n- Each worm period will take a few minutes - with time dependent on the type of mount\r\n- When complete the average curve will automatically be uploaded to the mount\r\n- To start playback of the recorded PEC curve, press `Enable mount PEC playback`, or enable playback using the handcontrol\r\n- You are now done and can exit\r\n- The PEC graph may be displayed either as a normal PE curve in arc-sec, or as a changing rate over time in arc-sec/s.  Here is a view as rate.  Note that the gearbox term shows clearly as a sinusoid with approximately 21 second period.  Other mounts will show different periods\r\n\r\n![View of PE curve as rate](https://www.dropbox.com/s/ybo1dvb07nixf1b/PECTrainerRateView.png?raw=1)\r\n\r\n## Additional features\r\n- You may download and view the current PEC curve in the mount using `Download from mount`\r\n- A new `PEC_*.json` file is created in the current directory every time you press `Start training` and it is updated with data for each cycle as it comes in\r\n- The stored `PEC*.json` files may be loaded and viewed later, and optionally uploaded to the mount\r\n- You may press `Stop training` if the accumulated curves look good enough and press `Upload` to manually load the current average to the mount\r\n\r\n## For best results\r\n- Polar align the mount well, but no need for perfection.  Within a few arc-minutes is fine.\r\n- Autoguide on a star high up but reasonably near the equator - within 20 degrees perhaps.  You want to be close to the equator so the star is moving across the sky quickly, and high up so the seeing is better.\r\n- Use a short guide period of 1 second or so if possible.  [MetaGuide](https://www.smallstarspot.com/) works well for this.  Each PEC measurement is a few seconds long, and for a mount such as the `CGX-L` the gearbox terms around 21 seconds long are in phase on each cycle.  This means the PEC table can capture and correct such fast terms, but only if the guide exposures are short enough and the guide corrections happen around once per second.\r\n- For best results record and average 6 or more cycles on a night with good seeing.\r\n- The [Celestron StarSense Autoguider](https://www.celestron.com/products/starsense-autoguider) should also work well for PEC training because it makes rapid guide corrections.\r\n- If the mount has gearbox terms that have the same phase on each cycle, they will stack on top of each other and show clearly in the average.  This is good and it means the PEC can smooth out the gearbox term.\r\n- ... But in contrast, if the gearbox terms are not in phase they will be different in each cycle and they won't stack in the average.  This means you should average many cycles so that the gearbox terms average out.  The PEC won't be able to smooth out the gearbox term - but at the same time the PEC curve won't have a residual gearbox term that would make tracking worse.\r\n\r\n## Notes\r\n- Make sure your mount is Celestron and has support for PEC\r\n- Behavior on SynScan mounts is unknown, but it may work\r\n- Once the mount is trained you can use the mount normally and you don't need to connect through the handcontrol.  You can also remove the handcontrol and use a different alignment app such as CPWI\r\n- There are issues with knowing if PEC playback is currently enabled, so the state is not displayed in the GUI.  When done with training, make sure the PEC playback is really happening by enabling it with the handcontrol or CPWI\r\n- Any drift in the PEC curves will be removed from the displayed plot and from the curve loaded to the mount\r\n- Declination guide corrections have no impact on the recorded curve\r\n- Some mounts don't guide well when PEC playback is enabled, but for Celestron mounts it can greatly improve guiding - particularly if the gearbox term is smoothed out\r\n",
    "bugtrack_url": null,
    "license": "MIT License  Copyright (c) 2023 Frank Freestar8n  Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.",
    "summary": "Train PEC for Celestron mounts",
    "version": "1.0.0",
    "project_urls": {
        "Homepage": "https://github.com/freestar8n/PECTrainer"
    },
    "split_keywords": [
        "pec",
        "celestron",
        "autoguide"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d20880d6714039b324b657cc95ec77594eb675e33e04b384bc2f9743c0b45f21",
                "md5": "14735ee6fde6823a57b545045c8f57ec",
                "sha256": "39c617bf107a5b7b6de93e6200f43671047c2bf50af33a087ee501040232ddd8"
            },
            "downloads": -1,
            "filename": "pectrainer-1.0.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "14735ee6fde6823a57b545045c8f57ec",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.7",
            "size": 12461,
            "upload_time": "2023-05-25T05:41:08",
            "upload_time_iso_8601": "2023-05-25T05:41:08.565217Z",
            "url": "https://files.pythonhosted.org/packages/d2/08/80d6714039b324b657cc95ec77594eb675e33e04b384bc2f9743c0b45f21/pectrainer-1.0.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "2dd7df1615de51bfa887087fddbf0c04edacbc92d54e152c4472d0f155bd1255",
                "md5": "6322bcf55c6deea273a332ace03e9f16",
                "sha256": "0559f6eb8705e4263cae17396474706c2433c97a33819121da52e8b9270861a9"
            },
            "downloads": -1,
            "filename": "pectrainer-1.0.0.tar.gz",
            "has_sig": false,
            "md5_digest": "6322bcf55c6deea273a332ace03e9f16",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.7",
            "size": 14283,
            "upload_time": "2023-05-25T05:41:11",
            "upload_time_iso_8601": "2023-05-25T05:41:11.067587Z",
            "url": "https://files.pythonhosted.org/packages/2d/d7/df1615de51bfa887087fddbf0c04edacbc92d54e152c4472d0f155bd1255/pectrainer-1.0.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-05-25 05:41:11",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "freestar8n",
    "github_project": "PECTrainer",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "pectrainer"
}
        
Elapsed time: 0.07204s