Age | Commit message (Collapse) | Author |
|
Musl has removed the declaration from string.h [1] which exposes the
problem especially with clang-17+ compiler where implicit function
declaration is flagged as error. Use posix basename and make a copy of
string to operate on to emulate GNU basename behaviour.
[1] https://git.musl-libc.org/cgit/musl/commit/?id=725e17ed6dff4d0cd22487bb64470881e86a92e7
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
|
Add RISC-V architecture and StarFive JH71x0-based boards
VisionFive and VisionFive 2.
Signed-off-by: Daniel Bovensiepen <oss@bovi.li>
Signed-off-by: Zhu Jia Xing <jiaxing.zhu@siemens.com>
|
|
Signed-off-by: Jefferson Lee <jeffersonlee2000@gmail.com>
|
|
UP Xtreme is based on the Intel(R) Core(TM) i3/i5/i7 Whiskey Lake SoCs.
The UP Xtreme presents one Raspberry Pi compatible HAT connector.
This implementaion supports i2c, spi, uart, adc and gpio through the
40pin HAT connector.
Gpio chardev capabilities have been disabled in this implementation. When
gpio chardev capabilities are enabled an input becomes unreadable after an
isr has been registered to the pin. See here for details:
https://github.com/intel-iot-devkit/mraa/issues/937
Tested on UP Xtreme, with UP Board Linux kernel 5.0.0
Features tested: gpio, gpio interrupts, i2c, spi, adc and uart.
Signed-off-by: Michael Campion <michael.campion@emutex.com>
|
|
Large change that removes the duplicated MIT notice withe a spdx tag
Signed-off-by: Thomas Ingleby <thomas.ingleby@intel.com>
|
|
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
|
|
Signed-off-by: Cosmin Popescu <gabrielcosmin.popescu@gmail.com>
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
|
|
Signed-off-by: Cosmin Popescu <gabrielcosmin.popescu@gmail.com>
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
|
|
Signed-off-by: Cosmin Popescu <gabrielcosmin.popescu@gmail.com>
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
|
|
Signed-off-by: Cosmin Popescu <gabrielcosmin.popescu@gmail.com>
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
|
|
1. Extend the lookup count to phy_pin_count to cover all physical pins
exposed on the board
2. Ignore the non GPIO pins by checking for GPIO capability
Signed-off-by: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
|
|
Updates to make the FT4222 platform extender more usable.
Previous implementation opened libft4222.so and loaded symbols as
needed. This implementation removes dynamic loading of libft4222 in
favor of creating a new shared libary which links against libft4222.so.
The dynamic loading is now done in mraa.c. One C method is exposed in
libmraa-platform-ft4222.so for finding/initializing an FT4222:
mraa_platform_t mraa_usb_platform_extender(mraa_board_t* board);
Mraa.c attempts to open this platform library and calls the
mraa_usb_platform_extender method. If an ftdi4222 is connected, the
user gets added IO from the extender. If no FT4222 device is connected,
continue as normal.
* Create a new platform library for the FT4222
* Expose only 1 C method from the library -
mraa_usb_platform_extender
* libmraa-platform-ft4222.so contains CXX code (as well as previous
C code). All *allocs have been removed in favor of global
C++ stl containers.
* Previously, the FT4222 would only initialize correctly if 2 ftdi
devices existed. Now, initialize FT4222 devices based on the
device id.
* Many fixes for various problems with the FT4222
* Added unit test for platform extender (minimal functionality w/o hw)
* Updated to FindFtd4222.cmake module to handle standard arguments
* Removed CMAKE_C_FLAGS addition of -DFTDID2XX and -DFTDI4222 since
these are NOT used anywhere in source.
* Building the FTDI4222 shim requires libft4222.h which requires
ftd2xx.h. Updated CMakeLists.txt to require both when building
the shim.
Signed-off-by: Noel Eck <noel.eck@intel.com>
|
|
Went a bit too far with the previous commit. Added pointer to pointer
back to mraa_find_uart_bus_pci.
Tested leaks against valgrind and verified dev_path gets set with gdb.
Signed-off-by: Noel Eck <noel.eck@intel.com>
|
|
Unfortunately the device_path char* is dynamically allocated
and #defined and const char *'ed depending on how each platform provided the
uart device paths which makes cleaning it up more complicated.
Added a check for the IEI_TANK.
Removed the char** (in favor of a char*) for mraa_find_uart_bus_pci.)
Signed-off-by: Noel Eck <noel.eck@intel.com>
|
|
Signed-off-by: Abhishek Malik <abhishek.malik@intel.com>
|
|
check is performed
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
|
|
This commit includes a set of small fixes flushed out from the google
unit tests.
* Fixed missing implementations of mraa_get_*_count methods.
* Fix for NULL string
* Fix for MOCK platform C++ define.
* Switched (void) -> () function definitions for consistency.
Signed-off-by: Noel Eck <noel.eck@intel.com>
|
|
Signed-off-by: Mihai Stefanescu <mihai.t.gh.stefanescu@gmail.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Mihai Stefanescu <mihai.t.gh.stefanescu@gmail.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Pinmap field value is an OS pin number, not mraa pin index,
so make the function return the proper one.
Fixes #817.
Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
|
|
Signed-off-by: Serge Vakulenko <vak@besm6.org>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Closes #736.
Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Tapani Utriainen <tapani@technexion.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Tapani Utriainen <tapani@technexion.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Closes #731.
Signed-off-by: Alex Tereschenko <alext.mkrs@gmail.com>
|
|
Signed-off-by: Tapani Utriainen <tapani@technexion.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Tapani Utriainen <tapani@technexion.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
This patch has no changes in function. It fixes three style issues
to be more readable and in line to the rest of the codebase:
- return types are declared on a separate line
- reversal of Yoda conditionals
- initialize for loop variable inside loop declaration
- Fix styling of pwm lookup doxygen
Signed-off-by: Tapani Utriainen <tapani@technexion.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
The Native PIO API provides both the libraries and headers for use with
the Android Things Peripheralanager client. This commit removes these
from the MRAA repo in favor of the FindAndroidThings.cmake provided by
the Native PIO API.
Signed-off-by: Noel Eck <noel.eck@intel.com>
|
|
These lookups provide the MRAA index with the Pin/Bus name as input
Signed-off-by: Vineela Tummalapalli <vineela.tummalapalli@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
This fixes #698 where an application will crash after calling mraa_deinit and
later closing calling deinit again because of the gcc destructor argument
introduced with cac8f7a
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
In the process of using the mraa mock platform to identify memory leaks
in UPM libraries. This commit fixes some non-critical places where
memory was getting lost in mraa.
Signed-off-by: Noel Eck <noel.eck@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Variable 'dup' doesn't get freed correctly as the pointer to it changes
after 'strsep' function is used. Also 'token' variable doesn't need to
be freed as freeing the original 'dup' already frees the same memory.
Signed-off-by: Simo Kuusela <simo.kuusela@intel.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
If we already have a subplatform present with the same type, return success
when trying to add it again. We don't check that the tty is the same because
that is hidden inside the t_firmata* structure but we should do at some point
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|
|
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
|