rd strobe fifo for only analog fifos

This commit is contained in:
maliakal_d 2018-12-03 14:33:32 +01:00
parent 8f3f9caf2b
commit 98b5e893b1
2 changed files with 6 additions and 6 deletions

View File

@ -245,8 +245,8 @@
#define DUMMY_FIFO_CHNNL_SLCT_OFST (0)
#define DUMMY_FIFO_CHNNL_SLCT_MSK (0x0000003F << DUMMY_FIFO_CHNNL_SLCT_OFST)
#define DUMMY_ALL_FIFO_RD_STRBE_OFST (8)
#define DUMMY_ALL_FIFO_RD_STRBE_MSK (0x00000001 << DUMMY_ALL_FIFO_RD_STRBE_OFST)
#define DUMMY_ANLG_FIFO_RD_STRBE_OFST (8)
#define DUMMY_ANLG_FIFO_RD_STRBE_MSK (0x00000001 << DUMMY_ANLG_FIFO_RD_STRBE_OFST)
#define DUMMY_DGTL_FIFO_RD_STRBE_OFST (9)
#define DUMMY_DGTL_FIFO_RD_STRBE_MSK (0x00000001 << DUMMY_DGTL_FIFO_RD_STRBE_OFST)

View File

@ -2224,7 +2224,7 @@ void readframe(int *ret, char *mess){
}
void unsetFifoReadStrobes() {
bus_w(DUMMY_REG, bus_r(addr) & (~DUMMY_ALL_FIFO_RD_STRBE_MSK) & (~DUMMY_DGTL_FIFO_RD_STRBE_MSK));
bus_w(DUMMY_REG, bus_r(addr) & (~DUMMY_ANLG_FIFO_RD_STRBE_MSK) & (~DUMMY_DGTL_FIFO_RD_STRBE_MSK));
}
void readSample() {
@ -2234,9 +2234,9 @@ void readSample() {
// read adcs
if (analogEnable) {
// read strobe to all adc fifos
bus_w(addr, bus_r(addr) | DUMMY_ALL_FIFO_RD_STRBE_MSK);
bus_w(addr, bus_r(addr) & (~DUMMY_ALL_FIFO_RD_STRBE_MSK));
// read strobe to all analog fifos
bus_w(addr, bus_r(addr) | DUMMY_ANLG_FIFO_RD_STRBE_MSK);
bus_w(addr, bus_r(addr) & (~DUMMY_ANLG_FIFO_RD_STRBE_MSK));
// loop through all channels
int ich = 0;