veyeimaging / raspberrypi Goto Github PK
View Code? Open in Web Editor NEWVEYE camera module software on RaspberryPi
VEYE camera module software on RaspberryPi
This command (--no-preview before --save-pts):
./veye_raspivid --verbose --settings --timeout 2000 --output ~/Videos/testvid1.h264 --nopreview --save-pts > ~/Videos/testvid1.log 2>&1
yields the expected video recording and no preview on screen. Logfile:
camera num -1
veye_raspivid Camera App v1.3.12
Width 1920, Height 1080, filename /home/pi/Videos/testvid1.h264
bitrate 17000000, framerate 30, time delay 2000
H264 Profile high
H264 Level 4
H264 Quantisation level 0, Inline headers No
H264 Fill SPS Timings No
H264 Intra refresh type (null), period -1
H264 Slices 1
Wait method : Simple capture
Initial state 'record'Preview No, Full screen Yes
Preview window 0,0,1024,768
Opacity 255
mmal: mmal_component_enable w 1920 h 1080raspipreview_create com
Encoder component done
mmal: Splitter has 4 output port,you could use num 2,3 for extend
Splitter component done
Starting component connection stage
Connecting camera video port to encoder input port
Opening output file "/home/pi/Videos/testvid1.h264"
Enabling encoder output port
mmal: running now!!
Starting video capture
mmal: running stop!! 0
Finished capture
Closing down
Close down completed, all components disconnected, disabled and destroyed
However, this command (--save-pts before --nopreview):
./veye_raspivid --verbose --settings --timeout 2000 --output ~/Videos/testvid2.h264 --save-pts --nopreview > ~/Videos/testvid2.log 2>&1
generates the appropriate video, but ignores the --nopreview flag, as can be seen from the log file:
camera num -1
veye_raspivid Camera App v1.3.12
Width 1920, Height 1080, filename /home/pi/Videos/testvid2.h264
bitrate 17000000, framerate 30, time delay 2000
H264 Profile high
H264 Level 4
H264 Quantisation level 0, Inline headers No
H264 Fill SPS Timings No
H264 Intra refresh type (null), period -1
H264 Slices 1
Wait method : Simple capture
Initial state 'record'Preview Yes, Full screen Yes
Preview window 0,0,1024,768
Opacity 255
mmal: mmal_component_enable w 1920 h 1080raspipreview_create com
Encoder component done
mmal: Splitter has 4 output port,you could use num 2,3 for extend
Splitter component done
Starting component connection stage
Connecting camera video port to encoder input port
Opening output file "/home/pi/Videos/testvid2.h264"
Enabling encoder output port
mmal: running now!!
Starting video capture
mmal: running stop!! 0
Finished capture
Closing down
Close down completed, all components disconnected, disabled and destroyed0.000
33.332
66.663
99.993
133.326
166.657
199.988
233.321
266.654
299.982
Hello
when using veye_raspivid and using any other format then 1080*1920 it splits the video in half and display both halves wrong.
1080p is behaving normally, but 720 is not.changed bitrate and other settings, but nothing changes the behaviour.
We've
this is 1080x1920
I've attatched the exact commands
$ /usr/local/share/veye-raspberrypi/veye_raspivid -b 5120000 -w 1280 -h 720 -fps 30
camera num -1
Hardare version: 2a22082
mmal: mmal_component_enable w 1280 h 720 fps 30
raspipreview_create com
mmal: Splitter has 4 output port,you could use num 2,3 for extend
$ /usr/local/share/veye-raspberrypi/veye_raspivid -b 5120000 -w 1920 -h 1080 -fps 30
camera num -1
Hardare version: 2a22082
mmal: mmal_component_enable w 1920 h 1080 fps 30
raspipreview_create com
mmal: Splitter has 4 output port,you could use num 2,3 for extend
raspberrypi/i2c_cmd/bin/camera_i2c_config
Line 102 in 2b088f2
Please add c03112
to the list of boards here for newer Raspberry Pi 4 4GB revisions.
Hello! I tried capture2opencv example on CS-MIPI-SC132 and got a small FPS(12) on rpi 3b. After changing 3b to 4 I got a same FPS(12). It just reading a stream without any calculation! Which is the right way to use CS-MIPI-SC132 with opencv? I would like to change this example, but I don't know how this should work. How people use cameras like this in projects with small FPS (and latency). Previews work's well but they without opencv.
Thank you!
I want to use this camera together with VLC and / or third part NVR. Is it possible to feed RTSP- or mjpeg from this driver?
My configuration is Raspberry Pi 4/ 2G (latest buster) python3.7.1. Im using modified file video.py from examples:
def callback(data):
buff = Dcam.buffer(data)
print("one frame len %d" % buff.length)
file = buff.userdata
buff.as_array.tofile(file)
return 0
if __name__ == "__main__":
try:
camera = Dcam.mipi_camera()
print("Open camera...")
camera.init_camera()
**file = open("/home/pi/test.h264", "wb")**
# Need keep py_object reference
file_obj = ctypes.py_object(file)
camera.start_video_stream(callback, file_obj)
time.sleep(10)
camera.stop_video_stream()
file.close()
print("Close camera...")
camera.close_camera()
except Exception as e:
print(e)
My observations only on using python examples (elf programs that recording video that you provided have no issue):
Is this normal ? I can provide my video for better see this "artifacts" and issue that I've described. Could you please support? What I'm missing to get python video script working as well as veye_raspivid .
Any way there could be some Python sample code along with the C sample code. I'm struggling to understand how you guys wrangled MMAL in your application.
Thanks,
~ Rit
When try load libdmipicam.so, i recivie OSError: /lib/libdmipicam.so: undefined symbol: mmal_log_category
My setup: Rpi 4b OS: Linux raspberrypi 6.1.21-v8+ #1642 SMP PREEMPT Mon Apr 3 17:24:16 BST 2023 aarch64 GNU/Linux
I'm using VEYE-MIPI-327 camera module on Raspberry Pi and i try to set the longer shutter speed as possible.
I've found the mshutter setting (section 3.10 on i2c wiki) http://wiki.veye.cc/index.php/VEYE-MIPI-290/327_i2c/
The documentation say
value is exposure time(seconds)
I need to use the 327 module to take picture with exposure time between 1 to 10 seconds.
but I don't understand how to use this settings.
in section 3.16 (aespeed) i read
AE adjust speed,p1 is agc speed, p2 is shutter speed,Slow to Fast: [0,0x64]
But seems that nothing happens (but the i2c communication works)
It's possible to know the setting to take picture with longest time and greater sensitivity as possible?
Can we use the veye camera with Java code?
Questions:
Bug
Hi,
we realized that when writing a command to change camera settings with veye_mipi_i2c.sh, sometimes the camera settings change, and sometimes NOT. Apparently, the return-value does not depend on the actual state of the camera setting.
I think this is a bug and needs to be improved.
According to the documentation, as far as I understand, running veye_raspivid with the --initial flag set to "pause" should not output any video data until the state is set to "record", for example by using the --signal flag and sending a SIGUSR1 signal to the process.
However, running the following command yields a 5 second video recording:
./veye_raspivid --verbose --settings --timeout 5000 --initial pause --output /tmp/signal_pause.h264 --nopreview > /tmp/signal_pause.output 2>&1
No matter what I do with different flags, using signals, not using timeout, etc, I cannot make the "pause" state actually stop the recording.
Am I misunderstanding something, or is the pause state not actually implemented?
For reference, this is the output file from the command above:
camera num -1
veye_raspivid Camera App v1.3.12
Width 1920, Height 1080, filename /tmp/signal_pause.h264
bitrate 17000000, framerate 30, time delay 5000
H264 Profile high
H264 Level 4
H264 Quantisation level 0, Inline headers No
H264 Fill SPS Timings No
H264 Intra refresh type (null), period -1
H264 Slices 1
Wait method : Simple capture
Initial state 'pause'
Preview No, Full screen Yes
Preview window 0,0,1024,768
Opacity 255
mmal: mmal_component_enable w 1920 h 1080
raspipreview_create com
Encoder component done
mmal: Splitter has 4 output port,you could use num 2,3 for extend
Splitter component done
Starting component connection stage
Connecting camera video port to encoder input port
Opening output file "/tmp/signal_pause.h264"
Enabling encoder output port
mmal: running now!!
Pausing video capture
mmal: running stop!! 0
Finished capture
Closing down
Close down completed, all components disconnected, disabled and destroyed
When I execute the demo program written in C language, I get the following error
pi@raspberrypi:~/veye/raspberrypi/D_mipi_rpi/c_demo $ ./capture
Open camera...
mmal: mmal_component_enable w 1920 h 1080
Capture image dimage1920x1080.jpg...
Segmentation fault
pi@raspberrypi:~/veye/raspberrypi/D_mipi_rpi/c_demo $
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.