Shop OBEX P1 Docs P2 Docs Learn Events
serin display on debug — Parallax Forums

serin display on debug

ab3idab3id Posts: 5
edited 2009-07-15 15:23 in BASIC Stamp
I am putting together a rotator control package and spent all day Sunday trying to see the azimuth and elevation reading
from Orbitron using WISPDDE. I am at the wrong computer or I would attach the code I was using but I tried everything I could think of.
Will add the code tonight. Meanwhile, anyone else make this work? The BS2 stamp works with other programs so the cable seems OK. Other sample programs write to debug screen.
Help,

Gary

Comments

  • Mike GreenMike Green Posts: 23,101
    edited 2009-07-13 14:27
    The more information you supply, the more likely you will get useful help. When you get around to posting your code, be sure to include information (documentation) on the "Orbitron using WISPDDE". Some people here may know what this is, but most will not. Include wiring information
  • ab3idab3id Posts: 5
    edited 2009-07-13 23:17
    Orbitron is a satellite tracking tracking program that will provide serial output of azimuth and elevation of the satellite from my location and radio frequencies for up and down link with Doppler correction. I am including the test file with several commented out lines to suggest the some of the changes I tried.
    WISPDDE is an application to convert the Orbitron information to a format usable to other applications like a rotator control or radio control ( for people with fancy computer controllable radios). I have been unable to locate the data output format for WISPDDE so I have been looking a code others have put on the web using WISPDDE and other tracking programs but I seem to be missing something to make it work for me.


    ' {$STAMP BS2}
    ' {$PBASIC 2.5}
    ' {$PORT COM1}

    'variables
    azinput VAR Word
    elinput VAR Word

    'constants
    baud CON 16468 'baud rate serial in 9600,8,n

    'SERIN 16,baud,[noparse][[/noparse]WAIT("AZ"),DEC azinput,DEC elinput]
    'SERIN 16,baud,[noparse][[/noparse]WAIT("Az"),DEC azinput, WAIT(".")]
    SERIN 16,baud,[noparse][[/noparse]WAIT("Az"),DEC azinput]
    'SERIN 16,baud,[noparse][[/noparse]WAIT("EL"),SDEC elinput, WAIT(".")]
    SERIN 16,baud,[noparse][[/noparse]WAIT("El"),SDEC elinput]
    'SERIN 16,baud, [noparse][[/noparse]DEC elinput]


    'DEBUG "AZ = ",DEC azinput
    DEBUG "AZ = ",DEC azinput,",EL = ",DEC elinput


    PAUSE 9000
    RETURN
  • dev/nulldev/null Posts: 381
    edited 2009-07-14 01:30
    You might try
    SERIN 16,baud,[noparse][[/noparse]WAIT("Az"),STR azinput\2]
    


    or
    SERIN 16,baud,[noparse][[/noparse]WAIT("Az"),azinput.LOWBYTE, azinput.HIGHBYTE]
    


    or
    SERIN 16,baud,[noparse][[/noparse]WAIT("Az"),DEC azinput.LOWBYTE, DEC azinput.HIGHBYTE]
    



    I'd also consider
    DEBUG "AZ = ",STR azinput\2,",EL = ",STR elinput\2
    


    or
    DEBUG "AZ = ",HEX azinput.LOWBYTE, HEX azinput.HIGHBYTE,",EL = ",HEX elinput
    

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Don't worry. Be happy
  • ab3idab3id Posts: 5
    edited 2009-07-15 00:41
    Tried the sugestions but to no good end. Went back to basics and stalled with the WISPDDE tying up the serial port so the BS2 could not be found. This tells me what? Now data is being sent but BS2 can't use the same com port (my only com port)? Maybe I need to contact WISPDDE author.
    Thanks, Gary
  • FranklinFranklin Posts: 4,747
    edited 2009-07-15 14:48
    You are right when you say that only one device can use the com port at a time. Before you can use the computer to talk to the stamp you need to release the com port in your other program.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    - Stephen
  • dev/nulldev/null Posts: 381
    edited 2009-07-15 15:23
    I would get another COM port for the WISPDDE. Example: www.sparkfun.com/commerce/product_info.php?products_id=8580.

    You also need an RS232 to TTL converter. You put this in the new COM port, and connect the Rx and Tx pins directly to stamp pins.
    If you want to build your own converter you can check this: www.seattlerobotics.org/encoder/aug97/cable.html

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Don't worry. Be happy
Sign In or Register to comment.