kurteknikk Posted March 26, 2010 Share Posted March 26, 2010 I don't know if there is anyone who tried this. I need to get sms messages from a mobile phone and i'll be using AT commands (from hyperterminal in windows) My problem is that i need to either access hyperterminal via command prompt; a connection can be open but i don't know how to input commands and get the response. Or else access hyperterminal directly from PHP which will be fabulous. Anyone could give me some help please ? I've searched a lot but i didn't find any help anywhere, because it seems that either not a lot of people tried it, or else its a bit more complicated than the usual normal stuff. Quote Link to comment https://forums.phpfreaks.com/topic/196593-using-at-commands-in-php/ Share on other sites More sharing options...
trq Posted March 26, 2010 Share Posted March 26, 2010 have you looked at the exec family of functions? Quote Link to comment https://forums.phpfreaks.com/topic/196593-using-at-commands-in-php/#findComment-1032183 Share on other sites More sharing options...
kurteknikk Posted March 26, 2010 Author Share Posted March 26, 2010 Yes, i know how to use exec, passthru etc... My actual question is if there's some kind of object in PHP which handles hyperterminal connections, or else if hyperterminal is available to use from command prompt and therefore i'll be able to use it from PHP by using exec functions. Quote Link to comment https://forums.phpfreaks.com/topic/196593-using-at-commands-in-php/#findComment-1032187 Share on other sites More sharing options...
trq Posted March 26, 2010 Share Posted March 26, 2010 There is no hyper terminal extension. As for wether or not the hyper terminal can be controlled via the command line? I don't see how that relates to php. Quote Link to comment https://forums.phpfreaks.com/topic/196593-using-at-commands-in-php/#findComment-1032217 Share on other sites More sharing options...
kurteknikk Posted March 26, 2010 Author Share Posted March 26, 2010 Yes, that's why i asked if anyone every tried it, because there might be someone who tried to use php directly and when he found out that there's not php extensions (like i just found out), maybe there's someone who found another solution... Quote Link to comment https://forums.phpfreaks.com/topic/196593-using-at-commands-in-php/#findComment-1032220 Share on other sites More sharing options...
trq Posted March 26, 2010 Share Posted March 26, 2010 Why don't you try checking within the cmd environment to see if there is actually a command line interface to hyper terminal? I'm not a windows user and don't really know what athe hyper terminal is / does. Quote Link to comment https://forums.phpfreaks.com/topic/196593-using-at-commands-in-php/#findComment-1032222 Share on other sites More sharing options...
DavidAM Posted March 26, 2010 Share Posted March 26, 2010 If I understand your question; you are trying to use AT commands to talk to a modem on a COM port. You don't need to use hyperterminal for this. It's just another layer of complication. Look at PHP's Direct IO extensions (http://us3.php.net/manual/en/book.dio.php). You should be able to open, read, and write a COM port directly. I've never done this in PHP either. But I would think it could be done. Quote Link to comment https://forums.phpfreaks.com/topic/196593-using-at-commands-in-php/#findComment-1032242 Share on other sites More sharing options...
kurteknikk Posted March 26, 2010 Author Share Posted March 26, 2010 Hi, Yes that's exactly what i'm trying to do, i thought that there must be some kind of solution. I was currently searching for using hyperterminal from cmd but this is a much better solution if it works. Thanks a lot mate, i really appreciate it Quote Link to comment https://forums.phpfreaks.com/topic/196593-using-at-commands-in-php/#findComment-1032253 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.