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.
AT_CellularNetwork_stub.cpp
00001 /* 00002 * Copyright (c) 2017, Arm Limited and affiliates. 00003 * SPDX-License-Identifier: Apache-2.0 00004 * 00005 * Licensed under the Apache License, Version 2.0 (the "License"); 00006 * you may not use this file except in compliance with the License. 00007 * You may obtain a copy of the License at 00008 * 00009 * http://www.apache.org/licenses/LICENSE-2.0 00010 * 00011 * Unless required by applicable law or agreed to in writing, software 00012 * distributed under the License is distributed on an "AS IS" BASIS, 00013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00014 * See the License for the specific language governing permissions and 00015 * limitations under the License. 00016 */ 00017 00018 #include "AT_CellularNetwork.h" 00019 #include "CellularNetwork.h" 00020 #include "CellularUtil.h" 00021 #include "CellularLog.h" 00022 #include "FileHandle.h" 00023 #include "nsapi_types.h" 00024 00025 using namespace mbed; 00026 using namespace mbed_cellular_util; 00027 00028 AT_CellularNetwork::AT_CellularNetwork(ATHandler &atHandler) : AT_CellularBase(atHandler) 00029 { 00030 } 00031 00032 AT_CellularNetwork::~AT_CellularNetwork() 00033 { 00034 } 00035 00036 nsapi_error_t AT_CellularNetwork::init() 00037 { 00038 return NSAPI_ERROR_OK ; 00039 } 00040 00041 nsapi_error_t AT_CellularNetwork::set_credentials(const char *apn, 00042 const char *username, const char *password) 00043 { 00044 return NSAPI_ERROR_OK ; 00045 } 00046 00047 nsapi_error_t AT_CellularNetwork::set_credentials(const char *apn, 00048 AuthenticationType type, const char *username, const char *password) 00049 { 00050 return NSAPI_ERROR_OK ; 00051 } 00052 00053 nsapi_error_t AT_CellularNetwork::connect(const char *apn, 00054 const char *username, const char *password) 00055 { 00056 return connect(); 00057 } 00058 00059 nsapi_error_t AT_CellularNetwork::connect() 00060 { 00061 return NSAPI_ERROR_OK ; 00062 } 00063 00064 nsapi_error_t AT_CellularNetwork::activate_context() 00065 { 00066 return NSAPI_ERROR_OK ; 00067 } 00068 00069 nsapi_error_t AT_CellularNetwork::open_data_channel() 00070 { 00071 return NSAPI_ERROR_OK ; 00072 } 00073 00074 nsapi_error_t AT_CellularNetwork::disconnect() 00075 { 00076 return NSAPI_ERROR_OK ; 00077 } 00078 00079 void AT_CellularNetwork::attach(Callback<void(nsapi_event_t, intptr_t)> status_cb) 00080 { 00081 } 00082 00083 nsapi_connection_status_t AT_CellularNetwork::get_connection_status() const 00084 { 00085 return NSAPI_STATUS_LOCAL_UP ; 00086 } 00087 00088 nsapi_error_t AT_CellularNetwork::set_blocking(bool blocking) 00089 { 00090 return NSAPI_ERROR_OK ;; 00091 } 00092 00093 nsapi_ip_stack_t AT_CellularNetwork::string_to_stack_type(const char* pdp_type) 00094 { 00095 return IPV4_STACK; 00096 } 00097 00098 nsapi_error_t AT_CellularNetwork::set_registration_urc(RegistrationType type, bool urc_on) 00099 { 00100 return NSAPI_ERROR_OK ; 00101 } 00102 00103 nsapi_error_t AT_CellularNetwork::get_network_registering_mode(NWRegisteringMode& mode) 00104 { 00105 mode = NWModeAutomatic; 00106 return NSAPI_ERROR_OK ; 00107 } 00108 00109 nsapi_error_t AT_CellularNetwork::set_registration(const char *plmn) 00110 { 00111 return NSAPI_ERROR_OK ; 00112 } 00113 00114 nsapi_error_t AT_CellularNetwork::get_registration_status(RegistrationType type, RegistrationStatus &status) 00115 { 00116 return NSAPI_ERROR_OK ; 00117 } 00118 00119 nsapi_error_t AT_CellularNetwork::get_cell_id(int &cell_id) 00120 { 00121 return NSAPI_ERROR_OK ; 00122 } 00123 00124 bool AT_CellularNetwork::has_registration(RegistrationType reg_type) 00125 { 00126 return false; 00127 } 00128 00129 nsapi_error_t AT_CellularNetwork::set_attach(int timeout) 00130 { 00131 return NSAPI_ERROR_OK ; 00132 } 00133 00134 nsapi_error_t AT_CellularNetwork::get_attach(AttachStatus &status) 00135 { 00136 return NSAPI_ERROR_OK ; 00137 } 00138 00139 nsapi_error_t AT_CellularNetwork::detach() 00140 { 00141 return NSAPI_ERROR_OK ; 00142 } 00143 00144 nsapi_error_t AT_CellularNetwork::get_apn_backoff_timer(int &backoffTime) 00145 { 00146 return NSAPI_ERROR_OK ; 00147 } 00148 00149 NetworkStack *AT_CellularNetwork::get_stack() 00150 { 00151 return NULL; 00152 } 00153 00154 const char *AT_CellularNetwork::get_ip_address() 00155 { 00156 return NULL; 00157 } 00158 00159 nsapi_error_t AT_CellularNetwork::set_stack_type(nsapi_ip_stack_t stack_type) 00160 { 00161 return NSAPI_ERROR_OK ; 00162 } 00163 00164 nsapi_ip_stack_t AT_CellularNetwork::get_stack_type() 00165 { 00166 return IPV4_STACK; 00167 } 00168 00169 bool AT_CellularNetwork::get_modem_stack_type(nsapi_ip_stack_t requested_stack) 00170 { 00171 return false; 00172 } 00173 00174 void AT_CellularNetwork::urc_no_carrier() 00175 { 00176 00177 } 00178 00179 nsapi_error_t AT_CellularNetwork::set_access_technology_impl(RadioAccessTechnology opsAct) 00180 { 00181 return NSAPI_ERROR_OK ; 00182 } 00183 00184 nsapi_error_t AT_CellularNetwork::set_access_technology(RadioAccessTechnology opAct) 00185 { 00186 return NSAPI_ERROR_OK ; 00187 } 00188 00189 nsapi_error_t AT_CellularNetwork::get_access_technology(RadioAccessTechnology& rat) 00190 { 00191 rat = RAT_CATM1; 00192 return NSAPI_ERROR_OK ; 00193 } 00194 00195 nsapi_error_t AT_CellularNetwork::scan_plmn(operList_t &operators, int &opsCount) 00196 { 00197 return NSAPI_ERROR_OK ; 00198 } 00199 00200 nsapi_error_t AT_CellularNetwork::set_ciot_optimization_config(Supported_UE_Opt supported_opt, 00201 Preferred_UE_Opt preferred_opt) 00202 { 00203 return NSAPI_ERROR_OK ; 00204 } 00205 00206 nsapi_error_t AT_CellularNetwork::get_ciot_optimization_config(Supported_UE_Opt& supported_opt, 00207 Preferred_UE_Opt& preferred_opt) 00208 { 00209 return NSAPI_ERROR_OK ; 00210 } 00211 00212 nsapi_error_t AT_CellularNetwork::get_rate_control( 00213 CellularNetwork::RateControlExceptionReports &reports, 00214 CellularNetwork::RateControlUplinkTimeUnit &timeUnit, int &uplinkRate) 00215 { 00216 return NSAPI_ERROR_OK ; 00217 } 00218 00219 00220 nsapi_error_t AT_CellularNetwork::get_pdpcontext_params(pdpContextList_t& params_list) 00221 { 00222 return NSAPI_ERROR_OK ; 00223 } 00224 00225 nsapi_error_t AT_CellularNetwork::get_extended_signal_quality(int &rxlev, int &ber, int &rscp, int &ecno, int &rsrq, int &rsrp) 00226 { 00227 return NSAPI_ERROR_OK ; 00228 } 00229 00230 nsapi_error_t AT_CellularNetwork::get_signal_quality(int &rssi, int &ber) 00231 { 00232 return NSAPI_ERROR_OK ; 00233 } 00234 00235 nsapi_error_t AT_CellularNetwork::get_operator_params(int &format, operator_t &operator_params) 00236 { 00237 return NSAPI_ERROR_OK ; 00238 } 00239 00240 int AT_CellularNetwork::get_3gpp_error() 00241 { 00242 return 0; 00243 } 00244 00245 nsapi_error_t AT_CellularNetwork::get_operator_names(operator_names_list &op_names) 00246 { 00247 return NSAPI_ERROR_OK ; 00248 } 00249 00250 nsapi_error_t AT_CellularNetwork::do_user_authentication() 00251 { 00252 return NSAPI_ERROR_OK ; 00253 } 00254 00255 00256
Generated on Tue Jul 12 2022 12:43:33 by
