You are here

HOW TO store data & GET DATA IN PSCO3-ES2 FROM KEYBOARD & LCD | Cypress Semiconductor

HOW TO store data & GET DATA IN PSCO3-ES2 FROM KEYBOARD & LCD

Summary: 5 Replies, Latest post by U2 on 23 May 2011 02:03 AM PDT
Verified Answers: 1
Last post
Log in to post new comments.
user_105297541's picture
User
10 posts

Hi

i m trying to write to data (like 12345) from keybaord. BUT i m unable to store this value.

I M USING  CY8C3866AXI-40.

plz help me.

 

U2
uday's picture
Cypress Employee
569 posts

 Could you provide us more information on what you are trying to do,

  • What kind of Keyboard are you using, is it a standard USB keyboard.
  • How far have you gone with your design
dasg's picture
Cypress Employee
730 posts

Hey SURENDRA,

 

You can use different communication protocols for communication of PSoC3/5 with PC. Some of them are:

1) UART to send data from PC to PSoC using the Hyperterminal.

2) I2C with the aid of Bridge Control Panel where PSoC acts as I2C Slave using EZI2C Component (PC acts as a master).

3) USB where PSoC acts as a USB device.

user_105297541's picture
User
10 posts

Hi UV,

i m sending you C program file main.c. In this program , i am using 2x4 matrix keybaord & 2x16 lcd. In this program i am writing from keybaord any value to display on lcd.    IN    set_offset()   function i m writing 5 digit value frm keybaord  and lcd diaplays tthis value. now i m trying to store  this numbet/data . when i give password  4321, lcd should diaplay store offset.            I want to store any number /digit in MEMORY through my keyboard setting.  I dont know how to write in memory & get data from memory to lcd.     please help

 

Attachments: 
user_105297541's picture
User
10 posts

Hi

i m sending you C program file main.c. In this program , i am using 2x4 matrix keybaord & 2x16 lcd. In this program i am writing from keybaord any value to display on lcd.    IN    set_offset()   function i m writing 5 digit value frm keybaord  and lcd diaplays tthis value. now i m trying to store  this numbet/data . when i give password  4321, lcd should diaplay store offset.            I want to store any number /digit in MEMORY through my keyboard setting.  I dont know how to write in memory & get data from memory to lcd.     please help

U2
uday's picture
Cypress Employee
569 posts
  • The simplest way to store in memory is to store it on SRAM. For this all you need to do is, declare an array of type uint8. The array will be allocated some memory in SRAM. As each key is being pressed, the same can be stored in successive elements of the array. The same can be displayed on LCD using the LCD_Char_PrintNumber() API.
  • In your case, since you are waiting for a sequence of keys being pressed, these keys could be stored in the array and check if the particular sequence has arrived. The comparisons can be made using simple if statements.
Log in to post new comments.