Shop OBEX P1 Docs P2 Docs Learn Events
New Unofficial OBEX — Parallax Forums

New Unofficial OBEX

I've taken on a little toy side project. It was brought up in another thread that the GitHub repository which replaces the OBEX isn't as friendly for downloading individual projects/objects as the original OBEX. It's not as easy to contribute, either, but I can't do anything about that.

I actually support and agree with Parallax's decision to retire the old OBEX and move to a monolithic GitHub repository for this, but I also understand that this new solution has some major drawbacks. And at least when it comes to downloading objects, I can do something to help.

So, please enjoy your first look at my unofficial OBEX: https://obex.zemon.name/
New names are welcome... I don't intend for this to be confused with anything officially hosted by Parallax.... but naming things isn't my strong suit ;)

Code is hosted here: https://github.com/DavidZemon/obex-parent
And as the README in that repository states, feature requests and bug reports are welcome; please submit them at https://github.com/DavidZemon/obex-parent/issues.

I've already opened four issues for enhancements which should drastically improve the experience and will be working on them soon.
It is my hopes that Parallax or someone else will take over maintenance and, at very least, hosting of this software in the future.

Anyone wishing to contribute is welcome to. Open a new ticket with the bug/feature you'd like to work on, or comment on an existing one, and we'll make it happen.
«1

Comments

  • Can I contribute to it? I wrote some P1 code for 433Mhz modules that transmits 0 to 255 and repeats. I'm using it for digital RC projects. I was hoping some users might find it useful and I wanted to share it with the community. I couldn't figure out how to add it to the Parallax GitHub repository.
  • It's just a frontend for the GitHub repository; it shows whatever's there. The only way to add something to it is to add it to the GitHub repository.

    @DavidZemon, have you thought about eventually adding an interface that would allow people to modify their own projects through your interface, which would require Parallax's support?
  • @DavidZemon, have you thought about eventually adding an interface that would allow people to modify their own projects through your interface, which would require Parallax's support?

    I have not thought about it, and there's not a whole lot I could or think I should do about it, unfortunately. I know submitting code to the GitHub repo is no where near as easy for those unfamiliar with Git as it was to upload a zip to the old OBEX, but there's very little that a third-party application can do to make that easier. I mean... I know what could be done, but it's a bad idea I wouldn't support it, nor do I think Parallax would either. The best I think any of us can hope for, is that Parallax start accepting submissions via email. At that point, I could stick a blurb at the top of the site that says "if you'd like to submit new code, please attach your code to an email directed at <EMAIL ADDRESS HERE>."
  • DavidZemon wrote: »
    @DavidZemon, have you thought about eventually adding an interface that would allow people to modify their own projects through your interface, which would require Parallax's support?

    I have not thought about it, and there's not a whole lot I could or think I should do about it, unfortunately. I know submitting code to the GitHub repo is no where near as easy for those unfamiliar with Git as it was to upload a zip to the old OBEX, but there's very little that a third-party application can do to make that easier. I mean... I know what could be done, but it's a bad idea I wouldn't support it, nor do I think Parallax would either. The best I think any of us can hope for, is that Parallax start accepting submissions via email. At that point, I could stick a blurb at the top of the site that says "if you'd like to submit new code, please attach your code to an email directed at <EMAIL ADDRESS HERE>."

    We accept object submissions by e-mail to developer@parallax.com. JonnyMac and a few others have used this method quite a bit, instead of wrestling with GitHub. We'll post 'em and David can make them accessible via his interface.

    Ken Gracey

  • I was actually just reading https://github.com/parallaxinc/propeller/wiki/Contributing at this very moment and noticed that :lol:
    Very convenient. And I'm adding a blurb to the top of the page now which says as much.
  • I think this is a positive development. It doesn't bother me that submitting is a bit more awkward, as it's always been a bit more awkward and well you have to create something before submitting it anyway. But if I am a user, and I just got $thing, and I want to know if there is a driver for my $thing, I just want to look for it and maybe then download $thing-driver. That was easy in the old Obex and it was by far the Obex's most important function as far as promoting development for the Propeller. If I can't quickly and easily find and then download $thing-driver odds are I will probably end up trying to hook it up to an Arduino.
  • Well... I was hoping to say "you can now preview files!" but... there are two GLARING issues that have cropped up. The first is that I'm apparently leaking some memory somewhere, and that has already caused my server (as in, the OS, not the HTTP server) to crash once. Ruh roh!

    So, since I plan to re-write this in Python anyway, I'm going to tackle that next. And, to prevent my server from crashing again, I'm taking the obex offline effective immediately. Hopefully it will come back up soon, with a shiny new Python backend. I will post back here when that does happen, at which point you'll be able to preview file contents as well.
  • David,

    I planned on showing your work at today's P2 Live Forum but I'm getting an access error when loading https://obex.zemon.name/ in Chrome.

    Ken Gracey
  • PublisonPublison Posts: 12,366
    edited 2020-08-06 18:59
    I also could not get to the site. "Timeout error"
  • Publison wrote: »
    I also could not get to the site. "Timeout error"

    Yep, sorry guys... I woke up this morning and discovered my server was hanging... completely frozen. Some memory leak ended up chewing through all the RAM. Since recovering from such an error is painful, and the error takes down a lot more than just this little app, I decided to disable it until I'm able to resolve the issue.

    Pretty sucky timing... sorry :(
    I could restart it real quick, in case it was still helpful... but there's a high probability of it crashing while you're using it, so it would be of limited usefulness.
  • Ken Gracey wrote: »

    We accept object submissions by e-mail to developer@parallax.com. JonnyMac and a few others have used this method quite a bit, instead of wrestling with GitHub. We'll post 'em and David can make them accessible via his interface.

    Ken Gracey

    Best answer.
  • DavidZemonDavidZemon Posts: 2,973
    edited 2020-08-07 03:45
    Okay.... that was infuriating, but it's done. Django/whitenoise does NOT play well with single page applications... I gave up and stuck an nginx server in front that proxies the client and server into a single domain.

    But, I am happy to say that the obex is back and I'm even happier to say that it is NOT eating all of my server's RAM anymore.

    First rendition of preview mode is live - you can click the little preview button next to any file to open a new browser tab with the file's contents. It assumes all files are text files, so don't bother trying to preview PDFs or images just yet.
  • dgatelydgately Posts: 1,631
    edited 2020-08-07 14:59
    David,

    On macOS, a .zip from the https://obex.zemon.name/ archive (in this case jm_i2c_scanner.zip) creates the following error:
    ~/Downloads/jm_i2c % ls
    README.md          jm_i2c.spin2       jm_i2c_scanner.zip
    altergator@MacBook-Pro ~/Downloads/jm_i2c % unzip jm_i2c_scanner.zip 
    Archive:  jm_i2c_scanner.zip
      End-of-central-directory signature not found.  Either this file is not
      a zipfile, or it constitutes one disk of a multi-part archive.  In the
      latter case the central directory and zipfile comment will be found on
      the last disk(s) of this archive.
    unzip:  cannot find zipfile directory in one of jm_i2c_scanner.zip or
            jm_i2c_scanner.zip.zip, and cannot find jm_i2c_scanner.zip.ZIP, period.
    

    The same file downloaded via git clone of the entire github-based repository (propeller), unzips without issue:
    jm_i2c % unzip jm_i2c_scanner.zip 
    Archive:  jm_i2c_scanner.zip
    PARALLAX INC PROPELLER 1 CHIP PROJECT ARCHIVE
    
    PROJECT: "jm_i2c_scanner"
    ARCHIVED: Wednesday, July 1, 2020 at 10:53:04 AM
    TOOL: Propeller Tool version 2.2.0.0 Alpha
      inflating: _README_.txt            
      inflating: jm_i2c_scanner.spin2    
    replace jm_i2c.spin2? [y]es, [n]o, [A]ll, [N]one, [r]ename: r
    new name: jm_12c.spin2.NEW
      inflating: jm_12c.spin2.NEW        
      inflating: jm_serial.spin2         
      inflating: jm_nstr.spin2
    

    The error shows up at a higher level UI as well:
    zipError.jpg

    dgately
    525 x 548 - 46K
  • Ah ha! Thank you for pointing this out.
    Turns out, this repo utilizes Git LFS, which I hadn't thought of. I've installed git-lfs on the server and initialized the objects - it's working now.
  • Works well for me, David - fast, easy to navigate, intuitive without any instructions too.

    Ken Gracey
  • Ken Gracey wrote: »
    Works well for me, David - fast, easy to navigate, intuitive without any instructions too.

    Ken Gracey

    Great to hear :smiley:
  • I'll get @"Jeff Martin" to put some eyes on this today, also.

    Ken Gracey
  • DavidZemon wrote: »
    Ah ha! Thank you for pointing this out.
    Turns out, this repo utilizes Git LFS, which I hadn't thought of. I've installed git-lfs on the server and initialized the objects - it's working now.
    Works now!

    Thanks

  • Question for the masses: Should the file preview be

    1. Opened in a new tab, displayed by my own app, as it is at the time of this post
    2. Opened in a modal window in the current tab (should load MUCH faster, but make it more difficult to do side-by-side comparisons of files)
    3. Link to the corresponding file on GitHub.com (very little work on my part to make this happen, and we automatically get a nice text editor, image/pdf/etc viewing.. only downside is that it could be a bit "jarring" to switch websites and it will be slower than the modal window option)
  • I prefer it to open the file on github, but I also am used to github and know it well enough, so I am biased.
    perhaps an option to choose between that and your own thing?
  • I would display the file in a model when you normally click it and open on github when you try to open in new tab - I think that can be done somehow
  • Wuerfel_21 wrote: »
    I would display the file in a model when you normally click it and open on github when you try to open in new tab - I think that can be done somehow

    I'm not aware of any such feature... but alternatively, I could use the "open_in_new" icon and "open_in_full" icon to do both... in what I hope would be a more clear fashion.
  • OK, still not entirely happy, though this is a big step foreward probably easily improved.

    Let us say I am a n00b and what I want is say, oh, a 40x18 VGA text driver such as some person *cough* may have once written for the P1. At the top level I see docs, libraries, and resources, and a few other things that make no sense.

    Docs is a rabbithole that has nothing to do with what I want.

    Resources is a rabbithole that has nothing to do with what I want.

    So I try libraries. Below that is community and official. Each has a p1 and p2 subfolder. In which one is my 40x18 driver that some guy wrote way back when?

    Turns out "official" just has a readme placeholder.

    "Community" has all the categories I know and remember from the old OBEX. Hey, is that "display?"

    Okay, I have found my driver. But there are a few extra steps there that shouldn't be necessary and aren't obvious if you don't know where you are going.

    This is a lot better than the raw github link, but please still fix it the rest of the way.

  • Okay... updated to add three buttons. Preview is now moved into a modal, and the extra button will bring you to GitHub. Images and PDFs can also now be previewed.
  • DavidZemonDavidZemon Posts: 2,973
    edited 2020-08-08 03:10
    localroger wrote: »
    OK, still not entirely happy, though this is a big step foreward probably easily improved.

    Let us say I am a n00b and what I want is say, oh, a 40x18 VGA text driver such as some person *cough* may have once written for the P1. At the top level I see docs, libraries, and resources, and a few other things that make no sense.

    Docs is a rabbithole that has nothing to do with what I want.

    Resources is a rabbithole that has nothing to do with what I want.

    So I try libraries. Below that is community and official. Each has a p1 and p2 subfolder. In which one is my 40x18 driver that some guy wrote way back when?

    Turns out "official" just has a readme placeholder.

    "Community" has all the categories I know and remember from the old OBEX. Hey, is that "display?"

    Okay, I have found my driver. But there are a few extra steps there that shouldn't be necessary and aren't obvious if you don't know where you are going.

    This is a lot better than the raw github link, but please still fix it the rest of the way.

    I hear you... loud and clear. I've already been thinking about this, and what can be done to resolve it. One option is that I just scrape all of the categories and objects, and then build out a completely custom UI that allows browsing/downloading (don't get your hopes up for search... unless you intend to offer up a pull request). This would be cool because finding the object(s) you're looking for would be easy, but it would be a step in a very different direction (because it's no longer just a "view in the git repo"). If I go that route, I could even forgo the separate folders for official/community, and instead display little "stickers" on each object indicating whether it's a "official" or not.

    Of course, the more complicated this application gets (and let me be very clear, this kind of custom UI would be an entirely new level of complexity), the less likely it is that Parallax will be interesting/willing/able to maintain it in the future. Perhaps a simpler solution is to consider the "libraries" folder to be the root. That would make it much faster to find what you're looking for. @localroger, I'm sure you'd find that to be an improvement. What's everyone else think?
  • "Libraries" as root would go a long way toward making it more discoverable. Or even a fixed text page header explaining to a new user where to go for whatever.

    I'm not so concerned with search. It would have seemed awkward when the Obex first came out but now you can just let the browser load all the objects in a category; OK so there are a thousand of them, big deal. Then use the browser search in page to look for VGA or HX711 or whatever you might be interested in.
  • @localroger, I have forgotten your request. Working out the details of how to go about making libraries as root (technically, yes it's easy, but there was another UX issue that cropped up)

    It was a good weekend. I added the ability to preview the markdown files as rendered markdown, instead of the raw markdown text. On top of that, and quite crucially I think, I added the ability to browse symlinks and preview/download individual files. You can not download the entire folder when that folder is a symlink (for instance, you can not download "libraries/community/p1/Data Storage/symlink/Heap"... but I'll get that fixed soon :smile:. The links/buttons to preview, open a file in GitHub, and download all do work, even for files under symlinks.

    I think I'm going to add a completely new view to the site - one that doesn't use expandable trees, but rather multiple "page loads" like GitHub. This should be easier/faster to navigate on a phone. I'll then provide two "tabs" at the top of the page so that anyone on a desktop wishing to get the browsable tree can still do so. The multi-page view will be the default tab, since it would ruin the performance benefit on mobile platforms otherwise :tongue:.
  • The page is currently providing an "undefined" link when you clock on the "Open Preview" icon of any text-based file.

    Screen%20Shot%202020-08-10%20at%209.02.38%20AM.pngScreen%20Shot%202020-08-10%20at%209.03.30%20AM.png

    dgately
  • DavidZemonDavidZemon Posts: 2,973
    edited 2020-08-10 16:12
    Something else is going on here... you should see the contents of that file under the filename and dismiss button. See my screenshot:

    Screenshot%20from%202020-08-10%2011-10-43.png

    Can you check your browser's console logs? Perhaps there's a hint there. I'm not seeing any error's on the server-side logs.
  • dgatelydgately Posts: 1,631
    edited 2020-08-10 16:24
    David...

    I attached a zip of the errors that Safari finds. I'll test with FireFox & Chrome, soon!

    UPDATE: FireFox & Google Chrome have no issues on the page!

    Safari debug shows: Err-Screenshot.png
Sign In or Register to comment.