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

Spinner Edge board

13

Comments

  • Updated version of software in the repo main branch.

    https://griswoldfx.visualstudio.com/Spinner Edge/_git/Software

  • OK,

    Your repo is somehow borked. Like before jm_nstr.spin2 is missing and jm_fullduplexserial.spin2 too.

    Is like that from the beginning. jm_fullduplexserial is not used, can be commented out jm_nstr.spin2 I have and could put in.

    Then it compiles. Like the older Versions it does not find the sd card, but commenting out the FAT32 stuff it starts.

    now it look like this:

    Cog0 Missing SD Card?
    Cog0 Can't mount FS
    Cog0 Missing SD Card?
    Cog0 Initialize Ethernet:$0
    Cog0 Chip Identification: $ff $6
    Cog0 Error: Wiznet W6100 NOT detected.

    can you maybe zip the working version on your own computer and attach here?

    Mike

  • I did not realize it was using jm_nstr.spin2. It was pulling it from the Propeller Tools library. That has been added to the repo. I have no idea why jm_fullduplexserial.spin2 was in there. I thought I had removed it. (Also being pulled from the library)

    I am concerned about it not finding the SD card. That's really strange. I will say that you can have problems if the SD card is mounted and you attempt to program flash. You will need to power cycle the SD card by removing it before you can program to flash. Programming to RAM works fine without any special considerations.

    Attached is a zip of what I am programming it with.

    BTW, your new board is on it's way. I will email you the tracking number.

  • OK, one step further, still with your new repo code, using SPI now works, but FAT32 not.
    Was Trying to replace FAT32 with FlexProps FileSystem.

    Lets try your current code

    Mike

  • msrobotsmsrobots Posts: 3,709
    edited 2023-03-26 22:57

    missing sd card

    Same SD works on Fat_Engine on P1.

    WTF?

    Mike

  • I have not tested on FlexProp. I will do that tonight.

    So, it can see the W6100 now?

  • different sd card, same problem.

    Now try different edge modul

    Mike

  • no luck with different edge, but TADA now running with SPI on EVAL rev B

    Mike

  • And running with parallel too, So the issue is the Edge's not your board

    I order a second one on your website, to pay for the second one you send.

    Might need it anyways.

    Mike

  • OK order 114 in and already send by you.

    Thanks

    Mike

  • Thanks Mike! Glad it is working for you! Thanks for pointing out the problems with DHCP and missing files with the repo. That kind of feedback really helps and I appreciate it.

    I will try the code with flexprop tomorrow evening. I just ran out of time tonight.

    --Terry

  • So my inital observations with flexprop:

    • The filesystem driver I use does not work with flexprop.
    • My W6100 driver only runs in SPI mode. Most likely a timing issue in parallel mode, though I don't know why. Returning $f6 $6 instead of $61 $00. Might be the pin inversion I use in parallel mode? Maybe? I suspect I will need to do that same for the CSn line in SPI mode. It just hasn't presented as a problem, as I have only used SPI in a single COG.
    • I tried all optimization levels to no avail.
    • I could get it to bypass the filesystem driver by commenting out my failure detection and it would deliver 404 pages.

    It might take more time to get it operating under flexprop than I have bandwidth for at the moment.

    I may utilize Chip's flash filsystem driver when it becomes available. I suspect that Eric will make flexprop compatible with Chips FS extensions from a spin2 perspective.

  • RaymanRayman Posts: 14,744
    edited 2023-04-02 19:04

    @ke4pjw Got your board working with your code. Glad to see it working.

    Modified you pin setting code a bit with a basepin:

      basepin = 8
      CLK   = basepin
      MOD   = basepin
      ADDR  = basepin+2 ADDPINS 1
      RSET  = basepin+7
      CSn   = basepin+1
      RDn   = basepin+5
      WRn   = basepin+6
    '  INTn  = 20  'Not used
      DATA  = basepin+8 ADDPINS 7
      DPINS = 24 / 8
      A0    = basepin+2
      A1    = basepin+3
    

    Didn't try your DNS yet, used the W5500 to get IP info...

    Tried to hack my W5500 code to make this work, but no joy.
    Think I'll assume the RP2040 code for W6100 works and start all over from that...

    Actually, guess I should update FlexProp first and make sure everything still works...

  • Glad you got it going with my code! I will incorporate your changes. That reminds me, I need to add INTn back into the codebase for this board. My code does not use it, but others may want to utilize it.

    --Terry

  • Terry,

    Can we get a board to Europe, Belgium?
    I can't select it on you webshop.

    Thanks

  • @Ltech I believe I can enable international shipping. Let me get up to speed on how to deal with VAT and customs declarations. It will take a few days. I only have 3 of these boards left in stock. I will be sure to hold one back for you. I will PM you when I get it setup.

    --Terry

  • @Ltech give it a try. I enabled international shipping. It ships at a flat rate. If you order multiple boards, I will combine them in shipping and refund the difference.

    Regards,
    Terry

  • LtechLtech Posts: 380
    edited 2023-04-06 19:14

    Ok done!
    I only take one of you precious stock this time

    Thank-you again

    Daniel

  • I updated the manual to include links to @Rayman 's port of the official Wiznet driver. I also updated it to reflect that SPI is now supported in the Griswold FX Spin 2 driver.

    https://www.griswoldfx.com/wp-content/uploads/2023/04/Spinner-Edge-Operation-Manual-V1.1.pdf

    Cheers!
    --Terry

  • LtechLtech Posts: 380
    edited 2023-04-25 20:54

    Terry,

    I just get you spinner edge.

    It do not work with you code. I assume the pins are wrong for a edge.

    in w6100driver you hard code on not standard breakout pins groups
    I have pin 0-7 and 8-15 or 16-23 and 24-31 on edge mini

    pin 0-7 and 8-15:

  • @Ltech
    Your pin assignments look correct.

    • Are you using Propeller Tool or some other compiler?
    • Do you have it configured for SPI or parallel in the top file?
    • Do you have the jumper installed or removed accordingly?
    • When you enable debug output, what do you get? Do you see "Wiznet W6100 detected" or something else?

    The default pins are 16-23 and 24-31. This board was tested on an Edge Mini.

    Thanks,
    Terry

    (I am traveling this week and won't be able to respond as quickly as I normally do)

  • It is working with my assignments

    But the pining in the soft is not the pining of you manual.
    You use default pins 16-23 and 24-31 But in the manual is written 0-7 and 8-15

    You hard coded the pins in the driver, witch is not usual for a driver in the propeller spin ecosystem.

    My question of the pining:

    -MOD constant function ? I put it to 0 like the Clock
    -The "DATA" and "PINS" contants can you explain the use ? For me this constants are the same

    I use propeller tool (spin tools give an error but no explanation why)
    I use the parallel mode
    I have the jumper

  • Ah, I see. In the Manual it shows P0-P15, whereas the code is actually P16-P31. I was attempting to make the written documentation port agnostic, by indicating the base pin as P0. I will note this difference in the manual. I may configure it for a single basepin in the software to completely remove potential typographical errors for the user.

    I am unsure what you mean by "hard coded". The pins are assigned in the constants section of the driver, not down in the code itself. If I have done that somewhere, please let me know where, so I can correct that. I know some drivers that have dedicated COGs will pass pin assignments as variables. However, there is no dedicated cog in my driver, with the exception of my E1.31 driver, which has code that is specific to the data structures used for Universe assignments and pixel information in the Blitzen 24. I doubt anyone would want to use that code. I may just pull it from the driver shipped for this board.

    So, it sounds as if you were able to get it on the network, yes?

    I may put some effort into figuring out why parallel mode doesn't work in FlexSpin and apparently the driver does not work in spintools.

    Thanks,
    Terry

  • LtechLtech Posts: 380
    edited 2023-04-27 19:06

    Hard coded,

    In the top spin you define the SD pins, the led pins, ip, mac, ... as expected
    So we expect to define the wiz pins in the top spin to.
    The wiz driver pins are best keep generic for use in different top spin programs.
    In a normal spin program you never define pins in an object file.

    This is only my opinion

    And yes I get you demo running wel
    Thank-you for this Wiz driver

  • You top spinneredge code works on "spin tools ide" after the 0.27 update

  • @Ltech said:
    You top spinneredge code works on "spin tools ide" after the 0.27 update

    Excellent! I need to circle back and see if it works with flexprop now.

  • ke4pjwke4pjw Posts: 1,169

    Good news everyone! I have had a couple of requests for more SpinnerEdge boards. Boards and parts have arrived and I will work up a batch of these this weekend hopefully. I will let you guys know when they are in my online store.

    Also, I am going to take some time and fix a known issue in the example web server. Files over 64K crash it. For some reason, I read the whole file into memory before sending it. This is some technical debt from the light controller project. Should be an easy fix.

    Regards,
    Terry

  • ke4pjwke4pjw Posts: 1,169

    A quick little hack fixed the 64K file limit issue, though a complete rewrite of the webserver needs to be done. I was able to download a 200MB MP4 file from the webserver as a test.

    You can download Version 1.4 from the link below.

    https://griswoldfx.visualstudio.com/Spinner Edge/_git/Software?path=/&version=GBVersion1.4

  • ke4pjwke4pjw Posts: 1,169

    Another bug found in the webserver. I do not check if the connection is reset while there is still data to be sent for the request. This was not apparent until I started sending very large requests, ones that I could cancel. Hopefully I will have a fix this evening.

  • ke4pjwke4pjw Posts: 1,169

    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
        else
          return False
    

    Repo is updated with 1.4.1

Sign In or Register to comment.