1.Which seller did you purchase the product(s) from?
Scoprion Vision, UK
2.The Model number of the product(s) you have purchased?
U
3.Which Platform are you using the product(s) on?
RPi 4 32 bit Linux
4.Which instruction are you following?
Reading C code
5.Has your product ever worked properly?
This feature has not worked
6.What problems are you experiencing?
Hello,
I’m trying to set the lens table of an UC-572 camera with the following code:
int ArduGrab::initCamera() {
int res;
log(“init camera”);
if (!cameraConnected) {
if (!this->sim) {
res = arducam_init_camera(&this->camera_instance);
if (res) {return -1;}
string str = “/home/pi/ArduGrab/imx298/ls_table_4656x3496.h”;
log("setting lens table from " + str);
char *path = new char[str.length() + 1];
strcpy(path, str.c_str());
arducam_set_lens_table(camera_instance, path);
delete [] path;
res = arducam_set_mode(camera_instance, 4);
if (res) {return -1;}
}
cameraConnected = true;
}
log(“init camera done”);
return 0;
}
However, this isn’t working, the output when testing this is:
pi@raspberrypi:~/ArduGrab $ ./run-c+±test.sh
set debug true
set sim false
init camera
Found sensor imx298 at address 1A
setting lens table from /home/pi/ArduGrab/imx298/ls_table_4656x3496.h
mmal: Failed to fix lens shading, use the default mode!
Just to check that we are pointing to the correct file:
pi@raspberrypi:~/ArduGrab $ ls -al /home/pi/ArduGrab/imx298/ls_table_4656x3496.h
-rw-r–r-- 1 pi pi 14348 Jun 15 17:39 /home/pi/ArduGrab/imx298/ls_table_4656x3496.h
Can you help advise as to the reason from the problem please?
Thanks.
Regards,
Neil
7.What attempts at troubleshooting have you already made?
Wrriten code and debugged it
8.How would you like us to help you?
advise on settign lens table