diff --git a/.github/workflows/bundle_webapp_and_release_v3.yml b/.github/workflows/bundle_webapp_and_release_v3.yml index 13bffe472..a64d6e288 100644 --- a/.github/workflows/bundle_webapp_and_release_v3.yml +++ b/.github/workflows/bundle_webapp_and_release_v3.yml @@ -101,7 +101,7 @@ jobs: tar -czvf ${{ steps.vars.outputs.webapp_bundle_name }} build - name: Artifact Upload - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: ${{ steps.vars.outputs.webapp_bundle_name }} path: ${{ steps.build-webapp.outputs.webapp-root-path }}/${{ steps.vars.outputs.webapp_bundle_name }} @@ -119,7 +119,7 @@ jobs: steps: - name: Artifact Download - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: ${{ needs.build.outputs.webapp_bundle_name }} diff --git a/.github/workflows/test_docker_debian_codename_sub_v3.yml b/.github/workflows/test_docker_debian_codename_sub_v3.yml index a9ec217dc..6deedb478 100644 --- a/.github/workflows/test_docker_debian_codename_sub_v3.yml +++ b/.github/workflows/test_docker_debian_codename_sub_v3.yml @@ -134,7 +134,7 @@ jobs: BASE_TEST_IMAGE=${{ steps.vars.outputs.image_tag_name_local_base }} - name: Artifact Upload Docker Image - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: ${{ steps.vars.outputs.image_file_name }} path: ${{ steps.vars.outputs.image_file_path }} @@ -159,7 +159,7 @@ jobs: uses: docker/setup-buildx-action@v3.0.0 - name: Artifact Download Docker Image - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: ${{ needs.build.outputs.image_file_name }} @@ -177,15 +177,15 @@ jobs: args: | ./${{ matrix.test_script }} - # cleanup after test execution - cleanup: - # run only if tests didn't fail: keep the artifact to make job reruns possible - if: ${{ !failure() }} - needs: [build, test] - runs-on: ${{ inputs.runs_on }} - - steps: - - name: Artifact Delete Docker Image - uses: geekyeggo/delete-artifact@v2 - with: - name: ${{ needs.build.outputs.image_file_name }} + ## cleanup after test execution + #cleanup: + # # run only if tests didn't fail: keep the artifact to make job reruns possible + # if: ${{ !failure() }} + # needs: [build, test] + # runs-on: ${{ inputs.runs_on }} + # + # steps: + # - name: Artifact Delete Docker Image + # uses: geekyeggo/delete-artifact@v4 + # with: + # name: ${{ needs.build.outputs.image_file_name }} diff --git a/documentation/builders/README.md b/documentation/builders/README.md index 6d9e67bff..ed08f5980 100644 --- a/documentation/builders/README.md +++ b/documentation/builders/README.md @@ -9,29 +9,31 @@ ## Features * Audio - * [Audio Output](./audio.md) - * [Bluetooth audio buttons](./bluetooth-audio-buttons.md) + * [Audio Output](./audio.md) + * [Bluetooth audio buttons](./bluetooth-audio-buttons.md) * [GPIO Recipes](./gpio.md) * [Card Database](./card-database.md) - * [RFID Cards synchronisation](./components/synchronisation/rfidcards.md) + * [RFID Cards synchronisation](./components/synchronisation/rfidcards.md) * [Auto Hotspot](./autohotspot.md) * File Management - * [Network share / Samba](./samba.md) + * [Network share / Samba](./samba.md) ## Hardware Components * [Power](./components/power/) - * [OnOff SHIM for safe power on/off](./components/power/onoff-shim.md) + * [OnOff SHIM for safe power on/off](./components/power/onoff-shim.md) + * [Battery Monitor based on a ADS1015](./components/power/batterymonitor.md) * [Soundcards](./components/soundcards/) - * [HiFiBerry Boards](./components/soundcards/hifiberry.md) + * [HiFiBerry Boards](./components/soundcards/hifiberry.md) * [RFID Readers](./../developers/rfid/README.md) ## Web Application * Music - * [Playlists, Livestreams and Podcasts](./webapp/playlists-livestreams-podcasts.md) + * [Playlists, Livestreams and Podcasts](./webapp/playlists-livestreams-podcasts.md) ## Advanced + * [Troubleshooting](./troubleshooting.md) * [Concepts](./concepts.md) * [System](./system.md) diff --git a/documentation/builders/components/power/batterymonitor.md b/documentation/builders/components/power/batterymonitor.md new file mode 100644 index 000000000..d57e14acb --- /dev/null +++ b/documentation/builders/components/power/batterymonitor.md @@ -0,0 +1,33 @@ +# Battery Monitor based on a ADS1015 + +> [!CAUTION] +> Lithium and other batteries are dangerous and must be treated with care. +> Rechargeable Lithium Ion batteries are potentially hazardous and can +> present a serious **FIRE HAZARD** if damaged, defective or improperly used. +> Do not use this circuit to a lithium ion battery without expertise and +> training in handling and use of batteries of this type. +> Use appropriate test equipment and safety protocols during development. +> There is no warranty, this may not work as expected or at all! + +The script in [src/jukebox/components/battery_monitor/batt_mon_i2c_ads1015/\_\_init\_\_.py](../../../../src/jukebox/components/battery_monitor/batt_mon_i2c_ads1015/__init__.py) is intended to read out the voltage of a single Cell LiIon Battery using a [CY-ADS1015 Board](https://www.adafruit.com/product/1083): + +```text + 3.3V + + + | + .----o----. + ___ | | SDA + .--------|___|---o----o---------o AIN0 o------ + | 2MΩ | | | | SCL + | .-. | | ADS1015 o------ + --- | | --- | | + Battery - 1.5MΩ| | ---100nF '----o----' + 2.9V-4.2V| '-' | | + | | | | + === === === === +``` + +> [!WARNING] +> +> * the circuit is constantly draining the battery! (leak current up to: 2.1µA) +> * the time between sample needs to be a minimum 1sec with this high impedance voltage divider don't use the continuous conversion method! diff --git a/documentation/developers/docstring/README.md b/documentation/developers/docstring/README.md index aa7cefecc..c48c34a41 100644 --- a/documentation/developers/docstring/README.md +++ b/documentation/developers/docstring/README.md @@ -104,6 +104,12 @@ * [pbox\_set\_state](#components.rfid.hardware.fake_reader_gui.gpioz_gui_addon.pbox_set_state) * [que\_set\_pbox](#components.rfid.hardware.fake_reader_gui.gpioz_gui_addon.que_set_pbox) * [create\_outputs](#components.rfid.hardware.fake_reader_gui.gpioz_gui_addon.create_outputs) +* [components.rfid.hardware.generic\_nfcpy.description](#components.rfid.hardware.generic_nfcpy.description) +* [components.rfid.hardware.generic\_nfcpy.generic\_nfcpy](#components.rfid.hardware.generic_nfcpy.generic_nfcpy) + * [ReaderClass](#components.rfid.hardware.generic_nfcpy.generic_nfcpy.ReaderClass) + * [cleanup](#components.rfid.hardware.generic_nfcpy.generic_nfcpy.ReaderClass.cleanup) + * [stop](#components.rfid.hardware.generic_nfcpy.generic_nfcpy.ReaderClass.stop) + * [read\_card](#components.rfid.hardware.generic_nfcpy.generic_nfcpy.ReaderClass.read_card) * [components.rfid.hardware.generic\_usb.description](#components.rfid.hardware.generic_usb.description) * [components.rfid.hardware.generic\_usb.generic\_usb](#components.rfid.hardware.generic_usb.generic_usb) * [components.rfid.hardware.rc522\_spi.description](#components.rfid.hardware.rc522_spi.description) @@ -1948,6 +1954,61 @@ Add all output devices to the GUI List of all added GUI objects + + +# components.rfid.hardware.generic\_nfcpy.description + +List of supported devices https://nfcpy.readthedocs.io/en/latest/overview.html + + + + +# components.rfid.hardware.generic\_nfcpy.generic\_nfcpy + + + +## ReaderClass Objects + +```python +class ReaderClass(ReaderBaseClass) +``` + +The reader class for nfcpy supported NFC card readers. + + + + +#### cleanup + +```python +def cleanup() +``` + +The cleanup function: free and release all resources used by this card reader (if any). + + + + +#### stop + +```python +def stop() +``` + +This function is called to tell the reader to exit its reading function. + + + + +#### read\_card + +```python +def read_card() -> str +``` + +Blocking or non-blocking function that waits for a new card to appear and return the card's UID as string + + # components.rfid.hardware.generic\_usb.description @@ -2659,7 +2720,7 @@ def stop_autohotspot() Stop auto hotspot functionality -Basically disabling the cronjob and running the script one last time manually +Stopping and disabling the timer and running the service one last time manually @@ -2671,9 +2732,9 @@ Basically disabling the cronjob and running the script one last time manually def start_autohotspot() ``` -start auto hotspot functionality +Start auto hotspot functionality -Basically enabling the cronjob and running the script one time manually +Enabling and starting the timer (timer will start the service) @@ -2966,35 +3027,7 @@ class battmon_ads1015(BatteryMonitorBase.BattmonBase) Battery Monitor based on a ADS1015 -> [!CAUTION] -> Lithium and other batteries are dangerous and must be treated with care. -> Rechargeable Lithium Ion batteries are potentially hazardous and can -> present a serious **FIRE HAZARD** if damaged, defective or improperly used. -> Do not use this circuit to a lithium ion battery without expertise and -> training in handling and use of batteries of this type. -> Use appropriate test equipment and safety protocols during development. -> There is no warranty, this may not work as expected or at all! - -This script is intended to read out the Voltage of a single Cell LiIon Battery using a CY-ADS1015 Board: - - 3.3V - + - | - .----o----. - ___ | | SDA - .--------|___|---o----o---------o AIN0 o------ - | 2MΩ | | | | SCL - | .-. | | ADS1015 o------ - --- | | --- | | - Battery - 1.5MΩ| | ---100nF '----o----' - 2.9V-4.2V| '-' | | - | | | | - === === === === - -Attention: -* the circuit is constantly draining the battery! (leak current up to: 2.1µA) -* the time between sample needs to be a minimum 1sec with this high impedance voltage divider - don't use the continuous conversion method! +See [Battery Monitor documentation](../../builders/components/power/batterymonitor.md) diff --git a/documentation/developers/rfid/mock_reader.md b/documentation/developers/rfid/mock_reader.md index 4d5a3ea36..d6cac8cd0 100644 --- a/documentation/developers/rfid/mock_reader.md +++ b/documentation/developers/rfid/mock_reader.md @@ -6,7 +6,7 @@ machine - probably in a Python virtual environment. **place-capable**: yes -If you [mock the GPIO pins](../../../src/jukebox/components/gpio/gpioz/README.rst#use-mock-pins), this GUI will show the GPIO devices. +If you [mock the GPIO pins](../../builders/gpio.md#use-mock-pins), this GUI will show the GPIO devices. ![image](mock_reader.png) diff --git a/src/jukebox/components/battery_monitor/batt_mon_i2c_ads1015/__init__.py b/src/jukebox/components/battery_monitor/batt_mon_i2c_ads1015/__init__.py index af193a37f..551759c14 100644 --- a/src/jukebox/components/battery_monitor/batt_mon_i2c_ads1015/__init__.py +++ b/src/jukebox/components/battery_monitor/batt_mon_i2c_ads1015/__init__.py @@ -37,36 +37,7 @@ class battmon_ads1015(BatteryMonitorBase.BattmonBase): """Battery Monitor based on a ADS1015 - > [!CAUTION] - > Lithium and other batteries are dangerous and must be treated with care. - > Rechargeable Lithium Ion batteries are potentially hazardous and can - > present a serious **FIRE HAZARD** if damaged, defective or improperly used. - > Do not use this circuit to a lithium ion battery without expertise and - > training in handling and use of batteries of this type. - > Use appropriate test equipment and safety protocols during development. - > There is no warranty, this may not work as expected or at all! - - This script is intended to read out the Voltage of a single Cell LiIon Battery using a CY-ADS1015 Board: - - 3.3V - + - | - .----o----. - ___ | | SDA - .--------|___|---o----o---------o AIN0 o------ - | 2MΩ | | | | SCL - | .-. | | ADS1015 o------ - --- | | --- | | - Battery - 1.5MΩ| | ---100nF '----o----' - 2.9V-4.2V| '-' | | - | | | | - === === === === - - Attention: - * the circuit is constantly draining the battery! (leak current up to: 2.1µA) - * the time between sample needs to be a minimum 1sec with this high impedance voltage divider - don't use the continuous conversion method! - + See [Battery Monitor documentation](../../builders/components/power/batterymonitor.md) """ def __init__(self, cfg): diff --git a/src/jukebox/components/controls/bluetooth_audio_buttons/README.rst b/src/jukebox/components/controls/bluetooth_audio_buttons/README.rst deleted file mode 100644 index 87a7eab2b..000000000 --- a/src/jukebox/components/controls/bluetooth_audio_buttons/README.rst +++ /dev/null @@ -1,55 +0,0 @@ -When a bluetooth sound device (headphone, speakers) connects -attempt to automatically listen to it's buttons (play, next, ...) - -The bluetooth input device name is matched automatically from the -bluetooth sound card device name. During boot up, it is uncertain if the bluetooth device connects first, -or the Jukebox service is ready first. Therefore, -after service initialization, already connected bluetooth sound devices are scanned and an attempt is made -to find their input buttons. - -.. note:: If the automatic matching fails, there currently is no - manual configuration option. Open an issue ticket if you have problems with the automatic matching. - -Button key codes are standardized and by default the buttons -play, pause, next song, previous song are recognized. Volume up/down is handled independently -from this module by PulseAudio and the bluetooth audio transmission protocol. - -The module needs to be enabled in the main configuration file with: - -.. code-block:: yaml - - bluetooth_audio_buttons: - enable: true - - -Custom key bindings ---------------------- - -You may change or extend the actions assigned to a button in the configuration. If the configuration contains -a block 'mapping', the default button-action mapping is *completely* replaced with the new mapping. The definitions for -each key looks like ``key-code: {rpc_command_definition}``. -The RPC command follows the regular RPC command rules as defined in :ref:`userguide/rpc_commands:RPC Commands`. - -.. code-block:: yaml - - bluetooth_audio_buttons: - enable: true - mapping: - # Play & pause both map to toggle which is also the usual behaviour of headsets - 200: - alias: toggle - 201: - alias: toggle - # Re-map next song button, to set defined output volume (for some fun) - 163: - package: volume - plugin: ctrl - method: set_volume - args: [18] - # Re-map prev song button to shutdown - 165: - alias: shutdown - - -Key codes can be found in the log files. Press the various buttons on your headset, while watching the -logs with e.g. ``tail -f shared/logs/app.log``. Look for entries like ``No callback registered for button ...``. diff --git a/src/jukebox/jukebox/version.py b/src/jukebox/jukebox/version.py index b97391207..a7f37c5e6 100644 --- a/src/jukebox/jukebox/version.py +++ b/src/jukebox/jukebox/version.py @@ -1,8 +1,8 @@ VERSION_MAJOR = 3 -VERSION_MINOR = 5 -VERSION_PATCH = 2 -VERSION_EXTRA = "" +VERSION_MINOR = 6 +VERSION_PATCH = 0 +VERSION_EXTRA = "alpha" # build a version string in compliance with the SemVer specification # https://semver.org/#semantic-versioning-specification-semver