2022-11-23 09:28 PM
Hello,
I am working on STM32h7 controller. I configure the AD9106 DAC to SPI. When I tried to write read the configuration register some some registers are get read write and some not why these happening I check the register they are read write able also I changes the SPI frequency low to hgh. For DAC external clock is 150MHZ and SCLK is 4MHZ.
2022-11-30 08:29 AM
Hi @MDeva.1,
what makes you think there's a problem with STM32H7?
Try analyzing the communication using a logic analyzer or some SPI sniffing device such as Beagle.
BR,
J
To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
2022-12-15 01:06 AM
I check on PICOSCOPE. But when I tries to read that particular registers I get the value 0 .
I tried to make the RUN bit 1,but when I read back I get the zero.Why these happening.Here is my code.
Can you me help me.
2022-12-15 06:57 PM
The state machine has multiple spi connection configuration. Check which one is enabled by default. If it is 3 wires, this is not the native 4 wire mode and requires that you disable STM32 Mosi pin when starting to read, then revert back manually when going back to output mode. If your SCK toggles, I guess the gpio config is ok.
2022-12-16 12:49 AM
Hi,
Can you please elaborate the things means what thinks I need to do ?There are two DACs are connected to the SPI4. MOSI ,MISO ,CLOCK are same. Right now I just try to access the DAC1 and for these I make the CS pin HIGH of the DAC2 through out the execution..
In these picture of waveforms I tried to write and read back the address of 1E RUN bit.
Write address=0x001E
Read address=0x801E
Value=0x0001;
I attaché the schematic Please have look.
Can you please help me .
2022-12-16 01:56 AM
2 slave dac on the same bus commandd 4 wire spi. Not multi drop, here it is daisy chain. STM32.MOSI goes to DAC1.SDI, DAC1.SDO goes to DAC2.SDI, DAC2.SDO goes to STM32.MISO
As it is daisy chain, you have 2 dac to update in one shot, so the data packet should be longer.... hope this helps.
2022-12-16 02:34 AM
We does not use the Daisy chain. We give parallel signal to DAC1 and DAC2 , using the chip select establish the communication for DAC1 or DAC2. At time we are not communicate to DAC1 and DAC2. Right now I just try to communicate with DAC1, for these I make CS pin of DAC2 High
2022-12-16 03:52 AM
I think an ST example with spi adc and dac would help many users...