Hello,
let me refer to the example DeviceIntegration that you will find in the subdirectory /Examples within the Raspberry Pi Build Environment. This example demonstrates how to access a hardware button and a LED by using the WiringPi library. You can use this example as template to make your own hardware integrations.
Concerning the question "Running a Python code from C in Raspberry Pi" let me refer to the different Raspberry Pi forums and tutorials.
Best regards,
Manfred.