I have a function that executed in c. When a certain condition is met I want to change the state of a UIButton. I was trying to dispatch an NSNotification but that doesnt work.
What would be a good way to send a message to an obj-c object from a c function?
Ideally I would like to somehow be able to use NSNotification
The C Code needs to be inside of a .m file. If it is not then add a C callback function inside your .m that can post your notification or do something else for you. Here is an example of accessing the Objective-C class that calls a C function outside of a .m file.