- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello everyone,
I am new in the community and getting my hands on PSoC1. I am trying to implement I2C slave on CY8C20637-24LQXI. I am following apllication note AN56007 provided by Cypress. I could not understand how to handle request coming from master (Read/Write). How to handle request coming from master (read/write) and respond to the same? Is there any handlers available which get fire on detecting request from master after matching address?
Thank you,
nIk
- Labels:
-
PSoC 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Welcome in the forum, nIK !
I2C is quite straightforward: The slave provides a buffer which the master can read from and another buffer the master can write to. Not quite easy checking that out with a PSoC1 since you (normally) do not have any debugging capabilities. Do you have got a development kit ? Which one exactly??
What is your master device? Link to datasheet if you have got one
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@Bob,
Thank you for quick response.. I am using AVR ATMega164PA as a master (Datasheet is attached). I am using this library for I2C communication. I have tested this library and its working completely. I have used Arduino (as slave) to test communication. Now in place of Arduino I want to use CY8C20637-24LQXI as a slave.
As you mentioned master can write and read into buffer but you have not mentioned way to do that. It would be great if you can show me a way to do so.
Regards,
nIk
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
In the datasheet of the I2CHW component is an example (C and ASM) for a slave. I admit the structure of the program is a bit strange, but it is working.
Bob
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
@Bob,
I am not finding I2CHW that you are talking about. Can you please make it clear??
nIk.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
You are posting here in the PSoC1 forum. When you use Designer v5.4 and choose a cy8c29466 chip you will see the I2CHW component in the "Communications"-folder.
Bob