Start getting the documentation into shape.

This commit is contained in:
Peter Steenbergen 2023-08-31 10:53:35 +02:00
parent bf166be419
commit b10f3abd0e
8 changed files with 102 additions and 300 deletions

9
documentation/README.md Normal file
View File

@ -0,0 +1,9 @@
# Documentation
## Contents
- [Supported Hardware](./boards.md) - Supported hardware/ board specific information.
- [Kernel](./kernel.md) - Kernel versions used.
- [System Architecture](./architecture.md) - How the system is build up.
- [Features](./features.md) - What is included within the system.
- [Building](./building.md) - How to build an image yourself.

View File

@ -0,0 +1,54 @@
# Technical system architecture
## Disk image build up
The system uses a so called "Double copy with fall-back" architecture. Also known as "A/B (seamless) system updates". This system guarantess that there is always a working copy even if the softwre update is interrupted or a power off occurs.
Each of these A/B copies contains a linux kernel within it's root file system, which is read only and compressed by utilizing squashfs. At current time the rootfs disk usage is ~300MB.
![Double_copy_layout](./images/Double_copy_layout.png)
A synergy with the boot loader is necessary, because the boot loader must decide which copy should be started. It must be possible to switch between the two copies. After a reboot, the boot loader decides which copy should run.
A seperate overlay partition for all changeable files is used to make the userspace system read/write. This seperate partition can be overlayed over either active rootfs partitions, being it slot A or slot B. A factory reset can therefor also being easliy obtained by resetting that overlay partition. It will then again start with the files shipped within the read only squashfs partition.
All docker containers and OVOS framework associated configuration files are stored with the users HOME directory which again is a seperate partition at the end of the disk which is also auto extended over the full size of the disk at boot. This is done based on the availability of free unused disk space at boot. (Any boot, being it the first or any consecutive boot)
## Boot system
The system uses UEFI boot stubs to launch the GRUB2 boot loader. The GRUB2 bootloader takes care of booting the active system partition or can be used to boot into rescue mode for both these system partitions.
## Partition layout
The partition table is written using GPT where possible. Boards/ systems that do not (yet) support GPT, a hybrid system is used. MBR to be able to boot from the ESP bootable partion and from there on GPT takes over again.
The disk image partitions/ partition table is build up as followed;
- ESP (EFI System Partition); VFAT formatted, 16 MB in size and containes the UEFI stub and GRUB2 boot loader.
- ROOTFS-1; Compressed SquashFS filesystem partion, 512 MB in size and containes the linux root system Slot-A including the kernel within the /boot folder.
- ROOTFS-1; Compressed SquashFS filesystem partion, 512 MB in size and containes the linux root system Slot-B including the kernel within the /boot folder.
- OVERLAYFS; Ext4 formatted, 256 MB in size used to persistant store files. Mostly /etc, /root and /var/log directories.
- HOMEFS; Ext4 formatted, 64 MB in size out of the box, however being extended over the unused disk space. A minimum of 8 GB as disk size is recommended.
A visual representation looks like this:
```text
-------------------------
| ESP |
-------------------------
| ROOTFS-1 |
| |
-------------------------
| ROOTFS-2 |
| |
-------------------------
| OVERLAY-FS |
-------------------------
| HOMEFS |
| |
| |
...
-------------------------
```
## ESP Boot system
The system uses UEFI boot stubs to launch the GRUB2 boot loader. The GRUB2 boot loader takes care of booting the active system partition or can be used to either switch/ roll back to the other system partition or boot into rescue mode for both these system partitions.
![GRUB2 boot menu](./images/grub2_menu.png)

View File

@ -4,54 +4,64 @@
### Raspberry Pi
| Device | Status | Board | Supported |
|--------|-----------|-----------|-----------|
| Raspberry Pi 3 B/B+ | Works | rpi3_64 | Work In Progress |
| Raspberry Pi 4 | Works | rpi4_64 | YES |
| Open Virtual Appliance (QEMU, VirtualBox, VMWare, Proxmox, etc)| Works | ova_64 | YES |
| Generic x86-64 (Intel NUC's) | Works | x86_64 | Work In Progress |
<br><br>
## Unsupported for now, but (perhaps) possible in the future
### Raspberry Pi
| Device | Status | Board | Supported |
|--------|-----------|-----------|-----------|
| Raspberry Pi A+/B/B+ | Unknown, most likely under powered | N/A | NO |
| Raspberry Pi Zero | Unknown, most likely under powered | N/A | NO |
| Raspberry Pi Zero W | Unknown, most likely under powered | N/A | NO |
| Raspberry Pi 2 B | Unknown, could possibly work | N/A | YES |
| Raspberry Pi 3 B/B+ | Works | rpi3 | YES |
| Raspberry Pi 4 | Works | rpi4 | YES |
<br><br>
## Unsupported for now, but perhaps possible in the future
### Hardkernel
| Device | Status | Board |
|--------|-----------|-----------|
| Odroid-C2 | most likely possible | Not available yet |
| Odroid-C2 | Possible | Not available yet |
| Odroid-C4 | Possible | Not available yet |
| Odroid-M1 | Possible | Not available yet |
| Odroid-N2 | Possible | Not available yet |
| Odroid-XU4 | Possible | Not available yet |
### Microsoft Windows
| Device | Status | Board |
|--------|-----------|-----------|
| WSL2 | Possible | Not available yet |
### Khadas
| Device | Status | Board |
|--------|-----------|-----------|
| VIM3 | Possible | Not available yet |
### Orange Pi
| Device | Status | Board |
|--------|-----------|-----------|
| Prime | most likely possible | Not available yet |
| * | most likely possible | Not available yet |
### Friendly ARM
| Device | Status | Board |
|--------|-----------|-----------|
| NanoPi M4 | most likely possible | Not available yet |
| * | most likely possible | Not available yet |
### Asus
| Device | Status | Board |
|--------|-----------|-----------|
| Tinker RK3288 | most likely possible | Not available yet |
| Tinker S RK3288 | most likely possible | Not available yet |
### Intel NUC
| Device | Status | Board |
|--------|-----------|-----------|
| Unknown | most likely possible | Not available yet |
### Seeedstudio
| Device | Status | Board |
|--------|-----------|-----------|
| ReSpeaker Core V2 | most likely possible | Not available yet |
| * | most likely possible | Not available yet |
<br><br>
Further ideas and discussion open at the issue tracker: #4

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

View File

@ -1,6 +1,12 @@
# Kernel Version
Linux kernel version used for supported boards.<br>
Default kernel tree: 6.1 LTS
| Board | Version |
|-------|---------|
| Raspberry Pi (3&4) | 5.15.x |
| Raspberry Pi 3 | 6.1.47 |
| Raspberry Pi 4 | 6.1.47 |
| Open Virtual Appliance | 6.1.47 |
| Generic x86-64 | 6.1.47 |

View File

@ -1,127 +0,0 @@
# Python 3.8
## Default installed Python libraries
The following Python libraries are installed when Mycroft has been fully booted and configured;
Package Version
------------------------ ---------
adapt-parser 0.3.4
appdirs 1.4.3
arrow 0.15.2
asn1crypto 1.2.0
astral 1.4
beautifulsoup4 4.8.1
bs4 0.0.1
cachetools 2.1.0
casttube 0.2.0
certifi 2019.9.11
cffi 1.13.1
chardet 3.0.4
Click 7.0
colorama 0.4.1
colorzero 1.1
configshell-fb 1.1.18
coverage 4.5.1
coveralls 1.5.1
cryptography 2.8
daemonize 2.5.0
ddg3 0.6.6
Deprecated 1.2.3
docopt 0.6.2
fann2 1.0.7
fasteners 0.14.1
feedparser 5.2.1
gitdb2 2.0.4
GitPython 2.1.11
google-api-python-client 1.6.4
google-auth 1.5.1
google-auth-httplib2 0.0.3
gpiozero 1.4.1
gTTS 2.0.4
gTTS-token 1.1.3
holidays 0.9.10
httplib2 0.14.0
humanhash3 0.0.6
idna 2.7
ifaddr 0.1.4
importlib-metadata 1.2.0
inflect 3.0.2
inflection 0.3.1
ipaddress 1.0.23
jaraco.itertools 4.4.2
lazy 1.4
lxml 4.4.1
monotonic 1.5
more-itertools 8.0.2
msk 0.3.14
msm 0.8.3
multi-key-dict 2.0.3
mycroft-core 19.8.4
netaddr 0.7.19
num2words 0.5.10
oauth2client 4.1.3
oauthlib 3.1.0
olefile 0.46
padaos 0.1.9
padatious 0.4.6
pako 0.2.3
pep8 1.7.0
petact 0.1.2
Pillow 6.2.1
pip 19.3.1
pocketsphinx 0.1.0
precise-runner 0.2.1
protobuf 3.9.1
psutil 5.2.1
pulsectl 17.7.4
py-mplayer 0.1
pyalsaaudio 0.8.2
pyasn1 0.4.7
pyasn1-modules 0.2.7
PyAudio 0.2.11
PyChromecast 3.2.2
pyCLI 2.0.3
pycparser 2.19
pycrypto 2.6.1
pyee 5.0.0
PyGithub 1.43.2
pyjokes 0.5.0
PyJWT 1.6.4
pyOpenSSL 19.1.0
pyowm 2.6.1
pyparsing 2.4.2
pyserial 3.0
python-dateutil 2.7.5
python-vlc 1.1.2
pytz 2017.2
pyusb 1.0.0
PyYAML 5.1.2
requests 2.20.0
requests-futures 0.9.5
rsa 4.0
setuptools 41.4.0
sgmllib3k 1.0.0
six 1.13.0
smmap2 2.0.4
soupsieve 1.9.4
source 1.2.0
SpeechRecognition 3.8.1
spidev 3.4
texttable 1.6.2
tornado 6.0.3
tzlocal 1.3
uritemplate 3.0.0
urllib3 1.24.2
urwid 2.0.1
uuid 1.30
websocket-client 0.54.0
wikipedia 1.4.0
wolframalpha 3.0
wrapt 1.11.2
xmlrunner 1.7.7
xmltodict 0.12.0
xxhash 1.2.0
zeroconf 0.23.0
zipp 0.6.0

View File

@ -1,150 +0,0 @@
---------------------------------------
**MycroftOS - Version 0.1.0 - alpha 8**
ChangeLog:
- ~~Ondemand governor for both RPI3 and 4 (instead of performance)~~ [DONE]
- ~~Fix: MPV not compiling because of missing LD stuff~~ [DONE]
- ~~Update to latest LTS kernel and drivers / firmwares~~ [DONE]
- ~~Update to latest LTS buildroot (20.02.1)~~ [DONE]
- ~~Update to latest Mycroft version and dependencies~~ [DONE]
- ~~Addition of additional packages for the near future~~ [DONE]
* ~~OpenCV~~ [DONE]
* ~~espeak~~ [DONE]
* ~~Python-Numpy~~ [DONE]
* ~~Motion~~ [DONE]
* ~~Mosquitto~~ [DONE]
* ~~Squeezelite~~ [DONE]
- ~~Add the last bits of the LAN-MAC address to the hostname~~ [DONE]
- ~~Update spotifyd to latest 0.2.24 version~~ [DONE]
- ~~Update snapcast to latest 0.19.0 version~~ [DONE]
- ~~Update respeaker driver to latest dev version.~~ [DONE]
- ~~More microphone support~~ [DONE]
* ~~PS3 Eye~~ [DONE]
- ~~Cleanup buildroot:~~ [DONE]
* ~~rootfs default overlay seperate~~ [DONE]
* ~~device specific overlays~~ [DONE]
- ~~Look into animating the boot splash screen, showing progress during boot~~ [DONE]
* ~~Add and implement psplash~~ [DONE]
* ~~Update all services to update psplash~~ [DONE]
- ~~Change the wording on the splash screens;~~ [DONE (Removed)]
* ~~Safe to reboot -> Safe to reboot / Rebootig now~~ [DONE (Removed)]
* ~~Safe to poweroff -> Safe to poweroff / Powering off~~ [DONE (Removed)]
- ~~Make use of systemd preset files (/usr/lib/systemd/system-preset/<prio>-<name>.preset)~~ [DONE]
* ~~wpa_supplicant@wlan0.service~~ [DONE]
* ~~wpa_supplicant@ap0.service~~ [DONE]
* ~~Enable any other mycroftos services that needs to be enabled by default~~ [DONE]
* ~~Remove all systemd (enabled) symlinks in the external packages~~ [DONE]
* ~~Disable any newly installed service by default. (/usr/lib/systemd/system-preset/99-default.preset)~~ [DONE]
* ~~wpa_supplicant systemd file can now be placed in rootfs-overlay / patch to be removed~~ [DONE]
- ~~Fix python-speechrecognition package. Do not copy flac binaries~~ [DONE]
TODO:
WiFi:
- WiFi does not come to life after setup with new 2020.02.1 version (found cause: see systemd preset task above)
- Add 5G support to the wifi system (Country setting most likely)
Enclosure:
- Implement initial framebuffer drawing GUI
* Look into showing the pairing code on the HDMI as well (look at mycroft's system)
* Look into showing the IP address on the HDMI as well (look at mycroft's system)
* Look into combining the wifi code, the framebuffer code and the enclosure code into one system.
- Move over / Integrated the WiFi setup into the Enclosure code.
* Change WifiSetup splash; MycroftOS-Setup -> MycroftOS-WiFiSetup
* Have a look at the wifi scan to exclude non real SSID (“ID List”)
* Figure out how to make the wifi password box to be able to show password (eye icon)
- Enclosure code for enabling services, halt, reboot, etc
- Enclosure code for pulseaudio control (volume mostly)
System:
- Systemd notify and Watchdog support to make starting/stopping/restarting and failures way more robust. [WIP]
- Enable (hardware) watchdog support.
- Include changing the hostname from the MycroftOS settings skill without messing up above MAC addition.
- Look into the msm error/warning "no package manager found" (there is none, but just handle the warning)
- Included volume skill can't be updated
* Should be changed to pulseaudio anyway, but...
* Check if the included volume-skill can be updated, via offical git commits
- Avahi zero config publish to be set up (pulseaudio, mpd, snapcast, etc.)
- MycroftOS settings skill to be able to setup smart speaker services / software
- VLC Framebuffer video playing support (if not accelerated, check omxplayer but needs to be created as audio backend within mycroft)
- Add and make configurable, where sound output has to go;
* BT Speaker (A2DP) normal (Use a bluetooth speaker as output)
* Bluetooth mic/speaker combo support using HSP (use headsets as input/output for Mycroft)
* Airplay (example: SONOS) using module-raop-discover and module-raop-sink of PulseAudio
* Autoconnect trusted BT devices as soon as it sees them using: module-switch-on-connect from PulseAudio
Documentation:
- Change README with all new changes [WIP]
- Update / Complete "documentation" folder and docs
* Building.md
* Boards.md
* Kernel.md
* Python-packages.md
- Instructions / Wiki for most common and different aspects and functions;
* Installation
* First run
* Configuration
- Smart speaker functions
- System Services
* Spotify setup
* Squeezelite setup
* Snapcast Client/Server setup
* Bluetooth speaker output setup
* Airplay speaker output setup
Cleanup & Maintenance:
- Fix / Check all Buildroot package dependencies (SELECT and DEPENDS references within Config.in)
- Cleanup buildroot config file
* remove / disable any unused packages that might have slipped in while testing / debugging / etc.
- Make sure all Skills from the market can install (python dependencies either available or pre-installed)
---------------------------------------
**MycroftOS - Version 1.0.0**
TODO:
- Add an first initial GUI system just as Mycroft.ai (QT5)
- Cleanup the kernel config
* Remove unused drivers and stuff (DVB and such)
* Separate default config into systeemwide .config
* Board specific configs as overlays
- Implement easy (OTA) update system (RAUC or SWUpdate, not sure yet)
- Support for more devices / boards
* OVA (Virtual system - Virtualbox)
---------------------------------------
**MycroftOS - Version 1.1.0**
- Build precise from source at build time (0.3.0 dev version)
* create buildroot packages for all dependencies.
* create buildroot package for precise-engine & runner
* create buildroot package for wake word modules (including the commodity ones)
* figure out how to give back to the communicty by allowing recording of wake words easily
- Support for more devices / boards
* Rockchip boards
* ReSpeaker Pro V2
* Odroid
* X86 / 64
* etc. / ideas
- Implement first initial WEB frontend/backend system for configuration and all
* Backend for settings, configuration and update
* Backend pulseaudio control (Already available project as quick fix, but needs to integrate with MycroftOS system)
* Frontend for possibly accelerated browser hooking into the Mycroft GUI
- 64bit support for RPI3 ~~and RPI4~~ [WIP]
- More hardware/microphone support
* Google-AIY
* Kinect-360
- ReSpeaker Mycroft LED pattern which is blue-isch and looks like the logo of Mycroft