Commit graph

105 commits

Author SHA1 Message Date
Joe Finney
424b825185 Merge branch 'master' into simplified-eventing
Conflicts:
	inc/MicroBitMessageBus.h
2015-10-18 18:20:03 +01:00
Joe Finney
7fb3fc02c4 version v1.2.3 2015-10-18 17:59:26 +01:00
Joe Finney
e3f0c7d6e5 Merge branch 'ble-profile' 2015-10-18 17:57:47 +01:00
Joe Finney
80f79f7faf Merge branch 'master' into ble-profile
Conflicts:
	source/CMakeLists.txt
	source/MicroBit.cpp
	source/MicroBitFiber.cpp
	source/MicroBitMessageBus.cpp
	source/MicroBitSuperMain.cpp
2015-10-18 17:54:37 +01:00
Joe Finney
464cf6cb51 Merge branch 'ble-profile' of https://github.com/lancaster-university/microbit-dal into ble-profile 2015-10-18 14:55:17 +01:00
Joe Finney
db3eccf6ff microbit: Final updates to BLE profile
Minor changes to BLE profile services (cleanup prior to merge with master branch):

  - Added temperature period characteristic to match design pattern of other sensors.
  - Updated endinaness of MicroBitLEDService Matrix to be more intuitive.
  - Cleaned up Microbit.cpp by removing unused reference to BLE services.
  - Exposed serial number and naming information thr BLE DeviceInformation and API.
  - Updated BLE advertisement period to be alightly more repsonsive (200ms vs 1000ms).
  - BUGFIX: micro:bit name is now always generated, regardless of BLE services.
  - BUGFIX: Scroll Period data length.
2015-10-18 14:46:42 +01:00
Joe Finney
aca544677e microbit: Updates to enable queing of display animation calls
Updates to change the behaviour of the scroll/print/animate faily of function away
from being pre-emtive and instead prroviding queing behaviour.

Minor updates to provide complete sets of async equivalent operations

Updates to the scheduler to provide wait/notify/waitone semantics.
2015-10-17 20:35:16 +01:00
bluetooth-mdw
4fd6052720 Changed LED Matrix State representation (1 octet per LED row) and added Temperature Period characteristic. 2015-10-17 19:27:04 +01:00
Joe Finney
85b2b1e09e version v1.2.2 2015-10-14 09:43:57 +01:00
Joe Finney
ac5685acb2 Merge branch 'dpgeorge-matrix-point-optimisation' 2015-10-14 09:41:52 +01:00
Joe Finney
068822ff12 Merge branch 'matrix-point-optimisation' of https://github.com/dpgeorge/microbit-dal into dpgeorge-matrix-point-optimisation 2015-10-14 09:38:13 +01:00
bluetooth-mdw
c1acdfdb5b Final tweaks after successful profile testing 2015-10-11 08:48:18 +01:00
Joe Finney
2011886e64 microbot: Cleanup of #ifdef in MicroBitHeapAllocator
Removed compiler warning if MICROBIT_HEAP_REUSE_SD is not defined.
2015-10-09 16:58:10 +01:00
bluetooth-mdw
8ef6dba587 Removed redundant issue tracker file. Now using github Issues to track... issues. 2015-10-09 14:45:53 +01:00
bluetooth-mdw
9cdd69b937 Merge branch 'ble-profile' of https://github.com/lancaster-university/microbit-dal into ble-profile 2015-10-09 13:37:08 +01:00
bluetooth-mdw
e838ef1075 Updated with latest position wrt testing 2015-10-09 13:36:42 +01:00
Joe Finney
6764c732ea microbit: BUGFIX to MicroBtDFU Service
- Updates to UI handling to avoid starving out the processor.
  - Clears screen before entering DFU bootloader
2015-10-09 01:14:36 +01:00
Joe Finney
122d885ee8 microbit: Updated Bluetooth device name from MicroBit to micro:bit to match brand guidelines 2015-10-09 00:03:01 +01:00
Joe Finney
ce2cc57bf1 microbit: Optimisation of internal Message Bus listeners
All message bus listeners with the micro:bit runtie are non blocking, and safe to be called
in an interrupt context. As such, these have now all been declared MESSAGE_BUS_LISTENER_IMMEDIATE
which should mitigate all unbounded event queueing effects.
2015-10-08 23:49:14 +01:00
Joe Finney
d4b4f70cb2 Merge branch 'ble-profile' of https://github.com/lancaster-university/microbit-dal into ble-profile 2015-10-08 23:25:34 +01:00
Joe Finney
1d76def8fa microbit: BLE service bugfixes
Updates to BLE interface to match specification following testing by Bluetooth SIG.

Accelerometer Period: now supports READ and WRITE
Magnetometer Period: now supports READ and WRITE
LED Matrix State: now supports READ and WRITE.

UUIDs of Temperature Service characteristic corrected.
2015-10-08 23:23:00 +01:00
Joe Finney
85a26dc8e1 microbit: Updates to enable semantic versioning of the micro:bit runtime DAL
More specifically, the build system now uses the semantic versioning meta-data
held in module.json to define a major.minor.patch version. Additionally, is the branch
being compiled is *not* the master branch, the version is appended with <branchname><githash>.

Specific updates:

- Updates to CMake files to expose this to the micro:bit runtime code.
- Addition of uBit.systemVersion() to expose this to application code.
- Displaying of version string over serial if MICROBIT_DBG is enabled.
- Distribution of version string over BLE via the firmware revision characteristic.
2015-10-08 14:37:35 +01:00
bluetooth-mdw
e79903e464 Tweaked following failed test 2015-10-06 10:26:21 +01:00
bluetooth-mdw
6d9e64fbc6 Minor tweaks to resolve failed tests 2015-10-05 21:08:45 +01:00
bluetooth-mdw
3bb76f6089 Changed event service UUIDs to match code 2015-10-04 16:45:36 +01:00
bluetooth-mdw
9a415f62cb Device Information Service characteristics had wrong UUID (BDS issue) 2015-10-04 16:09:47 +01:00
bluetooth-mdw
a0bcf7912f UUID for Generic Access Service was incorrect (BDS issue). Corrected. 2015-10-04 15:56:04 +01:00
Joe Finney
2230e39340 microbit: BUGFIX: #1291 ManagedString(INT_MIN) does not work properly
Corner case error in serialization code for INT_MIN only - corrected.
2015-09-29 23:51:20 +01:00
bluetooth-mdw
7459213d10 Merge branch 'ble-profile' of https://github.com/lancaster-university/microbit-dal into ble-profile 2015-09-29 11:14:18 +01:00
bluetooth-mdw
3f4a7cf5f1 Removed redundant HTML files 2015-09-29 11:13:59 +01:00
bluetooth-mdw
393cb25bc0 Updated Profile Design section 2015-09-29 11:12:37 +01:00
Joe Finney
5da263db81 Merge branch 'ble-profile' of https://github.com/lancaster-university/microbit-dal into ble-profile 2015-09-28 21:58:37 +01:00
Joe Finney
18236810a3 microbit: BLE Profile Beta 1
First functionally complete BLE profile, matching BLE speicfication v1.6.
More specifically, the following services are now functional:

  - AccelerometerService
  - MeganetometerService
  - EventService
  - TemperatureServide
  - IOPinService
  - DFUService
  - ButtonService
  - LEDService

Also, updates to underlying device drivers to enable greater configurability:

  - MicroBitCompass now supports variable sample rates and temperature sensing
  - MicroBitAccelerometer now supports variable sample rates and ranges
  - MicroBitThermometer introduced
  - MicroBitMessageBus adapted to permit enumeration and block removal of listeners

Finally, MicroBit DFU Service has been changed to the new UUIDs specificed in v1.6 of BLE spec.
2015-09-28 21:40:44 +01:00
Damien George
0dcb6834ec microbit: Use default constructor for MatrixPoint so data is ROMable.
Previous to this patch an explicit constructor was provided for creating
MatrixPoint instances, which meant that such objects could not be put in
ROM (since they needed to be constructed at runtime).

By using the defualt construction method for structs the MatrixPoint map
is now compiled into the rodata section, hence freeing up RAM.

Saves: 4 bytes data, 56 bytes bss, 148 bytes code.
2015-09-25 21:19:10 +01:00
bluetooth-mdw
5b54d1d3c1 Reports now include Summary and Abstract fields from Bluetooth Developer Studio 2015-09-25 11:14:01 +01:00
Joe Finney
4314b68643 microbit: First implementation of Temperature Service 2015-09-23 22:15:44 +01:00
Joe Finney
b00fc85548 Merge branch 'ble-profile' of https://github.com/lancaster-university/microbit-dal into ble-profile 2015-09-22 16:14:42 +01:00
Joe Finney
eb5ed28f74 microbit: First cut at MicroBitButtonService and microBitIOPinService
Strictly still development - untested code.
2015-09-22 16:13:08 +01:00
bluetooth-mdw
dcd03cb4e2 A range of changes motivated mostly by optimisation opportunities and implementation issues. 2015-09-22 15:07:12 +01:00
Joe Finney
ef613e9d86 microbit: Added BLE Magnetometer service compilation, initialization and configuration options 2015-09-19 22:19:57 +01:00
Joe Finney
3cfc7ec6e7 microbit: Ammendments to ensure fiber is never pages out due to eventing and minor cleanups
- renamed fiber flag to be more general.
- renamed idle to idleFiber to be consistent with the rest of the code.
- factored content of idle() into a funciton to avoid dupication.
- added test case to MessageBus::process() to avoid forking fibers if not requested.
- removed fiber_allow_run_idle_within mutator in favour of exposing currentFiber, as a more general solution.
2015-09-19 21:44:58 +01:00
Joe Finney
1e71169550 microbit: First draft of Magnetometer BLE service 2015-09-19 21:03:36 +01:00
Joe Finney
ae0e5611c3 microbit: First draft of reconfigurable frequencies of MicroBitCompass 2015-09-19 21:00:38 +01:00
Damien George
9ccdd25e9f microbit: Allow to run the idle task within the current fiber's stack.
If there is only 1 main fiber (plus the idle fiber) then enabling this
new feature for the main fiber (using fiber_allow_run_idle_within())
will mean that no heap is needed to swap the stack out.
2015-09-19 11:45:45 +01:00
Joe Finney
2c9f63902c microbit: Message Bus updates to support URGENT events queue optimisations
Added new URGENT listener type, that ensures immediate, non queuing delivery of events.
Introduced two-pass algorithm into message bus. Only events with an event listener are now
queued at ingress - this reduces unecessary memory usage for 'uninteresting' events.
2015-09-18 23:20:44 +01:00
Joe Finney
058f73ede1 microbit: Moved MicroBitDFUService UUIDs to match BLE profile specification 2015-09-18 18:48:27 +01:00
bluetooth-mdw
e2f6941728 Fixed file name typo 2015-09-18 13:51:25 +01:00
bluetooth-mdw
aa8e9176bd V1.5 of BLE profile 2015-09-18 08:56:58 +01:00
bluetooth-mdw
4524195f90 Allocated new UUIDs to DFU service and its characteristics to align with standard base UUID 2015-09-18 08:25:11 +01:00
bluetooth-mdw
44fcf4b04e Added suggestion regarding white listing and directed advertising 2015-09-18 07:01:27 +01:00