From: Florent Kermarrec Date: Tue, 18 Sep 2012 14:21:32 +0000 (+0200) Subject: update doc X-Git-Tag: 24jan2021_ls180~2575^2~129 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=7b7ef4f8dc6df12df3b2b19f8b2dc5b1369c79d2;p=litex.git update doc --- diff --git a/doc/Illustrations/migIo.PNG b/doc/Illustrations/migIo.PNG new file mode 100644 index 00000000..270e331e Binary files /dev/null and b/doc/Illustrations/migIo.PNG differ diff --git a/doc/Illustrations/migscope_structure.png b/doc/Illustrations/migscope_structure.png new file mode 100644 index 00000000..9e07fd7d Binary files /dev/null and b/doc/Illustrations/migscope_structure.png differ diff --git a/doc/Illustrations/migscope_structure.svg b/doc/Illustrations/migscope_structure.svg new file mode 100644 index 00000000..b9d4b714 --- /dev/null +++ b/doc/Illustrations/migscope_structure.svg @@ -0,0 +1,968 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + MigIo + MigLa + + MigIo + [...] + + + + + + + + + Design + + + + + + CSR Bus + + Wishbone2CSR Bridge + + Spi2CSR Bridge + + Ethernet2CSR Bridge + or + or + or + [...] + + MigIo + + + + + CSR Bus + N Synchronous Inputs + and/or + N Synchronous Outputs + + + diff --git a/doc/migScope.rst b/doc/migScope.rst index a8f4d718..bd46e83f 100644 --- a/doc/migScope.rst +++ b/doc/migScope.rst @@ -3,7 +3,7 @@ Introduction MigScope is a small logic analyzer to be embedded in an FPGA. -While free vendor's toolchains are generally used by beginners or for prototyping (situations where having a logic analyser in the design is generally very helpfull) free toolchains are always provided without the proprietary logic analyzer solution...:( +While free vendor toolchains are generally used by beginners or for prototyping ( situations where having a logic analyser in the design is generally very helpfull) free toolchains are always provided without the proprietary logic analyzer solution. . . :( Based on Migen, MigScope aims to provide a free and more portable / flexible alternative to vendor's solutions. @@ -17,8 +17,7 @@ Migen makes it possible to apply modern software concepts such as object-oriente Installing MigScope ******************* -Either run the setup.py installation script or simply set PYTHONPATH to the -root of the source directory. +Either run the setup.py installation script or simply set PYTHONPATH to the root of the source directory. Feedback ******** @@ -33,17 +32,17 @@ Migscope provides two kinds of cores: - MigIo : the virtual Input / Output core - MigLa : the virtual Logic Analyser core -A CSR bus controls the MigIo and MigLa cores.The CSR bus is a very simple bus originally used to control peripheral's registers in milkymist Soc.[*]_ +A CSR bus controls the MigIo and MigLa cores. The CSR bus is a very simple bus originally used to control peripheral registers in milkymist Soc.[*]_ .. [*] More information on Milkymist on : http://github.com/milkymist/milkymist-ng -Because it's simplicity, it can be adapted very easily to a wide range of interfaces: Wishbone, Uart, Spi, I2C, Ethernet... +Because of its simplicity, it can be adapted very easily to a wide range of interfaces: Wishbone, Uart, Spi, I2C, Ethernet... -MigScope uses CSR library from Migen to inter-connect cores. MigScope provides a Spi2Csr Bridge and is tested with an external Spi Interface. Support of others external interface will be added in future versions. +MigScope uses CSR library from Migen to inter-connect the cores. MigScope provides a Spi2Csr Bridge and is tested with an external Spi Interface. Support for others externals interfaces will be added in future versions. -Because Migen is a Python-based tool, using Python to control MigScope gives us lot's of advantages : Python Class can provides the HDL description **AND** the driver functions! +Because Migen is a Python-based tool, using Python to control MigScope gives lot's of advantages : Python classes can provide the HDL description **AND** driver functions! -*MigScope Structure Schematic* +.. image:: Illustrations/migscope_structure.png MigIo ##### @@ -51,14 +50,14 @@ MigIo Description ----------- -The MigIo is simply an internal GPIO equivalent. It provides N (configurable) inputs and/or outputs and can be used for lot's of purposes: +The MigIo is simply an internal GPIO equivalent. It provides N (configurable) inputs and/or outputs and can be used for lots of purposes: - stimulation of a core's parameters in a design where external control interface is not yet developped or still under developpement. - - update of a Look-Up-Table or a Ram in the design. - - read an internal / external bus values + - update of a Look-Up-Table or a Ram. + - read an internal / external bus. - ... -*MigIo Structure Schematic* +.. image:: Illustrations/migIo.png Instanciation @@ -76,12 +75,12 @@ MigIo parameters are: Driver ------ -To use drivers functions, an interface must be defined:: +To use drivers functions, an interface is defined:: csr = Uart2Spi(1,115200) migIo0 = migIo.MigIo(MIGIO_ADDR, 8, "IO", csr) -MigIo drivers functions will now use our csr interface. Note that it is only useful to define the migIo interface in the Python code that will be executed on the Host, the code that will be translated in HDL don't need it. +MigIo drivers functions will now use our csr interface. Note that it's only useful to define the migIo interface in the Python code that will be executed on the Host, the code that will be translated in HDL don't need it. Write Method:: @@ -109,4 +108,6 @@ The HDL Code is in examples/deX/top.py The Host Code is in examples/deX/client/test_MigIo.py MigLa -##### \ No newline at end of file +##### + +[To Be Done] \ No newline at end of file diff --git a/migScope/recorder.py b/migScope/recorder.py index a8570c3b..0c2aec1a 100644 --- a/migScope/recorder.py +++ b/migScope/recorder.py @@ -218,7 +218,6 @@ class Recorder: return self.interface.read(self.address + 0x02) == 1 def size(self, dat): - self.size = dat self.interface.write_n(self.address + 0x03, dat, 16) def offset(self, dat):