寄存器的读写问题。根据7.6.1的Table 10 寄存器地址 从0x00~0x28 , 我若使用Table 5 中的命令操作寄存器, 是不是寄存器地址右对齐即可? 那么我写入DEVICE_ID_REG的DEVICE_ADDR=0x0f , 命令是不是 11010_00_000000000<9-bit address>_0x000f<16-bit data>? READ_HWORD读回这个数据,命令是不是 11001_xx_000000000<9-bit address>_00000000_00000000?
wenbo liu1:
resetread REG_ID order=c8000000 , return= 809f0000, advalue = 59625read REG_RANGE order=c8160000 , return= 809f0000, advalue = 59625write REG_ID 0x0f, order=d0000000, return=0write REG_RANGE 0x04, order=d0160004, return=0read REG_ID order=c8000000 , return= 80ab0000, advalue = 64125read REG_RANGE order=c8160000 , return= 80ab0000, advalue = 64125
wenbo liu1:
回复 wenbo liu1:
resetread REG_ID, order=c8000000 , return= 80a30000, advalue = 61125read REG_RANGE, order=c8160000 , return= 80a30000, advalue = 61125write REG_ID 0x0f, order=d000000f, return=0write REG_RANGE 0x04, order=d0160004, return=0read REG_ID, order=c8000000 , return= 80930000, advalue = 55125read REG_RANGE, order=c8160000 , return= 80930000, advalue = 55125
刚才的write REG_ID 0x0f, order=d000000f, return=0 格式不对
wenbo liu1:
问题还是没有解决,寄存设置不了
wenbo liu1:
回复 wenbo liu1:
问题自己解决了,寄存器寻址错误
WenJia Tian:
回复 wenbo liu1:
请问一下你的联系方式 我也碰到类似的问题 请教一下
wenbo liu1:
回复 WenJia Tian:
42923277@163.com
wenbo liu1:
ADS8689 好像不抗干扰。外围的电容我按照手册画的。干扰严重时,其他器件不受影响,但是ADS8689的配置信息全丢了。 我处理器用的STM32F103,没有感觉。
wenbo liu1:
回复 WenJia Tian:
//ads8989 ORDER#define RD_BYTE 0x4800//WRITE byte#define WR_BYTE 0xD400#define REG_RANGE 0x14
GPIO_ResetBits(CS); SPI2_Send(WR_BYTE + REG_RANGE); SPI2_Send(0x04); GPIO_SetBits(CS); GPIO_ResetBits(CS); SPI2_Send(RD_BYTE + REG_RANGE); SPI2_Send(0x00); GPIO_SetBits(CS); vTaskDelay(1); vTaskDelay(1); GPIO_ResetBits(CS); temp = SPI2_Send(NOP); GPIO_SetBits(CS);
wenbo liu1:
回复 wenbo liu1:
ADS8689的rst脚非常的敏感,干扰很容易影响到。