stetsmando / pi-camera

A Node.js wrapper for the native Raspberry Pi camera utilities
MIT License
74 stars 17 forks source link

Timeout not being read as a valid option #12

Closed cdoern closed 6 years ago

cdoern commented 6 years ago

I am using the timeout option to make a 20 second long video. My options are: const myCamera = new PiCamera({ mode: 'video', output: '//home//pi//Videos//video.h264', width: 640, height: 480, timeout: 20000, nopreview: true, vflip: true, });

throws an error: "Invalid command line option (--timeout)"

cdoern commented 6 years ago

I manually removed timeout from the flags.json file and it seems to have fixed the issue. having it in both options and flags does not make sense. If there is a better fix for this please let me know

stetsmando commented 6 years ago

Yeah this makes sense. Let me look into this a bit. I think it has to do with some mismatch between the flags and the options but I'm not 100% sure. I haven't looked at this code in well over a year so I need to refresh my memory a bit.

stetsmando commented 6 years ago

Yup totally a bug. I'm fixing it now 👍

stetsmando commented 6 years ago

Should be fixed now. Pull the latest patched version. I'll leave this open until I've heard back or enough time has passed.

stetsmando commented 6 years ago

@cdoern ☝️

stetsmando commented 6 years ago

Also I've added a section on Flags and Options to hopefully help with any confusion