You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I am getting into FPGA programming and have pulled out my old Doppler to test my builds.
Once I had a binary, I tried uploading it using the sample code in this repository's README:
#include <ICEClass.h>
#include "[PATHTO]/top.bin.h" // set up the path to doppler_simple_io or custom firmware
ICEClass ice40; // subclass ICEClass to implement custom spi protocol
void setup() {
ice40.upload(top_bin,sizeof(top_bin)); // Upload BitStream Firmware to FPGA -> see variant.h
ice40.upload(); // Upload BitStream Firmware to FPGA -> see variant.h
ice40.initSPI(); // start SPI runtime Link to FPGA
}
void loop() {
static uint16_t x = 0;
ice40.sendSPI16(x++); delay(50);
}
It did not work. After some experimentation, I found the problem was
ice40.upload(top_bin,sizeof(top_bin)); // Upload BitStream Firmware to FPGA -> see variant.h
ice40.upload(); // Upload BitStream Firmware to FPGA -> see variant.h
If I remove the ice40.upload();, this code works. But with the ice40.upload();, it does not. What I believe is happening is that .upload(top_bin, sizeof(top_bin)) uploads the "top" array, whereas .upload with no arguments uploads some sort of default (possibly the SPI LED command program). It seems the .upload() should be removed from the example.
In addition, it would be helpful at this point to link to the ICEClass / ice40 documentation, or to whatever repo contains the classes so we can read whatever code or documentation is there. Because I am using the Arduino SDK gui app I do not understand where the header files I am loading during a compile are located.
The text was updated successfully, but these errors were encountered:
Hello, I am getting into FPGA programming and have pulled out my old Doppler to test my builds.
Once I had a binary, I tried uploading it using the sample code in this repository's README:
It did not work. After some experimentation, I found the problem was
If I remove the
ice40.upload();
, this code works. But with theice40.upload();
, it does not. What I believe is happening is that.upload(top_bin, sizeof(top_bin))
uploads the "top" array, whereas.upload
with no arguments uploads some sort of default (possibly the SPI LED command program). It seems the .upload() should be removed from the example.In addition, it would be helpful at this point to link to the ICEClass / ice40 documentation, or to whatever repo contains the classes so we can read whatever code or documentation is there. Because I am using the Arduino SDK gui app I do not understand where the header files I am loading during a compile are located.
The text was updated successfully, but these errors were encountered: