This directory shows an example of the minimum amount of information required for a stub package to be generated.
- All Above
- Firmware Version Folder (See Here)
- Firmware Device Folder (See Here)
- Device Definition File (See Here)
- Device Stubs1 (See Here)
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.