WMR camera interface.
More...
#include <asm/byteorder.h>
#include <libusb.h>
#include <stdlib.h>
#include <assert.h>
#include "math/m_api.h"
#include "os/os_threading.h"
#include "util/u_autoexpgain.h"
#include "util/u_debug.h"
#include "util/u_var.h"
#include "util/u_sink.h"
#include "util/u_frame.h"
#include "util/u_trace_marker.h"
#include "wmr_config.h"
#include "wmr_protocol.h"
#include "wmr_camera.h"
|
#define | WMR_CAM_TRACE(c, ...) U_LOG_IFL_T((c)->log_level, __VA_ARGS__) |
|
#define | WMR_CAM_DEBUG(c, ...) U_LOG_IFL_D((c)->log_level, __VA_ARGS__) |
|
#define | WMR_CAM_INFO(c, ...) U_LOG_IFL_I((c)->log_level, __VA_ARGS__) |
|
#define | WMR_CAM_WARN(c, ...) U_LOG_IFL_W((c)->log_level, __VA_ARGS__) |
|
#define | WMR_CAM_ERROR(c, ...) U_LOG_IFL_E((c)->log_level, __VA_ARGS__) |
|
#define | CAM_ENDPOINT 0x05 |
|
#define | NUM_XFERS 4 |
|
#define | WMR_CAMERA_CMD_GAIN 0x80 |
|
#define | WMR_CAMERA_CMD_ON 0x81 |
|
#define | WMR_CAMERA_CMD_OFF 0x82 |
|
#define | DEFAULT_EXPOSURE 6000 |
|
#define | DEFAULT_GAIN 127 |
|
#define | WMR_FRAMETYPE_SLAM 0x0 |
|
#define | WMR_FRAMETYPE_CONTROLLER 0x2 |
|
#define | WMR_DEBUG_SINK_SLAM 0 |
|
#define | WMR_DEBUG_SINK_CONTROLLER 1 |
|
◆ update_expgain()
◆ wmr_cam_usb_thread()
static void * wmr_cam_usb_thread |
( |
void * |
ptr | ) |
|
|
static |
- Todo:
- Think this is not needed? what condition are we waiting for?
◆ wmr_camera_set_exposure_gain()
int wmr_camera_set_exposure_gain |
( |
struct wmr_camera * |
cam, |
|
|
uint8_t |
camera_id, |
|
|
uint16_t |
exposure, |
|
|
uint8_t |
gain |
|
) |
| |
Set manual exposure and gain values.
- Parameters
-
cam | Camera container |
camera_id | Which camera to affect |
exposure | Time the shutter is open, observed values 60-6000. |
gain | Amplification of the analog signal, observed values: 16-255. |
Referenced by update_expgain().
◆ wmr_camera_start()
◆ camera_id2
◆ exposure
observed 60 to 6000 (but supports up to ~9000)
◆ gain