generate C via passed params
flash core with generated code
write states to file