I got chdkptp to work and connect to the camera. I can also use gphoto to see files on the camera under linux. I am completely inexperienced with lua scripting. It seems that most commands like 'ls' or file transfer in chdkptp return with "compile error" so I must need to build or install something on the camera side i think. There must be a tutorial on this somewhere.
As I mentioned, you need kdb_task running for anything involving lua script to work (this isn't obvious, but all CHDK scripting runs in kdb_task).
You also need the modules files in CHDK/MODULES. These should be updated any time you build anyway.
without kbd_task, you should be able to use the rmem to read memory from the camera, and the download and upload commands with the -nolua option.
The help command will give you a list of chdkptp commands, or details of a specific command, but again, most camera commands will be broken until you have kbd_task working.