Page 5 of 5

Re: Losing the REPL when an IRQ is triggered

Posted: Thu Sep 15, 2016 6:50 am
by jgmdavies
Many thanks both!

Re: Losing the REPL when an IRQ is triggered

Posted: Thu Sep 15, 2016 7:40 pm
by Roberthh
I removed the server timeout setting, but still no change. The ISR stays stable. So the only thing left to try would be omitting the expansion board and direct supply of WiPy. About the boot vs. boot.py issue. If you cannot load the new boot.py, you could rename the files on WiPy at the REPL prompt with uos.rename.

Code: Select all

import uos
uos.rename(old_name, new_name)

Re: Losing the REPL when an IRQ is triggered

Posted: Fri Sep 16, 2016 6:25 am
by Roberthh
This morning the behaviour changed. I found the by mistake I had loaded Version 1.6-310. I uploaded today's V1.8.4.12, and no I have the ISR failures. Most of the time, I do not even see the '1' count. Going back to 1.6.-310 cured it.
That indicates that it is indeed a SW version issue. Not clear why it worked with other 1.8 variants before.

Re: Losing the REPL when an IRQ is triggered

Posted: Fri Sep 16, 2016 7:04 am
by jgmdavies
Thanks Robert. I haven't had time to do more experiments yet. Typically, my ISR didn't even reach the '1' count in previous tries, although I have occasionally seen it work for a while with 1.8.3.

Re: Losing the REPL when an IRQ is triggered

Posted: Sat Sep 17, 2016 5:59 am
by Roberthh
Ok, now I have a consistent picture. The most recent stable version from the download page is 1.8.1. All others fail after a while, and that while can be hours, if your network is quiet. Following Damien's suggestion and changing mpconfigport.h to

Code: Select all

#define MICROPY_PY_THREAD                           (0)
#define MICROPY_PY_THREAD_GIL                       (0)
seems to suppress the problem for the recent builds. A build created that way now runs for 10 hours. I've placed a copy here, for people who do not want to build it themselves: https://github.com/robert-hh/Shared-Stuff

Re: Losing the REPL when an IRQ is triggered

Posted: Sat Sep 17, 2016 12:54 pm
by jgmdavies
Well done, and thanks Robert!

It's working so far here - I don't suppose Damien could include it as a run-time option soon? :D

What do you think is the best place for 'user contributions' like this for the WiPy? I had a go at a simple Float package, and I've also done small versions of things like 'configparser' for the WiPy. I think it would be good to have a shared list of contributions in one place, so anyone can see what's available (and what isn't).

Jim

Re: Losing the REPL when an IRQ is triggered

Posted: Mon Sep 19, 2016 7:18 am
by pythoncoder
Consider starting a WiPy section on the Wiki http://wiki.micropython.org/Home?

Re: Losing the REPL when an IRQ is triggered

Posted: Mon Sep 19, 2016 7:24 am
by jgmdavies
There's also the 'Pycom Exchange', mentioned at https://www.kickstarter.com/projects/17 ... ts/1485410 ?

Re: Losing the REPL when an IRQ is triggered

Posted: Wed Sep 21, 2016 4:39 pm
by danielm
Robert, your build of v1.8.4-16 works for me as well.
Hope there will be a solution which will make it work with threading enabled.

Re: Losing the REPL when an IRQ is triggered

Posted: Wed Sep 21, 2016 6:54 pm
by Roberthh
I'll update them about once a week, just in case you need it.