Private
Public Access
2
0
Commit Graph

243 Commits

Author SHA1 Message Date
Lay, Kuan Loon
0bd1ab2c53 iio: iio add get mounting matrix
Signed-off-by: Lay, Kuan Loon <kuan.loon.lay@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Lay, Kuan Loon
edb7f8a215 iio: iio consolidate read and write API
Signed-off-by: Lay, Kuan Loon <kuan.loon.lay@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Lay, Kuan Loon
7a55a1384a iio: added mraa_iio_write
Signed-off-by: Lay, Kuan Loon <kuan.loon.lay@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Brendan Le Foll
dc240913c7 iio: remove exec perms
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Lay, Kuan Loon
4c41d2c2df iio: added event api
Signed-off-by: Lay, Kuan Loon <kuan.loon.lay@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Alex Tereschenko
325ac461d6 iio: added function returning IIO device number by name
Closes #309.

Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Brendan Le Foll
acfb74f04e iio: Improve iio channel parsing to add enabled channels
scale and other attributes have to be read individually as they vary quite alot
depending on the channel. We only care/take data from scan_elements

Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Brendan Le Foll
2c97fd5953 iio: initial pass at getting channel information from scan_elements
This commit creates a new structure inside each _iio device when used and can
then be used to understand the data being read after a trigger is run/executed

Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Brendan Le Foll
d8c2c7c483 iio: Find attributes and channels in iio device
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Brendan Le Foll
d920d136ea iio: initial API and enumeration of devices
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Brendan Le Foll
0f312545e0 iio: Add initial module
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-15 10:42:06 +00:00
Srinivas Kandagatla
c0dfb71237 96boards: add support to 96boards (https://www.96boards.org/)
This patch adds support to 96boards. 96boards is an open platform
specification. This spec strandardizes the pins on the external
connectors like Low speed and High speed. Given these pins are standard
across multiple boards, I think adding a generic 96boards made sense to
me.

The idea behind adding this generic board file is to make mraa work on
most of the 96boards with minimal changes to board support in libmraa.

This patch adds support to the LS expansion connector which has got 12
gpio pins + 2 i2c + 1 spi and 2 uarts.

For now I have added Dragaon board DB401c support as part of this patch
and is tested.
More info about board @ https://www.96boards.org/products/ce/dragonboard410c/

Long term plan is to get all this configuration from the /sys and
populate the board specifics dynamically, which is bit easy with
96boards specs in-place.

Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-14 11:01:28 +00:00
Mihai Serban
759d387c5a edison: fix SPI IO pointers usage
Check if SPI IO pointers are holding valid data before using them.

Signed-off-by: Jianxun Zhang <jianxun.zhang@intel.com>
Signed-off-by: Bruce Beare <bruce.j.beare@intel.com>
Signed-off-by: Mihai Serban <mihai.serban@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-12-04 15:37:19 +00:00
Alex Tereschenko
24d4446193 gpio.h: Fixed a couple of typos in description
Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-10-02 13:40:49 +01:00
Mircea Bardac
31750be753 docs: Enabled samples in the Java documentation
Signed-off-by: Mircea Bardac <mircea.bardac@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-10-01 14:31:22 +01:00
Alex Tereschenko
b650a9fdc9 uart.hpp: Added missing include for types.hpp
Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-14 09:24:37 +01:00
Mihai Tudor Panu
f245cacd6f common.hpp: inlined getSubPlatformIndex to avoid multiple defs
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-12 08:31:52 +01:00
Petre Eftime
a0791f8277 gpio.hpp: remove unused args parameter from Java isr method
Signed-off-by: Petre Eftime <petre.p.eftime@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:54:43 +01:00
Petre Eftime
3934897864 mraa: Add types.hpp; Use types.hpp for C++ and SWIG
Signed-off-by: Petre Eftime <petre.p.eftime@intel.com>
Signed-off-by: Andrei Vasiliu <andrei.vasiliu@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:54:28 +01:00
Henry Bruce
3e76bee085 api: Added API calls that support both main and sub platforms
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:04 +01:00
Henry Bruce
b841d6c75c common.hpp: Removed platform selection methods.
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:04 +01:00
Henry Bruce
c03d746544 types.h: Added NULL platform
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:04 +01:00
Henry Bruce
5bd5f2d546 common.hpp: Added sub platform API calls.
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:04 +01:00
Henry Bruce
4031124081 api: Renamed some sub-platform API calls.
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:04 +01:00
Henry Bruce
33645791af api: Added mraa_has_sub_platform() function
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:03 +01:00
Henry Bruce
7058fea8bd mraa.c: Added mainn and sub-platform select API calls.
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:03 +01:00
Henry Bruce
13118e949b api: Added mraa_get_sub_platform_type()
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:03 +01:00
Henry Bruce
4a6bf832bc usb: Converted sub-platform bus/pin helper macros to functions.
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:03 +01:00
Henry Bruce
8f48df0533 usb: Skeleton platform code for FTDI FT4222 USB to i2c bridge
Signed-off-by: Henry Bruce <henry.bruce@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-08 14:42:03 +01:00
Brendan Le Foll
f95f2d8b35 nuc5: Add i2c support for intel 5th generation NUC
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-09-03 11:23:35 +01:00
Brendan Le Foll
37262fce93 common.hpp: add C++ bindings for i2c bus number functions
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-08-25 11:36:14 +01:00
Yong Li
02399b61f9 mraa.c: Add new API to support I2C bus number query
Add two new API to get the usable I2C bus count and related I2C adapter number

Signed-off-by: Yong Li <yong.b.li@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-08-25 11:36:14 +01:00
Brendan Le Foll
e481026227 examples/uart.c: Add a _read call to example
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-07-19 12:39:45 +01:00
Brendan Le Foll
f080a74497 gpio: all gpio enums prefixed with _mraa
Enum C types for gpio where not all prefixed with mraa correctly, now fixed

Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-07-01 10:59:03 +01:00
Brendan Le Foll
41d71e6ce2 i2c.h: Fix docs that incorectly states -1 is failure
Fixes #228

Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-20 20:41:44 +01:00
Brendan Le Foll
1c4be07aac i2c: fix return value doc for _read_bytes_data
Closes #218

Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-09 08:25:41 +01:00
Brendan Le Foll
91c56917c7 spi.hpp: fix wrong docstrings data -> txBuf
Closes #215

Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-02 14:28:37 +01:00
Brendan Le Foll
359cad0336 uart: Add c++ uart example
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-02 08:43:14 +01:00
Brendan Le Foll
e0ce5454bd uart: move string funcs to {read,write}Str
This commit adds raw binary read/write functions using the same typemaps as I2c
functions

Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-01 10:58:11 +01:00
Brendan Le Foll
40c52784ad spi.hpp: mraa_spi_write_buf_word cannot be used from SWIG bindings
In order for this to work we need to provide a typemap for it

Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-01 10:56:48 +01:00
Brendan Le Foll
236a8e9586 uart: make mraa_uart_get_dev_path return const char*
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-01 10:54:40 +01:00
Brendan Le Foll
347fd449f9 uart: Make C API use const where appropriate
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-01 09:36:00 +01:00
Brendan Le Foll
4628f3f2a0 uart.hpp: Use std::string constructor which lets use set a size parameter
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-01 09:32:44 +01:00
Brendan Le Foll
ea71308702 uart.hpp: trust c_str() instead of making copies
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-06-01 09:32:14 +01:00
Thomas Ingleby
fa57cee2e7 uart: update C++ API
Signed-off-by: Thomas Ingleby <thomas.c.ingleby@intel.com>
2015-05-28 23:31:12 +01:00
Thomas Ingleby
b982160ec5 uart: update C API
Signed-off-by: Thomas Ingleby <thomas.c.ingleby@intel.com>
2015-05-28 23:31:12 +01:00
Brendan Le Foll
19cad5cf24 uart: bunch of small changes to make C api work
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-05-28 23:31:11 +01:00
Thomas Ingleby
522a4feea1 uart: change hpp, use new names of functions
Signed-off-by: Thomas Ingleby <thomas.c.ingleby@intel.com>
2015-05-28 23:31:11 +01:00
Thomas Ingleby
4d86860e0c uart: remove un-needed includes from uart.h
No need for many included

Signed-off-by: Thomas Ingleby <thomas.c.ingleby@intel.com>
2015-05-28 23:31:11 +01:00
Brendan Le Foll
0a516ef3bf uart: make initial dump of uart module
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
2015-05-28 23:31:11 +01:00