| 1234567891011121314151617181920212223242526272829 |
- /*
- * Copyright (c) 2006-2021, RT-Thread Development Team
- *
- * SPDX-License-Identifier: Apache-2.0
- *
- * Change Logs:
- * Date Author Notes
- * 2021-05-29 hw630 the first version
- */
- #include <stdlib.h>
- #include <rtthread.h>
- #include <kobuki.h>
- void kobuki_set_speed_example(int argc, char* argv[])
- {
- struct kobuki robot;
- kobuki_init(&robot);
- if(argc == 3)
- {
- kobuki_set_speed(atof(argv[1]), atof(argv[2]));
- }
- else
- {
- rt_kprintf("kobuki_set_speed_example [tv] [rv]\n");
- }
- kobuki_close(&robot);
- }
- MSH_CMD_EXPORT(kobuki_set_speed_example, kobuki_set_speed_example [tv] [rv])
|