We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
I have function that reads status from GPIO port and stores it in local variable and then return that value.
unsigned int ulStatusRead(void) { unsigned int ulStatus; ulStatus = readPort(PORTx); return ulStatus; }
I need to write signal function that changes PORTx pins to some value when it is about to be read by ulStatusRead function so that ulStatus variable contains this value.
I tried the following, but without success:
signal void status(void) { rwatch(ulStatusRead); PORTx = someValue; }
I don't want to watch reads from PORTx as it is read in another locations.
Any help please ?