C program compile error


Results 1 to 2 of 2

Thread: C program compile error

  1. #1
    Registered
    Join Date
    Oct 2010
    Location
    USA
    Posts
    61
    Downloads
    0
    Uploads
    0

    Angry C program compile error

    When I try to compile my C program I get this error at the first line:

    C:\Mach3\PlugIns\InitStepDir3Axis.c:1: ';' expected

    All of the lines already end with a semicolon.

    I've attached the code for reference.

    Thanks,
    Dennis

    Similar Threads:
    Attached Files Attached Files


  2. #2
    Registered
    Join Date
    Oct 2010
    Location
    USA
    Posts
    61
    Downloads
    0
    Uploads
    0

    Default

    I figured it out. Newbie issue. I was missing the header for the includes and the function main.

    For other newb's that stumble across this issue. The .c program is in fact a full on C program, which is a very good thing. You can do a tremendous amount in C.


    If your getting the error that I had in my original post about missing a semicolon in the first line, make sure you have the following in your program at a minimum.


    #include "KMotionDef.h"

    main()
    {

    ..... Your code goes here .....

    }



    I've attached the InitStepDir3Axis file with the correction to this post. If you look at the InitStepDir3Axis file attached to the previous post and the one attached to this post you can see the difference.

    Hope this help someone,

    Dennis

    Attached Files Attached Files
    Last edited by nova24; 01-31-2012 at 07:09 PM. Reason: grammer


Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


About CNCzone.com

    We are the largest and most active discussion forum for manufacturing industry. The site is 100% free to join and use, so join today!

Follow us on


Our Brands

C program compile error

C program compile error