Hello newsgroup,
Mark Pappin posted some C source to model the situation for the house I'm remodeling. I'm a long way from understanding both the hardware and the software I would need to make it a reality.
// #include 0) { SWAMPCOOLER_FAN = --fanspeed; } } if (WATER_LEVEL < LO_WATER) { REFILL_SOLENOID = 1; } if (WATER_LEVEL > HI_WATER) { REFILL_SOLENOID = 0; } } return 0; /* for pedantry's sake */ } // gcc -o fan embed1.c
Not surprisingly, gcc notices some missing information:
C:\Documents and Settings\dan\Desktop\gfortran\source>gcc -o fan embed1.c embed1.c: In function 'main': embed1.c:28: error: 'ADC_DATA_IN_0' undeclared (first use in this function) embed1.c:28: error: (Each undeclared identifier is reported only once embed1.c:28: error: for each function it appears in.) embed1.c:29: error: 'ADC_DATA_IN_1' undeclared (first use in this function) embed1.c:35: error: 'DAC_DATA_OUT_0' undeclared (first use in this function) embed1.c:44: error: 'ADC_DATA_IN_2' undeclared (first use in this function) embed1.c:45: error: 'RELAY_OUT_0' undeclared (first use in this function)
Mark is pretty close with this first guess, as far as how these mechanisms work. I have one fan next to the woodburner and another that feeds the bedrooms, and a swamp cooler in the middle of everything.
How do I proceed?
Thanks and cheers,