Commit graph

42249 commits

Author SHA1 Message Date
Andrei Emeltchenko
b595f27c13 drivers/nble: Clean up nble headers
Change-Id: Iec078bf3cc4ee99a7df95a687272972b793844e6
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-15 14:52:31 +00:00
Andrei Emeltchenko
dfb5c2172b drivers/nble: Remove not used version_header struct
Change-Id: I72ff7bf785884bf20882af536d9fa2977e70d598
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-15 14:52:22 +00:00
Andrei Emeltchenko
805a126059 drivers/nble: gatt: Implement bt_gatt_discover()
Implement bt_gatt_discover() function.

Change-Id: I1662c650fc2c9c8058c4518c5f9920647f489d40
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-15 14:52:14 +00:00
Andrei Emeltchenko
9162e6aef0 drivers/nble: Use weak function definitions
Remove empty function declaration using weak autogenerated method.
This solves API to NBLE constantly changing problem.

Change-Id: I2ff90559dfbf78e9c34e602195d8a76ab9750a47
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-15 14:51:58 +00:00
Andrei Emeltchenko
d2dde33254 drivers/nble: Fix use of uninitialized data
Change-Id: I447614096180e5984b4b7a2494e0932fafe9c500
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-15 13:50:11 +00:00
Johan Hedberg
058d5b2266 drivers/nble: Kconfig: Add a note about ABI requirements
Change-Id: I2a5ff8b6944fd4022a02364bf75223af33b5cdd7
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-15 12:51:28 +00:00
Andrei Emeltchenko
3df0272a38 drivers/nble: Fix use of uninitialized status
Change-Id: Id14f33ca02717ba9a3d2c7e557672b32a139752d
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-15 12:43:59 +00:00
Szymon Janc
3e00c7ad0e tests: Simplify test_bluetooth configuration
Use common config for tests and use testcase.ini for defining micro
and nano kernel variants.

Change-Id: I47453cd49696dd496cc728cc1eb2eba9cf7f1c6c
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-02-15 12:57:57 +01:00
Mariusz Skamra
d768527930 Bluetooth: Add Environmental Sensing Service related UUID defs
This adds Environmental Sensing Service related UUID definitions.

Signed-off-by: Mariusz Skamra <mariusz.skamra@tieto.com>
Change-Id: Idd87139971fb3c992b7fb7e346ce2ea90553ad38
2016-02-15 11:53:13 +00:00
Johan Hedberg
acdee60fa5 drivers/nble: Export local address for bt_conn_get_info()
The bt_conn_get_info() API also needs the local address. For now
simply use an extern declaration to get access to the variable that
resides in gap.c.

Change-Id: I3ddb598785cfb6a5d07fc10621f6d20a610536be
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-15 11:27:56 +00:00
Johan Hedberg
f0315be577 drivers/nble: Track all connection parameters
The bt_conn_get_info() API requires that we track the role and the
various connection parameters.

Change-Id: I732eace1e45173f94962df3f11dbe5ad520a75cf
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-15 11:05:01 +00:00
Jukka Rissanen
44f990144b cc2520: Ignore received bogus packets silently
Instead of return 0 if there is an error, return
a value < 0 so that caller caller of cc2520_read()
can reject packet right away.

Change-Id: I99808db6aa692cf4415f630193d35e51d4bc3144
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
2016-02-15 10:55:24 +00:00
Andrei Emeltchenko
cde38ed754 drivers/nble: Fix passing uninitialized callback
Initialize callback to NULL.

Change-Id: I8c985fc656499f1885fbc58ddfd0f80acf2f18cf
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-15 10:25:37 +00:00
Tomasz Bursztyka
a47638cdda cc2520: Add debug prints in case of packet rejection
If current packet is being rejected, it will print some more cc2520
internal insights in debug mode.

Change-Id: If63225e7dd025fb239a7bac5638624accfcc7f4f
Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
2016-02-15 10:25:15 +00:00
Andrei Emeltchenko
123c6b8ba2 drivers/nble: Update headers following new 0215 fw release
These are mostly cosmetic changes, shall work with firmwares
niko-0214 and niko-0215.

Change-Id: Id39c6b9cee6e759f77a05259632e453492ffe498
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-15 09:57:39 +00:00
Szymon Janc
c5d2e76048 Bluetooth: Merge init_h5 into init test
There is no need to have spearate app for H5 testing as init test can
use multiple configuration targets.

Change-Id: I467b5939ae914e7c1ac22fdac24d8b0b6ed3f1cf
Signed-off-by: Szymon Janc <ext.szymon.janc@tieto.com>
2016-02-15 09:40:30 +01:00
Anas Nashif
bf0ec3b43b docs: fixed indentation in gerrit practices
Align code examples and other parts of the document.

Change-Id: I1f6eb9d5d22991f54e367ed248abfe0d49622cc5
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-02-14 18:40:35 -05:00
Anas Nashif
93f04f3e15 docs: fixed feature lists for quark_d2000_crb
Change-Id: I1512118189d215340306a34ef63795b960692bf0
2016-02-14 18:40:35 -05:00
Anas Nashif
47b9b4c838 docs: fixed lists and indent for arduino_due
Change-Id: I674bf1d0cab30a83dc28e186c05042c53095337e
2016-02-14 18:40:35 -05:00
Anas Nashif
0b5a8beeb5 docs: fixed lists and indent for galileo
Change-Id: Ia677871e02469f1d529d558310182221124508b7
2016-02-14 18:40:35 -05:00
Anas Nashif
1ab2d24c1a docs: Update information about tree structure
add boards, tests sub-directories to the tree.

Change-Id: I353fd4a4b2b23f7d3a7ca22d42b555ffb1b14ce5
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-02-14 18:40:35 -05:00
Dan Kalowsky
8b10ed80cd docs : arduino_101 : build steps are incorrect
The build steps as they are written imply that you will always need to
source the zephyr-env.sh file before flashing.  This is not the case.

Change-Id: I2cffd5ee4b190dee8304f1843727926c7467f5ed
Signed-off-by: Dan Kalowsky <daniel.kalowsky@intel.com>
2016-02-14 21:59:21 +00:00
Dan Kalowsky
1bf8859550 docs : arduino_101 : fix build command
The make command is broken

Change-Id: Ie7ac4d75941aad9efbbf9c40f9e6358c8b04f28f
Signed-off-by: Dan Kalowsky <daniel.kalowsky@intel.com>
2016-02-14 21:58:35 +00:00
Anas Nashif
8afd0c993f samples: move bluetooth shell/init to tests
Combine both nano and micro tests and cleanup whitelisting
for the testcases to include all buildable boards.

Change-Id: I28d41b82fb60d75d4b172d9dd3ac7e71480053b8
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-02-14 19:25:31 +00:00
Constanza Heath
4c8f28bb37 Updating TinyCrypt v2.0 documentation.
Change-Id: I53ffef8a799a41442c636509a67cca80bb375787
Signed-off-by: Constanza Heath <constanza.m.heath@intel.com>
2016-02-14 03:46:44 +00:00
Rodrigo Caballero
8a454e690a doc: Edit the UART driver APIs
Edit public API details for clarity, grammar, punctuation found
on file uart.h

Amost all elements in this driver are now documented.

Made consistent use of @retval to document return values.

Made all verbs in the brief descriptions imperative.

Change-Id: Ied3a80ea636855ba42b33877c0ac7ac66d42e458
Signed-off-by: Rodrigo Caballero <rodrigo.caballero.abraham@intel.com>
2016-02-12 17:20:46 -06:00
Anas Nashif
1b6140cc92 sanitychecks: update releas data after restructuring
We have moved tests around, update the files to get accurate footprint
changes per test case.

Change-Id: I563acef4665cb0ab6d3e7e01050a3a49f98b8b9d
Signed-off-by: Anas Nashif <anas.nashif@intel.com>
2016-02-12 22:41:46 +00:00
Ramesh Thomas
d230fc3653 adv_power:Power management hooks template app
A template app that defines the power management hooks and
enables the power management related CONFIG flags.  This
app will enable build testing of power management code inside
the CONFIG flags.

Change-Id: If26904f69333ff05a0711596218b51b828669de1
Signed-off-by: Ramesh Thomas <ramesh.thomas@intel.com>
2016-02-12 11:21:01 -08:00
Ramesh Thomas
3888735e0d adv_power:Advanced Power Management APIs
This is part of an ongoing development of power management
support in zephyr. This implementation builds upon an existing
hook interface and adds more enhancements. This was tested
with reference implementations on quark_d2000 and quark_se.

Change-Id: I28092b7ec90ce1f1cc661cf99ca88708910c8eb2
Signed-off-by: Ramesh Thomas <ramesh.thomas@intel.com>
2016-02-12 11:20:32 -08:00
Ramesh Thomas
72e248b11b adv_power:Rename PM functions according to coding convention
Renamed functions and labels used in power management code
according to coding convention.  Only doing this to relevant
functions and not touching functions that will be removed in
future patches.

The stack used during resume would be necessary so
renamed that too.

Change-Id: I2f09a349b0f0fd6520c11b4cd73f4c8e1a13f100
Signed-off-by: Ramesh Thomas <ramesh.thomas@intel.com>
2016-02-12 10:57:51 -08:00
Ramesh Thomas
c1a2523445 adv_power:Fix build error when ADVANCED_IDLE flag is enabled
GlobalTss is not defined anywhere. This was originally designed
to be used by power management code to switch thread context to
kernel resume location. An alternative to this method would be
implemented.

Change-Id: I9ae14ba14f9573d8bd8579869cdee9cf85a5684a
Signed-off-by: Ramesh Thomas <ramesh.thomas@intel.com>
2016-02-12 10:57:51 -08:00
Andrei Emeltchenko
0270fe43a5 drivers/nble: Change RPC following firmware update
Due to firmware update of NBLE starting from 02/12 revisions onwards
there is a need to sync RPC headers and functions.

Only to be used with above mentioned NBLE firmware!

Change-Id: Ifc2ce28f81e819bb517ef3891610d78089a00428
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-12 16:57:56 +00:00
Andrei Emeltchenko
d650bc298e Bluetooth: Add missing print format specifier
Change-Id: Ia4a3e70a990da69bc5be22f693081f0dd6b6a5e1
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-12 16:57:30 +00:00
Dan Kalowsky
5094d8b797 docs : arduino 101 doc update
Some remnants of earlier versions of the document are still visible in
the current version.

Change-Id: Id6d91d4e87dac641e1f1fe2c3e8200ebfb44a888
2016-02-12 16:44:50 +00:00
Dan Kalowsky
11b88eb1f1 docs : arduino_101 rom needs to be in correct location
Correcting the steps for running the loading of the ROM image.

Change-Id: Icdcfe1c5ffb28ba09b5d12ba0cf39ac25d3d166f
Signed-off-by: Dan Kalowsky <daniel.kalowsky@intel.com>
2016-02-12 16:43:47 +00:00
Johan Hedberg
f15b3fbf6a drivers/nble: Take advantage of the new net_buf_pull_u8() helper
Change-Id: Ia1c90c178b385b5bdb2e60a597810aa296c4da3e
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-12 16:25:47 +00:00
Andrei Emeltchenko
6e9de099d5 Bluetooth: Fix checking wrong variable
Check server instead of psm after lookup.

Change-Id: I80fe916432b69b376f04083980f1208aa7befbb1
Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
2016-02-12 16:25:20 +00:00
Johan Hedberg
1bc6597d4d Bluetooth: Take advantage of the new net_buf_pull_u8() helper
Change-Id: I41ac2bc721b916f6d939f23be293750a83d21523
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-12 16:03:43 +00:00
Dan Kalowsky
50d24833b0 correcting issues identified by coverity
Change-Id: I0bec297b2db36ddd70d754c90ab8396e0890d2ca
Signed-off-by: Dan Kalowsky <daniel.kalowsky@intel.com>
2016-02-12 15:48:48 +00:00
Jukka Rissanen
36605e6182 net: apps: Make sure CoAP server works with IPv6 ND
Fixed the IPv6 address handling so that CoAP server works
with default settings when IPv6 neighbor discovery is enabled.

Change-Id: Idd0b0df61aaebed43a9c5a408a192add445cacfe
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
2016-02-12 15:36:55 +00:00
Johan Hedberg
c3ba08c552 drivers/nble: Add proper boundary checks for function tables
We should just discard the data if the received table index goes
beyond the actual table size.

Change-Id: I267621f098e349abab5a1f37f485a28448a9396b
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-12 17:10:42 +02:00
Johan Hedberg
ed8c6b361f drivers/nble: Convert RPC deserialization to use net_buf
The data is in a net_buf already so we can just pass this to the
deserialization code. The net_buf context and API helps simplify the
code quite a lot.

Change-Id: Iecb62d3151d229a09538ad652508f1eb9c6c3ffc
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-12 17:10:42 +02:00
Johan Hedberg
9d6aaa1cc7 net: buf: Add net_buf_pull_u8() helper API
A helper for the (fairly common) task of decoding individual 8-bit
values.

Change-Id: Id7e97df152232d5dd9861cf1e107877f1b8febaa
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-12 15:10:20 +00:00
Jukka Rissanen
5c72abe769 net: apps: Make CoAP server to accept different bearer config
User can now say "make BOARD=xxx NET_IFACE=802154" to compile
IEEE 802.15.4 support into the CoAP server application.
The default is to compile for qemu and use slip.

Change-Id: I2c61ac91d4ae7b2c3611567646028bc751e0419e
Signed-off-by: Jukka Rissanen <jukka.rissanen@linux.intel.com>
2016-02-12 15:27:44 +02:00
Johan Hedberg
984c7a6945 Bluetooth: Kconfig: Introduce BLUETOOTH_RX_STACK_SIZE
Applications may want to fine-tune the stack size of the fiber that's
used to make callbacks into the application.

Change-Id: I2cd3e79283fe85359389528e84d9bcc21e3e19f6
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-12 13:01:13 +02:00
Johan Hedberg
24730069ab drivers/nble: Make UART reading more robust
Don't require being able to read the full header in a single ISR call.
Instead track the number of received header bytes. Also check for IPC
length before allocating buffer to avoid unnecessary buffer
allocations.

Change-Id: I1678c3ac3aaf35a1b9bbe930cc2e942fce3f458a
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-12 11:01:04 +00:00
Ravi kumar Veeramally
d324f357ee cc2520: Fix debug prints format specifiers
Change-Id: I5d9f0629cf801022c21438e4ecc673387aceacee
Signed-off-by: Ravi kumar Veeramally <ravikumar.veeramally@linux.intel.com>
2016-02-12 10:57:37 +00:00
Johan Hedberg
1589a22650 Bluetooth: samples: Move init and shell to tests
The init, init_h5 and shell are not really samples but fit better in
the test category.

Change-Id: Id1a7ff31ad8767f858705bd952311cf64ff1f3f2
Signed-off-by: Johan Hedberg <johan.hedberg@intel.com>
2016-02-12 10:46:32 +02:00
Juan Manuel Cruz
8dad8eeffa build: changes order in which paths are added to $PATH
MinGW expects to have new program locations added to
the end of the PATH variable.

Change-Id: Ifd31b63c9ef39a7f2b416ffef39461290c822dd7
Signed-off-by: Juan Manuel Cruz <juan.m.cruz.alcaraz@intel.com>
Signed-off-by: Yonattan Louise <yonattan.a.louise.mendoza@intel.com>
2016-02-12 03:04:13 +00:00
Juan Manuel Cruz
99198e794a kconfig: adapt kconfig to work with mingw
MinGW have small conventions differences in the
call of some APIs. The following differences are
addressed:
- mkdir method parameters
- printf format for 64 bit integers
- utsname structure
- glob library

MinGW does not provide glob library.
This patch adapts the code to avoid this library when
building for MinGW on windows systems.
The new routines allow windows to support wildcards
(*, ?) on Kconfig paths.

zconf.lex.c_shipped is the file that the build system
compiles by default. If the user defines the
REGENERATE_PARSES environment variable for the build,
then zconf.lex.c_shipped is generated from the file
zconf.l. Both files are provided in the patch
to keep coherency with the REGENERATE_PARSES option.

Change-Id: I5b6ad24ead0521913ab6ea9da93551edcd2dc66b
Signed-off-by: Louise Mendoza <yonattan.a.louise.mendoza@intel.com>
Signed-off-by: Juan Manuel Cruz <juan.m.cruz.alcaraz@intel.com>
2016-02-12 03:04:13 +00:00