Skip to content

Releases: microbit-foundation/micropython-microbit-v2

v2.1.2

30 Oct 09:52
Compare
Choose a tag to compare

The only change in this release is:

  • Update the neopixel module to increase compatibility with other ws2812 variants (#161)

v2.1.1

10 Nov 16:22
8aaa36b
Compare
Choose a tag to compare
  • Fix issue controlling pin 11 (#136)
  • Fix issue where stopping execution with Ctrl+C could continue executing code (#134)
  • Configure MicroPython with MICROPY_PY_BUILTINS_STR_UNICODE (unicode strings) and MICROPY_PY_BUILTINS_FROZENSET (frozenset) build flags to match V1 (#138)
  • Remove (unused, undocumented, and not working) support for None as a music tune rest (#139)
  • Fix audio and speech pin mode configuration when playing (#137)

Full Changelog: v2.1.0...v2.1.1

v2.1.0

26 Sep 21:15
e4321a8
Compare
Choose a tag to compare
  • microphone.sound_level() now uses a better SPL algorithm with better range detection (#122)
  • Setting the audio.SoundEffect constructor arguments and/or attributes to out of range values now throws an exception (#120, #129)
  • audio.SoundEffect.fx no longer returns None instead of 0 (the constant FX_NONE value) (#130)
  • Update microbit.scale() to set the output type depending on the to parameter type (#121)
  • Fix issue where power.deep_sleep() with a ms argument would block until the time elapsed when it was woken up via other wake up sources (#119, #128)
  • power.deep_sleep() parameter run_every updated to configure if microbit.run_every functions will continue to run while the board sleeps (#118)
    • Before the micro:bit would wake up at the next scheduled function event, and it was up to the user code to go back to sleep
    • Now it will automatically go back to sleep until the next scheduled event, or configured wake up source
  • Add UART as a wake up source from Deep Sleep (#127)
  • Fix issue where trying to go to Deep Sleep without wake up sources didn't work (#126)
  • Update CODAL from v0.2.42-hotfix.1 to v0.2.43 tag
    • Changes to codal-microbit-v2:
      • deepSleep() with no wake targets will now actually deep sleep.
      • Serial ports can now be used to wake the board from deep sleep.
      • New configuration flag MICROBIT_USB_SERIAL_WAKE can now be set to configure the board to wake on serial input.
    • Changes to codal-core:
      • Fixed spurious mic activation due to overlapping device IDs between CodalComponent and MicroBitCompat.

For a full list of commits since the last release: v2.1.0-beta.3...v2.1.0

v2.1.0-beta.3

16 Sep 12:50
Compare
Choose a tag to compare
  • Fix issue introduced in beta.2 playing SoundEffects (#124)
  • Update CODAL from v0.2.42 to v0.2.42-hotfix.1 with the fix for #124

For a full list of commits since the last release: v2.1.0-beta.2...v2.1.0-beta.3

v2.1.0-beta.2

15 Sep 13:25
Compare
Choose a tag to compare
  • SoundEffect() parameter wave renamed to waveform (bbcmicrobit/micropython#765)
  • Fix issue where power.deep_sleep() blocked until the time specified via argument elapsed (lancaster-university/codal-microbit-v2#221)
  • Update CODAL from v0.2.40 to v0.2.42 tag.
    • Fixed an off-by-one error in FiberLock whereby a semaphore-mode lock would have 1 slot fewer than expected [codal-core::feature/enhanced-lock]
    • Fixed an off-by-one error in the device pacic codes in MicroBitError, where all codes were one higher than needed (leaving code 50 empty) [codal-microbit-v2::bug/panic-code-offset]
    • Added a new deepSleep() call to support a kind of interruptable deep sleep mode, to better support the way Python sleeps [codal-microbit-v2::feature/interruptable-deep-sleep]
    • Minor patch to show --status without pagenation, for easier code status review
    • Improved sound level detection sensitivity to 35db from 52db, re-calibrated parameters for accuracy, and introduced optional 8 bit range sound level API
    • Merged a new NRF52LEDMatrix::rotateTo function (Thanks Martin!)

Known issues:

  • audio.SoundEffects and microbit.Sound have playback issues (#124)

For a full list of commits since the last release: v2.1.0-beta.1...v2.1.0-beta.2

v2.1.0-beta.1

30 Aug 18:54
8970afb
Compare
Choose a tag to compare

GitHub milestone: https://github.com/microbit-foundation/micropython-microbit-v2/milestone/4?closed=1

  • Add log module for data logging (bbcmicrobit/micropython#720)
  • Add audio.SoundEffect class to create custom sounds (#103, bbcmicrobit/micropython#753)
  • Add initial version of the power module for power management (#60, bbcmicrobit/micropython#754)
  • Add microbit.run_every function/decorator, to schedule functions at a set interval (bbcmicrobit/micropython#720)
  • Add microbit.scale() function to scale values between different ranges (#102, bbcmicrobit/micropython#762)
  • Add microbit.accelerometer.get_strength() method (#81)
  • Add microbit.accelerometer.set_range() method (bbcmicrobit/micropython#264)
  • Add microbit.Image.SCISSORS image (bbcmicrobit/micropython#602)
  • Allow value of 2 to be set for radio.config() data_rate parameter, to select the 250 Kbit rate for compatibility for V1 (#87)
  • Importing the radio module now turns on the radio automatically (#97)
  • A couple of sound differences with V1 fixed via CODAL update (#47, #67)
  • Fix shift_down(), shift_left(), shift_right(), shift_up(), methods from microbit.Image to retain the original image width/height (bbcmicrobit/micropython#718)
  • Fix issues where the first return value of microbit.microphone.current_event() could be None instead of the "quiet" sound event (#86)
  • Fix filesystem issue where it wouldn't sweep when there was just a few free chunks (#105)
  • Lock scheduler when starting audio pipeline to avoid scheduler starting a fetch at the same time (#47)
  • Update MicroPython from v1.6 to v1.18: micropython/micropython@1e2f0d2...v1.18
  • Update CODAL from v0.2.31 to v0.2.40 tag.
    • codal-microbit-v2:
      • stabilize I2C communications between NRF52 and KL27 DAPLINK chip when
        running on battery
      • improvements and optimizations to MicroBitLog
      • ensure mutual exclusion for all MicroBitLog APIs
      • introduce workaround for back-to-back I2C Flash transactions using KL27
        DAPLink firmware
      • move to runtime configuration of I2C DAPLink interface
      • update MicroBitLog serial mirroring to emit CRLF
      • option for Nordic Default UART characteristics
      • BLE: make Device Info Service Model Number String sensitive to board ID
      • fix typo in MicroBitLog units
      • increase resolution of SoundOutputPin playback; this reduces the period
        of generated sound from 50ms to 5ms, providing better approximation to
        micro:bit v1 PWM based behaviour
      • update to DAPLink I2C Protocol v2
      • implement fixed size journal and metadata regions
      • unify available off-chip flash
      • introduce delay following FLASH_ERASE request
      • remove verbose debug in source/MicroBitUSBFlashManager.cpp
      • align DAPLink v1/v2 workarounds
      • add MicroBitPowerManager::readInterfaceRequest()
      • change variable sampleRate to float to avoid rounding errors when
        generating frequencies
      • improve audio input pipeline for microphone support
      • add per-channel volume control methods
      • increase DAPLink I2C wait for data to be ready timeout
      • add missing end frequency parameter to the log generator function
      • add polyphonic real-time synthesizer
      • fix MicroBitBLEManager support for MicroBitPowerManager::deepSleep
      • add support for the BUSY flag on the KL27
      • add the DAPLink version to the data logging HTM page
      • add MicroBitLog::readData
    • codal-core:
      • optimize and fix logical error in inline ManagedString != method
      • remove sample endpointRequest() impl
      • don't crash when not initialized
      • add REAL_TIME_FUNC attribute
      • put REAL_TIME_FUNC on functions that disable IRQs or are used from ISRs
      • use new FORCE_RAM_FUNC attribute
      • shorten IRQ-disabled period in DMESG
      • fix warnings
      • mark more functions real-time
      • FORCE_RAM_FUNC now correctly uses .data.ramfuncs rather than plain .data,
        to work with newer gcc versions
    • codal-nrf52
      • introduce transaction timeout for NRF52I2C
      • add case for 31250 in switch(baudrate)
    • codal-microbit-nrf5sdk
      • no changes

For a full list of commits since the last release: v2.0.0...v2.1.0-beta.1

v2.0.0

30 Jun 19:56
Compare
Choose a tag to compare

GitHub milestone: https://github.com/microbit-foundation/micropython-microbit-v2/milestone/6?closed=1

  • Fixed issue where display.get_pixel() returned values in the range 0..255 instead of 0..9 (as V1) (#75)
  • Fixed issue playing Sound expressions in the background (#76)
  • Fixed issue grabbing pins when switching between different music/sound modes (#50)
  • Fixed issues with ADC measurements (#65, #66)
  • Fixed issue where UART pins were not redirected to the USB pins on a second call to uart.init() (#70)
  • Added Code of Conduct to the repository (#71)
  • Enable BLE partial flashing (#77)
  • Fixed internal name of microbit.speaker type to MicroBitSpeaker
  • Updated to the latest MicroPython on the 02/05/2021 (micropython/micropython@1e2f0d2)
  • Updated CODAL to v0.2.31
    • codal-microbit-v2:
      • mixer: add isSilent() and fire SOUND/SILENCE events
      • Introduction of persistent logging API
      • improvements to MicroBitLog
      • make private pin variable a pointer, to fix pins becoming other pins
      • deep sleep support
      • fix memory leak in MicroBitAudio::setSleep()/enable()
    • codal-core:
      • add default atomic operations for reference counted types
      • add events to CodalUSB
      • ifguard uf2_info in GhostFAT implementation
      • introduce framework for power efficient deep sleep
    • codal-nrf52:
      • USB for the nrf52 family
      • NRF52Serial - Avoid overwriting pin definitions during redirection
      • NRF52Serial::configurePins - wait for TX buffer to empty
      • NRF52ADC: Improvements to discrete sampling
      • NRF52I2C Workaround for missed SHORT trigger
      • update drivers to support deep sleep mode

v2.0.0-beta.5

16 Mar 11:42
Compare
Choose a tag to compare
v2.0.0-beta.5 Pre-release
Pre-release

Changelog:

  • Disable pin_speaker as a valid argument to play() pin argument in music/audio/speech (#63)
    • This pin can still use its own methods, like the PWM functionality
  • Improves buffering and flow control to the audio mixer (#47)
  • Updated CODAL to v0.2.25
    • Stability improvements with UART
    • Stability improvements with I2C
    • Improved accuracy of tone generation
    • Fixed timer resolution
    • Fixed issue in GPIO edge events
    • Added BLE Partial Flashing support for MicroPython
    • Fixed GPIO default pull mode to match V1

v2.0.0-beta.4

19 Feb 14:16
Compare
Choose a tag to compare
v2.0.0-beta.4 Pre-release
Pre-release

Changelog:

  • Added the antigravity, love, and this modules from v1
  • uart.read() doesn't trigger an OS error anymore if the buffer is empty (#45)
  • Fixed issue where the random number generator was not being seeded and producing the same sequence of random numbers (#53)
  • Fixed machine.time_pulse_us() (#26)
  • Fixed pin.set_analog_period() (#54)
  • Fixed issue where pin9 could not be used unless the display was disabled (#57)
  • The CODAL version used has not been updated

v2.0.0-beta.3

21 Dec 20:55
d6c01d0
Compare
Choose a tag to compare
v2.0.0-beta.3 Pre-release
Pre-release

Changelog:

  • Added pin.set_touch_mode() method (#14).
  • Updated the pin argument in audio/music/speech play function (#30).
  • The speaker enable/disable methods have been moved from pin_speaker.enable()/disable(), to speaker.on()/off()
  • Exceptions now show the line number on serial
  • microphone.is_event() now check the current event instead of the last in the internal list
  • Assembly decorator enabled
  • Fixes issue building with debian-packaged Arm GCC (#5)
  • Updated CODAL to v0.2.24
    • Fixes an issue with sequential PWM DMA writes that have a small delaybetween them, eg when driving Neopixels (#27).
    • Fixes issues with incorrect serial data on startup and when buffer overflows (#15, #35)
    • Fixes issue with 0-length i2c operations.