How to make DNG Remote Shoot without capturing the picture?
Remoteshoot is pretty complicated and tightly connected to the shooting process, so you'll need to dig into both the chdkptp and camera side code. I think the actual capture_get_data stuff should be mostly but you need a new camera side script (rlibs.lua rs_shoot) to initiate it. On the CHDK side you'd need to make sure remotecap_is_ready and remotecap_get_data_chunk do the right thing.
If your shooting process calls the raw hook code this might "just work", as long as init_usb_capture is called from lua with appropriate values beforehand.
i.e. camera's raw buffer already contains raw data and I need to create DNG file on PC without saving it on SD card.
Or maybe there is a simple way to create DNG file in RAM?
You could use con:getmem to just read the data directly, and then reverse byte order and combine it with a pre-exisiting DNG header. Note getmem returns a lua string, which you'd need to convert to an lbuf to use the existing chdkptp DNG code.
I should add an lbuf option added in r829.
The CHDK DNG header code relies on propcases which probably aren't valid if you aren't using the normal shoot process, so using a fake header may not be much of a disadvantage.
Most of the propcases should update in halfshoot, so you could potentially get reasonable data if the non-shoot exposure uses those values.