Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - blieber

Pages: [1]
1
I wrote a FIFO-ish interface to make it easy to write to and read from flash memory on Simblee - https://github.com/blieber/arduino-flash-queue

2
Support / Re: Force 4 byte alignment
« on: April 13, 2017, 02:06:45 PM »
Using __attribute__((packed)) seems to work as suggested here https://forum.arduino.cc/index.php?topic=78026.0

3
Support / Force 4 byte alignment
« on: April 13, 2017, 01:47:42 PM »
It seems the default Simblee compiler (under tools in install package - arm-none-eabi-g++, mac OSX, Simblee board version 1.1.0) is 8-byte aligned. Is there a way to force 4-byte alignment instead (e.g. such as "-m32" flag). This would be convenient for memory compaction purposes.

Thanks,
Ben

4
Simblee Libraries / Unexplained power draw floating UART Simblee
« on: March 22, 2017, 01:04:55 PM »
Trying to debug a custom board with Simblee, noticed strange symptoms where:
1. When UART is attached to 5V rails get expected ULP current draw of <10uA
2. When remove UART pins from rails to floating ULP current draw jumps up to ~120uA
3. If I've done analog write on any pin since setup this, ULP current draw is ~1mA

My board is actually running 3.3V -- my guess is somehow when UART pins pulled to 5V this disables some of hardware features in ULP (although these features seem to work normally otherwise... hmmm this maybe isn't the best theory).

Also tried:
-- Pulling pins to 0V or 3.3V
-- Serial.end()
-- Setting UART pins to explicit inputs/outputs
-- NRF_UART0->ENABLE = (UART_ENABLE_ENABLE_Disabled << UART_ENABLE_ENABLE_Pos)
None of these seemed to reduce/remove increased current draw when UART pins are removed from rails

5
BLE and Low Level Development / Simblee BLE Battery Service
« on: November 23, 2016, 03:23:03 PM »
Does Simblee expose a way to configure the BLE Batter Service? I.e. https://www.bluetooth.com/specifications/gatt/viewer?attributeXmlFile=org.bluetooth.service.battery_service.xml

If not, is this feature planned at all in the near future?

6
Simblee Libraries / Re: Avoid DFU mode entry at start of sketch
« on: November 09, 2016, 11:48:13 PM »
Got DFU working without calling ota_bootloader_start() in sketch, see http://forum.rfduino.com/index.php?topic=1559.msg5698#msg5698, happy to help troubleshoot if you're still running into issues here.

7
iOS / Re: Simble OTA iOS app
« on: November 09, 2016, 11:33:58 PM »
Was able to get OTA working, here are the details involved in case may be helpful to folks in the future:

0. Following this approach you don't actually need to call "ota_bootloader_start()" from the Simblee firmware. What you need is to include "OTA_Bootloader.h” in your sketch (then you can force DFU)

1. From the iOS side you can use the most up to date Nordic iOS DFU Swift 3 library
  • Best way to get usage patterns is to go through the example project. Basically you need to supply the library with the central manager, peripheral, image file and declare a few configuration parameters.

2a. Build Arduino sketch to get a hex file. I bet there are more sophisticated ways to do this, but so far just been copying the output produced from building via Arduino IDE https://forum.arduino.cc/index.php?topic=131655.0

2b. The Nordic DFU specification requires some init packet along with the application payload (e.g. read this). The easiest way have seen is to do this is to use nrfutil to make a zip image from the hex file. The following worked for me (copied from here
Code: [Select]
nrfutil dfu genpkg $1.zip --application $1.hex --application-version 0xffff --dev-revision 0xffff --dev-type 0xffff --sd-req 0xfffe

2c. Getting the right package for nrfutil threw me off a bit. Simblee uses the Nordic legacy DFU mode.The most up to date nrfutil package won’t work, but a legacy compatible package is available (currently it’s 0.5.2).

8
Simblee Libraries / Avoid DFU mode entry at start of sketch
« on: October 29, 2016, 06:26:34 PM »
Just by including this header - #include <OTA_Bootloader.h> - it seems that the Simblee enters DFU mode before hitting setup. Is this by design or is this a way to disable this? The contract I want instead is to enter DFU only when prompted from an external input.

9
iOS / Simble OTA iOS app
« on: October 26, 2016, 08:48:44 PM »
Want an easy way to be able to update Simblee OTA from within an iOS app. The idea would be that whenever want to rev Simblee firmware, would just push a new version of the app which would then update the Simblee the next time it would be run. Is there an existing API to do this? Ideally would be something like
1. Search for peripheral of interest
2. Update Simblee, given peripheral and binary file to flash OTA

Otherwise it seems like the best option is to adapt the code under ~/Library/Arduino15/packages/Simblee/hardware/Simblee/1.1.0/iPhoneApps

Thanks,
Ben

Pages: [1]