Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Large file copied on PSoC6 using Arduino LAB is not saved; file is empty!!! #68

Closed
Antonia-place opened this issue Jul 21, 2023 · 7 comments
Labels
bug Something isn't working

Comments

@Antonia-place
Copy link

Hello,
Today I try to copy a large file into PSoC6 board, using Arduinl LAb version 0.8.0 and the copied file is empty after the copy process
was finished. Moreover, the copying process take aprox. 9 minutes ( and for 2 minutes remain "blocked" at 22%). It is OK this large time for copying the file?
Here is all the steps used for repro:
step 01: prepare a file with more than 2500 lines (2588); See attached file "Program_02.py"
step 02: copy this file (Program_02.py) into PSoC6 using Arduino Lab; this action take aprox. 9 minutes (stay 2 minutes at 22%);
step 03: after file was copied, press Run (from Arduino LAB0 and observe console output;
step 04: try to select other file from PSoC (on board, I have other small files saved); in this moment, Arduino LAB is blocked and can not be used;
step 05: reset PSoC6 board; after that, Arduino Lab remain blocked and can not be used;
step 06: close Arduino LAB;
step 07: open again Arduino LAB, connect it to the PSoC6 board and select the filed copied erlier, named Program_02.py and observe: the file is empty and the capacity is 0 bits!!!

Attached you will find: code used for test (this code is not working because is not complete, but at least should be copied on PSoC6 board):
Program_02.zip
Image from the copy process:
Remain at 22% more than 2 minute
Image with console output after the copy process is done and Run button was pressed:
Console output after file was copied into PSoC6 and run
Image from PSoC6 after the MCU was reseted (see step 04, 05, 06 and 07), where the saved file is empty:
Copied file is empty

Please verify this on your side. On my side, I done this more than 3 times, with several files and the behaviou was the same: saved file is empty.
Moreover, do you have any news regarding to Thonny and large files? This question is related to this discussion: #62

Thank you for support,
Mihai

@Antonia-place Antonia-place added the bug Something isn't working label Jul 21, 2023
@NikhitaR-IFX
Copy link
Member

Hi @Antonia-place ,

Could you please try using the mpremote and let us know if it still does not work for you?
I have already raised this with thonny and if interested, you can follow up here Issue 2862.

I tried the same and I confirm that Arduino Lab for MPY is failing as well. Meanwhile, I will check on this and get back.

Thanks and Regards,
Nikhita

@Antonia-place
Copy link
Author

Hello,
I tested today the file transfer with mpremote, from my win11 PC to PSoC6, with the same result: file is created but is empty; Please see the below picture:
Tested also with mpremote

For transfer I used the same file like in the first post of this issue.
For mpremote I used the informations from here: https://docs.micropython.org/en/latest/reference/mpremote.html
Please investigate.

Thank you for support,
Mihai

@jaenrig-ifx
Copy link
Member

Hi @Antonia-place,

We need to further explore this issue. A first guess could be:

  1. Could you have exceeded the memory capacity?
  2. With a "large" file, a simple serial protocol as I would assume (since honestly I don´t know the details) behind mpremote and this IDE implementations, there is the change that some buffer has been overflowed? lack of segmentation mechanisms? even higher change of transmission errors and no checksum codes?
  3. Both 1 and 2 at the same time😞

While we find some time to further check I suggest you try splitting the file in several? and check memory size?

Thanks for your patience.
Juan

@Antonia-place
Copy link
Author

Hello,

I verified the memory ocupated from PS0C6 and from am RPI PICO after the file was trafered.
The values are in the following pictures:
Memory free on PSoC6
Memory free on RPI_PICO

I know that I can fragment my code in pieces, but for this particular project, it is hard to me to split my code because I have to work a lot with some Nokia5110 displays and I have to draw a lot of thing and this take a lot of lines of code...
I observer that the part file can not be saved correctly (from Thonny or Arduino LAB) if the code exced the number of 500 and something ( see discussion #62)

It is any posibility to enable some traces/logs in microPython or in Arduino LAB when the file transfer is in progress? Maybe we can find the issue...

Thank you for support,
Mihai

@Antonia-place
Copy link
Author

Hello,
Do you have any update regarding to maximum file that can be created and transferes/saven on PSoC6, using Thonny or Arduino Lab?
I checked the latest MicroPython v0.5.0 and this issue ie present .

Thank you,
Mihai

@NikhitaR-IFX
Copy link
Member

Hi Antonio,

Thank you for sharing the details and letting us know this is still a problem. We did not find any obvious reasons for this issue so far. Please allow us some more time as we want to do some more tests for our port and understand this in detail.

We will get back to you on this!

Thank you for your patience and contributions!

Thanks and Regards,
Nikhita

@jaenrig-ifx
Copy link
Member

Hi @Antonia-place,

This issue should be now fixed in v.0.6.0 for CY8CPROTO-062-4343W board.

Regards,
Juan

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants