在C程序中使用telnet [英] Using telnet in a C Program

查看:298
本文介绍了在C程序中使用telnet的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我工作的机器人自动化项目,我遇到了一个路障。为了控制机器人,需要用它进行无线通过telnet连接,并通过TCP / IP协议发送命令。 (例如,在'MABC'命令移动它向前基于左车轮速度(a)中,右轮速度(b)和时间(c))的。我所试图做的是做一些计算在C程序中,然后将消息发送到基于计算的值的机器人。

I am working on a robot automation project and I have run into a road block. To control the robot, one needs to connect with it wirelessly via telnet and send commands through the tcp/ip protocol. (ex. The 'Mabc' command moves it forward based on the left wheel speed (a), the right wheel speed (b) and time (c)). What I am trying to do is do some calculations in a C program and then send a message to the robot based on the value of the calculation.

如何能在C程序通过TCP / IP协议发送命令?

How can send commands via tcp/ip protocol in a C program?

谢谢!

埃里克

推荐答案

您正在寻找插座。 这是一个COM prehensive指导插座C. 的Telnet程序也是一个明确的协议,虽然我不知道是不是这个机器人会使用telnet或没有(这是因为它不会有一个机器人控制程序太多好处的协议额外的处理开销)。 Telnet是一种借助 RFC 854 详细介绍

You are looking for sockets. This is a comprehensive guide to socket programming in C. Telnet is also a well defined protocol, although I don't know if this robot would use telnet or not (it's extra processing overhead for a protocol that wouldn't have much added benefit for a robot control program). Telnet is covered in detail by RFC 854

这篇关于在C程序中使用telnet的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆