Custom array of ports using array?


Results 1 to 23 of 23

Threaded View

  1. #8
    Join Date
    Feb 2003
    Location
    Salt Lake City, Utah USA
    Posts
    517


    Did you find this post helpful? Yes | No

    Smile Neat Trick

    Steve,

    Yes, you are 100% correct in the logic - that is exactly how it works. This “trick” is not in the manual but first appeared on the PicBasic List in 2002 (http://list.picbasic.com/forum/messages/4011/4739.html? ).

    I remember being excited when this particular email came because it solved a problem I was having at the time. The links posted in my reply #6 above by Bruce and Melanie also clearly demonstrate this trick's use.

    As I understand it, it works for all SF/GP Register locations, not just PORT bits, hence the indexed locations must be sequential like you mentioned. I always check the datasheet if I am going to use it on sequential Ports to make sure they are indeed sequential (and they always have been for the PICs I have used).


    Paul
    Last edited by paul borgmeier; - 14th June 2006 at 06:40.

Similar Threads

  1. Bits, Bytes Words and Arrays
    By Melanie in forum FAQ - Frequently Asked Questions
    Replies: 24
    Last Post: - 14th June 2016, 08:55
  2. Simple Array Demo
    By Archangel in forum Code Examples
    Replies: 5
    Last Post: - 15th February 2010, 05:46
  3. Custom array of pins
    By bmagistro in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 29th March 2009, 00:15
  4. Crystalfontz LCD
    By jman12 in forum mel PIC BASIC Pro
    Replies: 9
    Last Post: - 9th February 2007, 16:04
  5. Making Array of two ports
    By John7 in forum General
    Replies: 3
    Last Post: - 5th March 2005, 03:20

Members who have read this thread : 2

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