Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.
Hi
actually the job is to convert the coding in 'C' to Verilog coding.
Many pointers are used int he coding and i want how it can be done using verilog
The usual approach is to redesign the C program's functionality as digital logic - counters, accumulators, registers, multiplexers, memory, sequencers, etc., and then use Verilog to describe that hardware.
If this is an FPGA project, you could drop a microprocessor into it and run your C code directly.
A pointer can be implemented in hardware(Verilog/VHDL) by a simple counter and a memory array. The counter will serve as an address to the memory so it will serve the same purpose as a C pointer. You can increment or decrement the counter as you would a pointer in C. You can modify the contentes of the memory(that is the data pointed to by the pointer), by reading the memory location currently pointed to by the address counter(that is your hardware pointer), modify it and write it back.
hope this helps.
Kind Regards,
Aviral Mittal
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.