C15 SystemC Support
C15 SystemC Support
C15 SystemC Support
15.1. Outline
1. 2.
3.
Compilation
Compiling SystemC into a dynamic-link library (*.dll) Adding SystemC modules to the design library
4.
Simulation
SystemC modules in various debugging tools Debugging C Code
Right-click empty area in the Design Browser, select Create New Folder, rename folder to Backup and move the files marked in red to that folder. You will re-create them in this training.
The Transactor Wizard generates source code skeleton with the class structure shown in the picture above.
2. Start the wizard with the Generate SystemC Transactors command from the Tools menu (right).
All materials updated on: November 20, 2006
All three functions should be pure virtual and public and return void.
Note: You will be using the SystemC templates located in the Tutorial / SystemC Transactors section of the Language Assistant while making changes.
select the comment inside the body of the send_message() function void transactor::send_message() { // enter your code here } expand the following branch in the assistant: Tutorial | SystemC Transactors | send_message click the Use Template button
select the entire body of the terminate() function void transactor::terminate() { // enter your code here } expand the following branch in the assistant: Tutorial | SystemC Transactors | terminate click the Use Template button close the Language Assistant The development of the transactor is now complete.
#include "test.h" void test::main() { transactor_interface->initialize(); transactor_interface->send_message("This is an example of SystemC Transaction Level testbench."); transactor_interface->terminate(); }
Select the Wizards tab and select the SystemC Source Code icon
- Right-click the previously compiled test_env.bde file and select Compile from the menu. The simulation top-level unit will be recompiled and the exclamation mark will change into a check-mark.