Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
rci_binary_element.h
00001 /* 00002 * Copyright (c) 2013 Digi International Inc., 00003 * All rights not expressly granted are reserved. 00004 * 00005 * This Source Code Form is subject to the terms of the Mozilla Public 00006 * License, v. 2.0. If a copy of the MPL was not distributed with this file, 00007 * You can obtain one at http://mozilla.org/MPL/2.0/. 00008 * 00009 * Digi International Inc. 11001 Bren Road East, Minnetonka, MN 55343 00010 * ======================================================================= 00011 */ 00012 00013 #define ELEMENT_ID_VARIABLE(rci) ((rci)->shared.element.id) 00014 #define set_element_id(rci, value) (ELEMENT_ID_VARIABLE(rci) = (value)) 00015 #define get_element_id(rci) (ELEMENT_ID_VARIABLE(rci)) 00016 #define invalidate_element_id(rci) set_element_id(rci, INVALID_ID) 00017 #define have_element_id(rci) (get_element_id(rci) != INVALID_ID) 00018 00019 static connector_group_element_t const * get_current_element(rci_t const * const rci) 00020 { 00021 ASSERT(have_group_id(rci)); 00022 ASSERT(have_element_id(rci)); 00023 00024 { 00025 connector_group_t const * const group = get_current_group(rci); 00026 unsigned int const id = get_element_id(rci); 00027 00028 ASSERT(id < group->elements.count); 00029 00030 return (group->elements.data + id); 00031 } 00032 } 00033
Generated on Tue Jul 12 2022 19:18:38 by
1.7.2