One thing to consider with your approach is writing your data to a log file (append) with each measurement rather than writing data from memory all at once. This would reduce data loss and would allow you to asynchronously download your data file whenever you like.
You can use the GPIO to provide a limited interface for you to trigger the data copy to a USB drive. You will need to mount, copy the file, and unmount your USB to assure reliable data transfer. You could implement this using interrupts to initiate a script and use a light emitting diode (LED) to indicate that the script executed and that it is safe to remove the USB drive. You can use different color LEDs to indicate script execution status.
Here is an article on interrupts that will get you started. A broader search on interrupts on the Raspberry Pi will find other references.
Here's a use case for how your system could work.
- Weather logger records data and writes to a log file. This happens asynchronously with respect to data transfer.
To copy log file data:
- Plug USB drive into Raspberry Pi.
- Press a button (debounced switch).
- LED (yellow) illuminates to indicate script execution start.
- Script mounts USB drive.
- Script copies log file to USB drive.
- Script unmounts USB drive.
- LED (green) illuminates to indicate success. (Or, LED (red) illuminates on error.)
- Remove USB drive.