cancel
Showing results for 
Search instead for 
Did you mean: 

EVALSTPM34 boards work unstable when using single Clock source

DominykasS
Associate II

Hello, I am trying out a 220 V power measurement set up with 3 STPM34 evaluation boards. I need to use as less wires as possible, so I am using SPI with 3 different CS and 1 SYN pin. I am also trying to reduce component count by using only 1 CLK source on one of the boards and providing clocking for other boards via CLKOUT like this diagram from datasheet:

DominykasS_2-1726464803562.png

I desoldered oscillators, capacitors and resistors on two eval boards and using simple wires I connected CLKs together. I also used ST provided fw for this eval board. The problem is that boards work very unstable with this kind of clocking provided. Sometimes readings are ok, but there is 1 or 2 samples that are completely off (Instead of 7.XX that I should get , I get 0 or something like 1100.XX and so on) , also sometimes one board just doesn't work and I get all 0xFF when reading data registers. Also sometimes when data is corrupted, I can see one or both LEDS on faulty board to flash dimly, datasheet states that power can be measured from LED PWM, but I am not writing anything to LED control registers and keeping them by default (Off). When oscillators are on every board, fw seems to work fine and I get a stable readings and no data randomness or LED flashing. I am using external power supply for Evalstpm34 boards, grounds connected to stm354f407G-disco board. I tried implementing CRC check on received data and most of the time CRC matches, so stpm34's send out wrong data with good CRC so it's not communication problem. Any idea why this information on datasheet is wrong and it is not possible to clock two stpm34 by one CLKOUT pin?

EDIT: There is a mistake on schematic .PDF of evalstm34 where it states that CKin is on XTAL1 pin, but stpm34 datasheet states that CKin is on XTAL2. Schematic also shows that output CKin pin header is connected to XTAL2 (just like datasheet of stpm34 states). I assume that it's not a major problem and traces are correctly traced to the right pins, but just a note.

STPM34 datasheet:

DominykasS_0-1726466058051.png

EVALSTPM34 schematic document:

DominykasS_1-1726466115301.png

 

0 REPLIES 0