I was working on a project using FPGA and Arduino, in which i have to show for how long my fpga device was OFF if it was so. I am using BASYS3 FPGA board. Once i switch off my FPGA the program is getting erased.
BASYS3 has quad spi FLASH onboard, fpga can be configured using stream stored there.
Follow instructions here: https://reference.digilentinc.com/learn/programmable-logic/tutorials/basys-3-programming-guide/start
Related
I am working on an esp project and compiled my code by using the esp32s2 toolchain and created a binary that ready to run on a real device. But I don't have a real device to test my binary. Is there any simulator to simulate the ESP32-S2 chip or the ESP32 chip?
You can use Wokwi to simulate the ESP32, and soon also the ESP32-S2.The Wokwi is a free online simulator for electronics, and it runs in your browser. This means you can simulate code that interacts with 3rd-party sensors, display modules, LEDs and many other common parts. There's also initial support for WiFi simulation, and the developers are working on extending it to support connecting to any host on the internet (e.g. HTTPS/MQTT)
Simulator Examples
Arduino Examples
Blink
Seven segment counter
APA102 Color Cycles (TinyPico Board)
WiFi Scanning
MicroPython Examples
SSD1306 Example
NeoPixels
WiFi Scanning
ESP-IDF Examples
The following examples use the ESP-IDF functions. They are compiled using Arduino ESP32 Core:
Blink using FreeRTOS API
Binary LED counter using FreeRTOS tasks
GPIO button input + interrupts
https://docs.wokwi.com/guides/esp32
You can try QEMU from https://github.com/espressif/qemu or https://github.com/Ebiroll/qemu_esp32
Not sure if they are supporting ESP32-S2, but it seems to be working with ESP32.
I am new to FPGA and I am trying to get a working JTAG setup on Lattice iCE40 FPGA.
The board I'm using is from Olimex and has iCE40-HX8K FPGA.
I'm using urjtag as PC application and tried with DirtJTAG and USB Blaster clones as programmer (flashed onto STM32 BluePill board).
Olimex board didn't have populated pull-up resistors for JTAG so I soldered them (10k for TMS, TDI and TCK).
But the end result is the same: I cannot get jtag to recognize FPGA, the error is:
jtag> cable UsbBlaster
Connected to libftdi driver.
jtag> detect
warning: TDO seems to be stuck at 1
Checked pinout of the JTAG connector and it's correct. Multimeter tests show that there is no short-circuit, no solder bridges, pullups are correct value and working and as expceted.
Tried my setup with Altera FPGA board and it's working, it will detect the FPGA.
Also, tried eBay UsbBlaster clone and it's not working on iCE40, but works for Altera FPGA.
I can flash the external flash (with other tools and programmer), but I want to be able to use JTAG so I can flash onboard SRAM instead.
Any ideas/hints what might be wrong/what to try next?
iCE40 FPGAs do not have a JTAG interface.
I have just finished a project using an Arduino Micro dev board and want to move to a standalone ATmega32.
I need to run this at 3.3V and I dont want to go down the overclocking road so I have an 8MHz crystal to put on it.
I still want to be able to upload sketches via USB and the Arduino compiler so I gather I need to burn a different bootloader.
For this purpose I have purchased a USBASP programmer.
I am slightly unsure of what to do next - everything I can find on the topic either relates to the ATmega328 or to burning bootloaders using another Arduino.
I have worked out that I need to modify boards.txt to point to the correct bootloader....but which is the correct bootloader for ATmega32 at 8Mhz?
Also do I need to change any fuses?
Thanks
I think you're a bit out of luck.
The ATmega doesn't have hardware USB, so I assume the bootloader is using V-USB to implement USB. That stack, being a software implementation of USB's high-speed signalling, requires at least a 12 MHz clock (higher is better).
I don't think you can run V-USB using only the internal 8 MHz oscillator.
According to the OP comments the micro is indeed an Atmega32u4, not an Atmega32 (#OP: please fix the question to match this).
Since it has onboard USB, you can use a pre-existing bootloader like the sparkfun one:
https://www.sparkfun.com/products/12587
Here you have the link to one of their products, the Arduino pro micro 3.3V (which runs at 8MHz). You can add the sparkfun arduino boards repository to your IDE and then just use the board specification for their pro micro 3.3V do upload the correct bootloader and to program it through the USB just like the usual Arduino Micro.
hi i have a fpga chip having cortex-m3 as hard-ip with it,i installed uclinux on cortex-m3 .
i wrote a c code which turns on 8 leds according to the number i give (it runs good on uclinux ) but now i want to give input number from c code on uclinux and transfer it to fpga ,then fpga will process on it and will glow the Leds,but i havn't find a way to do that(communication between uclinux and fpga).
for e.g. i can communicate with pendrive using uclinux cause i have the driver for it or i can write for any other device but how to show fpga circuit as device to uclinux,
one way i thought was as uclinux can access any address of cortex-m3 using pointers similarly i can do it for fpga ,but i don't understand how a digital circuit on fpga can have addresses.
I am working with Sasebo GII board that has two FPGAs on it:
Xilinx Spartan and Xilinx Virtex5 (and the board has several separate JTAG interfaces for configuration of fpgas).
I am useing ISE 14.4 under Linux and I have some troubles to configure the Virtex 5 FPGA.
(no problems with Spartan).
I am using "Impact" to send the configuration files to FPGAs.
At the beginning Impact scans the board and finds Spartan FPGA without problems
and I can configure it, but when I plug the cable to the other interface and press scan on Impact it says:
"There are many unknown devices being detected. Press Yes to continue or press No to stop."
If I press the NO option, well, obviously nothing happens :-)
And if I click on YES it fails, I can manually add Virtex5 FPGA, but than it fails to upload the config file to it (and even fails when I try to detect the device ID).
I already tried all JTAG interfaces on the board, nothing.
Same operations work on the same board with SPARTAN FPGA, so I'm stuck. Any ideas ?
Well, I am not familiar with that particular board, but there are many things you can look into when it comes to your JTAG problem.
Check the voltage of your VCC, make sure it has a good value for the board
Make sure your ground connection is well connected and you don't have much impedance
between the connector's GND and the boards GND
Try other JTAG connectors and see if you see any difference in the detection of the
devices.
Try to run the IMPACT in debug mode. Capture the data and see if the patterns look OK
Also something that may not be JTAG related, is to make sure your V5 device has all the powers it needs, if there are any power problems, it may cause the JTAG interface to behave like you explained here.
Also, look on the board and see if there are any switches or jumpers to chose different way of configuring the V5 device. This can be a big issues with multi-FPGA board, maybe the V5 is configured to be programmed from a controller or other devices on the board and the JTAG chain is not set up for programming.
These are just different thoughts, they may help you toward the right direction.
Found this on their site:
User guide for the board
To reprogram the flash ROM (ST45DB16D, U11) for the control FPGA (Spartan-3A), attach the configuration
cable to CN7. For configuration, use the provided mcs file sasebo_gii_ctrl.mcs.
Reprogram the flash ROM (ST45DB16D, U4) for the cryptographic FPGA (Virtex-5 LX30) with the provided
mcs file sasebo_aes_comp_lx30.mcs as well. Connect the configuration cable to CN4.
To configure the FPGA immediately after reprog
ramming of the flash ROM, cycle the power.
Blockquote
This means you can't program the FPGA directly, you need to convert your bit file into MCS file and then load it into the FLASH memory on the board.