
all: own.hex

main.rel: main.c main.h
	sdcc -mmcs51 -c main.c

f330.rel: f330.c main.h
	sdcc -mmcs51 -c f330.c

own.rel: own.c main.h
	sdcc -mmcs51 -c own.c

ds1820.rel: ds1820.c main.h
	sdcc -mmcs51 -c ds1820.c

ds1822.rel: ds1822.c main.h
	sdcc -mmcs51 -c ds1822.c

ds2438.rel: ds2438.c main.h
	sdcc -mmcs51 -c ds2438.c

own.hex: main.rel f330.rel own.rel ds1820.rel ds1822.rel ds2438.rel
	sdcc -mmcs51 main.rel f330.rel own.rel ds1820.rel ds1822.rel ds2438.rel
	mv main.ihx own.hex

clean:
	rm -f *.rel
	rm -f *.asm
	rm -f *.lst
	rm -f *.map
	rm -f *.rst
	rm -f *.sym
	rm -f *.lnk
	rm -f *.mem
