greetings programming masters,
i have this task on hand, which requires me to show different freq for each channels i have. like ch1=98.1, ch2=95.1, etc up to 6 channels. but i still need to keep the range for the fm freq (87.5MHz-108.0MHz)
currently i am just defining the freq to be as following
which is actually wrong, because since i have defined the lowest values for each channel to be 98.1MHz and 95.1MHz respectively, I cant access the freq from 87.5MHz - 98.0MHz (for ch 1) and 87.5MHz - 95.1MHz (for ch 2)Code:#define FM_LOW1 981 #define FM_LOW2 951 #define FM_LMT 1080 #define FM_MAX1 (FM_LMT - FM_LOW1)*2 #define FM_MAX2 (FM_LMT - FM_LOW2)*2
is there any other ways to do this?