Shop Learn P1 Docs P2 Docs Events
Spin Tools IDE - Page 6 — Parallax Forums

Spin Tools IDE

12346»

Comments

  • Found an issue I don't believe found. A constant referencing another constant from a child object can't find the symbol in that child object. Example below.

    TestA.spin2

    CON
      _xtlfreq                      = 20_000_000
      _clkfreq                      = 20_000_000
    
      ' works
      #0
        ENUM1_VAL_A
        ENUM1_VAL_B
        ENUM1_VAL_NEXT
    
      #ENUM1_VAL_NEXT ' <- technical
        ENUM2_VAL_C
        ENUM2_VAL_D
    
      ' doesn't work
      '#child.ENUM_VAL_NEXT ' <----- "symbol 'child.ENUM_VAL_NEXT' not found!"
      '      ENUM2C_VAL_A
    
    OBJ
      child:         "TestB"
    
    PUB Main()
      debug(udec(child.ENUM_VAL_A))
      debug(udec(child.ENUM_VAL_B))
      debug(udec(ENUM2C_VAL_A))
    

    TestB.spin2

    CON
      #0
            ENUM_VAL_A
            ENUM_VAL_B
            ENUM_VAL_NEXT
    
    PUB TLO()
      ABORT
    

    It isn't completely crazy to do something like this. I have low-level general abort codes (timeout, argument invalid, etc.) but a library can extend them for library-specific codes. e.g., my I2C library would extend the codes for I2C-y things like early NACK. Verified in Propeller Tool can pull from child objects.

  • maccamacca Posts: 563

    @"Greg LaPolla" said:

    @macca said:
    A link to the source ?

    Forum link : https://forums.parallax.com/discussion/175121/p2gui-framework
    Source link: https://github.com/jrullan/P2GUI

    Downloaded your source, there are a number of object file names with mixed cases, after fixing that, there are still some syntax errors where you use the object method pointers. They are caused by a little mistake in the compiler and can be worked-around by adding the round parentheses like a method call, @button[MODE_BTN].set_enable -> @button[MODE_BTN].set_enable(), will be fixed in the next release.

    After that I don't see other errors, of course I can't check the functionality.

  • maccamacca Posts: 563

    @JonnyMac said:
    The only thing missing for me is the "blob/block select" (Alt + drag-select) in Propeller Tool. I have found this in other editors, too, and make use of it. Not a deal-breaker at all, but a really nice-to-have.

    The widget I'm using as text editor supports the block selection, however it is a toggle so it needs a button somewhere and/or a keyboard shortcut to enable/disable it.
    Using Alt+drag, or something like that to detect the action, doesn't seems possible.

  • @macca said:

    Downloaded your source, there are a number of object file names with mixed cases, after fixing that, there are still some syntax errors where you use the object method pointers. They are caused by a little mistake in the compiler and can be worked-around by adding the round parentheses like a method call, @button[MODE_BTN].set_enable -> @button[MODE_BTN].set_enable(), will be fixed in the next release.

    After that I don't see other errors, of course I can't check the functionality.

    Not my code. I am just using it. I will let the code owner know. Kinda weird that it compiles on propeller tool missing the parens.

  • maccamacca Posts: 563

    Released version 0.24.

    I have finally managed to update the Spin2 interpreter. This was a bit more difficult than expected because new bytecodes were added in the middle of existing bytecodes causing a partial renumber so I needed to update all my references. The libraries and examples binaries matches those produced by PNut so I hope to have updated all locations.

    The new interpreter allowed me to add a startup delay using the locations used to write the clock frequency to the debug rx pin. These locations are used only when the debug is enabled, without the debugger they should be filled with NOPs, instead I'm injecting a waitx instruction to delay the startup by 100ms. This will work-around the serial startup issue with the terminal.

    • Interpreter and debugger updated to 2022.11.19 (PNut v38)
    • Implemented ^@ and FIELD operators
    • Optional use of clock setter code for PASM-only programs (instead of asmclk)
    • MacOS system menu should now work for Preferences and About dialogs
    • Updated content assist and method documentation hover to handle pointers
    • Added block selection toggle to Edit menu
    • Preferences moved to Edit menu (from File)
    • PTRx registers can now be used in expressions
    • A number of fixes for the reported issues

    Last but not least, the code is now published on GitHub, along with a Ko-Fi link for those who want to help the development with some contributions.

  • LtechLtech Posts: 330

    Macca, I love you tool!

    Fails on automatic update .23 to .24

    And Work on manual update :) Menu's are as expected on osx.

  • maccamacca Posts: 563

    @Ltech said:
    Macca, I love you tool!

    Thank you!

    Fails on automatic update .23 to .24

    That's weird, it worked with Linux and Windows, hope it was just a glitch with the download.

    And Work on manual update :) Menu's are as expected on osx.

    Good!

  • Greg LaPollaGreg LaPolla Posts: 301
    edited 2023-03-06 17:23

    I get the same error on my mac.

    Here is the error:

    /Applications/Spin Tools IDE.app/Contents/Java/lib/spin-tools-0.23.0.jar: Archive entry cannot be linked to a file in the configuration

  • maccamacca Posts: 563

    @"Greg LaPolla" said:
    I get the same error on my mac.

    Here is the error:

    /Applications/Spin Tools IDE.app/Contents/Java/lib/spin-tools-0.23.0.jar: Archive entry cannot be linked to a file in the configuration

    I really don't know what I've changed to break the update, since it works on Linux and Windows.
    The weird thing is that it shows with the download, while the actual update is done at program startup (that's why it needs to be restarted).

    Now I wonder why it worked with the previous releases...

  • dgatelydgately Posts: 1,579

    Here's the full Java error output on macOS:

    java.lang.IllegalStateException: /Applications/Spin Tools IDE.app/Contents/Java/lib/spin-tools-0.23.0.jar: Archive entry cannot be linked to a file in the configuration
        at org.update4j.Archive.lambda$load$2(Archive.java:88)
        at java.base/java.util.Optional.orElseThrow(Optional.java:403)
        at org.update4j.Archive.lambda$load$3(Archive.java:88)
        at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197)
        at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197)
        at java.base/java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:179)
        at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197)
        at java.base/java.util.Iterator.forEachRemaining(Iterator.java:133)
        at java.base/java.util.Spliterators$IteratorSpliterator.forEachRemaining(Spliterators.java:1921)
        at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509)
        at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499)
        at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:921)
        at java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
        at java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:682)
        at org.update4j.Archive.load(Archive.java:90)
        at org.update4j.Archive.read(Archive.java:40)
        at classpath//com.maccasoft.propeller.SpinTools$68.run(SpinTools.java:2399)
        at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:122)
    

    dgately

  • LtechLtech Posts: 330

    Perhaps you make to big changes for OSX menu's ....

    I just install the experimental version manually, and all is fine.

    The update from .22 to .23 go fine on OSX.

  • maccamacca Posts: 563

    While waiting for the next Eclipse/SWT release that should fix the file dialog last accessed path issue, I started to experiment with additional languages integration:

    Still at the early stages and don't know how far it will get but it is something...

  • LtechLtech Posts: 330

    Just mention: update to Spin Tools IDE 0.24.1 working on OSX

  • LtechLtech Posts: 330

    Macca, this give error on spin tools, but compile on others.

  • Upgrade worked for me. The app doesn't restart though. It shut down but did not start back up.

  • maccamacca Posts: 563

    @Ltech said:
    Macca, this give error on spin tools, but compile on others.

    NR in that specific case can be avoided since it is the default, nevertheless effects were not handled for the hub instructions. Will be fixed in the next release.

  • I'm a little slow to the game here, but I was able to install Spin Tools IDE 0.24.1 easily on MacOS 10.15.7 and get it up and running just fine after updating to JDK 19.0.2.

    Thank you, @macca for the effort you're putting into this IDE.
    Paul

Sign In or Register to comment.