Using Arducam Panorama with Arduino Mega

Hi,

I am attempting to follow the following link to use an ArduCAM 4 Cameras Adapter Board, with 4 OV5642 (I believe) cameras:

http://www.arducam.com/arduino-panorama-photography-arducam/

However, the code it says to use links to a 404. I googled the name of the link and found this code: https://github.com/sumotoy/ArduCAM/blob/master/examples/mini/ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower/ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower.ino

I've already gotten the ArdCAM library from https://github.com/ArduCAM/Arduino

However, when I click upload, I receive an error. I've been attempting to fix these errors by editing the arducam.h file and the code. First I received an error that VSYNC_LEVEL_MASK was not declared, so I went into the arducam.h file and commented out the "if !define" statements preceding the definitions of VSYNC_LEVEL_MASK in order to make sure they get defined. This them revealed another problem that cam1 cam2 cam3 and cam4 were not declared, so I just declared them at the top of the actual code as cam1 = true; cam2 = true; etc. This worked but then I received this set of errors: In file included from

C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ov5642_regs.h:3:0,

from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:455,

from C:\Users\user1_000\Dropbox\Documents\Arduino\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower.ino:16:

C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:348:8: error: redefinition of 'struct sensor_reg'

struct sensor_reg {

^

In file included from C:\Users\user1_000\Dropbox\Documents\Arduino\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower.ino:16:0:

C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:348:8: error: previous definition of 'struct sensor_reg'

struct sensor_reg {

^

In file included from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ov5642_regs.h:3:0,

from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:455,

from C:\Users\user1_000\Dropbox\Documents\Arduino\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower.ino:16:

C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:359:7: error: redefinition of 'class ArduCAM'

class ArduCAM

^

In file included from C:\Users\user1_000\Dropbox\Documents\Arduino\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower.ino:16:0:

C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:359:7: error: previous definition of 'class ArduCAM'

class ArduCAM

^

In file included from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ov2640_regs.h:3:0,

from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:463,

from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ov5642_regs.h:3,

from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:455,

from C:\Users\user1_000\Dropbox\Documents\Arduino\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower.ino:16:

C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:348:8: error: redefinition of 'struct sensor_reg'

struct sensor_reg {

^

In file included from C:\Users\user1_000\Dropbox\Documents\Arduino\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower.ino:16:0:

C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:348:8: error: previous definition of 'struct sensor_reg'

struct sensor_reg {

^

In file included from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ov2640_regs.h:3:0,

from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:463,

from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ov5642_regs.h:3,

from C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:455,

from C:\Users\user1_000\Dropbox\Documents\Arduino\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower.ino:16:

C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:359:7: error: redefinition of 'class ArduCAM'

class ArduCAM

^

In file included from C:\Users\user1_000\Dropbox\Documents\Arduino\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower\ArduCAM_Mini_5MP_4Cams_TimeElapse2SD_LowPower.ino:16:0:

C:\Users\user1_000\Dropbox\Documents\Arduino\libraries\ArduCAM/ArduCAM.h:359:7: error: previous definition of 'class ArduCAM'

class ArduCAM

^

exit status 1 Error compiling for board Arduino/Genuino Mega or Mega 2560.

I need this to work ASAP. What am I doing wrong? I assume starting over from the original code is likely good, I'm fairly beginner with all this.

Thanks!