rggen / rggen

Code generation tool for control and status registers

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support SPI as bus interface

hpretl opened this issue · comments

Is your feature request related to a problem? Please describe.
It would be a super feature if rggen could be used to create an SPI-based register file.

Describe the solution you'd like
In addition to apb and wishbone also support spi type.

Describe alternatives you've considered
n/a

Additional context
Can provide this on request.

How about creating your own RgGen plugin to add SPI support?

I was thinking about it, but so far, I am shying the learning curve and the effort. Maybe we start a small project implementing it.

I created a plugin template.
https://github.com/taichi-ishitani/rggen-spi

By uisng this plugin, you only have to implement RTL adapter modules below.

You need to tell the path to the repository by using the --plugin switch:

$ rggen --plugin rggen-verilog --plugin rggen-vhdl --plugin PATH/TO/REPO/lib/rggen/spi.rb -c your/config.yaml your/register_map.yaml

If you don't need to generate Verilog RTL/VHDL RTL, you need to remove the related plugin code below.

@hpretl
Does the plugin template work well for you?

We have not yet looked into it yet, but it is on our todo list.

Ok, I understood.