iizukanao / picam-streamer

Out-of-the-box SD card image for live streaming with Raspberry Pi
MIT License
62 stars 6 forks source link

Instructions? #40

Closed jpt000 closed 2 years ago

jpt000 commented 5 years ago

Picam-server works great out of the box. Nevertheless it would be nice to have a little more information, namely on how to change settings. Took me a couple of hours to figure out where to look: /home/pi/picam-streamer/lib/server.js Thanks for the hard work! Very much appreciated!

kerwinf commented 4 years ago

I am starting to use this for a RPi0w and am curious how to set default values at launch. My camera seems to have too much red so all the colors are off. Everything is pinkish purple.

iizukanao commented 4 years ago

@jpt000 Sorry, I missed your message!

@kerwinf You might want to set white balance using picam's --wb <value> option. You can add picam options by editing line 44 of /home/pi/picam-streamer/lib/server.js like this:

    picam = child_process.spawn('nice', ['-n', '-20', 'ionice', '-c1', '-n0', 'sudo', '-u', "#" + PICAM_UID, PICAM_PATH, '--rtspout', '--alsadev', 'hw:1,0', '--wb', 'fluorescent' ], {
iizukanao commented 4 years ago

See https://github.com/iizukanao/picam#command-options for the list of picam options.

TomTomCountry commented 2 years ago

You have done a really great job. I finally got my picam running after trying for some weeks in my freetime. But I still struggle to rotate the picture. I have added the '--rotation 180' to the server.js file, but it seems not working. I even tried to put it in brackets <>. So I will be thankful for any tip ;-) And maybe some very basics for the most, but how can I restart picam-streamer via ssh without rebooting? Thanks in advandce

iizukanao commented 2 years ago

@TomTomCountry Hi, thanks for using picam-streamer! sudo service picam-streamer restart will do the job!

iizukanao commented 2 years ago

As for rotation, could you share the line you have edited?

TomTomCountry commented 2 years ago

Hi @iizukanao sure, here is the line for the rotation picam = child_process.spawn('nice', ['-n', '-20', 'ionice', '-c1', '-n0', 'sudo', '-u', "#" + PICAM_UID, PICAM_PATH, '--rtspout', '--alsadev' , '--rotation 180', 'hw:1,0'], { Thanks for your fast response :)

iizukanao commented 2 years ago

@TomTomCountry You have to write '--rotation', '180' instead of '--rotation 180'. Also, there must be 'hw:1,0' right after '--alsadev', so put '--rotation', '180' at the very end of the arguments.

picam = child_process.spawn('nice', ['-n', '-20', 'ionice', '-c1', '-n0', 'sudo', '-u', "#" + PICAM_UID, PICAM_PATH, '--rtspout', '--alsadev', 'hw:1,0', '--rotation', '180'], {