mirror of
https://github.com/openmv/openmv.git
synced 2025-09-26 23:09:13 +08:00
docs: Add information about board configuration.
This commit is contained in:
parent
7bd3cb08bd
commit
b6c40ca05f
@ -66,6 +66,8 @@ The above code works for Windows, Mac, or Linux. You just need to change the abo
|
||||
|
||||
The easiest way to patch the firmware and rebuild it, is to fork this repository, enable Actions (from the Actions tab) in the forked repository, and pushing the changes. Our GitHub workflow rebuilds the firmware on pushes to the master branch and/or merging pull requests and generates a development release with attached separate firmware packages per supported board. For more complex changes, and building the OpenMV firmware from source locally, see [Building the Firmware From Source](https://github.com/openmv/openmv/blob/master/docs/firmware.md).
|
||||
|
||||
For more information about customizing your OpenMV Cam's configuration see [Board Configuration](docs/boards.md).
|
||||
|
||||
## Contributing to the project
|
||||
|
||||
Contributions are most welcome. If you are interested in contributing to the project, start by creating a fork of each of the following repositories:
|
||||
|
51
docs/boards.md
Normal file
51
docs/boards.md
Normal file
@ -0,0 +1,51 @@
|
||||
# Board Configuration Customization
|
||||
|
||||
You can customize the firmware for your OpenMV Cam by editing the board configuration files
|
||||
under `boards`.
|
||||
|
||||
## Image Library Configuration
|
||||
|
||||
All boards have an `imlib_config.h` which enables or disables different machine vision algorithms
|
||||
onboard your OpenMV Cam. If you need to save firmware space quickly then the best way to do so is
|
||||
to disable different unused algorithms onboard via commenting out things in the `imlib_config.h`.
|
||||
|
||||
## Built-in Python Modules
|
||||
|
||||
The `manifest.py` file specifies which python modules are built-into the firmware and available as
|
||||
frozen modules which can be imported.
|
||||
|
||||
## Low-level Board Configuration
|
||||
|
||||
`omv_boardconfig.h`, `omv_boardconifg.mk`, `omv_bootconfig.h`, and `omv_pins.h` control low-level
|
||||
board controls like RAM/FLASH memory layouts, pin controls, and other resources allocations. Do
|
||||
not edit these files unless you know what you are doing.
|
||||
|
||||
## ROMFS Configuration
|
||||
|
||||
You can edit the default files built-into the ROMFS partition by the build system by editing the
|
||||
`romfs.json` file. The ROMFS parition is a memory mapped file system in which large data structures
|
||||
like models can be executed in-place from.
|
||||
|
||||
The json layout in the `romfs.json` file specifies the different ROMFS paritions to be created
|
||||
by the build system and the size of these partitions. In general, you should only edit the entry
|
||||
array of files built-into the ROMFS image.
|
||||
|
||||
Each entry in `entries` accepts a `type`, `path`, and optional `alignment` field. `type` should be:
|
||||
|
||||
`<None>`: The file is included without any transformation.
|
||||
|
||||
`tflite`: Use this format for compiling `tflite` models into the ROMFS. Note that the `alignment`
|
||||
for `tfilte` models should be `16` on cameras without NPUs, `16` for for cameras with the ARM
|
||||
Ethos NPU, and `32` for STEdgeAI powered boards. For ARM Ethos NPU boards, the entry must contain
|
||||
the `optimize` argument for the NPU to control optimization, which may either be `Size`
|
||||
or `Performance`. For STEdgeAI Powered boards, the entry must contain an argment to select the
|
||||
`profile` to use when compiling models, which may be `default`.
|
||||
|
||||
`haar`: Use this format for compile `xml` haar cascades into the ROMFS. Accepts a required `stages`
|
||||
argument which specifies the maximum number of stages of the cascade to run. Use `0` to run all
|
||||
stages. Cascades do not require any memory alignment.
|
||||
|
||||
## ULAB Library Configuration
|
||||
|
||||
You can change how [ULAB](https://micropython-ulab.readthedocs.io/en/latest/ulab-intro.html) is
|
||||
setup for the firmware by edting the `ulab_config.h` file.
|
Loading…
Reference in New Issue
Block a user