Help with GOSUB


Closed Thread
Results 1 to 17 of 17

Thread: Help with GOSUB

Hybrid View

  1. #1
    Join Date
    Jul 2015
    Posts
    7


    Did you find this post helpful? Yes | No

    Default Re: Help with GOSUB

    Henrik,

    That was it! I had my GOTO Mainloop after the dat: subroutine. I moved it up like you
    mentioned and it works.

    GOSUB dat 'last gosub dat

    GOTO MAINLOOP
    dat:
    RD = 1
    For i = 0 to 65535
    RD = 0 ' Pull pin low
    PAUSEUS 10 ' Wait 10us
    RD = 1 ' Pull pin high
    PAUSEUS 10 ' Wait 10us
    NEXT
    RETURN

    END

    Thanks a ton! If you were here, I'd buy you a beer.
    Instead, I'm taking a vacation day tomorrow and goin' fishing.

    Jim

  2. #2
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default Re: Help with GOSUB

    Quote Originally Posted by HEXhacker View Post
    Henrik,



    Thanks a ton! If you were here, I'd buy you a beer.
    Instead, I'm taking a vacation day tomorrow and goin' fishing.

    Jim
    Wow, beer and fishing all in the same post
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

Similar Threads

  1. gosub - return
    By l_gaminde in forum mel PIC BASIC Pro
    Replies: 4
    Last Post: - 11th August 2010, 11:21
  2. On...gosub
    By circuitpro in forum PBP Wish List
    Replies: 5
    Last Post: - 7th December 2009, 22:40
  3. If ... Then Gosub <> If ... Then Goto?
    By oldtoddler in forum General
    Replies: 6
    Last Post: - 27th February 2006, 12:52
  4. gosub and if-then working together?
    By bartman in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 23rd November 2005, 14:54
  5. GoSub Problem
    By ghoot in forum mel PIC BASIC Pro
    Replies: 3
    Last Post: - 11th May 2004, 16:15

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts