From:                              Usher, Nathan

Sent:                               Tuesday, September 06, 2011 4:27 PM

To:                                   Davis, Mark

Subject:                          Re: LLRF2 RCM pin usage

 

Mark,

 

All of the Rab_SPI2.x pins are part of the same SPI bus.  There are five devices on the bus: the ZWorld (master), DSP (master), FPGA (master), FPGA's ROM (slave), and DSP's ROM (slave).  Rab_SPI2.DSPen is the chip select for the DSP boot ROM and can be driven by either the ZWorld or the DSP.  Rab_SPI2.FPGAen is the chip select for the FPGA boot ROM and can be driven by either the ZWorld or the FPGA.  The PROG_B signal is the reset signal for the FPGA, and /DSP_RESET is the reset for the DSP.  To guarantee that the other chips aren't trying to use the SPI bus when you are trying to program the ROM, hold both other chips in reset.

 

In normal operation, you should set all Rab_SPI2.x signals, /DSP_RESET, and PROG_B as inputs.

 

When downloading a new file to either ROM, follow this procedure:

1)         Drive both PROG_B and /DSP_RESET low.  (this guarantees the DSP and FPGA won't try to drive the SPI pins)

2)         Set Rab_SPI2.MOSI to output.

3)         Pull either Rab_SPI2.FPGAen or Rab_SPI2.DSPen low to select the correct ROM (both signals have pull-ups)

4)         Write the file to the ROM

5)         Set Rab_SPI2.MOSI, Rab_SPI2.FPGAen, and Rab_SPI2.DSPen to input

6)         Release PROG_B (it has a pull-up)                (the FPGA will configure itself from the ROM, then release the SPI bus)

7)         wait for FPGA_done to go high

8)         Release /DSP_RESET            (the DSP will now control the SPI bus)

 

 

Any low pulse on /DSP_RESET will reset the DSP and cause it to reload from its ROM.  Any low pulse on PROG_B will cause the FPGA to reload its configuration from its ROM, but to reset the FPGA it would be best to follow the procedure above (skipping steps 2-5), to guarantee everything boots in the same order each time.

 

 

The Rab_SPI1.x pins are completely independent of the Rab_SPI2.x pins, so they have no effect on programming the ROMs.  The Rab_SPI1 protocol is unchanged from the previous protocol with the exception of register addresses being added/moved.

 

 

 

 

On Sep 6, 2011, at 3:37 PM, Davis, Mark wrote:



Nathan,

 

Attached is a summary of my understanding of the usage for the Rabbit Core Module signals for the new LLRF2 controller.  Please review it and let me know of anything that is not correct and provide the answers to my questions about some of the things I know are not yet clear.

 

In particular I suspect there are problems with my assumptions regarding the following signals and their relationships:

 

/DSP_RESET

Rab_SPI1_DSP_EN

Rab_SPI2.DSPen

 

Rab_SPI2.FPGAen

PROG_B

FPGA_DONE

 

<Pin usage for RCM3200.rtf>