Shop OBEX P1 Docs P2 Docs Learn Events
OBEX code samples — Parallax Forums

OBEX code samples

infoinfo Posts: 31
edited 2014-04-01 15:05 in General Discussion
What do you use to open the files in OBEX? Notepad, Wordpad or browser displays continuous block of text impossible to read. Somehow the code sample formatting got lost on OBEX.

Comments

  • Beau SchwabeBeau Schwabe Posts: 6,566
    edited 2014-04-01 07:23
    You should be able to read most of the code with the Propeller IDE.

    Propeller IDE software:
    http://www.parallax.com/downloads/propeller-tool-software
  • PublisonPublison Posts: 12,366
    edited 2014-04-01 07:33
    Welcome to the forums info!

    If you are having a problem where the file in the OBEX shows up as a .SPIN file, select all, then paste it in the Propeller Tool that Beau linked to.

    Somehow the OBEX got broken where it just displays a SPIN file instead of downloading it. ZIP file should download correctly.
  • ratronicratronic Posts: 1,451
    edited 2014-04-01 07:55
    Info if you are using Windows try right clicking on the Spin file or zip file you want to save and click "Save target as" and enter the filename.spin or filename.zip and hit enter.
  • PublisonPublison Posts: 12,366
    edited 2014-04-01 08:02
    ratronic wrote: »
    Info if you are using Windows try right clicking on the Spin file or zip file you want to save and click "Save target as" and enter the filename.spin or filename.zip and hit enter.

    Forgot, that works too! :)
  • infoinfo Posts: 31
    edited 2014-04-01 13:23
    You should be able to read most of the code with the Propeller IDE.

    Propeller IDE software:
    http://www.parallax.com/downloads/propeller-tool-software


    Sorry for being pest, but I can not make it happen. When I click on file it opens in browser as block of text. When I right-click, it wants to save as html (not spin). When I open the saved file in the Propeler Tool, it is the same block of text on light yellow background.

    So much for learning programming. No go. I wonder why do we jump on new "improved" things like html 5 and other programs that just crash in older browser and display differently in every brand or make of browser. What can html 5 do better for a website than html 3 or 4? OK, that's kinda unrelated to my problem, I'm just venting frustration, but I'm on world's biggest manufacturer of SBC website and I can't open simple text file. That's not good. I really wanted to use the Propeler chip in a design for simple reason. It is programmable in 3 languages, Assembly, Spin and FemtoBasic. That's hard to beat. (If I just could read the sample programs and learn something).
  • PublisonPublison Posts: 12,366
    edited 2014-04-01 13:31
    Take for example, if you go to http://obex.parallax.com/object/73

    right click on the SPIN file in the OBEX and "save link as", select the destination and it will save it as a SPIN file.

    I will put another log on the fire for Parallax to fix that. Stick with us, we will get it done.
  • ratronicratronic Posts: 1,451
    edited 2014-04-01 14:38
    Info most people here would tell you to use the right browser(?). But you can save the files as Publison shows above but you have to type in the filename.spin or the filename.zip before you save.

    Then it will save the html file as .spin or .zip that can be used.
    .
  • NWCCTVNWCCTV Posts: 3,629
    edited 2014-04-01 14:47
    Are you using IE 11? I have had this same issue ever since installing IE 11 so I just use Chrome for downloads now.
  • infoinfo Posts: 31
    edited 2014-04-01 15:05
    Thanks to all of you guys. Yes, with right-clicking, renaming file and opening it in Parallax Tools I was able to see spin code the way it was written. Wow. Shouldn't computers do all that work?

    Now I just need to delete all the code samples I saved and download them using the 3-step process. The funny thing is that all this code is already in the Propeler's ROM, but there are no hooks to use it. If I remember correctly, DOS had the feature. BIOS calls that were fully documented, so the programmer was able to optimize program to fit on 512 byte floppy disk sector and use BIOS calls to make nearly impossible and unbelievable tricks. Today even reading and writing the i2c eeprom requires lot of code. That's where the OBEX samples are real life saver.



    Publison wrote: »
    Take for example, if you go to http://obex.parallax.com/object/73

    right click on the SPIN file in the OBEX and "save link as", select the destination and it will save it as a SPIN file.

    I will put another log on the fire for Parallax to fix that. Stick with us, we will get it

    done.
Sign In or Register to comment.