1 |
5 |
redbear |
# UART 8 bit + parity whit Self Checking using SystemC model
|
2 |
2 |
redbear |
This project provide the necessary to run a env test a simple uart verilog using SystemC and running it on icarus verilog
|
3 |
5 |
redbear |
|
4 |
|
|
###Donate and help us "Bitcoin is the future"
|
5 |
|
|
|
6 |
|
|
- 16tCHCq1nMZVDQeYTVwFXjzz53hnHSA2Q3
|
7 |
|
|
|
8 |
|
|
###ABOUT this UART
|
9 |
|
|
|
10 |
|
|
This consist in a simple UART 8 bit using opensource rtl simulator icarus verilog with mixed code vpi "verilog procedural interface" and systemC. This uart is alredy tested on ALTERA FPGA and it work well. But RX could be more elaborated to take signal since he take just catch signal on middle of counter and not see another point of signal. But this is the base to elaborate another applications on future or modify it to a specific propurse. SystemC model do the same way but i need finish just check parity from DUT "Device under test" to SystemC model.
|
11 |
|
|
|
12 |
|
|
This IP was developed in order to:
|
13 |
|
|
|
14 |
|
|
- Concepts acquired in training in the digital stream
|
15 |
|
|
- Integration with free software
|
16 |
|
|
- Different forms of functional verification
|
17 |
|
|
- Projects aimed at ASIC
|
18 |
|
|
- IP facing low density - average
|
19 |
|
|
- Promoting microelectronics interested people on Latin America
|
20 |
|
|
- Teamwork
|
21 |
|
|
|
22 |
|
|
|
23 |
|
|
###Requisites
|
24 |
|
|
|
25 |
|
|
- Linux Distro
|
26 |
|
|
- Icarus verilog [http://iverilog.icarus.com/]
|
27 |
|
|
- SystemC 2.3 [http://accellera.org/downloads/standards/systemc]
|
28 |
|
|
- gtkwave [http://gtkwave.sourceforge.net/]
|
29 |
|
|
|
30 |
|
|
*Obs: you need alredy know how to compile and understand concepts and how work icarus / SystemC / linux tools
|
31 |
|
|
|
32 |
|
|
###Configuration of Environment
|
33 |
|
|
|
34 |
|
|
To systemC , icarus verilog and gtkwave follow instalation guide provided by developers and make propely exports to linux distro see includes and objects used during build of environment. The folder work is where you need compile and execute the test using systemC and DUT in verilog. Note on env_uart.cpp some includes fail because location so you need set it where you have compiled or instaled icarus verilog.
|
35 |
|
|
|
36 |
|
|
On work folder you should see after yoo installed systemC if is propely installed
|
37 |
|
|
|
38 |
|
|
```sh
|
39 |
|
|
$ ldd sc_uart.so
|
40 |
|
|
```
|
41 |
|
|
|
42 |
|
|
The result of command should be this
|
43 |
|
|
|
44 |
|
|
```sh
|
45 |
|
|
linux-vdso.so.1 (0x00007ffd92ffe000)
|
46 |
|
|
libsystemc-2.3.0.so => /lib64/libsystemc-2.3.0.so (0x00007f24c2420000)
|
47 |
|
|
libstdc++.so.6 => /usr/lib64/libstdc++.so.6 (0x00007f24c209d000)
|
48 |
|
|
libm.so.6 => /lib64/libm.so.6 (0x00007f24c1d9c000)
|
49 |
|
|
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007f24c1b85000)
|
50 |
|
|
libc.so.6 => /lib64/libc.so.6 (0x00007f24c17de000)
|
51 |
|
|
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f24c15c0000)
|
52 |
|
|
/lib64/ld-linux-x86-64.so.2 (0x000056321eb36000)
|
53 |
|
|
```
|
54 |
|
|
|
55 |
|
|
To Run environment just do the follow command
|
56 |
|
|
|
57 |
|
|
```sh
|
58 |
|
|
bash run.sh
|
59 |
|
|
```
|
60 |
|
|
|
61 |
|
|
Whit this simulation you can generate till 1000 data. This a sample used to proof viability using icarus verilog like a simulator whit mixed code. More information enter in contact with some propose.
|