Search found 83 matches: casio

Searched query: casio

by dhylands
Tue Nov 13, 2018 8:32 pm
Forum: Development of MicroPython
Topic: How do I make a port of MicroPython for Casio calculators?
Replies: 66
Views: 11819

Re: How do I make a port of MicroPython for Casio calculators?

The MICROPY_LONGINT_IMPL_MPZ is what you want. MPZ implement arbitrary precision integers. You can find the support files in the py directory: https://github.com/micropython/micropython/blob/master/py/mpz.h https://github.com/micropython/micropython/blob/master/py/mpz.c I'm not sure where the incomp...
by Zezombye
Tue Nov 13, 2018 6:31 pm
Forum: Development of MicroPython
Topic: How do I make a port of MicroPython for Casio calculators?
Replies: 66
Views: 11819

Re: How do I make a port of MicroPython for Casio calculators?

... found these long-int implementations: - MICROPY_LONGINT_IMPL_NONE (int is limited to 2^31 bits) - MICROPY_LONGINT_IMPL_LONGLONG (can't use it as Casio doesn't have 64-bit, and no long long) - MICROPY_LONGINT_IMPL_MPZ (no idea what it is, throws a preprocessor error "incompatible MICROPY_LONGINT_IMPL") ...
by Zezombye
Tue Nov 13, 2018 5:45 pm
Forum: Development of MicroPython
Topic: How do I make a port of MicroPython for Casio calculators?
Replies: 66
Views: 11819

Re: How do I make a port of MicroPython for Casio calculators?

As 2064 is very close to a power of 2, I think there is a hardcoded limit somewhere. I don't think there is a coincidence because 2 kb is quite low I knew it, there is indeed a hardcoded limit (in main.c, hiding in plain sight): static char heap[2048]; Changing the size of the heap works, but in my...
by pfalcon
Wed Sep 12, 2018 9:56 pm
Forum: Announcements and News
Topic: MicroPython in Casio's graphic calculator
Replies: 1
Views: 6542

MicroPython in Casio's graphic calculator

http://edu.casio.com/products/graphic/fxcg50/#Python "Python mode supports a version of MicroPython Version 1.9.4, which has been adapted to run on this calculator. Please note that MicroPython is different from the Python that ...
by jickster
Sat Sep 08, 2018 11:24 am
Forum: Development of MicroPython
Topic: How do I make a port of MicroPython for Casio calculators?
Replies: 66
Views: 11819

Re: How do I make a port of MicroPython for Casio calculators?

Micropython is a work in progress.


Sent from my iPhone using Tapatalk Pro
by Zezombye
Sat Sep 08, 2018 9:31 am
Forum: Development of MicroPython
Topic: How do I make a port of MicroPython for Casio calculators?
Replies: 66
Views: 11819

Re: How do I make a port of MicroPython for Casio calculators?

Thanks. This is very misleading, I expected reader->pos to be the position in the file, and reader->len to be the length of the file. Also the name mp_reader_posix_readbyte() implies that it reads only one byte, it should be mp_reader_posix_readbytechunk or something that implies it reads 20 bytes b...
by jickster
Fri Sep 07, 2018 7:23 pm
Forum: Development of MicroPython
Topic: How do I make a port of MicroPython for Casio calculators?
Replies: 66
Views: 11819

Re: How do I make a port of MicroPython for Casio calculators?

I am perplexed by this bit of code: typedef struct _mp_reader_posix_t { bool close_fd; int fd; size_t len; size_t pos; byte buf[25]; } mp_reader_posix_t; STATIC mp_uint_t mp_reader_posix_readbyte(void *data) { mp_reader_posix_t *reader = (mp_reader_posix_t*)data; if (reader->pos >= reader->len) { i...
by Zezombye
Fri Sep 07, 2018 5:24 pm
Forum: Development of MicroPython
Topic: How do I make a port of MicroPython for Casio calculators?
Replies: 66
Views: 11819

Re: How do I make a port of MicroPython for Casio calculators?

I am perplexed by this bit of code: typedef struct _mp_reader_posix_t { bool close_fd; int fd; size_t len; size_t pos; byte buf[25]; } mp_reader_posix_t; STATIC mp_uint_t mp_reader_posix_readbyte(void *data) { mp_reader_posix_t *reader = (mp_reader_posix_t*)data; if (reader->pos >= reader->len) { if...
by jickster
Mon Sep 03, 2018 8:29 pm
Forum: Development of MicroPython
Topic: How do I make a port of MicroPython for Casio calculators?
Replies: 66
Views: 11819

Re: How do I make a port of MicroPython for Casio calculators?

... if an error happens (syntax error, or out of memory error for example). I just overrode the close, read and open functions in reader.c with the Casio ones (which are very similar in function, if not the exact same). How do I make sure MPy closes the file? I can't put the file handle in global ...
by jickster
Mon Sep 03, 2018 8:05 pm
Forum: Development of MicroPython
Topic: How do I make a port of MicroPython for Casio calculators?
Replies: 66
Views: 11819

Re: How do I make a port of MicroPython for Casio calculators?

... if an error happens (syntax error, or out of memory error for example). I just overrode the close, read and open functions in reader.c with the Casio ones (which are very similar in function, if not the exact same). How do I make sure MPy closes the file? I can't put the file handle in global ...