Skip to content

Latest commit

 

History

History
56 lines (43 loc) · 2.25 KB

README.md

File metadata and controls

56 lines (43 loc) · 2.25 KB

Example Package

This directory shows an example of the minimum amount of information required for a stub package to be generated.

Requirements

For Firmware Modules

For Device

Result

If all of the above requirements are met, you should have a directory tree similiar to this:

 └──     micropy-branch/
 │  ├────     info.json
 │  └────     v1.0/
 │  │  └────     esp32/
 │  │  │  ├────     info.json
 │  │  │  └────     stubs/
 │  │  │  │  ├────     stub1.py
 │  │  │  │  └────     stub2.py

Which will then be recognized and have the rest automatically generated as so...

 └──     micropy-branch/
 │  └────     frozen/
 │  │  ├────     fwaremod1.py
 │  │  └────     fwaremod1.pyi
 │  ├────     info.json
 │  └────     v1.0/
 │  │  └────     esp32/
 │  │  │  ├────     info.json
 │  │  │  └────     frozen/
 │  │  │  │  ├────     devicemod1.py
 │  │  │  │  └────     devicemod1.pyi
 │  │  │  └────     stubs/
 │  │  │  │  ├────     stub1.py
 │  │  │  │  └────     stub2.py

...with the info.json files updated accordingly.

1: As far as I know, the best way to create device stubs is to do it on the actual device using micropy-cli or more directly micropython-stubber. Therefore, the stubs must be added manually. As I don't own every micropython compatible device, this project will require some PRs for it to be successful.