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_group.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 00014 #define GROUP_ID_VARIABLE(rci) ((rci)->shared.group.id) 00015 #define set_group_id(rci, value) (GROUP_ID_VARIABLE(rci) = (value)) 00016 #define get_group_id(rci) (GROUP_ID_VARIABLE(rci)) 00017 #define invalidate_group_id(rci) set_group_id(rci, INVALID_ID) 00018 #define have_group_id(rci) (get_group_id(rci) != INVALID_ID) 00019 #define increment_group_id(rci) (GROUP_ID_VARIABLE(rci)++) 00020 00021 #define GROUP_INDEX_VARIABLE(rci) ((rci)->shared.group.index) 00022 #define set_group_index(rci, value) (GROUP_INDEX_VARIABLE(rci) = (value)) 00023 #define get_group_index(rci) (GROUP_INDEX_VARIABLE(rci)) 00024 #define increment_group_index(rci) (GROUP_INDEX_VARIABLE(rci)++) 00025 #define invalidate_group_index(rci) set_group_index(rci, INVALID_INDEX) 00026 #define have_group_index(rci) (get_group_index(rci) != INVALID_INDEX) 00027 00028 static connector_group_t const * get_current_group(rci_t const * const rci) 00029 { 00030 connector_remote_group_table_t const * const table = (connector_rci_config_data.group_table + rci->shared.callback_data.group.type); 00031 unsigned int const group_id = get_group_id(rci); 00032 00033 ASSERT(have_group_id(rci)); 00034 ASSERT(group_id < table->count); 00035 00036 return (table->groups + group_id); 00037 } 00038 00039 00040
Generated on Tue Jul 12 2022 19:18:38 by
1.7.2