Ultimaker / Cura

3D printer / slicing GUI built on top of the Uranium framework
GNU Lesser General Public License v3.0
6.1k stars 2.06k forks source link

Implement Preference Setting(s) for: 'Preferred "Save to" Device', and/or a(n) (Never-Save-To) 'Exclusion List' #16472

Open h8t0r opened 1 year ago

h8t0r commented 1 year ago

Is your feature request related to a problem?

Broad overview of 'issue' that sparks me desire for an additional set of features:

I have 1 flash drive that is used as a general backup drive on my computer, used to save and store various random files. This drive is always plugged into my computer and rarely gets removed.

My 'PRINTER' Flash drive, which I use exclusively for saving my G-Code onto, is most commonly plugged into my QIDI X-Plus printer. As I open/load a .STL file via CURA, I go to my printer and start heating it up; It's at this time that I grab the 'PRINTER' drive, that resides in my printer, and place it into my PC. {Doing this allows the file/part(s)/program to load while I start my printer, and then allows my printer to pre-heat while I return to my computer to tweak any Slicer settings before Exporting the G-Code}

It's always been a frustration that (as far as my limited knowledge): I'm not able to setup CURA to [Automatically] default to a specific Flash Drive. Thus, There have been many a time in which: I click to {Save to Removable Drive (Whatever Drive Letter has been defaulted:)}, Eject or Unplug the 'PRINTER' drive, Plug it into my Printer, only to realize CURA saved, by default, to my other flash drive that is used for backups, rather than my drive intended exclusively for printer G-Code.


I'm aware that: I can manually select the correct flash drive when saving; But that's often a forgotten action in the excitement of trying to get my print started. I currently subvert this 'issue' by manually ejecting my 'Storage/Backup' drive (whenever I expect to be using CURA), so that the 'PRINTER' drive is the exclusive option that can even be seen. This 'Works', until my computer needs to be restarted for any reason; If my computer is restarted then my 'Storage/Backup' USB is reassigned a drive letter and is visible, requiring me to eject it again or realize my oversight when I inevitably save my G-Code to that 'Storage/Backup' drive and can't find it when trying to locate the file on my printer's menu, when searching through my 'PRINTER' drive.

Describe the solution you'd like

A minimalized solution would be having the ability to select a default Drive Letter as a 'Preferred 'Save to' Device'.

"Device" might not be the most ideal term, but it's intended to be a term that conveys: Disks, Removable Drives, SD Cards(?), and any other storage hardware 'Devices'. {I've never saved to an SD Card from CURA, so it might already be considered a Removable Drive, just like a USB Flash Drive.}


Example of implementation:

You navigate to CURA->[Preferences]->[Configure Cura...] (The "Preferences" Form Opens) Under the [General] Tab, "Opening and saving files" section, there would be a new entry labeled 'Preferred 'Save to' Device'.

'Preferred 'Save to' Device' would have a dropdown-style Listbox UI object, which, by default, is set to "None". You click the Listbox and scroll to whatever Drive Letter is associated with your preferred location (ex. "Z:").

Directly below the setting for 'Preferred 'Save to' Device', would be a checkbox option labeled 'Automatically override "Save to {Location}" to Selected Preference, whenever possible.'


How this would work/help, for my use-case.

This 'Solution' would require you to, firstly, assign a Persisting Drive Letter within your operating system (A feature that's at least available within Windows, I'm unfamiliar with other OS's features). For me, I would take my 'PRINTER' Flash Drive and set up a Persisting Drive Letter of "Z:" to ensure it's almost impossible that there would be a drive letter collision; Thus, any time my 'PRINTER' drive is plugged into my computer, it get assigned as "Z:".

I would then be able to have "Z:" selected within the CURA->[Preferences]->[Configure Cura...] >> [General]->"Opening and saving files"->'Preferred 'Save to' Device'. This selection alone would mean that, Upon Loading CURA, if "Z:" is available, CURA will automatically set the "Save to {Location}" (Button) mapping to "Save to REMOVEABLE DRIVE (Z:)".

Furthermore, I, personally, would check (Enable) the option for: CURA->[Preferences]->[Configure Cura...] >> [General]->"Opening and saving files"->'Automatically override "Save to {Location}" to Selected Preference, whenever possible.' This would mean that: Regardless of wherever the "Save to {Location}" (Button) currently happens to be mapped, If I connect my preferred 'Preferred 'Save to' Device', "Z:", Then the software would automatically override the "Save to {Location}" (Button) mapping to "Save to REMOVEABLE DRIVE (Z:)".


Potential issues

This would be the most minimal implementation that I can currently come up with, which would sufficiently resolve my 'issue' in a satisfactory manner. I believe this would also be reasonably simple to implement; but it's obviously "easier said than done" and there may be a plethora of alternative 'Connect via USB' and 'Saving' features, which already exist, that might have interactions with the implementation of this proposed feature.

Describe alternatives you've considered

Here are some alternative implementations or additional features that would couple well with the initial idea:


Additional depth to initial implementation:

As most Printers are, I presume, likely to require files to be located on the Root Location of a given Device, I'm not sure on how much of a benefit could be gained by adding an additional layer of depth to this implementation. However, I can see that, for some users, it might be even better if you could add a Preference of Folder within a given Preferred Device.

So, Beyond just 'Preferred 'Save to' Device', there would be an Option such as: 'Preferred Folder on Device'. Setting this Path might be best as 'Browse Folder-Location'-style of selection. You could click a 'Browse Folder-Location' (button) and use the typical/canned browse to folder means of selection.

The downside here is that you would have to have the device connected, so that might present some degree of inconvenience; This could be handled by pairing a Textbox and Browse-to-folder selector object. If you know the Folder path but don't have the device connected, you could simply type the path into the textbox: "Z:\UnprintedFiles".

An implementation consideration is that: When a person goes to save the G-Code to their 'Preferred Device' & has a set 'Preferred Folder', the "Save to REMOVEABLE DRIVE (Z:\UnprintedFiles)" button-click event would need to verify that the folder path "\UnprintedFiles" actually exists, prior to saving. {The folder might have been moved, deleted, or never existed.}

CURA could just, by default, create the folder and save the file inside the folder, without having to throw an exception error/prompt.

Otherwise, This would mean that an exception should be thrown, and that would imply the need for the simple addition of a checkbox of: "Automatically Create Folder on 'Preferred Device' if 'Preferred Folder' path does not exist".

A little more flexibility

As a potential 'Nice to have', I could see where other people would have a use-case in which they would benefit from an additional degree of control.

For example: If you have several printers (ex. Some that use USB drives and others that require SD cards), it might be nice to have the ability to: enable more than one 'Preferred Device'; add them in a listbox; and click+drag to arrange the drives into a hierarchical order that would enable the 'Automatically override "Save to {Location}" to Selected Preference(s), whenever possible.' option to set the "Save to {Location}" (Button) to whichever option, if any are available, is highest in priority.

I can't really fathom a use-case where each 'Preferred Device' would need any more than a 1-to-1 mapping for a 'Preferred Folder on Device'.



A potentially viable alternative

As an alternative implementation, or potentially an additional feature: it would be possible to attain a similar functionality, within my use-case, by having an Exclusion List.

In this regard, you basically add 'Locations' to a blacklist, which the software will intentionally avoid; in the scope of the initial concept, a 'Locations' would be a 'Drive Letter'.

This would mean that: I could assign my 'Storage/Backup' drive to a Persisting Drive Letter, ex. "Y:"; After doing so, I could add multiple locations like "Y:" and "C:" to the Exclusion list. By doing this, the "Save to {Location}" (Button) would never map to either "Y:" or "C:"; If I don't have my 'PRINTER', G-Code exclusive, flash drive plugged into my computer, the "Save to {Location}" (Button) would then default to something like "No Save Locations Available" and become disabled.

This would effectively ensure that: I would never accidentally save my G-Code to the locations that aren't intended.

This implementation, of an Exclusion List, would likely be effective in my use case, because I only have 3 drives that are assigned whenever my computer restarts (not including my 'PRINTER' USB) : ex. (C: , L: , and E:), "L:" is an additional internal SSD. For me, it would be trivial to assign 2 Persisting Drive Letters (One for my 'additional' SSD and one for my 'Storage/Backup' USB) and add them to an Exclusion List; but that might not be the same for others.

Furthermore, even if an Exclusion List were to be implemented without the "Preferred Device/Location" features, the 'problem/frustration' would still occur if a user plugs in any set of 2+ 'temporary' drives. One of them might be your intended "Save to {Location}", but CURA might default to another, random, available location, which in this example would be a drive that is only temporarily connected and would never warrant either: having an assigned, Persisting Drive Letter__ or being added to an Exclusion List.

Affected users and/or printers

Who benefits?!?

The inception of this 'set of features' came from my experience of wanting to save my prints to a specific USB drive, without the hassle that results from also having another USB drive connected to my computer.

The USB I use for 'Storage/Backups' is a larger drive at 250gb of capacity, and is formatted in exFAT (out of necessity). A FAT32-formatted drive, like the one I use for 'PRINTING' is limited to a max of 32gb of allocation; my printer can handle the FAT32 format, without issue.

I would expect that a fair portion of the 3D printers in use, currently, would have a drive format limitation. So anyone who has a printer and wants to have a larger, connected storage-device, as I have, should benefit from these features.

I recognize that: in the time I've spent (several hours) writing out these thoughts: for potential features, and trying to format things, I could've manually clicked the "Save to ..." button: to adjust to an alternate location, based on the current implementation, thousands of times.

The point is that: If this/these features were added, it might save a non-trivial proportion of the Cura users a couple of seconds per G-Code file save, every time. Cura states, "Ultimaker Cura users worldwide prepare over 2 million prints per week."


If we assume the following assumptions and napkin math:

So, if those nominal metrics are even remotely close to accurate, then The time wasted: selecting an alternative save location, for all of the Cura prints (in single a week), could equate to about ~27.8x the amount of time it might take 1 developer to implement these features.

If you take 1/~27.8, we're talking .036; So, (Roughly speaking, in theory) only 3.6% of Cura prints would need to be affected by the same irritation that I experience, before it would seem worth while to have a dev spend ~1 week of time implementing these features.

I'm trying to justify the implementation of all of these potential features, while only looking at the value that is likely to be gained by just the inclusion of a 'Preferred Device' option regarding file-saving; doing so, knowing that these additional features: 'An Exclusion List', 'Preferred Folder Location', and 'A "Preferred Device(s)" hierarchy' would only further extend the reach of how many users would benefit.

Personally, I feel that these 'irritating' UI/implementation interactions are likely to affect more than 3.6% of prints being saved. Obviously, Cura Devs will have the kind of internal metrics to see how reasonable or unreasonable my nominal values are. But, again, even if my assumed values are off by an order of magnitude, we're looking at the impact for all of the Cura prints that occur (in single a week).

In conclusion:

I feel that: If the internal data shows that even just a few % of weekly prints are saved, in circumstances where more than one additional "Save to ..." device is available (beyond the user's OS Disk storage), then these features should be sincerely considered and brought forth in discussion for development.


If there's enough interest, I would be willing to spend more time creating a mock-up, simplified GUI in C++ that would help demonstrate the concept and value of this set of features.

Additional information & file uploads

No response

Slug-Cat commented 4 months ago

This feature would be appreciated. I face the same issues when using more than one flash drive on the same device.