Bavo Van Achte
/
MLX90418_I2C_master
Fork
Diff: main.cpp
- Revision:
- 4:8d7322108eb7
- Parent:
- 3:557d5725b1bb
- Child:
- 5:daab0e0e67e2
--- a/main.cpp Fri Dec 18 10:25:46 2020 +0000 +++ b/main.cpp Tue Jan 12 12:01:27 2021 +0000 @@ -66,7 +66,7 @@ #define NV_SOFT_STEP_SIZE 6 #define NV_START_UP_TIME 0 - #define OTP_I2C_STARTUP_DATA_H (0x00 << NV_SOFT_START) | (0x00 << NV_LONG_START) | (0x03 << NV_COMM_START_NUM) | (0x03 << NV_START_DUTY) + #define OTP_I2C_STARTUP_DATA_H (0x00 << NV_SOFT_START) | (0x00 << NV_LONG_START) | (0x02 << NV_COMM_START_NUM) | (0x03 << NV_START_DUTY) #define OTP_I2C_STARTUP_DATA_L (0x03 << NV_SOFT_STEP_SIZE) | (0x24 << NV_START_UP_TIME) #define OTP_I2C_STARTUP_ADDR_H 0x13 @@ -90,7 +90,7 @@ wait_ms(2000); //reset the FPGA for 2s fpga_rstb = 1; //enable FPGA wait_ms(1); -/* + //Postion Test Pulse setting char i2cPositionPulseRead[4] = {OTP_I2C_POSITIONPULSE_ADDR_H, \ OTP_I2C_POSITIONPULSE_ADDR_L, \ @@ -114,13 +114,13 @@ fpga_rstb = 0; //disable FPGA }; } -*/ + -/* + //Start Up setting - char i2cStartUpPulseRead[4] = {OTP_MOTOR_START_ADDR_H, \ - OTP_MOTOR_START_ADDR_L, \ + char i2cStartUpPulseRead[4] = {OTP_I2C_STARTUP_ADDR_H, \ + OTP_I2C_STARTUP_ADDR_L, \ 0x00, \ 0x00}; i = 3; @@ -141,7 +141,7 @@ fpga_rstb = 0; //disable FPGA }; } -*/ + //ack+=i2c_word_write(i2c_master,i2cMotorStartSetup);