My astronomy miniPC for some reason saves *VERY* slowly to it's SD card slot, particularly during a imaging run (my guess is it's on the same USB bus as the cameras and thus competing for cycles). It adds about 10 seconds to each image capture over saving to the internal flash drive (so a 30 second image will take 42 seconds vs 32 seconds in the Deep Sky sequencer). As a result, my preferred workflow is to save to the internal drive while imaging and the copy those files to the SD card after the run is complete.
While I would love this to be an option that was available as part of the "After Capture Complete" features in the Deep Sky Sequence Planner, I get that my case is a bit of corner case. So I am attempting to use the 'Advanced Edit' (also called the 'Sequence Editor') to do this. I don't see any thing in the 'Available Steps' that has to do with file management, so I figured I'd just run a program and use the copy feature. And I can't get it to work. Here's the output:
6:46:02 AM Starting :
6:46:02 AM Starting : Run 'copy' with parameters 'C:\Users\astro\Desktop\SharpCap-Captures\Study D:\SharpCap-Captures-SD' and wait for it to exit
6:46:02 AM Error : 'An error occurred trying to start process 'copy' with working directory 'C:\Program Files\SharpCap 4.1 (64 bit)'. The system cannot find the file specified.' while running step Run 'copy' with parameters 'C:\Users\astro\Desktop\SharpCap-Captures\Study D:\SharpCap-Captures-SD' and wait for it to exit
6:46:02 AM End : Sequence halted due to error.
6:46:02 AM Finished
I can run "copy C:\Users\astro\Desktop\SharpCap-Captures\Study D:\SharpCap-Captures-SD" from the command line successfully, so it's not a filename error.
What am I missing? Is there a better way to do this?
As a final question, assuming running a program is the right way to go, currently I'm hard-coding the "Study" directory. I'd love to be able to use a variable like <Target Object Name> in place of "Study". Is there a way to do that?
Copying files at the end of a sequence - run command issues
- admin
- Site Admin
- Posts: 15369
- Joined: Sat Feb 11, 2017 3:52 pm
- Location: Vale of the White Horse, UK
- Contact:
Re: Copying files at the end of a sequence - run command issues
Hi,
I think the problem is that there is no 'copy.exe' for SharpCap to run - copy is a built in function of the Windows command processer (cmd.exe).
The best way to get around this is to create a batch (*.bat) file that contains the copy commands and then tell the sequencer to run that. The added bonus is that you can run and test the batch file outside of the sequence editor to get it right before wiring it into the sequence.
cheers,
Robin
I think the problem is that there is no 'copy.exe' for SharpCap to run - copy is a built in function of the Windows command processer (cmd.exe).
The best way to get around this is to create a batch (*.bat) file that contains the copy commands and then tell the sequencer to run that. The added bonus is that you can run and test the batch file outside of the sequence editor to get it right before wiring it into the sequence.
cheers,
Robin
- admin
- Site Admin
- Posts: 15369
- Joined: Sat Feb 11, 2017 3:52 pm
- Location: Vale of the White Horse, UK
- Contact:
Re: Copying files at the end of a sequence - run command issues
Actually, I should add that there *is* an xcopy.exe in Windows, so you could probably use xcopy in place of copy in your current approach.
cheers,
Robin
cheers,
Robin
Re: Copying files at the end of a sequence - run command issues
Ah, I didn't know that about copy. Changing to xcopy works. Thanks! For now I'll stick with xcopy, but there might be reasons a batch files will have other benefits that I'll consider using in the future. (As a short "ps" I apologize for putting as a question on your forum what is really a question about how windows works... I'm sure it's frustrating to be answering questions that aren't really about your program.)
Now about that final question... is there a way to put the name of the target as variable like <Target Object Name> as part of the command? I tried making a quick batch file and using the set command to see if it was part of the enviornment variables, but it doesn't look like it is.
Now about that final question... is there a way to put the name of the target as variable like <Target Object Name> as part of the command? I tried making a quick batch file and using the set command to see if it was part of the enviornment variables, but it doesn't look like it is.
- admin
- Site Admin
- Posts: 15369
- Joined: Sat Feb 11, 2017 3:52 pm
- Location: Vale of the White Horse, UK
- Contact:
Re: Copying files at the end of a sequence - run command issues
Hi,
sorry, there aren't any ways to include parameters or variables in the run command step. It was originally envisaged for simple things like 'Run PHD2' or 'Run a command that closes the observatory roof' or similar.
It's an intersting idea to inject things into the command as environment variables though - thanks for suggesting it.
cheers,
Robin
sorry, there aren't any ways to include parameters or variables in the run command step. It was originally envisaged for simple things like 'Run PHD2' or 'Run a command that closes the observatory roof' or similar.
It's an intersting idea to inject things into the command as environment variables though - thanks for suggesting it.
cheers,
Robin
Re: Copying files at the end of a sequence - run command issues
Thanks Robin. I understand how that level of complexity wasn't envisioned. But yeah, it seems like something that would add a great deal of power to interfacing with other applications that you don't already work with (which is an impressive set between the guiding, plate solving, etc.). Perhaps for that next set of corner-case features for when you're "bored".
And thanks again for setting me on the right path to add copying the files as part of the automated workflow.
Ken

And thanks again for setting me on the right path to add copying the files as part of the automated workflow.
Ken