element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • About Us
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Arduino
  • Products
  • More
Arduino
Arduino Forum Andy
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Arduino to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Suggested Answer
  • Replies 3 replies
  • Answers 3 answers
  • Subscribers 388 subscribers
  • Views 1154 views
  • Users 0 members are here
Related

Andy

andy2000
andy2000 over 4 years ago

First time using this so hoping someone can help and I'm explaining it well enough but I'm wanting to make a project for work - the idea being to easily locate an item on a shelf using LED lights.

 

I will be using a standard keypad input that converts that input to a single 8 digit number, using a SIPO shift register. I'm struggling on the next part, which is then trying to match that number with some sort of modifiable database list that is numbered 1 to 100 (it has to be modifiable due to the fact I need to update the number manually myself as it will/can change everyday). The plan would be, if the keypad matches to one of these numbers it would turn on the corresponding LED that is located on the shelf.

Attachments:
image
  • Sign in to reply
  • Cancel

Top Replies

  • fmilburn
    fmilburn over 4 years ago +4 suggested
    Hi Andy, Another method that might work for you is to use individually addressable LED strings (not strips) sometimes called Neopixels. See for example: https://hackaday.com/2020/01/26/light-the-way-to…
  • beacon_dave
    beacon_dave over 4 years ago +4 suggested
    So basically you have 100 locations on the shelf each lit with a LED, and each item placed on the shelf has been tagged with a 8 digit code ? You could create a 100 element array which holds your 8 digit…
  • shabaz
    shabaz over 4 years ago +2 suggested
    Hi Andy, You could (if desired) split this project into two pieces (or more). Once piece is the mapping from your source number to your destination number. The second piece is using the destination number…
Parents
  • beacon_dave
    0 beacon_dave over 4 years ago

    So basically you have 100 locations on the shelf each lit with a LED, and each item placed on the shelf has been tagged with a 8 digit code ?

     

    You could create a 100 element array which holds your 8 digit codes for the day.

    Loop through the array to see if the current number entered matches any value in the array and if so use the array index number to light the LED.

     

    https://www.arduino.cc/reference/en/language/variables/data-types/array/  

     

    Note that the arrays are zero-indexed so it would be 0-99 and not 1-100, so you need to subtract / add 1 accordingly or may want to create a 101 element array (0-100) and ignore the first element. Or renumber your shelf 0-99.

     

    Updating the 'database' would be just a case of selecting the index position in the array and storing a new 8-digit value.

     

    Need to consider if you can ever have two or more 8-digit numbers at the same time and how you want to handle that. Also need to consider if you want to store this data to EEPROM or SD card so as you don't lose it after a power cycle.

    • Cancel
    • Vote Up +4 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
Reply
  • beacon_dave
    0 beacon_dave over 4 years ago

    So basically you have 100 locations on the shelf each lit with a LED, and each item placed on the shelf has been tagged with a 8 digit code ?

     

    You could create a 100 element array which holds your 8 digit codes for the day.

    Loop through the array to see if the current number entered matches any value in the array and if so use the array index number to light the LED.

     

    https://www.arduino.cc/reference/en/language/variables/data-types/array/  

     

    Note that the arrays are zero-indexed so it would be 0-99 and not 1-100, so you need to subtract / add 1 accordingly or may want to create a 101 element array (0-100) and ignore the first element. Or renumber your shelf 0-99.

     

    Updating the 'database' would be just a case of selecting the index position in the array and storing a new 8-digit value.

     

    Need to consider if you can ever have two or more 8-digit numbers at the same time and how you want to handle that. Also need to consider if you want to store this data to EEPROM or SD card so as you don't lose it after a power cycle.

    • Cancel
    • Vote Up +4 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
Children
No Data
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube