Starting out

193 views
Skip to first unread message

Marián

unread,
Apr 14, 2024, 11:56:41 PMApr 14
to FPGAwars: explorando el lado libre
Hello everyone!
I have only just started experimenting with FPGAs and I'm using the TinyFPGA BX board. However I have an issue with icestudio. When I connect the FPGA and try to upload some code I get a message on first screenshot. However when I completely disconnect the board, I get the message on the second screenshot. There probably is a problem with the USB interface or something. Is there a way to manually route a port to the board or a way to fix it? Thank you for any advice. 

Screenshot 2024-04-15 005042.png
Screenshot 2024-04-15 005147.png

Democrito

unread,
Apr 15, 2024, 4:11:57 AMApr 15
to FPGAwars: explorando el lado libre
Before uploading the circuit, did you press the button on the TinyFPGA BX board?

charli va

unread,
Apr 15, 2024, 11:23:32 AMApr 15
to fpga-wars-explora...@googlegroups.com
Hi Marián! i'm checking it and i'm experimenting the same error as you.

I'll try to fix it, tell you soon.

El lun, 15 abr 2024 a las 10:12, Democrito (<spo...@gmail.com>) escribió:
Before uploading the circuit, did you press the button on the TinyFPGA BX board?

--
Has recibido este mensaje porque estás suscrito al grupo "FPGAwars: explorando el lado libre" de Grupos de Google.
Para cancelar la suscripción a este grupo y dejar de recibir sus mensajes, envía un correo electrónico a fpga-wars-explorando-el...@googlegroups.com.
Para ver esta conversación en el sitio web, visita https://groups.google.com/d/msgid/fpga-wars-explorando-el-lado-libre/ffc18346-39cc-4d6f-b51b-8ba937ff60d2n%40googlegroups.com.

charli va

unread,
Apr 15, 2024, 11:32:43 AMApr 15
to fpga-wars-explora...@googlegroups.com
Hi Marián, what OS are you using?

charli va

unread,
Apr 15, 2024, 11:47:07 AMApr 15
to fpga-wars-explora...@googlegroups.com
Hi Marián, i'm digging into the problem, appears that arount october 2023, the tinyprog not works well:


i'm trying to look for a solution and fix it.

Thanks for find it because anybody report it until you.


charli va

unread,
Apr 15, 2024, 12:32:29 PMApr 15
to fpga-wars-explora...@googlegroups.com
Hi Marian! I'm fixing it but I have to talk to @obijuan to make a fix on celery and it might take a little time.

If you're in a hurry, are you a developer? Are you comfortable editing Python files? the solution is very simple but you need to comment out a line in the celery tiniprog package, tell me if you want to edit the file or wait for it to be fixed in icestudio (maybe in a day or two tops).

Thank you!

Marián

unread,
Apr 15, 2024, 1:51:51 PMApr 15
to FPGAwars: explorando el lado libre
Hello, 
I am using Windows 10. I am not a code developer. I mean, I wouldn't mind editing a Python file, however I don't really know how would I translate it back to a functioning program. But with some guidance I can probably do it. I am not in that big of hurry but y'know, the sooner I get this working the better. So I would be really grateful for some assistance :-) . 

Cheers!

Dátum: pondelok 15. apríla 2024, čas: 18:32:29 UTC+2, odosielateľ: charliva

Marián

unread,
Apr 17, 2024, 6:04:06 AMApr 17
to FPGAwars: explorando el lado libre
Hello,
I would like to ask again, how can I fix the tinyprog bug on my end? Or perhaps is the bug getting fixed sometime soon?

Thanks you!

Dátum: pondelok 15. apríla 2024, čas: 19:51:51 UTC+2, odosielateľ: Marián

Jose Luis

unread,
Apr 17, 2024, 8:11:23 AMApr 17
to fpga-wars-explora...@googlegroups.com

hello,


This pull request to the TinyFPGA bootloader repository fixed it on my end but to upload from icestudio im not sure if it could use the patched bootloader tool


https://github.com/tinyfpga/TinyFPGA-Bootloader/pull/73


looks like some boards from crowd supply shipped with a non or partly working bootloader


i hope it helps

charli va

unread,
Apr 17, 2024, 10:19:47 AMApr 17
to fpga-wars-explora...@googlegroups.com
Hello everyone! The fix applied to Icestudio will probably be out in a day or two. I'm stabilizing other things and will upload everything together.

But if you want to try it now, I am attaching this file that you must overwrite on your system.

Find this directory in your installation:

.icestudio\venv\lib\python3.9\site-packages\tinyprog

the .icestudio directory could be on Windows in your user folder or in c:\

replace the __ini__.py file in this directory with the one attached here.

I also attach a simple test, that light turns the tinyfpga LED on and off (thanks Demócrito for it).

Tell me if it works please.

On the other hand, thank you José for your reference thread, I think this is another problem or if it is the same I think I solved it in another way. I am reading your reference again because it is very interesting to apply this patch also because there could be other problems with the tinyfpga board that have not yet come to our attention.

Thank you all, I look forward to your tests!



__init__.py
test-tiny.ice

Marián

unread,
Apr 17, 2024, 1:55:02 PMApr 17
to FPGAwars: explorando el lado libre
Hello! 
Thank you for the code. However I must report that it unfortunately doesn't work and the error is still the same. I've also tried the code from PR #73 and it doesn't work either, but in a different way
Screenshot 2024-04-17 183704.png
Which is concerning, because it is neither compatible with Python 3.11 nor 3.12, so I'm not really sure what could be the issue now. However from further testing, first, there were no metadata on any board we have, then I tried the __init__.py from PR  #73 (with added data_tables.py ) in command line tinyprog, which can read the metadata correctly.
I also tried uploading a .bin file exported from icestudio using tinyprog -p, which sort of worked. The progress bar in the middle of the upload stopped and I got multiple errors saying that it failed to read from serial port. However what was interesting was that the boot LED turned off and there was no blinking. I then tried loading in a code that was supposed to turn a pin HIGH and LOW. Which resulted in the output pin being floating while other pins were at 5V for some reason. 

tldr; the new fix __init__.py didn't solve the issue while code from #73 with added data_tables.py from #73 sort of worked and half uploaded the code compiled in ice studio and uploaded through tinyprog via terminal.

I hope any of this helps in any way, I am truly lost now. 
Thank you! - Marián

Dátum: streda 17. apríla 2024, čas: 16:19:47 UTC+2, odosielateľ: charliva

charli va

unread,
Apr 17, 2024, 2:57:17 PMApr 17
to fpga-wars-explora...@googlegroups.com
Don't worry Marian, give me today to check it and I'll tell you tomorrow. I'm working on a different operating system than yours and that could be it, don't pay attention to python3.9

Thank you very much for your comments, we will make it work together!

charli va

unread,
Apr 18, 2024, 12:06:47 PMApr 18
to fpga-wars-explora...@googlegroups.com
Hi at all! i  found the problem and i'm fixing it, sorry for the previous fix that only apply to OSX that is different from windows.

Tell you soon

charli va

unread,
Apr 18, 2024, 6:16:49 PMApr 18
to fpga-wars-explora...@googlegroups.com
Hi Marián!! come on with other test.

Remove (save before delete :).  ). the path .icestudio\venv\Lib\site-packages\apio
then unzip the apio folder attached inside .icestudio\venv\Lib\site-packages

Try it, if all works fine, you could upload the bitsrtream but you view a red toast message with some errors and a Sucess OK at the end (dont worry for this if upload works then i fix this other).

Thanks!
apio.zip

Marián

unread,
Apr 20, 2024, 10:05:03 AMApr 20
to FPGAwars: explorando el lado libre
Hello, I tried it, and I got a different error once again. This one more spicy :D 124eef42-66ba-4730-880a-2cd5fae6300a.jpg
And it happened that I can't get the metadata out of the board anymore :/. 

Cheers!

Dátum: piatok 19. apríla 2024, čas: 0:16:49 UTC+2, odosielateľ: charliva

Marián

unread,
Apr 20, 2024, 10:12:32 AMApr 20
to FPGAwars: explorando el lado libre
But an interesting thing about getting metadata is the fact, that the program outside of .icestudio directory doesn't seem to work 
Screenshot 2024-04-20 161111.png
Dátum: sobota 20. apríla 2024, čas: 16:05:03 UTC+2, odosielateľ: Marián

charli va

unread,
Apr 20, 2024, 3:33:05 PMApr 20
to fpga-wars-explora...@googlegroups.com
Thanks for trying it Marian, we had two different problems, on the one hand the update of the latest tinyprog tool did not work with any board, and on the other hand it seems that there are a series of cards that have bad or non-existent metadata (your case) .

The first problem is already solved, it already works on my tinyfpga and Democritus. Now we have to solve the metadata issue.

It is quite complex. I have been reading several threads these days and there are no clear answers, but I am trying to investigate how the bootloader works internally to find a solution. In the next few days I hope to give you an answer, I'll work on it.

Marián

unread,
Apr 20, 2024, 5:04:54 PMApr 20
to FPGAwars: explorando el lado libre
Thank you very much!
I have been reading threads as well and tried a few things but since I'm not really good at python, I haven't had much success as you can see :D. But thank you for your ongoing support. I hope to hear from you soon, keep me updated.

Cheers!



Dátum: sobota 20. apríla 2024, čas: 21:33:05 UTC+2, odosielateľ: charliva

charli va

unread,
May 20, 2024, 5:16:56 PMMay 20
to fpga-wars-explora...@googlegroups.com
Hi Marián! dow you fix your board? i have a possible fix but i can't try it because my board is fine and this problem occurs only in some last batches of this board.

If you are looking for a solution, tell us and i'm explaining you what do you need to try.

Thanks!

Marián

unread,
May 23, 2024, 5:42:01 PMMay 23
to FPGAwars: explorando el lado libre
Hello charliva,
Apologies for late reply. I am still looking for some sort of a solution, I haven't been able to find anything so far, hence I would really appreciate any advice or help you could offer

Cheers!

Dátum: pondelok 20. mája 2024, čas: 23:16:56 UTC+2, odosielateľ: charliva

charli va

unread,
May 29, 2024, 3:47:28 PMMay 29
to fpga-wars-explora...@googlegroups.com
Sorry for the delay Marian. I have two possible ways to try it.

Let's try the easiest one first.

Replace the __init__.py file in the .icestudio/venv/lib..../tinyprog directory as in the previous test and try to upload from icestudio (remember to press the button until upload).

If this doesn't work, I have another possible way, but I prefer to try this first.

I also attach a test file that makes the LED pulse very quickly.

I'm waiting for your news!



__init__.py
test-tiny.ice
Reply all
Reply to author
Forward
0 new messages