Search found 96 matches

by martincho
Fri Jul 15, 2022 2:27 pm
Forum: General Discussion and Questions
Topic: General Question
Replies: 16
Views: 4631

Re: General Question

...Oh, yes, the designer thought they were clever and mis-wired the ROM to jumble-up the bits. In other words, instead of wiring bits 0-7 to the corresponding pins on the ROM chip, they wired 5 to 2, 7 to 0, etc. An attempt to make the disassembled code meaningless... He made your life too easy. He...
by martincho
Wed Jul 13, 2022 8:09 pm
Forum: General Discussion and Questions
Topic: General Question
Replies: 16
Views: 4631

Re: General Question

But again... I would seriously question how valuable this is and whether it's worth the additional cost and complexity to your development. What are you really protecting against? I want to prevent the micropython code running on the controller from any attacker . This is my main goal . Your descri...
by martincho
Tue Jul 12, 2022 10:42 pm
Forum: General Discussion and Questions
Topic: Problem with sendbreak in UART
Replies: 11
Views: 2881

Re: Problem with sendbreak in UART

Hello, I have a problem, I installed micropython 1.19.1 on an esp32 and I need a sendbreak on the UART with more than 13 milliseconds. Unfortunately sendbreak has no duration option and it only lasts 8 milliseconds. Would there be any alternative to increase the sendbreak duration time in the UART?...
by martincho
Tue Jul 12, 2022 4:41 pm
Forum: General Discussion and Questions
Topic: @micropython.native not implemented too long
Replies: 14
Views: 5399

Re: @micropython.native not implemented too long

Interesting. As a matter of interest do you use the second core? I will in the future. I hope you agree with this: I have been avoiding using the second core because I don't want to fall into the trap of throwing hardware at bad code. It's all too easy to write bad code and "fix it" by using the se...
by martincho
Tue Jul 12, 2022 4:32 pm
Forum: General Discussion and Questions
Topic: @micropython.native not implemented too long
Replies: 14
Views: 5399

Re: @micropython.native not implemented too long

Are you running mpy-cross with exactly the same configuration as the board is using, specifically `march=armv6m`? It should be Yes, exactly that configuration. But further to what Peter already said... if you're hitting this error then your function must be huge. Something's not right. Not really. ...
by martincho
Tue Jul 12, 2022 2:59 pm
Forum: General Discussion and Questions
Topic: @micropython.native not implemented too long
Replies: 14
Views: 5399

Re: @micropython.native not implemented too long

I suggest you review your use of micropython.native . Like all optimisations it's best only to apply it where there is a true performance bottleneck. My approach is to identify which part of the code is causing the slowdown and optimise it until it sqeals. micropython.native rarely makes a large di...
by martincho
Tue Jul 12, 2022 7:46 am
Forum: General Discussion and Questions
Topic: @micropython.native not implemented too long
Replies: 14
Views: 5399

Re: @micropython.native not implemented too long

Just ran into this one again using mpy-cross. What's interesting is that the source files, unmodified, run just fine on the RP2040. No warnings whatsoever. The minute I tried to pre-compile I got: NotImplementedError: native method too big Not complaining (how could one when it comes to amazing free...
by martincho
Mon Jul 11, 2022 7:21 pm
Forum: General Discussion and Questions
Topic: @micropython.native not implemented too long
Replies: 14
Views: 5399

Re: @micropython.native not implemented too long

Knowing the exact error you're seeing would help. But it should be pretty clear -- either your method is using a lot more locals than before, or it's just gotten longer. Either way though, what Pete said -- use the cross-compiler instead. It's designed for this purpose. I had trouble reproducing it...
by martincho
Mon Jul 11, 2022 3:42 pm
Forum: General Discussion and Questions
Topic: @micropython.native not implemented too long
Replies: 14
Views: 5399

Re: @micropython.native not implemented too long

I don't know off the top of my head why the minifier is causing this unless it's doing inlining? Circling back to this, not sure what it might be doing that is causing the anger of MicroPython gods. I don't think I am going to pursue this path. Probably not worth the effort required to diagnose and...
by martincho
Mon Jul 11, 2022 8:12 am
Forum: General Discussion and Questions
Topic: @micropython.native not implemented too long
Replies: 14
Views: 5399

Re: @micropython.native not implemented too long

As a general point I stopped using pyminify on MP programs several years ago. Cross-compiling achieves a size reduction on the order of 3:1. It has other benefits: faster loading and lower RAM use because the code is pre-compiled. Playing with different workflows at the moment. That's actually on m...