Quantcast
Channel: Altera Forums
Viewing all 19390 articles
Browse latest View live

How to use SDRAM Vhdl with DE2-115??

$
0
0
English use of I might be wrong. Because I am not good at English.

I have been using de2-115.
I would like to create a SDRAM circuit to verify that the data is written to the SDRAM, data is read from the SDRAM.
But since I do not understand about the SDRAM , it is difficult .

Could you tell me the code and its operation to me someone ?

By the way , the code shown below is a SRAM that created me.
I would like to create SDRAM something similar to this circuit .

Code:

library ieee;
 use ieee.std_logic_1164.all;

 entity top_level_entity is
 port (
  SW: in std_logic_vector (17 downto 0);
  LEDR: out std_logic_vector (17 downto 0);

  SRAM_ADDR: out std_logic_vector (19 downto 0);
  SRAM_DQ: inout std_logic_vector (15 downto 0);
  SRAM_CE_N: out std_logic;
  SRAM_OE_N: out std_logic;
  SRAM_WE_N: out std_logic;
  SRAM_UB_N: out std_logic;
  SRAM_LB_N: out std_logic
 ) ;
 end top_level_entity;


 architecture inside_top_level_entity of top_level_entity is

  signal address: std_logic_vector (1 downto 0);
  signal data: std_logic_vector (14 downto 0);
  signal output: std_logic_vector (14 downto 0);
  signal we: std_logic;

 begin

  SRAM_WE_N <= not SW (15);

  SRAM_CE_N <= '0 ';
  SRAM_OE_N <= '0 ';
  SRAM_UB_N <= '0 '; 
  SRAM_LB_N <= '0 ';

  address <= SW (17 downto 16);
  SRAM_ADDR (19 downto 2) <= (others => '0 ');
  SRAM_ADDR (1 downto 0) <= address;

  data <= SW (14 downto 0) when SW (15) = '1 'else (others =>' Z ');
  SRAM_DQ (15) <= '0 ';
  SRAM_DQ (14 downto 0) <= data;

  output <= SRAM_DQ (14 downto 0);
  LEDR (14 downto 0) <= output;

 end inside_top_level_entity;



help, help, sir, for the love of Heaven.

Cannot create an Internal Memory Initialization (.hex) File

$
0
0
Hello,
I'm a beginner in Nios II software development.
I used the Quartus 13.0, the Qsys and the Nios II EDS for Eclipse to create the count_binary example for the CycloneIII_3c25 Starter Kit.
Everything is OK if "Run As -> Nios II Hardware" is used.


But I cannot create an Internal Boot Memory Initialization (.hex) File.


I follow the steps to create memory initialization files in the Nios II Software Developer's Handbook.
1. Right-click the application project.
2. Point to Make targets and click Build to open the Make Targets dialog box.
3. Select mem_init_generate.
4. Click Build.
5. Add the .qip (meminit.qip) file to the Quartus II project.


But I cannot find the .hex files


6. Recompile the Quartus II project.
After it I see the warning "Can't find design file <Project name>_mem.hex"


There is another way to create memory initialization file - to use the mem_init.mk
But how one can include this file in the application makefile and how a target can be set properly is unknown.


Any idea?


Regards,
tduty

Classic DMA core speed?

$
0
0
Hi everybody,

Please allow me one silly question. Let me explain small problem. I have one DMA inside Qsys, 1x 16bit PIO, SDRAM controller (16bit databus width). All peripherials are running at 100MHz. When I will force to transfer 100 dma transacations it takes 200 clock cycles. Is it correct? I was thinking when I am feeding DMA with 100MHz it will make 100 DMA transactions in 100 clock cycles.

Now the solution could be made by incresing the FCLK to 200MHz but I my SDRAM chips are 133MHz... I am little confused about the speeds and abilities of this configuration.

Could someone please make me short explanation?

Thank you,

Jan.

using the FPU on Cortex A9

$
0
0
Hello,

I'm trying to use the FPU in my baremetal project.

I use the ARM DS-5 (altera edition) with the DS5-GCC.

I try to compile a simple project with the following options:
Code:

-mfloat-abi=hard  -mfpu=vfpv3-d16-fp16 -ftree-vectorize -ffast-math -march=armv7-a -mtune=cortex-a9 -mcpu=cortex-a9
The output is always something like this:

Code:

gcc version 4.6.3 (Sourcery CodeBench Lite 2012.03-56)
arm-none-eabi-g++ -Taltera-socfpga-hosted.ld -g -O0 -mfloat-abi=hard  -mfpu=vfpv3-d16-fp16 -ftree-vectorize -ffast-math -march=armv7-a -mtune=cortex-a9 -mcpu=cortex-a9 -Werror -Wall -Wstrict-prototypes hello.o -o hello.axf
c:/altera/13.1/embedded/host_tools/mentor/gnu/arm/baremetal/bin/../lib/gcc/arm-none-eabi/4.6.3/../../../../arm-none-eabi/bin/ld.exe: error: hello.o uses VFP register arguments, hello.axf does not
c:/altera/13.1/embedded/host_tools/mentor/gnu/arm/baremetal/bin/../lib/gcc/arm-none-eabi/4.6.3/../../../../arm-none-eabi/bin/ld.exe: failed to merge target specific data of file hello.o
collect2: ld returned 1 exit status
make: *** [hello.axf] Error 1

Ok, the message let me know, that at least one library (may be i.e. libc...) is not linked for hard floatingpoint.
Maybe there is generally no hardware-floatingpoint support by the delivered DS5-GCC compiler/toolchain?
Normally the Codesourcery Lite only supports software-floatingpoint and only the standard and professional versions have hardware floatingpoint support.

using the flag -mfloat-abi=softfp doesn't work for me. In this case all floating point operation will be done by software and that's to slow.

Does anyone know, how to get it work?

HPS2FPGA bridge throughput

$
0
0
Hi everybody,

I am currently playing around with the Cyclone V SoC Development board.
I have a QSys system running resembling the Golden system reference design apart from the fact that the h2f_axi_clock is controlled by a PLL residing on FPGA side.
The h2f_axi_clock is 80 MHz in my case.

I have the onchip memory up and running according to the GSRD. I used the Linux example to run a Linux application on the HPS. From within the application I can write to and read from the on-chip memory, the memory address range is mmaped to the linux user space for this purpose.
Now the question:
I get about 45 MByte/s throughput when using a memcpy to copy a block of 65kBytes of data from the HPS to the FPGA (transfer needs about 1.4 ms). I measured the time it takes to memcpy the following way:

clock_gettime(CLOCK_REALTIME, &start);
memcpy((void*)hw_onchip_mem_base, (void*)&buffer[0], ONCHIP_MEMORY2_0_SPAN);
clock_gettime(CLOCK_REALTIME, &end);


45 MBytes/s seem to be quite low. I have a 64 Bit bus width to the memory and a clock of 80 MHz. So I would expect about 640 MBytes/s theoretical throughput.
Of course I can imagine that the bridge is only able to transmit with a certain burst size, arbitration must take place, Linux data handling will add some overhead and maybe there are other restrictions.
But is 45 MByte/s all I can get? That would be quite bad...
Any ideas how to improve the performance?
What am I doing wrong?
Has anybody better results and how?

Tool is Quartus 13.1, Linux 3.9 Kernel.

Thanks in advance!!

Volker

Problem with tri-state controller

$
0
0
Hi everyone!
I'm trying to use tri-state controller to connect nios2 system to w5300 chip (w5300 is considered as SRAM). Write command works very strange: two nWR pulses and two nCS are formed, so two write operations are executed. Address value stays the same during both write operations, but data changes to all zeros before second operation, so firstly correct value is written into SRAM, but then controller writes zero to the same address. If I change some timing options (setup time=0, write wait time=0, data hold time=0) only one pair of nCS/nWR pulses is formed, but these changed timing options don't correspond to required write diagram. Has anybody faced this issue?

Cyclone II ESD Problem

$
0
0
Hi there,

We are experiencing very strange behavior of the FPGA (EP2C5T144C8) when conducting ESD tests according to IEC 61000-4-2. During the indirect discharge test, the FPGA freezes and all I/Os become low level. The buffers do not respond to any change. The implemented internal logic reset is not working also. When I drive the nCONFIG to low the reconfiguration is started and completed successfully (the nSTATUS is transitioning to low and than to high), but the buffers still do not respond and stay at low level. Only reset of the power supply is restarting the FPGA. I think it could be something with the internal hot socketing feature of the I/Os. Probably we have some issues with the PCB power and ground planes but I've never seen such a behavior of the FPGAs. Do you have any suggestions how to reset the IO buffers without interrupting the 3.3V PS or something that could prevent freezing of the I/O buffers?

Thanks.
Victor

How to put devtab.h into ?

$
0
0
Hi!

In io.cdl, I see:

cdl_package CYGPKG_IO {
display "I/O sub-system"
doc ref/io.html
include_dir cyg/io
requires CYGPKG_ERROR
description "
The eCos system is supplied with a number of different
device drivers. This option enables the basic I/O system
support which is the basis for all drivers."
...
In ecos.db, there is
package CYGPKG_IO {
alias { "I/O sub-system" io }
directory io/common
script io.cdl
...

There is devtab.h in packages/io/common/current/include.

However, after building, I see no devtab.h file in cyg/io. What may be wrong?
TIA

de2-115 Development Board USB Hardware problem

$
0
0
Hi. I am working on DE2-115 and I can´t see in Control Panel the status of any USB Devices(A or B). Any of the other functions on Control Panel work perfectly.
If i connect a Mouse on the host port, it seems to be no power on it, so I don´t think that is a problem in Windows.
It´s a Hardware problem? How can I check this?


Control Panel software for PC and FPGA. Version 3.01
Quartus II - 64 bit 13.1
USB Blaster work fine
Al functions of Control Panel are working.


Thank you

Startup problems web edition

$
0
0
I downloaded and installed web edition . Tried to run first tutorial and advised that the Cyclone II was not installed. Downloaded Cyclone II files and then each time I try and install -> tools -> Install devices I get error message " Cant find web edetion devices in directory " this is in spite of the .qdz file being in the target directory.

Any advice appreciated .

Linux options with ethernet on Neek kit

$
0
0
Hi,
I would like to use my Neek kit as a modbus master to read some data over RS232 and then send it out via the ethernet port to a website for logging. The application makes use of the http://libmodbus.org/ modbus library to get the data and then sent useing https://github.com/xively/libxively.

My question is it is sensible to even try using the neek and if so what quatus version, nios2, and flavour and version of linux would you suggest. I will be doing the inital debug using Ubuntu on the desktop and then cross compile.

Any suggestions usefully recived.

Thanks

trigger from power off state

$
0
0
Hi,
I know there's power up trigger feature in signaltap II, but can it be done in the off -> on transition?
Meaning, the board is off, signaltap is waiting for trigger, then I power up the board and the signatap catches the signals.
Thx.

FIR compiler support in cycloneV

$
0
0
I want to use FIR ipcore in cycloneV, when I start Megawizard, it shows that FIR compiler is disabled for device cycloneV, stratixIV, while it is enabled in stratix III and other old device.I use quartus13.0sp1, anybody meet the same problem?Altera will not support FIR compiler in latest devices or quartus version?
Attached Images

vga controller for quartus v13.0 for sopc

$
0
0
hi
i am new to using quartus v13.0. i wanna build a video interfacing system using dsp cyclone 2 ep2c70f672c6. to create a core in sopc builder in quartus 2 v13.0 i cant find vga controller for engaging it to fpga. my initial aims are to:
1. engage sd ddr2 ram mt4htf3264ay to fpga.
2. engage vga conroller to fpga.
3. using i2c controller to control image sensor module which is c3038.
pls can some1 help in or direct me how to go about it and help in finding vga controller

Cyclone V GX Hard Power down all Transceivers

$
0
0
I am using Cyclone V GX C9 FPGA with 560 I/Os (F1152 package) in my design, which has 12 transceivers. The FPGA is selected for the number of I/Os required (approx 550 I/Os) and low power consumption as this is a battery operated, handheld device. The transceivers are totally unused and need to be hard power down if possible to minimize power consumption. In Cyclone V Device Handbook, page 3-15, it is mentioned to ground the transceiver power supply of the respective side to enable PMA hard powerdown, but no further information is available. Kindly let me know

1) Whether all the VCCE_GXBL,VCCH_GXBL,VCCL_GXBL power pins need to be connected to ground.
2) How to terminate the unused GXB_RX, GXB_TX and REFCLK pins.
3) Any other details to be considered.

usb camera can not capture 640*480 image

$
0
0
I use a helio board with 3.10 kernel, I can capture 320*240 image by otg port.
but when capture 640*480 image, the return information is:
Read_frame:resource temporarily unavailable.

did anyone ever encounter this issue ?

Modelsim_Altera error (Memory Allocation Failure)

$
0
0
My design successfully compiled on Quartus II v.11.0 sp1, and i try to simulate it using Modelsim-Altera web free edition 10.0 C. I open a new project (.mpf)on modelsim_ Altera V. 10.C and add the (.vho) files from simulation directory of the design ( I use this method along the different stages of the project and I succeeded to simulate every module of the project separately- all of them are VHDL no mixed design languages- , the problem appears at the last stage when i combined all the modules together). in modelsim_Altera (.vho) files compilation succeeded but when simulating the following message appears:

** Fatal: (vsim-4) ****** Memory allocation failure. *****
*
* Attempting to allocate 29707280 bytes
*
* Please check your system for available memory and swap space.
*
* Time: 0 ps Iteration : 0 Root : / File : NOFILE
* Fatal error while loading design
* Error loading design

My response was reviewing the swap space i increase it many times till the extreme (300 giga bytes) but the same response. i tried with different versions of Modelsim_Altera (V. 6.0, 10.0 C, 10.0 D). I also try to compile the project using different chip rather than stratixIII, I used Arria II, but the same response when simulation.
? are am I go in the right or wrong way? is the design large to be simulated using web free edition? please give me response about that, and how i can overcome this problem. thanks in advance.

How to communicate DE2-115 to PC via USB or Ethernet?

$
0
0
Hello,
I have an external ADC and need to transfer data from it with my DE2-115 evalution board to user PC with a high rate of 3 MB/sec. I think USB or Ethernet interface would be good choise.
Could you please advice me some Verilog module that would implement such communication? I didn't find one on DE2-115 System CD within it's examples. Any step-by-step guide of installing and tuning NIOS processor for this purpose will be fine too.
Thank you!

Altera Max V CPLD Development Board problem

$
0
0
I am using Altera Max V CPLD Development Board version 11.1. The user manaul for Board Test System software shows a Config menu option to allow the user to reprogram the CPLD with some standard examples each of which have their own tab folder in the software. However, my installation has only File and About options with no Config and all the tabs are disabled except for the GPIO tab.

Anyone know how I can access these other configurations? Why don't I have a Config menu option? I downloaded the latest version 11.1?

thanks!

Output for only one clock cycle

$
0
0
Hi all,

I have a counter that counts up every time an input of '1' is seen. At the max count value a flag should output '1' and the count resets. I can achieve this, however the output lasts for as long as the input stays at '1' on the final count.

How do you code for an output to last for just one clock cycle?

Thanks
Viewing all 19390 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>