Comments (2)
@bettse I'm starting to run into code size limits as well, while working on adding unauthenticated security.(this is a fairly ambitious Arduino library).
I wasn't planning to add OTP, but it should be pretty straight forward, the diff is pretty much
- 0x06,0x06,0xf0,0x00,0x03,0x15,0x39,\
+ 0x06,0x06,0xf0,0x00,0x83,0x84,0xb1,\
So in nRF8001.cpp
- send CRC:
data.buffer[4] = 0x03;
needs to be changed to:
data.buffer[4] = 0x83;
The other change is not to send run/calculate setup messages, but still calculate the pipe numbers.
We'll need to experiment if splitting the setup message part to a new method and not calling in in OTP mode will actually result in code savings.
Also, this is pretty dangerous for the average Arduino user, if you get it wrong, you can't change the OTP (you can still send memory resident setup data on power up). We'll have to provide some action the user needs to take, for example Nordic's generated services_lock.h requires you to remove a #error
.
I'm leaning towards looking into reduce code size another way first, maybe there is stuff in the utilities folder (imported from the Nordic nRF8001 SDK) that can be removed or reworked? Also, reworking other parts of the library, or pre-calculating all setup messages at build time ... thoughts?
from arduino-bleperipheral.
Yeah, certainly a dangerous thing that should require non-trivial confirmation by the developer to execute. If there are code savings that could be made without that, it seems like that would be the safer path.
Its nice to know that, if it comes to it, the changes for using the OTP are already known.
from arduino-bleperipheral.
Related Issues (20)
- Can't detect remote devices
- NRF5: CCCDs aren't persisted for bonded peers
- How to set service name ? HOT 1
- ANCS Implementation canWrite is false
- Speed / baudrate of the BLE connection?
- Numpad key codes, anyone?
- How to send more than 20bytes in each transaction with bleSerial.write()?
- Olimexino-nano + Olimexino-nano-ble freezes after begin()
- Why is my BLE Service not appearing after a successful flash? HOT 2
- [Question] Sending long string BLECharacteristic
- Abandoned project?
- nrf52840 HOT 4
- Freeze on blePeripheral.begin(); HOT 7
- BLE Scan
- softdevice_sys_evt_handler_set()
- RFDuino using BLEPerfipheralObserver to scan for iBeacons - Issue HOT 2
- Update iBeacon broadcast packet after starting
- Setting chip to idle state in between measurements
- nRF52832 Supported?
- UART Rx hangs after a few seconds when BLEPeripheral.begin(); is called on nRF51802
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arduino-bleperipheral.