Tiny Core Linux
Tiny Core Base => Raspberry Pi => Topic started by: goetzmoritz on March 07, 2016, 01:43:48 AM
-
Hi there,
I'm trying to get my pi camera to run.
I installed a v7 piCore image on my just unpacked class 10 sd-card (8 gig).
After burning image to the sd card I added
gpu_mem=128
start_file=start_x.elf
fixup_file=fixup_x.dat
to boot/config.txt
After that:
tce-load -wi rpi-vc.tcz
and than:
chmod 777 /dev/vchiq
finally:
filetool.sh -b
reboot
When I try to activate the camera, I get this:
tc@box:~$ raspistill -t 5000
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
mmal: Failed to create camera component
mmal: main: Failed to create camera component
mmal: Camera is not detected. Please check carefully the camera module is installed correctly
To verify that it's not my hardware I did not touch anything, changed the sd-card to working raspbian and took an image whiched worked well.
I'm using rpi1-B with standard camera module and I'm connected to the pi via ssh.
I also tried the -n option in case it's a preview-issue.
Any suggestions? Thanks!!!!
-
Hi goetzmoritz
gpu_mem=128
start_file=start_x.elf
fixup_file=fixup_x.dat
According to this:
https://www.raspberrypi.org/forums/viewtopic.php?f=43&t=39996&sid=762c27cb9ea1a3d6b3a6ccbe1e8ec5dc&start=25
the syntax is:
start_file=start_x.elf
start_fixup=fixup_x.dat
That was from Apr 11, 2013 4:42 am so maybe that has changed.
and than:
Code: newbielink:javascript:void(0); [nonactive]
chmod 777 /dev/vchiq
finally:
Code: newbielink:javascript:void(0); [nonactive]
filetool.sh -breboot
The /dev directory gets rebuilt from scratch after every boot. You should probably add the chmod line to your
bootlocal.sh file.
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
Thise site suggests possible cable problems for that error:
http://elinux.org/Rpi_Camera_Module#Camera_not_working_at_all
-
According to this:
https://www.raspberrypi.org/forums/viewtopic.php?f=43&t=39996&sid=762c27cb9ea1a3d6b3a6ccbe1e8ec5dc&start=25
the syntax is:
Code: [Select]
start_file=start_x.elf
start_fixup=fixup_x.dat
That was from Apr 11, 2013 4:42 am so maybe that has changed.
I tried it but it didn't help. When I look at the startup of my working raspbian it only showes me the gpu_mem=128 line but start_file and fixup are missing there.
The /dev directory gets rebuilt from scratch after every boot. You should probably add the chmod line to your
bootlocal.sh file.
good hint. I forgot about that.
Thise site suggests possible cable problems for that error:
http://elinux.org/Rpi_Camera_Module#Camera_not_working_at_all
Unfortunately no, as I mentioned above the camera is working when I insert a sd-card with raspbian so a hardware-issue is not possible. Also I changed the raspberry, sd card (burned the image to a brand new one) and the camera and it didn't help.
-
Hi goetzmoritz
I tried it but it didn't help. When I look at the startup of my working raspbian it only showes me the gpu_mem=128 line but start_file and fixup are missing there.
Try removing start_file and fixup and check for or add this to config.txt:
start_x=1
As per:
http://elinux.org/RPiconfig#Camera
-
Using the 7.1beta1
Just tested this on Pi3, camera not working
Same SDcard works on old Pi B.
Putting "start_x=1" in config.txt works, must be related to new 4.1.18?
Seem to remember something on the Raspberry forums about different GPIO/I2C pin are used on Pi 3.
Lots of activity in Raspberry Pi userland re vc last few days.
So probably rpi-vc.tcz will need be to be updated.
-
Hi Goetzmoritz
Just tried the camera on a Pi 3 with latest Raspbian with updates and 4.1.19 kernel.
Bit low on power as it was running from a PC USB port, 3's do need lots of power.
Got the little 4 color square on the monitor that indicates low voltage.
Had that same message until I used raspi-config to enable the camera.
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
mmal: Failed to create camera component
mmal: main: Failed to create camera component
mmal: Camera is not enabled in this build. Try running "sudo raspi-config" and ensure that "camera" has been enabled
Camera now working, have not tested everything but "sudo raspistill -d" works.
Just tested same Raspbian SDcard on old B with same camera, still works.
I test with Raspbian as well to find out if camera is not working or software faulty.
At the moment I think rpi-vc.tcz and/or kernel needs an upgrade in piCore for Pi 3's.
Sometimes the connector is not in perfectly.
Also had one a bit dirty, it worked after a clean, take care about static.
I assume the camera chip needs to be setup via the i2c commands first before image can be taken.
Some sort of IO expander is used on Pi3, GPIO/I2C messed up, fixed in Raspbian not yet in piCore?
Think Bela is working on it for next release.
Sure wish we had a schematic for 2 and 3.
U20 is a i2c multiplexer or I/O expander, tiny 16 pin part on the 3.
Rumour is, it has something to do with the WiFi chip and maybe the LEDs.
There is also supposed to be some control for the switch mode power chip that is on the 2 and 3.
Probably a reason Raspberry Org don't want people to know how this bit works;)
Magic smoke and mirrors stuff.
Somebody will figure it out and get us water cooled 1.5GHz Pi3's :P
Gavin
-
Only a few makers of i2c chips.
Ti no luck with matching package shape.
NXP has a PCA6404 in a XQFN16 that looks about right.
Address 0x43 would match the rumored one if Addr input is tied high.
All this probably relevant to WiFi/Bluetooth chip, SW power and LEDs.
If controlled by the VPU/GPU, going to be harder for mere mortals to figure out.
Or maybe the PCAL6408A?
Topside marking don't match?
MCP23S09? nope 3x3mm
Someone been here
https://www.raspberrypi.org/forums/viewtopic.php?f=63&t=138280&p=922287&hilit=GPIO+expander#p922287
-
Confirmed Pi 2 and camera also not working with piCore 4.1.19 with rpi-vc.tcz.
But does on Raspbian, still need better power supply just in case it's that.
Tends to confirm a change in the way 2 and 3's talk to the camera.
In Raspbian the bin files are in /opt/vc/... piCore puts the rpi-vc.tcz files elsewhere - /usr/local...
Swap the files in Raspbian into a new rpi-vc.tcz?
Had not tried camera on a Pi 2 before, got so many old A and B's still to use up.
Need it to work for WiFi Pi 3 robots. Pi 3 going to be interesting for OpenCV.
-
Also having the same errors with an R-Pi2 and camera board. Tested on 7 Final, beta1 and beta2.
Brand new install. Only changes are:
config.txt has:
start_x=1
gpu_mem=128
start_file=start_x.elf
start_fixup=fixup_x.dat
bootlocal.sh has: (Then backed up)
chmod 777 /dev/vchiq
Installed rpi-vc using:
tce-load -wi rpi-vc
vcgencmd get_camera:
supported=1, detected=0
vcgencmd get_mem arm:
arm=880M
vcgencmd get_mem gpu:
gpu=128M
raspistill -o test.jpg:
mmal: mmal_vc_component_create: failed to create component 'vc.ril.camera' (1:ENOMEM)
mmal: mmal_component_create_core: could not create component 'vc.ril.camera' (1)
mmal: Failed to create camera component
mmal: main: Failed to create camera component
mmal: Camera is not enabled in this build. Try running "sudo raspi-config" and ensure that "camera" has been enabled
The camera LED flashes for a brief moment the first time after boot when you do anything with the camera like raspistill, raspivid, vcgencmd get_camera. But it will only do it once until you reboot.
I've had the camera working in the past. Only just come back to this project and can't find my old SD card with a working version on.
[edit]
Just tested a fresh raspbian install, enabled camera and ran raspistill -o test.jpg and it worked fine. So it's not my camera.
[/edit]
-
supported=1, detected=0
I think it needs i2c comms to detect a camera chip.
The rpi-vc.tcz is old and not Pi2/3 compatible?
If you know how to do it, you could grab these files and make a new rpi-vc.tcz
https://github.com/raspberrypi/firmware/tree/master/opt/vc
-
Ok, I got the camera working again. I had to edit the config.txt file and change the Enable peripheral buses dtparam line
From:
dtparam=i2c=on,spi=on,i2s=on,i2c_vc=on
To:
dtparam=i2c=on,spi=on,i2s=on,i2c_vc=off
Doing this vcgencmd get_camera now shows as detected=1 and raspivid and raspistill work fine.
-
Hi mosimo,
Well done, nice detective work.
It works on my Pi2's and 3's, need to turn i2c_vc=off.
dtparam=i2c=on,spi=on,i2s=on,i2c_vc=off
Now to get WiFi going.
Gavin
-
I'm running into the same issue with Picore 7.07 on my Raspberry Pi Zero. I've set my config.txt file the same as listed about:
start_x=1
gpu_mem=128
start_file=start_x.elf
start_fixup=fixup_x.dat
as well as the bit about:
...i2c_vc=off
I've updated the permissions on /dev/vchiq, added the rpi-vc module, backed up and rebooted.
When I run vcgencmd get_camera i get:
supported=0 detected=0
I've verified my camera works on Arch Linux, Raspian, and a few others. Any suggestions on what I might try. This is the very last piece to me being able to use Tiny Core on my pi instead of Arch Linux... and I really want to use TC. TC freaking rocks!
Thanks for any input and Thank you very much for the RPI build of TC!
-
Also to note, this is a cheaper Ebay camera:
http://www.ebay.com/itm/Night-Vision-IR-Surveillance-Camera-2-Pcs-3W-Infrared-Light-For-Raspberry-Pi-/262351644157?hash=item3d156065fd:g:RuEAAOSwoudW9Il5 (http://www.ebay.com/itm/Night-Vision-IR-Surveillance-Camera-2-Pcs-3W-Infrared-Light-For-Raspberry-Pi-/262351644157?hash=item3d156065fd:g:RuEAAOSwoudW9Il5)
Says it has a Omnivision 5647 sensor on it. Not sure if the rpi-vc package only knows how to talk to a certain set of cameras or if they are all fairly standard... Just thought I'd mention this just in case.
-
Went a ahead and took a stab at compiling userland myself. Got the compile-essentials package, git, cmake and a few others. I was able to clone the userland and compile it following a tutorial I found:
http://www.stuffaboutcode.com/2013/08/compile-raspberry-pi-userland-raspivid.html
I then used the squashfs to build a new tcz, generated a new md5 and copied both to the tce/optional dir on the 2nd partition. Looks like my compiled module loads without issue but a called to:
vcgencmd get_camera
is still yielding
supported=0 detected=0 :(
I think I'm about tapped out on ideas.
Thanks in advance to anyone that can help. It would be much appreciated!
-
Have you tried with root permissions?
Also give the latest 8.0beta5 a test. That is using the latest 4.4.19 kernel.
-
Finally came across a TC forum link:
http://forum.tinycorelinux.net/index.php?topic=20220.0
Someone with a zero was able to clone the official Raspberry Pi firmware repository:
https://github.com/raspberrypi/firmware
and build a TCZ with the contents of "/hardfp/opt/vc"
I got really excited, clone the repo built the TCZ, generated the checksum and tried it... :( I'm still getting:
supported=0
from:
vcgencmd get_camera
-
Finally... success!
While I wasn't able to get the current PiCore 7 stable release to work with the camera on my zero, I was able to get the latest PiCore 8 release candidate and add the rpi-vc.tcz package from the 7 repo. After doing this, vcgencmd get_camera reports supported=1 detected=1! And alas raspistill takes a picture!
I've only been using the PiCore RC 8 for a short time, but it appears to be stable. My RT8188CUS wifi dongle is working well with the rtl firmware package.
Thanks again to the TC team. Tiny core is awesome!
-
I've only been using the PiCore RC 8 for a short time, but it appears to be stable. My RT8188CUS wifi dongle is working well with the rtl firmware package.
Thanks for the feedback. It looks really stable and uptudate both in kernel and core components, so it will turn to final soon.