Print CLS stopped USB from working


+ Reply to Thread
Results 1 to 5 of 5

Thread: Print CLS stopped USB from working52 days old

  1. #1
    Prolific Poster See_Mos's Avatar
    Join Date
    Feb 2004
    Posts
    1,280
    Thumbs Up
    Received: 16
    Given: 0
    Total Downloaded
    872.27 MB

    0 Not allowed!

    Default Print CLS stopped USB from working

    I'm putting this here because it is not really an error, more of a coding problem.

    I have been working on some 18F25K50 USB code for several days but sometimes the PC reported "Device not recognized". Eventually I found that if I removed the Cls the error cleared

    The code that caused it was reduced to this

    Code:
    While 1 = 1
    
      Print CLS
      USBPoll
      Gosub DoUSBIn
      Select USB Command
    
      Case 1
      Print Dec USBCommand
      End Select
      Wend
    by adding two lines before the CLS
    Code:
    Clear USBOutBuffer
    GoSub DoUSBOut
    cleared the problem and USBPoll was not needed.
    My RAM is failing

Attention

This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

The advertisements we display are relevant to this web site and your browsing history

Please consider supporting us by disabling your ad blocker.


Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

If you can, please report issues in the forum area WebSite / Forum Issues


Thank you for your attention.

  • #2
    Prolific Poster johngb's Avatar
    Join Date
    Oct 2003
    Posts
    2,134
    Thumbs Up
    Received: 95
    Given: 1
    Total Downloaded
    2.42 GB

    0 Not allowed!

    Default Re: Print CLS stopped USB from working

    Does that mean you are working with the old USB Pic Loader I produced?
    Sounds like it was timing problem!
    JohnB

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #3
    Fanatical Contributor top204's Avatar
    Join Date
    Feb 2002
    Posts
    3,341
    Thumbs Up
    Received: 289
    Given: 139
    Total Downloaded
    1.60 GB

    0 Not allowed!

    Default Re: Print CLS stopped USB from working

    The Cls command adds a 30mS delay after sending the command to the LCD. This is mandatory for Hitachi LCDs, and each LCD command has to have a small delay after it so the LCD chipset can perform the command.

    The 30ms delay may delay the polling of the USB too long.

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #4
    Prolific Poster towlerg's Avatar
    Join Date
    Mar 2012
    Posts
    2,157
    Thumbs Up
    Received: 74
    Given: 173
    Total Downloaded
    5.06 GB

    0 Not allowed!

    Default Re: Print CLS stopped USB from working

    If you use the alternate USB build, polling can be set to interupt driven. I works great such that polling becomes completly transparent.
    George.

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

  • #5
    Prolific Poster See_Mos's Avatar
    Join Date
    Feb 2004
    Posts
    1,280
    Thumbs Up
    Received: 16
    Given: 0
    Total Downloaded
    872.27 MB

    0 Not allowed!

    Default Re: Print CLS stopped USB from working

    Thanks Les and thanks George for reminding me. I have used the technique before but my RAM really is failing now and I had forgotten about that.
    My RAM is failing

  • Attention

    This valuable resource relies upon the very small amount of revenue generated by displaying online advertisements to our visitors.

    The advertisements we display are relevant to this web site and your browsing history

    Please consider supporting us by disabling your ad blocker.


    Note: Some users have reported issues related to ad-blockers rendering parts of this wesite unusable,
    where possible we will rectify the issues to enable you to use this resource with adblocking enabled.

    If you can, please report issues in the forum area WebSite / Forum Issues


    Thank you for your attention.

    Thread Information

    Users Browsing this Thread

    There are currently 1 users browsing this thread. (0 members and 1 guests)

       

    Similar Threads

    1. Proton stopped working!
      By Colin G3YHV in forum Projects discussion
      Replies: 7
      Last Post: 27th May 2018, 12:26
    2. Proton stopped working!
      By Colin G3YHV in forum Projects discussion
      Replies: 7
      Last Post: 8th May 2018, 12:48
    3. PicKit 2 stopped working
      By charliecoultas in forum The Lounge
      Replies: 30
      Last Post: 1st March 2018, 19:53
    4. CLS and Print CLS
      By i2tzk in forum LCD module
      Replies: 6
      Last Post: 2nd July 2013, 08:05
    5. Frontend loader stopped working
      By adamsj3 in forum Proton Plus Compiler v3
      Replies: 0
      Last Post: 12th June 2013, 01:35

    Members who have read this thread : 29

    Actions :  (Set Date)

    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