FPGA Question..... - Page 1
Forum section: electronics / general

author: Splinter34
author_rank: Newbie
timestamp: October 09, 2023, 10:10:09 pm
content: First off, If this question is in the wrong forum, I apologize. This might be a better question in the newbie forum. My son and I have matching higher end portable radios. We enjoyed talking on them often as he did not live far from me. A short while before he passed there was a firmware upgrade that had become available. So he went ahead and flashed his radio which for some reason did not complete the upgrade. These radios have Cyclone III FPGAs and an Max II epm240's along with 64MB Spansion flash chips. I have taken other radios that have bricked and swapped the firmware from a working radio to the bricked one before the revive it and was wondering about how one would go about doing that to one that has FPGA's. If it were an Arm processor it would be quite easily to revive it. I have read a great deal and learned quite alot about FPGAs, but I just can't seem to find the information I am looking for to help me accomplish this task. I have everything I need to do it. A real Usb-blaster, Quartus 13.1 web, and exact chip support. I also have found Verilog files for the Spansion flash Which is a nor flash. I don't really need the other radio but would really like to get it repaired just because. The manufacturer has end-of-lifed these radios and no longer offer support for them. I was hoping that some kind soul could steer me in the correct direction about how this would need to be accomplished. I can query the FPGAs in quartus programmer and they show up correctly, but only the epm240 allows me to examine it and save the pof file but the flash does not show up. Sorry for the long read.Splinter..

author: Daixiwen
author_rank: Frequent Contributor
timestamp: October 17, 2023, 09:37:42 am
content: The flash for the Cyclone 3 is not directly connected to the JTAG, but you can do it by using a serial flash loader image for your target.Use the Quartus programmer to configure the FPGA with the correct SFL image (that you will find in the Quartus installation folder, quartus/common/devinfo/programmer/sfl_enhanced_ep3c**.sof , find the file for the correct variant of Cyclone III)Then do a new autodetect in the Quartus programmer, and the flash memory should appear.

author: Splinter34
author_rank: Newbie
timestamp: October 22, 2023, 09:32:14 pm
content: First off, Thank you so much for your reply Daixiwen. Although that didn't work for my radio, that did work perfectly on my DE0 project board. And I am starting to understand more about FPGAs. They are extremely interesting. My mind is starting to bussle with opportunities for the them. I am unsure of why it didn't work on my radio though. I think the reason it worked on my DE0 board is because the max II 240 is not in the jtag chain as it never shows up, but on my radio that Max II 240g is in the jtag chain. So that makes me think that I need to put an enhanced serial interface on the Max device. Although I have tried this and I have never gotten it to fit on the device (user error) I am wondering if there is a depository with some good examples that could be adapted to my Max II 240GF100|5N. I have been looking around and have yet to find any. Do you think my theory of the Max II device needing the serial interface is correct? Or am I going in the wrong direction? Once again thank you for your earlier reply Daixiwen it is most appreciated.Splinter

author: Daixiwen
author_rank: Frequent Contributor
timestamp: October 24, 2023, 09:48:54 am
content: No it's only the Cyclone FPGA that should have the serial flash loader. What the serial flash loader does is connect the EPCS pins to a JTAG controller inside the FPGA so that you can access the EPCS from Quartus programmer.I have boards with several components in the JTAG chain and it never has been a problem. I do remember that there was a bug in the SFL in some versions of Quartus though, so you could try another version. IIRC version 16.1 at least works well. And of course make sure you are using the SFL for the correct variant of Cyclone III.

author: Splinter34
author_rank: Newbie
timestamp: October 26, 2023, 03:41:27 am
content: Quartus II 17.1 appears not no longer support the cyclone III. I have a request in to Intel for a copy of Quartus 16.1, we'll see what happens.Thanks DaixiwenSplinter

author: Daixiwen
author_rank: Frequent Contributor
timestamp: October 26, 2023, 09:22:04 am
content: It doesn't support it for compiling, but maybe the quartus programmer still supports it? I see in my 18.1 installation that SFLs for even the Cyclone 1 are still present

author: AK6DN
author_rank: Regular Contributor
timestamp: October 26, 2023, 06:31:40 pm
content: Both 13.0sp1 and 13.1 Quartus are publically available for download from Intel/Altera, and they both support the CycloneIII series.No need to fool around with getting a CNDA with Intel to be able to access no longer publicly supported versions.I use 13.0sp1 on Windows 10 and it works just fine for my CycloneII board, and for MAX EPM7K part support.I also use the serial flash loader module so that I can update the EPCS flash config eprom via the Quartus Programmer tool.

author: Daixiwen
author_rank: Frequent Contributor
timestamp: October 27, 2023, 08:22:29 am
content: You can also try the regular sfl (sfl_ep3c**.sof) instead of the enhanced (sfl_enhanced_ep3c**.sof) files. It's a bit fuzzy because it was a while ago, but I think that when I had some problems with an sfl enhanced not working, with a specific version of Quartus, I could get the regular one to work.What happens when you do an autodetect after you have loaded the SFL? Does it still just show the Cyclone and the Max?

author: Splinter34
author_rank: Newbie
timestamp: October 28, 2023, 09:48:07 pm
content: After I load either the enhanced or the regular flash loader , they still just show the cyclone III and the max240g chips. But, after I load the enhanced or regular serial flash loader it does change the Cyclone III model number from EP3C40U484I7N to a EP3C40F780. I did recently see that in Quartus 17 after loading the .sof files it would do nothing. If I tried to add a flash (just a common CFI 512) it would say that attached flash was not compatible with Quartus. If I tried to change the chip after I loaded the IP it would say that the IP would be removed because the chips aren't compatible, Fine vs. Ultra fine? It would seem that I am going to have to find a tutorial on how to exactly make a SFL for my exact Cyclone III model? Does that sound correct? I guess that the fine model is not compatible with the ultra fine?Thanks for your replies people, greatly appreciated.Splinter

author: Splinter34
author_rank: Newbie
timestamp: October 28, 2023, 10:20:20 pm
content: After a successful operation loading the enhanced or standard flash loader this is what Quartus says:Error (209062): Flash Loader IP not loaded on device 1Error (209053): Unexpected error in JTAG server -- error code 5Error (209012): Operation failed.BTW, Quartus always sees my chip as a "F" series vs a "U" series. It never sees it as what exactly it is. Although it is in the Quartus device list as an exact supported match. Can the .sof file be edited in quartus to the exact correct chip and then renamed and saved?

author: Daixiwen
author_rank: Frequent Contributor
timestamp: October 30, 2023, 09:58:08 am
content: I'm sorry I didn't realize you were using a CFI flash, I had just assumed the board had a serial configuration device. For a CFI flash you should use the parallel flash loader instead (pfl_ep3c40.sof in the same folder). Try this one and see if you detect the flash.

author: Splinter34
author_rank: Newbie
timestamp: October 30, 2023, 12:45:11 pm
content: Still not.... Tried Quartus 13.1 and 17Error (209025): Can't recognize silicon ID for device 1. A device's silicon ID is different from its JTAG ID. Verify that all cables are securely connected, select a different device, or check the power on the target system. Make sure the device pins are connected and configured correctly.Error (18591): Can't recognize the Flash device that attached to device 1. The Flash device is not supported by Quartus Prime software.Error (209012): Operation failedI tried to define the flash device, But it won't let me check the box. It will let me highlight it but the box won't check. Do I need to add the flash device to Quartus flash database? I remember reading somewhere about writing a flash definition txt file.Splinter

author: Daixiwen
author_rank: Frequent Contributor
timestamp: October 31, 2023, 12:41:54 pm
content: Yes it looks like it. I don't know why Quartus makes it so complicated, but it won't try and use a CFI device it doesn't know. Unfortunately I haven't done this operation myself so you'll have to search a bit to find out how to add a silicon ID to Quartus' list of recognized flash devices.