Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- *
- *@file process.cpp
- **/
- #include <stdint.h>
- #include "process.h"
- enum TStatusValve {VALVE_OPENNED, VALVE_CLOSED};
- #define OUT_REGISTER 0XFEAFEO // a sample register address
- uint32_t mirror_digital_output;
- void process_Init(void) {
- mirror_digital_output = 0x0000;
- out(OUT_REGISTER, mirror_digital_output);
- }
- void process_WriteActuatorValve(TStatusValve status) {
- // "1" means open
- // "0" means closed
- // bit for valve is bit 6
- // modify teh mirrror according "status" variable
- // put the mirror in the out() register
- }
Advertisement
Add Comment
Please, Sign In to add comment