Hi Ken,

The intended sequence for synchronizing NCO updates is to disable/pause SYSREF, 
set each desired tile’s mixer event source to a SYSREF event, configure the 
mixer (type, mode, scale, frequency, etc), and then enable SYSREF. There are 
two ways to pause/disable SYSREF from triggering events. The first is to assert 
the `adcX_sysref_gate` pin on the RFDC’s real-time status port interface for 
each tile intending to be active to SYSREF. This method is only supported in 
Gen 3 RFSoCs. There have been recent updates in CASPER’s RFDC mask to enable 
the ADCs real-time interface. To expose that you will need to activate the 
checkbox “Enable ADC Real-time Ports” under the “System Clocking And Real-time 
Ports” tab. Once that is enabled, a `adcX_rts_in` port is enabled where X is 
the tile index 0-3 for the corresponding enabled tiles. The LSB of that 
interface is `adcX_sysref_gate`. This pin can be driven by a software register 
in casper, or some other external synchronous event arriving in the fabric, 
such as a PPS.

The second method for pausing SYSREF is to program the PLL chip producing the 
SYSREF to change from a continuous SYSREF mode to a pulsed SYSREF mode. In this 
mode, SYSREF pulses are sent when events need to be triggered. This method 
requires custom code, out side of what is readily available in CASPER, to 
program and manipulate the PLLs configuration.

The methods for setting the mixer’s event source, and changing all other 
configurations, are intended to be done from casperfpga. This handles the 
remote calls to casper’s katcp library. The casperfpga methods are:

`set_mixer_event_source()`
`set_mixer_mode()`
`set_mixer_type()`
`set_mixer_fine_ferquency()`

Start with first setting the mixer event source to a SYSREF event 
(`EVNT_SRC_SYSREF`), then use the other methods to configure the rest of the 
mixer.

All of the current configuration settings for the mixer is queried using the 
`get_mixer_settings()` method.

Hope his helps,
Mitch

> On Aug 16, 2025, at 6:19 PM, Ken Semanov <[email protected]> wrote:
> 
> I am currently calling an NCO update for the purposes of multi-tile synch.  
> To do this, I use a function called   rfdc_update_nco_cmd( ) , linked below.  
>  This method causes the tcpborphserver to update a single NCO located in a 
> specific tile and a specific NCO.  It will then set a trigger update event 
> for the mixer.  
> 
> Unfortunately, I am calling this function remotely over ethernet via the 
> casper katcp library. This entails a pause between each NCO update session, 
> as the network traffic is routed, during which earlier NCOs will have 
> triggered already. The rising edge of a SYSREF clock very likely already 
> occurred, and successive calls will arrive too late.    
> 
> Is it possible to get a more compact version of this method, that would set 
> all 16 NCOs all at once in a tight loop performed locally?  
> 
> Alternatively, should I pause the SYSREF clock and then enable it again? 
> 
> My tcpborphserver3 is v8.1  posted to /zcu216update/
> 
> rfdc_update_nco_cmd() is located in the rfdc branch of
> 
> gitlab ras byu edu 
> /alpaca/casper/katcp/-/blob/rfsoc/rfdc/tcpborphserver3/rfsoc.c  
> 
> Thanks!
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "[email protected]" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to [email protected] 
> <mailto:[email protected]>.
> To view this discussion visit 
> https://groups.google.com/a/lists.berkeley.edu/d/msgid/casper/84228ea0-e2a2-4455-9c0d-754e4f4ba0b8n%40lists.berkeley.edu
>  
> <https://groups.google.com/a/lists.berkeley.edu/d/msgid/casper/84228ea0-e2a2-4455-9c0d-754e4f4ba0b8n%40lists.berkeley.edu?utm_medium=email&utm_source=footer>.

-- 
You received this message because you are subscribed to the Google Groups 
"[email protected]" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion visit 
https://groups.google.com/a/lists.berkeley.edu/d/msgid/casper/723EC0ED-0BF0-49B9-8952-991720B336B4%40gmail.com.

Reply via email to