6502.org
http://forum.6502.org/

Wincupl Error Codes
http://forum.6502.org/viewtopic.php?f=10&t=7553
Page 1 of 1

Author:  programmingbasic [ Tue Mar 28, 2023 11:00 pm ]
Post subject:  Wincupl Error Codes

I am having 13 warnings and 0 errors shown when I try to compile this code for an atf16v8c project for school. This is my first time ever using wincupl so any feedback is appreciated. I also get a run time error 35602 after the compile has failed if that helps narrow it down. I have put the code below if someone doesn't mind looking through it. Thank you in advance...




/* *************** INPUT PINS *********************/
PIN 1 = x3 ; /*BCD Input */
PIN 2 = x2 ; /* */
PIN 3 = x1 ; /* */
PIN 4 = x0 ; /* */

/* *************** OUTPUT PINS *********************/
PIN 19 = a ; /*Seven Segment Output */
PIN 18 = b ; /* */
PIN 17 = c ; /* */
PIN 16 = d ; /* */
PIN 15 = e ; /* */
PIN 14 = f ; /* */
PIN 13 = g ; /* */

a = !x3 & !x2 & !x1 & !x0
# !x3 & !x2 & x1 & !x0
# !x3 & !x2 & x1 & x0
# !x3 & x2 & !x1 & x0
# !x3 & x2 & x1 & !x0
# !x3 & x2 & x1 & x0
# x3 & !x2 & !x1 & !x0
# x3 & !x2 & !x1 & x0 ;

b = !x3 & !x2 & !x1 & !x0
# !x3 & !x2 & !x1 & x0
# !x3 & !x2 & x1 & !x0
# !x3 & !x2 & x1 & x0
# !x3 & x2 & !x1 & !x0
# !x3 & x2 & x1 & x0
# x3 & !x2 & !x1 & !x0
# x3 & !x2 & !x1 & x0 ;

c = !x3 & !x2 & !x1 & !x0
# !x3 & !x2 & !x1 & x0
# !x3 & !x2 & x1 & x0
# !x3 & x2 & !x1 & !x0
# !x3 & x2 & !x1 & x0
# !x3 & x2 & x1 & !x0
# !x3 & x2 & x1 & x0
# x3 & !x2 & !x1 & !x0
# x3 & !x2 & !x1 & x0 ;

d = !x3 & !x2 & !x1 & !x0
# !x3 & !x2 & x1 & !x0
# !x3 & !x2 & x1 & x0
# !x3 & x2 & !x1 & x0
# !x3 & x2 & x1 & !x0
# x3 & !x2 & !x1 & !x0
# x3 & !x2 & !x1 & x0 ;

e = !x3 & !x2 & !x1 & !x0
# !x3 & !x2 & x1 & !x0
# !x3 & x2 & x1 & !x0
# x3 & !x2 & !x1 & !x0 ;

f = !x3 & !x2 & !x1 & !x0
# !x3 & x2 & !x1 & !x0
# !x3 & x2 & !x1 & x0
# !x3 & x2 & x1 & !x0
# x3 & !x2 & !x1 & !x0
# x3 & !x2 & !x1 & x0 ;

g = !x3 & !x2 & x1 & !x0
# !x3 & !x2 & x1 & x0
# !x3 & x2 & !x1 & !x0
# !x3 & x2 & !x1 & x0
# !x3 & x2 & x1 & !x0
# x3 & !x2 & !x1 & !x0
# x3 & !x2 & !x1 & x0 ;

Author:  gfoot [ Wed Mar 29, 2023 1:03 am ]
Post subject:  Re: Wincupl Error Codes

Are you running this through the command line, or the GUI? If the latter, could you post the output?

Did you strip off the headers at the top of your file as well, or are they missing in your original file?

Aside from the missing headers the code looks OK to me in principle, though there are some language features that you could learn which would make it easier to write and cleaner - especially "Field".

Author:  BigEd [ Wed Mar 29, 2023 7:00 am ]
Post subject:  Re: Wincupl Error Codes

(Welcome, programmingbasic)

I get the impression that WinCUPL is quite fragile and quite unforgiving, but that it will work if the input is in exactly the right form. So, your predicament is not unexpected! I hope others can help - but as gfoot says, it's best if you share all your input and output. Preferably, use Code blocks for your code when posting, to help the formatting.
Code:
code here

Author:  GARTHWILSON [ Wed Mar 29, 2023 7:29 am ]
Post subject:  Re: Wincupl Error Codes

BigEd wrote:
Preferably, use Code blocks for your code when posting, to help the formatting.

Yes; put  [code]  and  [/code]  around the code as book ends, and it will look like this:
Code:
/* *************** INPUT PINS *********************/
PIN     1 = x3 ; /*BCD Input                      */
PIN     2 = x2 ; /*                               */
PIN     3 = x1 ; /*                               */
PIN     4 = x0 ; /*                               */

/* *************** OUTPUT PINS ********************/
PIN     19 = a ; /*Seven-Segment Output           */
PIN     18 = b ; /*                               */
PIN     17 = c ; /*                               */
PIN     16 = d ; /*                               */
PIN     15 = e ; /*                               */
PIN     14 = f ; /*                               */
PIN     13 = g ; /*                               */

        a = !x3 & !x2 & !x1 & !x0
          # !x3 & !x2 &  x1 & !x0
          # !x3 & !x2 &  x1 &  x0
          # !x3 &  x2 & !x1 &  x0
          # !x3 &  x2 &  x1 & !x0
          # !x3 &  x2 &  x1 &  x0
          #  x3 & !x2 & !x1 & !x0
          #  x3 & !x2 & !x1 &  x0 ;
         
        b = !x3 & !x2 & !x1 & !x0
          # !x3 & !x2 & !x1 &  x0
          # !x3 & !x2 &  x1 & !x0
          # !x3 & !x2 &  x1 &  x0
          # !x3 &  x2 & !x1 & !x0
          # !x3 &  x2 &  x1 &  x0
          #  x3 & !x2 & !x1 & !x0
          #  x3 & !x2 & !x1 &  x0 ;

        c = !x3 & !x2 & !x1 & !x0
          # !x3 & !x2 & !x1 &  x0
          # !x3 & !x2 &  x1 &  x0
          # !x3 &  x2 & !x1 & !x0
          # !x3 &  x2 & !x1 &  x0
          # !x3 &  x2 &  x1 & !x0
          # !x3 &  x2 &  x1 &  x0
          #  x3 & !x2 & !x1 & !x0
          #  x3 & !x2 & !x1 &  x0 ;

        d = !x3 & !x2 & !x1 & !x0
          # !x3 & !x2 &  x1 & !x0
          # !x3 & !x2 &  x1 &  x0
          # !x3 &  x2 & !x1 &  x0
          # !x3 &  x2 &  x1 & !x0
          #  x3 & !x2 & !x1 & !x0
          #  x3 & !x2 & !x1 &  x0 ;

        e = !x3 & !x2 & !x1 & !x0
          # !x3 & !x2 &  x1 & !x0
          # !x3 &  x2 &  x1 & !x0
          #  x3 & !x2 & !x1 & !x0 ;

        f = !x3 & !x2 & !x1 & !x0
          # !x3 &  x2 & !x1 & !x0
          # !x3 &  x2 & !x1 &  x0
          # !x3 &  x2 &  x1 & !x0
          #  x3 & !x2 & !x1 & !x0
          #  x3 & !x2 & !x1 &  x0 ;

        g = !x3 & !x2 &  x1 & !x0
          # !x3 & !x2 &  x1 &  x0
          # !x3 &  x2 & !x1 & !x0
          # !x3 &  x2 & !x1 &  x0
          # !x3 &  x2 &  x1 & !x0
          #  x3 & !x2 & !x1 & !x0
          #  x3 & !x2 & !x1 &  x0 ;

And welcome.

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/