Thread: Morse Code

    #1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2003
    Location
    Atlanta
    Posts
    3
    Rep Power
    0

    Post Morse Code


    I need to write a program using C, that will translate english letters(words) to their appropriate morse codes. Could you please help me.
  2. #2
  3. jasondoucette.com
    Devshed Newbie (0 - 499 posts)

    Join Date
    Feb 2003
    Location
    Canada
    Posts
    378
    Rep Power
    12
    The first step is to look up the morse code characters. I found this website real quick using google.com:

    http://www.babbage.demon.co.uk/morseabc.html

    Then you have to look into parsing a character string. So, you should look up the ASCII code, next.
  4. #3
  5. Banned ;)
    Devshed Supreme Being (6500+ posts)

    Join Date
    Nov 2001
    Location
    Woodland Hills, Los Angeles County, California, USA
    Posts
    9,648
    Rep Power
    4248
    Or you can cheat using system() to call morse, which comes with many unix systems ;).

    sprintf(cmd, "morse -s %d", words);
    system(cmd);

IMN logo majestic logo threadwatch logo seochat tools logo