GadgetFactory / Arduino-Soft-Core

http://papilio.cc/index.php?n=Papilio.ArduinoCore
64 stars 21 forks source link

Missing default Arduino sketch #8

Open Art-ut-Kia opened 6 months ago

Art-ut-Kia commented 6 months ago

Hello, I've successfully synthetized the whole VHDL code to fit a spartan-6 and simulated it with Xilinx tools. Now I would like to put my own sketch in the softcore program memory. But to start with, I would appreciate to get the default sketch. I observe that it emits the following message: "This is TAR Diode signal counter device" Also, If I use Arduino IDE to compile my own C/C++ code, which MCU should I select? AVR8 is too vague. Is it an Atmega103? an Atmega328? an Atmega8? Thanks for the information. Jean-Paul

ZvonimirBandic commented 6 months ago

Hi Jean-Paul,

huh, it has been a while i have built this. I also had help, and not sure who is still active in the community, plus I have moved to Verilog ans System Verilog long time ago due to job requirements. However, when I saw "TAR diode" I can see this is my work. So, I am committed to help best that I can and remember, and if necessary, I can pull out the hardware, which I should still have.

Hopefully, you are using (Sstill) Xilinx ISE, as this is what was used back then. I am going to comment your message, one questions by one, and then we go from there:

1) I have used PapilioOne board. Since it is cheap (https://papilio.cc/index.php?n=Papilio.Buy), it may be easiest to reproduce the demo first with the target board. It will save you a lot of time with UCF file configs. Notice that this is Spartan-3E and not -6. 2) For compilation, you need a special skew of ArduinoIDE that support Papilio boards. This is a problem. I can see that default environment now is ZAP (https://papilio.cc/index.php?n=Papilio.ZAPIDE#:~:text=ZAP%20(ZPUino%20Arduino%20Papilio)%20IDE,Processors%20in%20a%20single%20download.) 3) The design used soft core, so it is essential to use that core specifically, as additional hardware I designed for signal counting was tied up on the bus of that soft core (otherwise, you cannot add hardware into hardened cores , like the one you mention)

Sorry, I have not touched this for a while, I don;t think this will be easy to fully rescuscitate quickly!

Zvonimir

ZvonimirBandic commented 6 months ago

Jean-Paul, let me know if you saw the answers, and if you have more questions. In the mean time, I look into ZAP, and a lot of things look very similar to old IDE I recall. If you want to work on the design, I still have the board, and can get it up and running with ZAP (if it is possible, there could be obstacles - as a matter of fact, there are always obstacles with FPGA, but, there is no better learning ground for embedded systems, IMHO). BR, Z

Art-ut-Kia commented 6 months ago

Hi Zvonimir, Many thanks for the reply. In fact I struggle to find a tool chain for making atmega103 code. All links to ZAP IDE or DesignLab IDE are no more effective. And I'm not in a position to build it from GitHub. BR, JPP

ZvonimirBandic commented 6 months ago

JPP,

oh boy - now I see that all the ZAP IDE links are dead, and that the forum is non-existant. Ach, that is sad, but, given how long this project started (2011!), it had a nice run.

I tried internet archive (you can try this too, needs a lot of exploration...):

https://web.archive.org/web/20130101000000*/https://forum.gadgetfactory.net/index.php?/files/file/8-papilio-arduino-ide/

It does seem to have archived a lot of things, somewhat randomly. No traces of the original toolchain - that would be the best start, because at this point, we have no idea if ZAP IDE was ever debugged with AVR8 soft CPU with extensions to build your own FPGA hardware. This is bad - I think Papilio is still a pretty powerful and interesting FPGA board, but without software support, it is hard to use.

I am not sure how I can help any more. I tried to "quikcly" search internet for FPGA boards that are supported by Arduino IDE. There are few, but are lacking extensive software support and hardware demos Papilio used to have. Also lacking in terms of linkage you need with FPGA synthesis tools, so that new hardware can show up on a CPU memory map - this was so simple and powerful with AVR8 soft core. Did you ask @jackgassett what he recommends? THis may be worth a shot.

Also, if you have more precise requirements of what you need, let me know in direct email.

THanks, Zvonimir

Art-ut-Kia commented 6 months ago

Hello Zvonimir, Eventually I succeeded to install an old version of AVR studio on my recent Windows 11. It compiles C codes successfuly. Now I just have to figure out how to generate the VHDL for program memory initialization and I will be in the starting blocks for discovering SoC world.. BR, JPP