Modifying SlaveFifoAsync | Cypress Semiconductor
I am interested in modifying the SlaveFifoAsync example to do a few extra things.
I have figured out how to get GPIO control and I2C control in from other projects, so that is working well, but there are three questions remaining that I am hoping someone can help me with.
1) Currently I initialize my I2C peripherals by just dumping the code into cyfxslfifoasync.c where the UART is set up. I should probably do this where control flows to the user application thread. Where is the body of this thread defined?
2) is the UtoP (OUT) endpoint the endpoing where data flows out to the host PC?
3) I want to modify the application to only stream data from the FX3 to the PC, but to catch command messages coming from the PC to the FX3 so I can alter parameters of the I2C peripherals based on a control application. My current plan is to modify the callback function (P to U I think?) to raise a software flag when the command packet is received and leave it up to the non-interrupt code to decode it and act on it. If someone could show me how to modify the callback handler to just catch the event and grab the data without it going to the GPIF I would appreciate it.
Thanks in advance.