HEADS-project / training

Training material to get started with the HEADS technologies
10 stars 16 forks source link

When compiling CPrinter.thingml in tutorial step 3. compiler generates error #1

Closed kehusa closed 9 years ago

kehusa commented 9 years ago

Compiling with "C/C++ for Linux / Posix" (Platform: posix) Selected input file: L/Tutorial/ThingML_Basics/3.PlatformPrint/_c/CPrinter.thingml (C:\Users\KnutEilif\HeadsIde\workspace\Tutorial\ThingML_Basics\3.PlatformPrint_c\CPrinter.thingml) ERROR: The selected model contains errors: file:/C:/Users/KnutEilif/HeadsIde/workspace/Tutorial/ThingML_Basics/3.PlatformPrint/_c/CPrinter.thingml : Unable to load model with uri: ../CustomPrint.thingml cause: java.io.FileNotFoundException: C:\Users\KnutEilif\HeadsIde\workspace\Tutorial\ThingML_Basics\3.PlatformPrint\CustomPrint.thingml (The system cannot find the file specified) file:/C:/Users/KnutEilif/HeadsIde/workspace/Tutorial/ThingML_Basics/3.PlatformPrint/_c/CPrinter.thingml : Cannot resolve thing CustomPrinter file:/C:/Users/KnutEilif/HeadsIde/workspace/Tutorial/ThingML_Basics/3.PlatformPrint/_c/CPrinter.thingml : Cannot resolve port Print file:/C:/Users/KnutEilif/HeadsIde/workspace/Tutorial/ThingML_Basics/3.PlatformPrint/_c/CPrinter.thingml : Cannot resolve message customPrint file:/C:/Users/KnutEilif/HeadsIde/workspace/Tutorial/ThingML_Basics/3.PlatformPrint/_c/CPrinter.thingml : Cannot resolve receive message(event) parameter: myString file:/C:/Users/KnutEilif/HeadsIde/workspace/Tutorial/ThingML_Basics/3.PlatformPrint/_c/CPrinter.thingml : Cannot resolve thing CustomPrinterClient file:/C:/Users/KnutEilif/HeadsIde/workspace/Tutorial/ThingML_Basics/3.PlatformPrint/_c/CPrinter.thingml : Cannot resolve port Print file:/C:/Users/KnutEilif/HeadsIde/workspace/Tutorial/ThingML_Basics/3.PlatformPrint/_c/CPrinter.thingml : Cannot resolve port Print Compilation stopped.

brice-morin commented 9 years ago

OK, I'll investigate the problem

brice-morin commented 9 years ago

OK, the fix is simple, you need to import "../CustomPrinter.thingml" instead of import "../CustomPrint.thingml"

I will update the repository

brice-morin commented 9 years ago

Note that the wrong import should have been reported as an error in the HEADS IDE and higlighted in red if you open the file with the ThingML editor. If that was not the case, you can open another issue on error reporting.