Brendan Le Foll
0aed0003ff
mraa.c: make mraa_get_platform_name use a const char
...
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2016-01-21 15:28:03 +00:00
Brendan Le Foll
0ebab9603e
Blink-IO.js: Call the function after declaring it
...
This works ok if executing the whole file but the node.js interactive
interpreter gets confused when yoy copy and paste the code
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2016-01-06 16:37:15 +00:00
Pieterjan Camerlynck
a87a104efe
CMakeLists.txt: do not require a C++ compiler
...
By default, CMake assumes both a C and C++ compiler are required.
This is not needed for mraa because it only provides C++ header
files. Note that if using SWIG you need one and if using node.js 3+ you'll need
a C++11 compiler
Signed-off-by: Pieterjan Camerlynck <pieterjan.camerlynck@gmail.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2016-01-06 10:42:40 +00:00
Henry Bruce
a708e08101
examples/mraa-i2c: Fixed physical bus id error in list command
...
Signed-off-by: Henry Bruce <henry.bruce@intel.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2016-01-06 10:38:51 +00:00
Brendan Le Foll
8862ebd9f2
mraa: Remove trailing whitespace/tabs from various parts
...
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-12-21 15:27:15 +00:00
Henry Bruce
8e4a809f12
iio: C API changes and C++ API enhancements
...
- C API read/write integer functions changed to int to match C types
- C API now has close function to release resources acquired during init
- iio internal type isr_event() function now has args param in signature
- C++ API now supports events with handler interface and new data structure
- C and C++ examples updated to use API changes
Signed-off-by: Henry Bruce <henry.bruce@intel.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-12-15 10:42:14 +00:00
Henry Bruce
3429b5383d
examples: Converted iio dummy driver test app to C++
...
Signed-off-by: Henry Bruce <henry.bruce@intel.com >
2015-12-15 10:42:06 +00:00
Henry Bruce
c1d081c783
examples: Extended iio_dummy_test to cover more cases.
...
Signed-off-by: Henry Bruce <henry.bruce@intel.com >
2015-12-15 10:42:06 +00:00
Henry Bruce
448f14f41c
examples: Added iio_dummy_test, a test app that uses iio_dummy driver
...
Signed-off-by: Henry Bruce <henry.bruce@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
078b6371d7
iio-example: printf take extra argument
...
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
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
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
b192e7a223
iio_driver.c: remove weird API calls
...
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
8c19105309
iio_driver.c: Add example for iio interface
...
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-12-15 10:42:06 +00:00
Alex Tereschenko
f9a31956ab
examples: added more elaborated Python UART example
...
Closes #376 .
Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-12-14 15:34:16 +00:00
Kevron Rees
c7a405a531
cmake: use cmake includedir
...
We need to use CMake variables to avoid installing things in the wrong places on
systems that have multilib enabled.
Signed-off-by: Kevron Rees <kevron.m.rees@intel.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-12-01 15:07:36 +00:00
Henry Bruce
6aaf48940e
examples: Fixed bug in mraa-gpio introduced by sub-platform update.
...
Signed-off-by: Henry Bruce <henry.bruce@intel.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-10-26 15:46:54 +00:00
xbolshe
dbd1a31536
uart.js: Rewrite of example to show more functionality
...
Signed-off-by: Eugene Bolshakov <pub@relvarsoft.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-10-09 14:38:27 +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
Petre Eftime
06e5e7dc11
Isr.java: Fix ISR example to use pin 6 and sleep properly
...
Signed-off-by: Petre Eftime <petre.p.eftime@intel.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-10-01 14:31:22 +01:00
Petre Eftime
42d169e003
samples.mapping.txt: Add samples mapping for java samples
...
Signed-off-by: Petre Eftime <petre.p.eftime@intel.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-10-01 14:31:09 +01:00
Petre Eftime
bda9f4d211
examples/java: Port examples containing [Interesting] tag from C/C++
...
Signed-off-by: Petre Eftime <petre.p.eftime@intel.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-10-01 14:31:01 +01:00
Petre Eftime
0e44dfac44
examples/java: Update, indent and add [Interesting] tags to examples
...
Signed-off-by: Petre Eftime <petre.p.eftime@intel.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-10-01 14:30:51 +01:00
Brendan Le Foll
08fe460772
Isr-pin6.cpp: Add example for c++ isr
...
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-09-29 14:23:39 +01:00
Brendan Le Foll
99b7f131d9
mraa-i2c.c: remove unused arguments to printf statements
...
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-09-08 15:09:28 +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
Brendan Le Foll
b2a0bbfcbc
hellomraa.c: Remove i2c calls
...
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-09-08 14:42:04 +01:00
Henry Bruce
2101e491ce
mraa-i2c: Updated to use new sub-platform API.
...
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
6284806b96
mraa-gpio: Support new sub-platform 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
b109a12dd1
mraa-i2c: Added interactive mode.
...
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
001e291d63
mraa-gpio: Added sub-platform support.
...
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
7ada55982d
platform_type: platform_type now in mraa_board_t
...
Now platform_type is no longer global it tracks with board instance
so that platform and sub-platform can report different types.
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
1c9b87bfd3
cmake: add FTDI FT4222 support
...
Existing FTDI D2xx support is just for serial comms library
but FT4222 needs a different library for i2c operation.
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
6dfe6ff6bc
examples: Created mraa-i2c tool for i2c layer testing.
...
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
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
Andrei Vasiliu
cb97f24edd
mraa-gpio.c: Solved issue with getchar() call on Galileo
...
There is a problem with missing symbols __fgetc_unlocked and __stdin in the
libc library build for Galileo. Solved this by replacing the getchar() call
with fscanf().
Signed-off-by: Andrei Vasiliu <andrei.vasiliu@intel.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-08-21 11:05:20 +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
8734a42377
mraa-gpio.c: add %d to printf statement
...
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-07-08 10:14:56 +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
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
Jakub Kramarz
f86703d7bb
java: added example GpioRead6 based on gpio_read6.c
...
Signed-off-by: Jakub Kramarz <jkramarz@virtuslab.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-04-29 09:53:32 +01:00
Jakub Kramarz
609e9fb102
java: added example BlinkOnboard based on blink_onboard.c
...
Signed-off-by: Jakub Kramarz <jkramarz@virtuslab.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-04-29 09:53:31 +01:00
Jakub Kramarz
ddff33280e
java: added example CyclePwm3 based on cycle-pwm3.c
...
Signed-off-by: Jakub Kramarz <jkramarz@virtuslab.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-04-29 09:53:31 +01:00
Jakub Kramarz
472b1c1370
java: capitalized file names of examples, required on case-sensitive systems
...
Signed-off-by: Jakub Kramarz <jkramarz@virtuslab.com >
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-04-29 09:50:32 +01:00
Brendan Le Foll
0b382100d2
mraa-gpio.c: fix unused printf argument
...
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com >
2015-04-24 16:05:12 +01:00