Home
last modified time | relevance | path

Searched refs:argc (Results 1 – 25 of 71) sorted by relevance

123

/drivers/peripheral/usb/sample/device/linux/
Dusb_dev_test.c36 int32_t main(int32_t argc, char *argv[]) in main() argument
38 if (argc < OPTION_LENGTH) { in main()
40 HDF_LOGE("%s:%d argc=%d is too flew!", __func__, __LINE__, argc); in main()
45 AcmRead(argc - 1, arg); in main()
47 AcmWrite(argc - 1, arg); in main()
49 AcmTest(argc - 1, arg); in main()
51 PropTest(argc - 1, arg); in main()
53 AcmSpeedRead(argc - 1, arg); in main()
55 AcmSpeedWrite(argc - 1, arg); in main()
Dusb_dev_test.h19 int32_t AcmRead(int32_t argc, const char *argv[]);
20 int32_t AcmSpeedRead(int32_t argc, const char *argv[]);
21 int32_t AcmSpeedWrite(int32_t argc, const char *argv[]);
22 int32_t AcmTest(int32_t argc, const char *argv[]);
23 int32_t AcmWrite(int32_t argc, const char *argv[]);
24 int32_t PropTest(int32_t argc, const char *argv[]);
Dacm_write.c45 int32_t AcmWrite(int32_t argc, const char *argv[]) in AcmWrite() argument
68 if (argc >= NUM_INPUT) { in AcmWrite()
Dacm_speed_read.c84 int32_t AcmSpeedRead(int32_t argc, const char *argv[]) in AcmSpeedRead() argument
86 (void)argc; in AcmSpeedRead()
/drivers/peripheral/usb/sample/device/liteos/
Dusb_dev_test.c34 int32_t main(int32_t argc, char *argv[]) in main() argument
36 if (argc < OPTION_LENGTH) { in main()
38 HDF_LOGE("%s:%d argc=%d is too flew!", __func__, __LINE__, argc); in main()
43 AcmTest(argc - 1, arg); in main()
45 PropTest(argc - 1, arg); in main()
47 AcmSpeedRead(argc - 1, arg); in main()
49 AcmSpeedWrite(argc - 1, arg); in main()
Dusb_dev_test.h19 int32_t AcmSpeedRead(int32_t argc, const char *argv[]);
20 int32_t AcmSpeedWrite(int32_t argc, const char *argv[]);
21 int32_t AcmTest(int32_t argc, const char *argv[]);
22 int32_t PropTest(int32_t argc, const char *argv[]);
/drivers/hdf_core/framework/tools/hc-gen/src/
Doption.cpp33 Option &Option::Parse(int argc, char **argv) in Parse() argument
36 if (argc < ARG_COUNT_MIN) { in Parse()
41 if (!ParseOptions(argc, argv)) { in Parse()
45 if (optind >= argc) { in Parse()
57 bool Option::ParseOptions(int argc, char **argv) in ParseOptions() argument
61 op = getopt(argc, argv, HCS_SUPPORT_ARGS); in ParseOptions()
Dmain.cpp19 int main(int argc, char *argv[]) in main() argument
21 auto option = Option::Instance().Parse(argc, argv); in main()
Doption.h25 Option &Parse(int argc, char *argv[]);
69 bool ParseOptions(int argc, char *argv[]);
/drivers/hdf_core/framework/tools/hdf_dbg/
Dhdf_dbg.cpp269 static bool ParseParameterCount(int argc, char **argv, HdfDbg &info) in ParseParameterCount() argument
286 if ((info.inParam * PARA_MULTIPLE + info.outParam) != (argc - PARA_CNT_IDX - 1)) { in ParseParameterCount()
293 static bool ParseParameterIn(int argc, char **argv, HdfDbg &info) in ParseParameterIn() argument
310 static bool ParseParameterOut(int argc, char **argv, HdfDbg &info) in ParseParameterOut() argument
324 static bool ParseHdfDbg(int argc, char **argv, HdfDbg &info) in ParseHdfDbg() argument
326 if (argc < DBG_HDI_PARA_MIN_LEN) { in ParseHdfDbg()
333 if (!ParseParameterCount(argc, argv, info) || !ParseParameterIn(argc, argv, info) || in ParseHdfDbg()
334 !ParseParameterOut(argc, argv, info)) { in ParseHdfDbg()
340 static int32_t InjectDebugHdi(int argc, char **argv) in InjectDebugHdi() argument
343 if (!ParseHdfDbg(argc, argv, info)) { in InjectDebugHdi()
[all …]
/drivers/peripheral/audio/test/audio_utils/audio_mixer/
Daudio_mixer_main.c440 static int32_t MixerESet(unsigned int argc, char *argv[], int32_t roflag) in MixerESet() argument
445 if (argc < 1) { in MixerESet()
464 if (roflag == SSET_WR && argc < 2) { // 2 for number of argcs in MixerESet()
482 ret = MctlSetElem(g_service, &ctlInfo, argc, argv); in MixerESet()
544 static int32_t MixerSetChannels(unsigned int argc, char *str) in MixerSetChannels() argument
546 if (argc < 1) { in MixerSetChannels()
551 return SetChannels(g_service, g_serviceName, argc, str); in MixerSetChannels()
555 int main(int argc, char *argv[]) in main() argument
597 c = getopt_long(argc, argv, shortOptions, longOpts, &optionIndex); in main()
703 if (argc - optind <= 0) { in main()
[all …]
Daudio_mixer.c894 static int32_t FillChnlsIntVal(struct AudioMixerCtlElemInfo *info, unsigned int argc, char *argv) in FillChnlsIntVal() argument
929 int32_t SetChannels(const struct HdfIoService *srv, const char *cardSrv, unsigned int argc, char *a… in SetChannels() argument
934 if (srv == NULL || cardSrv == NULL || argc == 0) { in SetChannels()
939 DEBUG_LOG("argc = %u, argv = %s\n", argc, argv); in SetChannels()
957 ret = FillChnlsIntVal(&infoData, argc, argv); in SetChannels()
981 static int32_t FillIntVal(struct AudioMixerCtlElemInfo *info, unsigned int argc, char *argv[]) in FillIntVal() argument
987 if (argc != 2) { // 2 for numbers of argc in FillIntVal()
992 ptr = argv[argc - 1]; in FillIntVal()
993 DEBUG_LOG("argv[%u] = %s\n", argc - 1, ptr); in FillIntVal()
1027 static int32_t FillEnumVal(struct AudioMixerCtlElemInfo *info, unsigned int argc, char *argv[]) in FillEnumVal() argument
[all …]
/drivers/hdf_core/adapter/uhdf2/host/
Ddevhost.c119 int main(int argc, char **argv) in main() argument
121 if ((argc != DEVHOST_INPUT_PARAM_NUM) && (argc != DEVHOST_PARAM_NUM_WITH_PRI)) { in main()
122 HDF_LOGE("Devhost main parameter error, argc: %{public}d", argc); in main()
138 if (argc == DEVHOST_PARAM_NUM_WITH_PRI) { in main()
/drivers/peripheral/usb/sample/host/liteos_test/src/
Dusbhost_speed_test.c209 static int32_t CheckParam(int32_t argc, const char *argv[], struct UsbSpeedTest *speedTest) in CheckParam() argument
214 if ((argv == NULL) || (speedTest == NULL) || (argc <= 0)) { in CheckParam()
217 switch (argc) { in CheckParam()
226 if ((argc == 7) && (speedTest->writeOrRead == TEST_READ)) { in CheckParam()
245 speedTest->paramNum = argc - 1; in CheckParam()
251 int32_t main(int32_t argc, char *argv[]) in main() argument
256 ret = CheckParam(argc, argv, &test); in main()
/drivers/peripheral/camera/test/demo/
Ddemo_main.cpp186 const int argc, char** argv) in ManuList() argument
191 c = getopt_long(argc, argv, shortOptions, LONG_OPTIONS, &idx); in ManuList()
242 int main(int argc, char** argv) in main() argument
265 ManuList(mainDemo, argc, argv); in main()
271 int main(int argc, char** argv) in main() argument
273 OHOS::Camera::main(argc, argv); in main()
/drivers/external_device_manager/test/moduletest/driver_extension_controller_mt/
Ddriver_extension_controller_mt.cpp58 int TestEntry(int argc, char **argv) in TestEntry() argument
63 if (argc != PARAM_COUNT_NEED) { in TestEntry()
141 int main(int argc, char **argv) in main() argument
143 return DriverExtensionControllerMt().TestEntry(argc, argv); in main()
/drivers/hdf_core/framework/tools/hdi-gen/
Dmain.cpp19 int main(int argc, char **argv) in main() argument
22 if (!options.Parse(argc, argv)) { in main()
/drivers/peripheral/usb/sample/host/src/
Dusbhost_test.c319 int32_t main(int32_t argc, char *argv[]) in main() argument
325 if ((argc < ARGV_CMD_TYPE) || (argc < PARAM_GET_CMD_LEN) || (argv[ARGV_CMD_TYPE] == NULL)) { in main()
326 HDF_LOGE("%s:%d invalid parma, argc=%d", __func__, __LINE__, argc); in main()
330 if ((argc == PARAM_GET_CMD_LEN) && in main()
338 status = TestParaseCommand(argc, argv[ARGV_CMD_TYPE], &cmdType, apiType); in main()
Dusbhost_loader_test.c45 int32_t main(int32_t argc, char *argv[]) in main() argument
47 (void)argc; in main()
/drivers/peripheral/distributed_camera/hdi_service/test/sample/
Ddemo_main.cpp206 static void ManuList(const std::shared_ptr<DcameraHdfDemo>& mainDemo, const int argc, char** argv) in ManuList() argument
211 c = getopt_long(argc, argv, shortOptions, LONG_OPTIONS, &idx); in ManuList()
257 int main(int argc, char** argv) in main() argument
283 ManuList(mainDemo, argc, argv); in main()
290 int main(int argc, char** argv) in main() argument
292 OHOS::DistributedHardware::main(argc, argv); in main()
/drivers/peripheral/codec/test/demo/jpeg/src/
Dcommand_parse.cpp29 bool CommandParse::Parse(int argc, char *argv[], CommandOpt &opt) in Parse() argument
33 int c = getopt_long(argc, argv, "i:o:w:h:", g_longOptions, &optionIndex); in Parse()
/drivers/peripheral/codec/test/demo/adapter/src/
Dcommand_adapter_parse.cpp32 bool CommandAdapterParse::Parse(int argc, char *argv[], CommandOpt &opt) in Parse() argument
44 int c = getopt_long(argc, argv, "i:o:w:h:", long_options, &optionIndex); in Parse()
/drivers/external_device_manager/frameworks/js/napi/device_manager/
Ddevice_manager_middle.cpp343 size_t argc = PARAM_COUNT_1; in QueryDevices() local
345 NAPI_CALL(env, napi_get_cb_info(env, info, &argc, argv, nullptr, nullptr)); in QueryDevices()
348 if (argc > 0 && IsMatchType(env, argv[0], napi_number)) { in QueryDevices()
389 size_t argc = PARAM_COUNT_3; in BindDevice() local
391 NAPI_CALL(env, napi_get_cb_info(env, info, &argc, argv, nullptr, nullptr)); in BindDevice()
392 if (argc < PARAM_COUNT_2) { in BindDevice()
424 if (argc > PARAM_COUNT_2 && IsMatchType(env, argv[PARAM_COUNT_2], napi_function)) { in BindDevice()
436 size_t argc = PARAM_COUNT_2; in UnbindDevice() local
438 NAPI_CALL(env, napi_get_cb_info(env, info, &argc, argv, nullptr, nullptr)); in UnbindDevice()
439 if (argc < PARAM_COUNT_1) { in UnbindDevice()
[all …]
/drivers/peripheral/codec/test/demo/idl/src/
Dcommand_parse.cpp28 bool CommandParse::Parse(int argc, char *argv[], CommandOpt &opt) in Parse() argument
42 int c = getopt_long(argc, argv, "i:o:w:h:", long_options, &optionIndex); in Parse()
/drivers/peripheral/codec/test/demo/v1.0/
Dcodec_utils.c119 int32_t ParseArguments(CodecCmd* cmd, int argc, char **argv) in ParseArguments() argument
124 if ((argc <= 1) || (cmd == NULL)) { in ParseArguments()
129 while (optindex < argc) { in ParseArguments()

123