Last week, we had the author of TDD for a Shopping Website LiveProject. Friday at 11am Ranch time, Steven Solomon will be hosting a live TDD session just for us. See for the agenda and registration link
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

Need Suggestions..

 
clojure forum advocate
Posts: 3479
Mac Objective C Clojure
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hey all.
I want to create a phone # detecdor application in Java.
I have a modem (56 KB) that is connected to the phone line, this modem is installed on COM4 port.
I am using Java Communication API to connect with the PC's ports.
the application is listing to COM4 and write whatever its recieves.
when dialing to my phone # and running the application, I got nothing , neither a result neither an exception.
well, I am not an expert in these topics, so any suggestions are welcomed.
thanks.
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
1. Are you sure that the package is installed correctly and that it can find all your com ports?
2. How have you implemented the "listening to COM4" code?
Bill
 
Hussein Baghdadi
clojure forum advocate
Posts: 3479
Mac Objective C Clojure
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have developed a small application thats iterates over all the ports and print them, I get :
COM1, COM2, COM3, COM4, LPT1, LPT2
the following code is PhoneDetecdor class:

Thanks for help ..
 
William Brogden
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If this was my problem, I would be dumping all the information carried on those SerialPortEvent events to System.out. For example, you say you are dialing into the modem - this should cause a RI - Ring Indicator event. You really want to know every event that occurs - the modem has to be controlled step by step.

Once you are sure you are getting RI, you need to tell the modem to pick up the line - thats going to be an "AT" command of some sort ( ATA<cr> I think )- from the old Hayes Smartmodem command set that became a standard.

Unfortunately I have not messed with that for over 10 years so I can't guide you step by step. Talking to a modem requires that you have the serial connections wired up right and that you follow a particular series of commands to answer a connection.
Bill
 
Arthur, where are your pants? Check under this tiny ad.
free, earth-friendly heat - a kickstarter for putting coin in your pocket while saving the earth
https://coderanch.com/t/751654/free-earth-friendly-heat-kickstarter
reply
    Bookmark Topic Watch Topic
  • New Topic