The shooting needs to be triggered from either the USB 5V trigger, or the separate remote trigger on the G15. Basically we can't trigger it from the computer connected by USB (but we can initiate picture transfer from the computer if needed). As a last resort we can have the camera triggering itself at an interval, but we'd like to avoid that.
If you could find a way to make triggering form the computer acceptable, you could use the "remote shoot" function in chdkptp shoot and download immediately. On a PC, this is generally about as fast as saving the to the SD card. Shooting and downloading would still be sequential (unless you use the cameras continuous mode) but it should take no longer than regular shoot.
The shooting triggers will be between 500-1000ms apart (possibly inconsistent) and the camera needs to be fairly responsive to the triggers (something like 50 ms delay is fine).
According to
http://www.usa.canon.com/cusa/support/professional/professional_cameras/digcameras/powershot_g15?selectedName=Specifications continuous shooting on G15 is good for 2.1 shots/sec, so it is extremely unlikely you will get 500ms between non-continuous shots.
50 ms trigger time is also likely to be optimistic, although it may be possible with the USB remote.
The USB transfer will be slower than normal, so it's almost guaranteed there will be a backlog of pictures waiting to transfer.
Leaving aside whether there is a practical way to do it, shooting in parallel to downloading would not be a good idea. The camera allows only a very limited number of file handles to be open at a given time, so it's likely you would encounter crashes.
The pictures have to be taken consistently, so we can't alternate between shooting and transferring.
Have you considered using and eye-fi or similar card? AFAIK modern Canon cameras disable it while shooting, but this can be overridden with the eye-fi code in CHDK 1.3. See
http://chdk.setepontos.com/index.php?topic=10750.0 and
http://chdk.setepontos.com/index.php?topic=6753.80We haven't found a way to monitor the non-USB trigger on the G15 through a script
I don't know anything about the Canon remote, but it's quite likely that you could see it's state in physw_status.
and it seems we can't monitor the USB 5V trigger and do USB data transfer at the same time.
Correct. The USB remote trigger relies on the USB power signal. If you have a real connection, this is on all the time. The normal USB remote modes hide status of the of the USB power signal, otherwise the camera would switch to PTP mode when you power it on, and switch back when you power it off. A possible workaround is discussed in
http://chdk.setepontos.com/index.php?topic=8769.80