Cannot download to PYGAMER

I wasn’t getting any error codes trying to upload the game or while playing it. I wasn’t able to upload the game via Makecode (webusb) or via the computer by dragging the .uf2 file. During the transfer the device showed the bootstrapping screen, it flickered blank for a second but showed the bootstrapper screen again. Eventually I did get it to work, but the problem is I don’t know what got it to work. I was just thinking that maybe the size of the game might have been the problem, but it may have just been my computer, the usb cable (as I kept trying different ones) or webusb finally working.
I thank you :two_hearts: all for helping out with this issue, as you can imagine I was devastated to finish part of the game and to not have it work on the pygamer, but it is working now. I’ll keep my fingers crossed each time I upload and hope that I don’t have any problems in the future.

1 Like

Hi @richard,

I made a few changes to my game (the biggest being the array of images for the player) after which I can no longer upload the game to my PyGamer. Sometimes when I commit changes to GitHub, while in the blocks view, I see a message saying that the blocks may be damaged or corrupted. Can you see if there is anything wrong with the code, and are you able to upload to a PyGamer? (if you have one).

After many attempts not being able to download the game, I saw a brief popup from the bottom the editer saying ‘Compilation failed contact support’.

Hmm, yes I’m able to flash that to my pygamer. Could you check the developer tools console for your browser and see if any exceptions are printed out?

Hi @richard
A support member at Adafruit said that they also had a problem downloading the game, and asked if I could display the errors in the console.
https://forums.adafruit.com/viewtopic.php?f=64&t=170730

I am not able to attach the .log file from Microsoft Edge, but the following is shown in the Console when loading in the game. I hope you are able to help.

Summary of errors:

  • [Deprecation] Application Cache API manifest selection is deprecated and will be removed in M85, around August 2020. (Warning)
  • Bad HTTP status code: 404 (Error)
  • Deprecated use of setting size_.width to 0 to rerender a field. Set field.isDirty_ to true instead. (Warning)

I couldnlt paste in the entire log, it exceeded that max characters of 32000 : -) I’ve uploaded the log files to my Google Drive:

(froggingFun-log-20201022.txt) This is the log from today, and the summary of errors are above.
The other files were made yesterday, so in the order of:

  1. arcade.makecode.com-loadingGame.log
  2. arcade.makecode.com-selectedHardware.log
  3. arcade.makecode.com-downloading-NoGameOnDevice.log

I just updated my bootloader to 3.10.0 and I still have no trouble flashing the device using the version you linked.

How are you copying it over? Can you try downloading it a folder other than the device and then manually dragging it over? We’ve seen a few isolated issues in the past when downloading directly to the device drive.

Other than that my only guess is that it has something to do with you being on Windows (I’m on a mac). @jwunderl do you have a PC you can give this a try with?

Also thanks for the logs, nothing looks amiss from what I can see.

Yeah, tested windows / latest build (ish) and it flashed correctly.

@cosmoscowboy From those logs, it looks like it 404d trying to get to https://github.com/cosmoscowboy/frogging-heck, which doesn’t exist – it’s possible that just creating the repo (and switching the branch from main to master for now, as we have work to do to accommodate new options for default branches) would fix that? Not sure right away, have you tried to upload it before?

Just to confirm, if you click the dropdown to the right of the download button, it does say Adafruit PyGamer exactly like this, right?

image

Hi Joey, thanks for getting back to me. I’ve tried everything. Microsoft Edge, Chrome, another laptop. Also via webusb or by dragging the downloaded game from my computer to the drive of the pygamer. I do see the correct device when trying to download it.


This is in Chrome.
Latest version: https://makecode.com/_bE8cTveDKMyK

As discussed here, Array of animations, I have created a new version, and the 404 errors have disappeared. That’s good. If only I could find a way to get it work on my PyGamer.

I’m having the same issue on a game I am working with my son. We were able to download to his Pygamer, but after changing from color-coded tilemaps to the new tilemap API we aren’t able to do so. It exhibits the same behavior you described. I am having no issues with other games.

I cannot pinpoint a behavior that prevents me from uploading games on to my PyGamer. In the game that I posted, it is using the color-code tilemap. I was able to upload the game in the beginning, but after some time (I guess more code, animations, etc), it no longer works. I am no longer working on this game. I think the issue is quite random. For the game I posted for the Ocean Jam, Shark Frenzy, it does not use a tilemap and I cannot upload it either. The game saved in GitHub does not work, but when I create a new project, not hosted in GitHub, and copy the entire code over, I can upload it. Personally I believe that once a game reaches a certain size, it just doesn’t work. Perhaps it could also be if it hosted in GitHub, as others were able to upload a shared version. It is a conundrum that is somewhat annoying, but so long as the game works in a browser, and on a mobile phone, that I don’t mind so much; except for the investment made in the hardware. :wink:

I was able to get the game to download to his Pygamer.

I removed all color-coded timemap tiles, and remapped all existing maps to use all the earlier maps stored in tilemap.g.ts and tilemap.g.jres: level, level_0, level _1… etc.

I created a new project, copied and pasted the JavaScript, and fixed all mismatched tiles on Overlap functions. After getting the game working, I was able to download the game to the Pygamer. I saved the game as a PNG and then made a few minor changes then commited and pushed my changes to a new Git repo. After doing this, I was not able to download to the Pygamer. I then deleted the project and Git repo and imported the saved PNG. I made the same changes and was able to download to the Pygamer. So far that is working. I will not release it to Git until the game is ready for release.

1 Like