Shop OBEX P1 Docs P2 Docs Learn Events
Expert coder needed - Page 3 — Parallax Forums

Expert coder needed

1356

Comments

  • computer guycomputer guy Posts: 1,113
    edited 2008-02-10 07:49
    Steven,

    code looks good.
    I will test the code in the next few days.
    Will keep you posted.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-10 08:50
    Steven,

    I am doing testing on a Hybrid board.
    It uses P24-27 for tv, I changed text.start(12) to read text.start(24) however all I get is white specks on a black background.
    I am using a Pal TV.

    Is there anything else I have to change in order to get TV Text to work.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-10 09:08
    Yep, you will have to change TV_Text as it is set to NTSC by default and since my tv will do NTSC I haven't bothered changing it.

    You need to change this line in the DAT section
    long    %10010          'mode
    


    to
    long    %10011          'mode
    
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-10 09:22
    No good, I still get the same results.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-10 09:39
    If you change TV_Text_Demo does that work?
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-10 09:57
    I get the same results with TV-Text_Demo.
    might have to look into the Hybrids timing. I think. smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-10 09:59
    Turns out the Hybrid is a bit faster than proto board. smile.gif

    It is now working.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-10 10:01
    Do they use a 10MHz crystal? I also believe that on the HYDRA the resistors on the video DAC are the opposite way to those on the Demo board. Would someone who knows about the hybrid care to comment?
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-10 10:03
    The Hybrid uses a 6MHZ crystal.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • deSilvadeSilva Posts: 2,967
    edited 2008-02-10 10:04
    For just checking the hardware try these test programs I used with Drone some time ago:
    http://forums.parallax.com/showthread.php?p=699285
    They are called MPE_TEXT_021NTSC and MPE_TEXT_021PAL and are configured for the Hydra (Pin 24)
    ----
    Edit:
    Oh, I see, its already working with you
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-10 10:08
    The TV output constantly displays "called code start1" over and over.
    I am assuming this is because I have no RTC attached at the moment.

    Thank you smile.gif

    @deSilva
    If my quick scan over that thread is correct.
    Is that a modified TV driver for smaller(pocket size) tv's?

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-10 10:16
    @computer guy that is correct, if you want to see the schedule just comment out the line that displays it in the doInstruction method. You can also slow it down by uncommenting the waitcnt(cnt) in the start method. Since I'm only storing and checking things by the minute we only need to check every minute or slightly less. note that instead of doing this it would be better to wait for the serial for this amount of time than just a wait cnt.
  • deSilvadeSilva Posts: 2,967
    edited 2008-02-10 11:25
    computer guy said...
    @deSilva
    If my quick scan over that thread is correct.
    Is that a modified TV driver for smaller(pocket size) tv's?
    Yes, it addresses some of the quality problems with 320x240 pixel screens WITHOUT having to modify the TV-driver. For some applications you just need a few good looking characters for small messages...
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-11 05:36
    Steven,

    If I was to for testing purposes want to add a schedule via the "basic stamp editor dubug terminal" or "Hyper terminal".
    What would I send.
    When I launch the program (on the prop) it displays "Finished setup" in the terminal, but I can't get it to add a schdule.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-11 06:42
    I'm just about to start testing it. However I'm using a mac at the moment so you will have to figure out where the settings are in the program that you are using.

    The commands you need to send are something like this
    BYTE %0101000
    BYTE day (0 to 6)
    BYTE hour (0 to 12)
    BYTE minute (0 to 60)
    BYTE instruction code (whatever you define)
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-11 07:06
    Steven,

    I have found a slight bug.
    It is not backing up the number of schedule items.

    So I added the line-
    eeprom.VarBackup(@NumScheduleItems,@NumScheduleItems)

    That now allows me to reboot the prop and still keep the records.
    The only problem is that any manually added records loose their data.

    Also

    In order to get it to listen for a new record I have to type '(' in to the terminal.
    I am assuming that the binary representation of '(' is %0101000 is this correct?


    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-11 07:20
    Somebody said...
    I have found a slight bug.
    It is not backing up the number of schedule items.

    So I added the line-
    eeprom.VarBackup(@NumScheduleItems,@NumScheduleItems)

    That now allows me to reboot the prop and still keep the records.
    The only problem is that any manually added records loose their data.

    I noticed that yesterday and just hadn't fixed it yet. See attached version.
    Somebody said...
    In order to get it to listen for a new record I have to type '(' in to the terminal.
    I am assuming that the binary representation of '(' is %0101000 is this correct?

    That would be a good guess. In this new version you can use
    -"n" to add an item
    -"s" to send the schedule
    -"c" to clear the schedule

    This isn't tested yet. I haven't got quite got the serial working on my mac yet smile.gif I've never used a serial terminal on a mac yet smile.gif

    Have a look at the changes in the backupSchedule and insertItem methods and in the CON section before the checkSerial method.

    Steven
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-11 07:37
    Fixed a bug, I wasn't writing all the schedule items to the eeprom, now fixed.

    Also, did you know that if you are using your propPlug you have to set the tx and rx pins to 30 and 31. I forgot to change them and was wondering why I wasn't getting anything confused.gif
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-11 07:38
    I changed them on h second attempt to get it going. smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-11 07:44
    One other thing.
    Is the clear code meant to remove all entries because all it does is fool the prop into thinking there are no schedules and then gradually override them as you add new ones.

    The 's' command only displays random garbage.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-11 07:51
    computer guy said...
    One other thing.
    Is the clear code meant to remove all entries because all it does is fool the prop into thinking there are no schedules and then gradually override them as you add new ones.

    That would be correct

    Somebody said...
    The 's' command only displays random garbage.

    I'm checking this at the moment.
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-11 07:53
    Could the problem with the 's' command be that it is displaying the ascii equivalent.
    Maybe they need to be converted to decimals and strings before they are sent.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-11 08:01
    Yep, I'll have an updated version in a couple of minutes...
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-11 08:07
    Here is a version that should output the same over the serial as on the TV
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-11 08:18
    Works wonderfully.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-11 08:56
    Steven,

    when you say

    'n'
    BYTE day (0 to 6)
    BYTE hour (0 to 12)
    BYTE minute (0 to 60)
    BYTE instruction code (whatever you define)

    could you give an example?

    I can get it to add an item but I just type random data and I get reading like-

    Time 54:54 Day , Code 32

    It would be nice to test it with real data.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-11 09:04
    The problem is that you are sending ascii and not the actual numbers. To make it work change this
    PUB getItemSerial
      insertItem(newItem(ser.rx,ser.rx,ser.rx,ser.rx))
    


    to this
    PUB getItemSerial
      insertItem(newItem(ser.rx-"0",ser.rx-"0",ser.rx-"0",ser.rx-"0"))
    



    This will only work for single digit numbers though. If you want to use ascii for all of it you will need to use the Numbers object to convert from a string to a number.
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-11 09:11
    Ok thank you.

    Will make a quick program in VB for debug then.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • computer guycomputer guy Posts: 1,113
    edited 2008-02-12 05:42
    I have finished the "quick" VB program and it all works great.
    I can add and clear the items nicely.

    Thank you smile.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my robot using the propeller RECONAUTOR
    If you like my avatar then check this out Propeller Domed Sticker
  • stevenmess2004stevenmess2004 Posts: 1,102
    edited 2008-02-12 06:39
    Now to see if you can make the MatchPort do what you want smile.gif
Sign In or Register to comment.