-
Notifications
You must be signed in to change notification settings - Fork 199
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Re-implement EnumMember::hasValue() #159
Merged
MichalPrincNXP
merged 1 commit into
EmbeddedRPC:develop
from
SWISensorHub:pr_EnumMember_hasValue
Feb 11, 2021
Merged
Re-implement EnumMember::hasValue() #159
MichalPrincNXP
merged 1 commit into
EmbeddedRPC:develop
from
SWISensorHub:pr_EnumMember_hasValue
Feb 11, 2021
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Issue EmbeddedRPC#41 describes a problem where an enum value of -1 causes a failure of an assertion in erpcgen. The new version of hasValue uses a bool member variable to track when the value is set rather than using a sentinel value of -1.
Closed
Hello @dpfrey , I am sorry for late response, please give me some time for the review, I would like to have a look at it next week. |
I never saw negative numbers in enums before, that was why it was solved that way. But now i know that it wasn't best solution. So thank you for this PR. Looks correct. |
MichalPrincNXP
approved these changes
Feb 11, 2021
MichalPrincNXP
added a commit
that referenced
this pull request
May 7, 2021
-- Update erpcgen and unit tests to cover the case when enum member value is negative (Github #159 PR / #41 issue solving). -- Update (D)SPI transport layers to avoid busy loops in rtos environments, introduce semaphores. -- Introduced new transports: i2c_slave_transport (C/C++), LIBUSBSIOSPITransport (Python), LIBUSBSIOI2CTransport (Python). -- Remove const qualifier from InterThreadBufferTransport::send method parameter to align with parent Transport class (GitHub issue #172). -- Allow conditional compilation of message_loggers and pre_post_action to help to reduce the code size when compiler does not correctly strip unused code. -- Minor documentation updates. -- Version changed to 1.8.1.
danderson-presonus
pushed a commit
to PreSonusAudioElectronics/erpc
that referenced
this pull request
Jul 9, 2021
* transport arbitrator: override Transport::hasMessage Override the default implementation of hasMessage from Transport with a version that calls through to the hasMessage of the shared transport that the transport arbitrator is using. * Fixed doxygen comments. * Replace deprecating error verbose declaration * Use token keywords instead of values. * Add option to put void in function declaration (no paramaters case). * Fixing several misra issues in shim code. * First minor changes * Infra folder did more misra complaint. * Port folder did more misra complaint. * Transport folder did more misra complaint. * Setup folder did more misra complaint. * Fix ERPC_THREADS_IS(ERPC_THREADS_NONE) macro to ERPC_THREADS_IS(NONE) * Fix tcp transport. * Fixed pytest issues related to latest changes. * Fix build issue. * Update (C) * Re-implement EnumMember::hasValue() Issue EmbeddedRPC#41 describes a problem where an enum value of -1 causes a failure of an assertion in erpcgen. The new version of hasValue uses a bool member variable to track when the value is set rather than using a sentinel value of -1. * Fixes based on PR review * Fixes based on PR review * fix hidding unused wariables * Align dspi code with spi * Fix Typ in comment * Fully automate dev setup with Gitpod This commit implements a fully-automated development setup using Gitpod.io, an online IDE for GitLab, GitHub, and Bitbucket that enables Dev-Environments-As-Code. This makes it easy for anyone to get a ready-to-code workspace for any branch, issue or pull request almost instantly with a single click. * Initial support for Threading/ThreadX and building with CMake * Added auto-config supoort for Threading/ThreadX * eRPC updates 05/2021 -- Update erpcgen and unit tests to cover the case when enum member value is negative (Github EmbeddedRPC#159 PR / EmbeddedRPC#41 issue solving). -- Update (D)SPI transport layers to avoid busy loops in rtos environments, introduce semaphores. -- Introduced new transports: i2c_slave_transport (C/C++), LIBUSBSIOSPITransport (Python), LIBUSBSIOI2CTransport (Python). -- Remove const qualifier from InterThreadBufferTransport::send method parameter to align with parent Transport class (GitHub issue EmbeddedRPC#172). -- Allow conditional compilation of message_loggers and pre_post_action to help to reduce the code size when compiler does not correctly strip unused code. -- Minor documentation updates. -- Version changed to 1.8.1. * * Added separate erpc_port_threadx.cpp for ThreadX support * Removed CMakeLists.txt * Assert that m_sharedTransport is set before use * Copyright year update * Fixing Travis build fails * - fix compiler warnings and use extended files in the build * Linux -> RTOS working, but RTOS -> Linux not * Fix the eRPC TTY RTOS transport so that it correctly handles sending the return values of service functions back to the caller * adding extended files to build * handle linux tty driver initial "hello world!" message slightly more gracefully * Created an #ifdef'd alternate version of base class RPMsgBaseTransport who's member variables are not static. This enables clean creation of multiple transport instances to support multiple endpoints on the same system. The original base class used static member variables and a templated instantiation system to make make static allocation "appear" like dynamic allocation at the user interface. The problem is it in effect acted like an unprotected singleton, so you could instantiate multiple instances, but the member data would get overwritten since it was static. This paves the way for "full duplex" function calls utilizing two separate endpoints. * Make serial transport non-blocking to faciliate multi threading * - yield to sleep for lower cpu usage * adding comments * revert thread sleep modification to erpc_serial_transport.cpp, change private variables in class SerialTransport from protected to private to allow extension * bring in name changes * Update CMakeLists.txt Co-authored-by: David Frey <dfrey@sierrawireless.com> Co-authored-by: Dusan Cervenka <Cervenka.dusan@gmail.com> Co-authored-by: Cervenka Dusan <cervenka@acrios.com> Co-authored-by: Michal Princ <michal.princ@nxp.com> Co-authored-by: aelray <aelray@gmail.com> Co-authored-by: werner-dk <werner.hirtsiefer@dormakaba.com> Co-authored-by: Ibrahim ERTURK <ierturk@ieee.org>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue #41 describes a problem where an enum value of -1 causes a failure
of an assertion in erpcgen. The new version of hasValue uses a bool
member variable to track when the value is set rather than using a
sentinel value of -1.