Shop OBEX P1 Docs P2 Docs Learn Events
Output and input files — Parallax Forums

Output and input files

DTB12DTB12 Posts: 2
edited 2008-12-17 13:44 in General Discussion
Can anyone tell me how to or if the javelin stamp can read info from a file and output info to a file?
Thanks
Dan

Comments

  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2008-11-10 08:38
    There are several options.
    You can setup a Uart and connect to a pc comport.
    Running any terminal program you can log incoming messages
    to file or transmit file. Due to the limited receive buffer
    (255 bytes) on the javelin, a hardware handshake is necessary.

    Another option is to use my JideWin Terminal program that also lets you
    log incoming messages and transmit files, but it uses the Javelin SIN/SOUT pins.
    http://tech.groups.yahoo.com/group/JavelinCode/files/JideTerm/

    Third option is to use the IDE beta that offers the same possiblity as above
    but integrated into the message window (several windows in fact, each can be logged
    seperately).
    http://forums.parallax.com/showthread.php?p=654012

    regards peter
  • DTB12DTB12 Posts: 2
    edited 2008-11-10 12:18
    I'll give that a try thank you for your help.
    Dan
  • jmspaggijmspaggi Posts: 629
    edited 2008-11-10 13:17
    Hi Peter.

    Can this: www.hittconsulting.com/sddatalogger.htm also be an option? Don't really know how to use it, but might be interesting...

    JM
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2008-11-10 13:46
    Yes, also Parallax USB datalogger (for usb stick)
    and UsbWiz (both SD and usb stick).
    These all have TTL level serial interfaces so you
    would use Uarts to communicate with these
    devices.

    regards peter
  • jmspaggijmspaggi Posts: 629
    edited 2008-11-10 13:54
    Hi Peter,

    Thanks for your prompt reply.

    How does it work (Like for the USB datalogger)? Do we have to implement the FAT logic on the Javelin side? I'm interested by this function (adding file writing to my application), but don't want to implement all the file system logic...

    JM
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2008-11-10 15:24
    Read the manuals for the devices. They usually all implement
    some functions like openFile, readFile, writeFile, closeFile.

    regards peter
  • jmspaggijmspaggi Posts: 629
    edited 2008-12-15 19:44
    Hi Peter,

    Is there any way to reduce the number of PINs used by the Parallax Memory Stick Datalogger? Like sharing the pins for transmit and receive? Or will it be better to use the SPI mode and share the Data and Clock line with my other components and command the Datalogger with the Chip Select PIN?

    Thanks,

    JM
  • Peter VerkaikPeter Verkaik Posts: 3,956
    edited 2008-12-15 23:10
    Here are my classes for the Parallax Datalogger.
    The class Datalogger.java implements the logical methods,
    but requires to be extended to do the physical I/O.
    The class DataloggerSPI.java extends class Datalogger.java
    to provide the physical I/O.
    Class DataloggerSPI_test.java is the main program that
    you can download to the javelin.

    You could write a class DataloggerUart.java that extends
    Datalogger.java using Uarts to do the physical I/O.
    I would recommend to use SPI for 2 reasons:
    1.·SPI does not take up a VP slot.
    2. The datalogger may send unsollicited messages
    and this may be harder to detect when using uarts.

    regards peter
  • jmspaggijmspaggi Posts: 629
    edited 2008-12-17 13:44
    Hi Peter,

    Thanks for the files. I will test them and see if it's working fine for me. I also like the SPI approach in order to share the pins with the solar sensor, and so on.

    Regards,

    JM
Sign In or Register to comment.