Shop OBEX P1 Docs P2 Docs Learn Events
output to a Windows file? — Parallax Forums

output to a Windows file?

rjo_rjo_ Posts: 1,825
edited 2007-09-05 10:27 in Propeller 1
You guys!!!

The problem for us mere mortals is that sometimes the obvious is not so obvious.

This is not a metaphorical request... I am actually working on a one pixel camera. And to make it cheap, I'm going to use a pinhole.

The final image will be ordered samples from the camera.


My problem? I need to write to an ascii formatted raw data file to a fixed file location on my Windows machine.


Thanks

Rich

Comments

  • Kevin WoodKevin Wood Posts: 1,266
    edited 2007-07-01 18:13
    >>> My problem? I need to write to an ascii formatted raw data file to a fixed file location on my Windows machine. <<<

    What part are you having trouble with?
  • Graham StablerGraham Stabler Posts: 2,507
    edited 2007-07-01 18:50
    Well you could use serial via the programming interface but you will need to write a windows program to receive the data and make the file.

    You didn't mention if you were familiar with any programming languages for windows but you would need to look into implementing a serial link with the one you were comfortable with, often you can download libraries for this functionality.

    To get started why not try:

    www.parallax.com/html_pages/downloads/software/software_plxdaq.asp

    It will allow you to get data from the propeller into an excel spreadsheet.

    Graham
  • Harrison.Harrison. Posts: 484
    edited 2007-07-01 20:09
    You could use the fat16 object + an sd card to write your file to an sd card then plug that into your computer. I am also working on a camera (although its a bit higher res than 1 pixel at a time, at 640x480 color) and I am streaming the images to a sd card with no problems. I wrote a vb.net program to capture a serial stream and build an image, but it took way more work then just a simple sd card (which is amazingly fast compared to serial).
  • AribaAriba Posts: 2,685
    edited 2007-07-01 23:41
    You could use PropTerminal for that. Use PC_Text.spin as driver, and send first character 0 (Zero) and then your ASCII-data.
    When the whole file is arrived you can save the Data with "Save Text" in the file-menu. PropTerminal limits a received Text-file to 32kByte.

    Andy
  • rjo_rjo_ Posts: 1,825
    edited 2007-07-02 06:29
    Kevin...all of it. Not a clue.

    Graham... I am/was a Mac guy... Pascal, Java, AppleScript, Basic and one or two words in a variety of other languages. When it comes to Windows, I should probably stick to Basic. I saw PLX but then I need Excel... but that might make it scriptable too! If we can export automatically to Excel and turn our Props into an 80Mhz Scope ... why can't we export data to a plain old text file?

    Harrison... "Necessity is the mother of invention"... but laziness is the path to genius. Hurry up already with your camera[noparse]:)[/noparse]
    Is there such a thing as a dual ported sd card that could be written by my Prop... but simultaneous available for reading by my Windows machine?

    I want to automate the process. There is a public domain image processing program (ImageJ by Wayne Rasband at NIH). I can point ImageJ at just about any kind of image file... including RAW and text files and make it do just about anything.

    ANDY!!!! That's almost enough... BUT can I automate the process (so that I don't have to physically choose a file-menu item).
    I saw a comment (too old to remember exactly which thread) about sending key equivalents... can the PropTerminal be driven by some kind of macro?

    Thanks everybody.

    Rich

    Once I get this done... I'm planning to upgrade my camera to two pixels[noparse]:)[/noparse]
  • Graham StablerGraham Stabler Posts: 2,507
    edited 2007-07-02 09:27
    rjo_ said...
    Kevin...all of it. Not a clue.

    If we can export automatically to Excel and turn our Props into an 80Mhz Scope ... why can't we export data to a plain old text file?


    You can if you write a program to do it. The file name could even be chosen by the propeller.

    Is your question "how to do this" or "is there something to do this already" or "will something do this for me?".

    Graham
  • rjo_rjo_ Posts: 1,825
    edited 2007-07-02 14:34
    Graham,

    I was hoping that there was already a general purpose solution available that I could hack. I have a couple of holes in my tool bag[noparse]:)[/noparse]

    If there isn't already a general solution... I certainly can't create one from scratch right now. So if anyone wanted to throw a prototype ... "almost ready for idiots" solution together, I'd appreciate it... and there are probably lots of other people that would find a use for it.

    When you say... "You can write a program...The file name can even be chosen by the Propeller" are you referring to the PLX approach?

    (I suspect that you are right and it is probably the fastest way to do it... and I can probably do it myself... just have to steal Excel from my daughter!)

    I still have't tried Andy's suggestion...

    Thanks Again

    Rich
  • Graham StablerGraham Stabler Posts: 2,507
    edited 2007-07-02 14:38
    By write a program I meant a visual basic program or similar as it could interpret commands sent from the propeller and act on them.

    Graham
  • rjo_rjo_ Posts: 1,825
    edited 2007-07-02 15:42
    Graham and Andy,

    Now I have... downloaded PropTerminal.

    It works!!! I just have to remember to minimize the PropTerminal when I am starting my program...

    I love my Propeller... and you guys!!!

    Rich
  • rjo_rjo_ Posts: 1,825
    edited 2007-07-02 15:42
    In a hetero sort of way[noparse]:)[/noparse]
  • Fred HawkinsFred Hawkins Posts: 997
    edited 2007-07-02 22:21
    rjo_ said...
    In a hetero sort of way[noparse]:)[/noparse]
    Good thing.
    ·swish swish swish just doesn't seem a valid propeller sound.
  • SapiehaSapieha Posts: 2,964
    edited 2007-09-05 10:27
    www.parallax.com/html_pages/downloads/software/software_plxdaq.asp


    Very nice piece job !!

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Sapieha
Sign In or Register to comment.