micropython icon indicating copy to clipboard operation
micropython copied to clipboard

ustruct module not documented

Open whaleygeek opened this issue 5 years ago • 3 comments

As per a discussion on slack just now...

This search does not find anything about the ustruct module...

https://microbit-micropython.readthedocs.io/en/latest/search.html?q=ustruct&check_keywords=yes&area=default

Screen Shot 2019-03-31 at 11 23 46

But using the latest MicroPython from https://python.microbit.org/v/1.1

It does exist in the runtime image...

Screen Shot 2019-03-31 at 11 19 51

whaleygeek avatar Mar 31 '19 10:03 whaleygeek

Thanks David, we should port the docs (or link to) from https://docs.micropython.org/en/latest/library/ustruct.html

microbit-carlos avatar Mar 31 '19 10:03 microbit-carlos

What other modules are there? ujson ? uhashlib ?

Would it be possible to create an alphabetical module index as per the micropython docs. Or is that a lot of work for just a few modules which are indexed elsewhere

rhubarbdog avatar Apr 01 '19 08:04 rhubarbdog

You can see the available modules running help('modules'):

MicroPython v1.9.2-34-gd64154c73 on 2017-09-01; micro:bit v1.0.1 with nRF51822
Type "help()" for more information.
>>> help('modules')
__main__          love              os                time
antigravity       machine           radio             ucollections
array             math              random            ustruct
audio             microbit          speech            utime
builtins          micropython       struct
collections       music             sys
gc                neopixel          this
Plus any modules on the filesystem
>>> 

The API Reference index on the left-side menu should have an entry for each one of these, excluding aliases (e.g. time/utime), and easter eggs (antigravity, love, and this).

I've created https://github.com/bbcmicrobit/micropython/issues/655 to track this, and PRs are welcomed :)

microbit-carlos avatar Apr 01 '19 10:04 microbit-carlos