Shop OBEX P1 Docs P2 Docs Learn Events
Spinner Edge board - Page 4 — Parallax Forums

Spinner Edge board



  • AribaAriba Posts: 2,682

    @ke4pjw said:
    Such a simple little fix. I created a new method to see if the socket was disconnected. I just check it after every packet is sent in a TCP connection. If it returns True, close your file and open the listener again.

    pub isdisconnected(socket) : rtv
        if (readreg(REG_Sn_IR,socket,1,@REGBUFFER) & Sn_IR_DISCON) == Sn_IR_DISCON
          return True
          return False

    Repo is updated with 1.4.1

    You can simplify this to:

    pub isdisconnected(socket) : rtv
        return readreg(REG_Sn_IR,socket,1,@REGBUFFER) & Sn_IR_DISCON == Sn_IR_DISCON

    In Spin the result of a comparison operator is True or False

  • ke4pjwke4pjw Posts: 1,079

    I did not know you could do that. Cool!

  • ke4pjwke4pjw Posts: 1,079

    I have found an issue where shared hubram between cogs can cause issues with the W6100dvr.spin2 driver. This appears to be obvious now, but never manifested itself as a bug until recent testing revealed it. Specifically, these relate to the following variables:

    REGBUFFER - Fixed
    TX_WR - Fixed
    RX_RD - Open
    RX_RSR - Open

    Fix is incoming shortly. It will not require any user code to be changed, just the W6100dvr.spin2 file needs to be updated.


  • ke4pjwke4pjw Posts: 1,079

    Sorry for the delay in posting this update. Version 1.5 has been released and resolves the issue of corruption of data when multiple cogs access the W6100.

    Let me know if it causes you any issues.


Sign In or Register to comment.