Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
L
linux-elphel
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
linux-elphel
Commits
20671814
Commit
20671814
authored
Sep 21, 2016
by
Andrey Filippov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
improved switching trigger modes
parent
2e959354
Changes
2
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
94 additions
and
74 deletions
+94
-74
mt9x001.c
src/drivers/elphel/mt9x001.c
+59
-41
pgm_functions.h
src/drivers/elphel/pgm_functions.h
+35
-33
No files found.
src/drivers/elphel/mt9x001.c
View file @
20671814
This diff is collapsed.
Click to expand it.
src/drivers/elphel/pgm_functions.h
View file @
20671814
...
...
@@ -87,7 +87,7 @@ int add_sensor_proc(int port, int index, int (*sens_func)(int sensor_port, struc
#define SET_SENSOR_MBPAR(p,f,s,r,v) { pars_to_update[nupdate ].num= P_SENSOR_REGS+(r) ;\
pars_to_update[nupdate++].val=(v);\
X3X3_I2C_SEND2((p), (f), (s), (r), (v)); \
int _MINDEX= MULTIREG(p,P_SENSOR_REGS+(r),0); \
{
int _MINDEX= MULTIREG(p,P_SENSOR_REGS+(r),0); \
if (_MINDEX) { \
EDBG(if (GLOBALPARS(G_DEBUG) & (1 <<4)) printk("%s:%d:%s _MINDEX=0x%x, v=0x%x, FRAMEPAR_MODIFIED(_MINDEX)=0x%x\n",__FILE__,__LINE__,__FUNCTION__, _MINDEX, (int) (v), (int) FRAMEPAR_MODIFIED(_MINDEX) ));\
if (!FRAMEPAR_MODIFIED(_MINDEX)) { \
...
...
@@ -107,6 +107,7 @@ int add_sensor_proc(int port, int index, int (*sens_func)(int sensor_port, struc
pars_to_update[nupdate++].val=(v);\
} \
} \
} \
}
/**Set parameter for the same register in multiple multiplexed sensors and send to hardware i2c sequencer
* Similar to SET_SENSOR_MBPAR, but it does not update "parent" parameter, only individual ones.
...
...
@@ -120,6 +121,7 @@ int add_sensor_proc(int port, int index, int (*sens_func)(int sensor_port, struc
* @param v value to set (16 bits)
* @see SET_SENSOR_MBPAR */
#define SET_SENSOR_MBOPAR(p,f,s,r,v) { X3X3_I2C_SEND2((p), (f), (s), (r), (v)); \
{ \
int _MINDEX= MULTIREG(p,P_SENSOR_REGS+(r),0); \
EDBG(if (GLOBALPARS(G_DEBUG) & (1 <<4)) printk("%s:%d:%s _MINDEX=0x%x, v=0x%x, FRAMEPAR_MODIFIED(_MINDEX)=0x%x\n",__FILE__,__LINE__,__FUNCTION__, _MINDEX, (int) (v), (int) FRAMEPAR_MODIFIED(_MINDEX) ));\
if (_MINDEX) { \
...
...
@@ -140,10 +142,10 @@ int add_sensor_proc(int port, int index, int (*sens_func)(int sensor_port, struc
pars_to_update[nupdate++].val=(v);\
} \
} \
} \
}
/**Set individual (multiplexed) sensor parameter (and send to hardware i2c sequencer)
* Do nothing if there is no individual parameter reserved
* @param p Sensor port number
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment