|
37 | 37 | #define IMX500_IMAGE_ONLY_FALSE 0x00
|
38 | 38 | #define IMX500_IMAGE_ONLY_TRUE 0x01
|
39 | 39 |
|
| 40 | +#define IMX500_REG_SENSOR_TEMP_CTRL CCI_REG8(0x0138) |
| 41 | + |
40 | 42 | #define IMX500_REG_ORIENTATION CCI_REG8(0x101)
|
41 | 43 |
|
42 | 44 | #define IMX500_XCLK_FREQ 24000000
|
@@ -2505,6 +2507,14 @@ static int imx500_start_streaming(struct imx500 *imx500)
|
2505 | 2507 | if (ret < 0)
|
2506 | 2508 | return ret;
|
2507 | 2509 |
|
| 2510 | + /* |
| 2511 | + * Disable the temperature sensor here - must be done else loading any |
| 2512 | + * firmware fails... |
| 2513 | + * |
| 2514 | + * Re-enable before stream-on below. |
| 2515 | + */ |
| 2516 | + cci_write(imx500->regmap, IMX500_REG_SENSOR_TEMP_CTRL, 0, &ret); |
| 2517 | + |
2508 | 2518 | ret = cci_write(imx500->regmap, IMX500_REG_IMAGE_ONLY_MODE,
|
2509 | 2519 | imx500->fw_network ? IMX500_IMAGE_ONLY_FALSE :
|
2510 | 2520 | IMX500_IMAGE_ONLY_TRUE,
|
@@ -2599,6 +2609,9 @@ static int imx500_start_streaming(struct imx500 *imx500)
|
2599 | 2609 | /* Disable any sensor startup frame drops. This must be written here! */
|
2600 | 2610 | cci_write(imx500->regmap, CCI_REG8(0xD405), 0, &ret);
|
2601 | 2611 |
|
| 2612 | + /* Re-enable the temperature sensor. */ |
| 2613 | + cci_write(imx500->regmap, IMX500_REG_SENSOR_TEMP_CTRL, 1, &ret); |
| 2614 | + |
2602 | 2615 | /* set stream on register */
|
2603 | 2616 | cci_write(imx500->regmap, IMX500_REG_MODE_SELECT, IMX500_MODE_STREAMING,
|
2604 | 2617 | &ret);
|
|
0 commit comments