diff --git a/Operating_Instructions.txt b/Operating_Instructions.txt new file mode 100644 index 0000000..b3461ec --- /dev/null +++ b/Operating_Instructions.txt @@ -0,0 +1,82 @@ +Instructions +============== + +Normal dialing +============== + +Just pull the dial round from the desired number to the fingerstop and release immediately. + +Dialing * and # +=============== + +for * pull the dial from "1" and hold on the fingerstop for 2 seconds until you hear a beep, release, and a tone for * will be generated. + +For # do the same but use "2". + +Redial +====== + +Pull the dial around from "3" and hold on the fingerstop for 2 seconds. Release when you hear the beep, and the last number will be redialed. + +Speed dials +=========== + +There are 7 speed dial locations. 0, 4, 5, 6, 7, 8, 9. Pull the dial around to the fingerstop and hold for 2 seconds, release when you hear the beep and the desired number will be dialed. + +Programming a speed dial +======================== + +Pull the number of the desired location around to the fingerstop and hold for 4 seconds, you will hear a quick rising-tone beep. Release the dial. + +You are now in programming mode. Now simply dial out the number you wish to store, releasing the dial immediately after each digit. You will hear a simple beep after digit. Once complete, hang up, the number is now saved. + +Up to 32 digits may be saved in each speed dial location. If you enter too many digits a warning beep sequence will sound. + +If you want to program another number without hanging up, just finish programming the last number, then select the next memory location to store by holding that digit against the finger stop. Allow the modes to cycle (single beep > rising beeps) until the rapidly rising beep tone is heard and release the dial. Program the number for this location as above. + +When doing this you will likely have your telephone exchange furiously beeping at you because you haven"t dialed a number. If annoying, you should dial a number known to be busy or with a recording, while programming. + +Hotline Feature +=============== + +The device can automatically dial a pre-programmed number when the receiver is taken off-hook. + +Program the desired hotline number into memory "0" as described above. + +Dial and hold the "1" digit against the finger stop for 4 seconds until a beep is heard. Release the dial. A series of slow ascending tones will sound, followed by one beep, indicating the hotdial feature is now active and set for one second delay from off-hook to dial. + +Repeat the process. Two beeps will be heard, indicating a two-second delay is active. Three and four second delays may be set in a similar fashion. + +After setting a four second delay, if the programming sequence is repeated, s slow descending series of tones will be heard. indicating the hotline feature is disabled. + +Hotline settings are saved in nonvolatile EEPROM memory. + + +Adjusting tone length +===================== +The length of each DTMF tone may be set, from the default of 100 milliseconds. Supported lengths are 50ms, 100ms, 150ms, and 200ms. + +Dial and hold the "2" digit against the finger stop for 4 seconds until a beep is heard. Release the dial. A sequence of beeps will play, indicating the set digit duration. One beep = 50ms, two beeps = 100ms, three beeps = 150ms, and four beeps = 200ms. The setting wraps back from 200ms to 50ms. + +The tone duration setting is saved in nonvolatile EEPROM memory. + + +MF (multifrequency) "Blue Box" mode (optional) +============================================== +The unit may be switched so that MF multifrequency trunk signalling tones are played, rather than standard DTMF. + +If equipped in software, dial and hold the "3" digit against the finger stop for 4 seconds until a beep is heard. Release the dial. A series of slow ascending tones will sound, indicating that MF mode is active. + +To return to normal DTMF mode, repeat the above procedure. Slow descending tones indicate MF mode is off. + +Manual dialing is done normally. To dial the "KP" or Key Pulse tone, pull the dial from "1" and hold on the fingerstop for 2 seconds until you hear a beep, release, and a tone for KP will be generated. + +For the ST or Start tone, do the same but use "2". + +To dial a long 2600Hz trunk seizure tone, pull the dial from "3" and hold on the fingerstop for 2 seconds until you hear a beep, release, and a long 2600 tone will be generated. + +Memories saved in MF mode will be played back using MF tones regardless of the current mode of the unit, DTMF or MF (the tone mode is saved along with the digit sequence). + +The 2600Hz tone may be saved to a memory like any other tone (in MF mode only, of course). A suitable delay will be inserted after the 2600Hz tone is played from memory to allow time for the trunk wink acknowledgement. + +The hotline number, if programmed and used will always play back from memory "0". Memory "0" should be programmed while in DTMF mode when used for hotline operation. If programmed in MF mode, MF tones will be played when going off-hook, resulting in a failed call. diff --git a/README.md b/README.md new file mode 100644 index 0000000..174634a --- /dev/null +++ b/README.md @@ -0,0 +1,37 @@ +This code is a branch from Matthew Millman's excellent Pulse > DTMF converter project, which converts a rotary dial telephone to DTMF operation. This branch adds a "blue box" or MF multifrequency mode. + +I cleaned up a few operating anomalies and added adjustable DTMF tone length (saved in EEPROM) and a "hotline" mode that auto-dials the number stored in speed dial location zero whenever the phone is taken off-hook. + +The time between going off-hook and the start of dialing is adjustable and also saved in EEPROM. + +I updated the hardware design schematics to include a diode bridge for polarity protection, as the voltage regulator used is subject to damage if the telephone wiring is polarity reversed from the standard arrangement. + +I also added a zener diode to the circuit to assure sufficient voltage is available to the input of the voltage regulator for most telephones and loop currents. + +Without the zener diode, certain ATAs with low voltage/current or telephones with low internal network resistance would not develop enough voltage drop to power the unit reliably. + +Bugs fixed are the failure to return to normal dialing mode after speed dialing or playing the * or # tones. This made it impossible to use DTMF on a connected call after initial dialing. + +I also made it possible to save the * and # tones in speed dial and last number memories. + +I also added a "blue box" mode that adds the multifrequency dual-tone "MF" signals historically used by the US long distance network. + +"Phone phreaks" could use these tones in conjunction with the 2600Hz supervisory tone to take over a long distance call and re-route it, for free. Google for additional info. + +I run an Asterisk server at +1 630-485-2995 which accepts these tones and allows blue box phreaking in a legal environment using a blue box or this circuit with a rotary phone. + +Blue box mode is entered by hold-dialing digit 3 for four seconds. MF mode is signified by ascending beeps. + +In blue box mode, normal dialing results in the special MF tones. The dialing sequence for * and # generates "KP" and "ST" tones. + +Last number dialed recall is disabled in MF mode. Instead, hold-dialing digit 3 produces a 2600Hz tone to seize a trunk. + +With this code version, the tone mode (DTMF or MF) is stored in EEPROM memory. Therefore, a mix of DTMF and MF tone sequences may be saved in the speed dial memories. 2600Hz may also be saved and played back. + +Both DTMF and MF tone sequences in speed dial memories may be played back in either DTMF or MF mode. + +Exit MF mode by hold-dialing digit 3 for 4 seconds. Descending tones indicate entry to DTMF mode. + +The hot line number will always play back in DTMF mode. Memory zero should be programmed in DTMF mode if using the hotdial feature. + +Numbers are not saved to the last number dialed memory while in MF mode and are therefor retained when returning to the DTMF mode. diff --git a/attiny85_fuse_settings.txt b/attiny85_fuse_settings.txt new file mode 100644 index 0000000..02d90d9 --- /dev/null +++ b/attiny85_fuse_settings.txt @@ -0,0 +1,5 @@ +Correctly set fuse bytes: + +LFUSE: 0xFD +HFUSE: 0xDF +EFUSE: 0xFF \ No newline at end of file diff --git a/dtmf.c b/dtmf.c index bddc033..3e3304b 100644 --- a/dtmf.c +++ b/dtmf.c @@ -91,13 +91,40 @@ const uint8_t auc_sin_param[NUM_SAMPLES] = { // 852hz ---> x_SW = 56 // 941hz ---> x_SW = 61 // +//MF Frequencies +//700hz ---> x_SW = 46 +//900hz ---> x_SW = 59 +//1100hz ---> x_SW = 72 +//1300hz ---> x_SW = 85 +//1500hz ---> x_SW = 98 +//1700hz ---> x_SW = 111 +// +//Trunk Seize Frequency +//2600hz ---> x_SW = 170 +// // | 1209 | 1336 | 1477 | 1633 // 697 | 1 | 2 | 3 | A // 770 | 4 | 5 | 6 | B // 852 | 7 | 8 | 9 | C // 941 | * | 0 | # | D +// +//Digit 0 85 98 +//Digit 1 46 59 +//Digit 2 46 72 +//Digit 3 59 72 +//Digit 4 46 85 +//Digit 5 59 85 +//Digit 6 72 85 +//Digit 7 46 98 +//Digit 8 59 98 +//Digit 9 72 98 +//KP 72 111 +//ST 98 111 + +//2600 Seizure 170 170 + -const uint8_t auc_frequency[12][2] = +const uint8_t auc_frequency[26][2] = { { 87, 61 }, // 0 { 79, 46 }, // 1 @@ -111,9 +138,26 @@ const uint8_t auc_frequency[12][2] = { 96, 56 }, // 9 { 79, 61 }, // * { 96, 61 }, // # + + { 0, 0 }, // # Placeholder for DIGIT_PRE2600 + + { 85, 98 }, // 0 + { 46, 59 }, // 1 + { 46, 72 }, // 2 + { 59, 72 }, // 3 + { 46, 85 }, // 4 + { 59, 85 }, // 5 + { 72, 85 }, // 6 + { 46, 98 }, // 7 + { 59, 98 }, // 8 + { 72, 98 }, // 9 + { 72, 111 }, // KP + { 98, 111 }, // ST + + { 170, 0 }, // 2600 }; -volatile uint32_t _g_delay_counter; // Delay counter for sleep function +volatile uint32_t _g_delay_counter; // Delay counter for sleep function volatile uint8_t _g_stepwidth_a; // step width of high frequency volatile uint8_t _g_stepwidth_b; // step width of low frequency volatile uint16_t _g_cur_sin_val_a; // position freq. A in LUT (extended format) @@ -142,7 +186,7 @@ void dtmf_generate_tone(int8_t digit, uint16_t duration_ms) { GIMSK = 0; - if (digit >= 0 && digit <= DIGIT_POUND) + if (digit >= 0 && digit <= DIGIT_2600) { // Standard digits 0-9, *, # _g_stepwidth_a = auc_frequency[digit][0]; @@ -150,7 +194,8 @@ void dtmf_generate_tone(int8_t digit, uint16_t duration_ms) dtmf_enable_pwm(); // Wait x ms - sleep_ms(duration_ms); + if(digit == DIGIT_2600){sleep_ms(DURATION_MS_2600);} + else{sleep_ms(duration_ms);} } else if (digit == DIGIT_BEEP) { @@ -183,6 +228,18 @@ void dtmf_generate_tone(int8_t digit, uint16_t duration_ms) sleep_ms(duration_ms / 3); _g_stepwidth_a = 51; // G=784Hz sleep_ms(duration_ms / 3); + } + else if (digit == DIGIT_TUNE_ASC2) + { + _g_stepwidth_a = 85; // 1300Hz + _g_stepwidth_b = 0; + dtmf_enable_pwm(); + + sleep_ms(duration_ms / 6); + _g_stepwidth_a = 98; // 1500Hz + sleep_ms(duration_ms / 6); + _g_stepwidth_a = 111; // 1700Hz + sleep_ms(duration_ms / 6); } else if (digit == DIGIT_TUNE_DESC) { @@ -196,6 +253,18 @@ void dtmf_generate_tone(int8_t digit, uint16_t duration_ms) _g_stepwidth_a = 34; // C=523.25Hz sleep_ms(duration_ms / 3); } + else if (digit == DIGIT_TUNE_DESC2) + { + _g_stepwidth_a = 111; // 1700Hz + _g_stepwidth_b = 0; + dtmf_enable_pwm(); + + sleep_ms(duration_ms / 6); + _g_stepwidth_a = 98; // 1500Hz + sleep_ms(duration_ms / 6); + _g_stepwidth_a = 85; // 1300Hz + sleep_ms(duration_ms / 6); + } // Stop DTMF transmitting // Disable PWM output (compare match mode 0) and force it to 0 @@ -258,4 +327,4 @@ void sleep_ms(uint16_t msec) { sleep_mode(); } -} \ No newline at end of file +} diff --git a/dtmf.h b/dtmf.h index 5c2e669..69b2e3f 100644 --- a/dtmf.h +++ b/dtmf.h @@ -28,11 +28,31 @@ #define DIGIT_BEEP_LOW -13 #define DIGIT_TUNE_ASC -11 #define DIGIT_TUNE_DESC -12 +#define DIGIT_TUNE_ASC2 -14 +#define DIGIT_TUNE_DESC2 -15 #define DIGIT_OFF -1 #define DIGIT_STAR 10 #define DIGIT_POUND 11 +#define DIGIT_PRE2600 12 //Use to play pending 2600 tone + +#define DIGIT_MF0 13 +#define DIGIT_MF1 14 +#define DIGIT_MF2 15 +#define DIGIT_MF3 16 +#define DIGIT_MF4 17 +#define DIGIT_MF5 18 +#define DIGIT_MF6 19 +#define DIGIT_MF7 20 +#define DIGIT_MF8 21 +#define DIGIT_MF9 22 +#define DIGIT_MFKP 23 +#define DIGIT_MFST 24 + +#define DIGIT_2600 25 #define DTMF_DURATION_MS 100 +#define MF_DURATION_MS 100 +#define DURATION_MS_2600 1500 // PWM frequency = 4Mhz/256 = 15625Hz; overflow cycles per MS = 15 #define T0_OVERFLOW_PER_MS 15 diff --git a/generic_schematic.jpg b/generic_schematic.jpg new file mode 100644 index 0000000..21abf40 Binary files /dev/null and b/generic_schematic.jpg differ diff --git a/main.c b/main.c index 436010d..603b5f9 100644 --- a/main.c +++ b/main.c @@ -14,6 +14,13 @@ // Cleaned up implementation, modified to work more like the // Rotatone commercial product. // +// Modified : Donald Froula 2019-07-28 +// http://projectmf.homelinux.com/pulsetotone +// Fixed not returning to normal dialing mode after * or # dialing or redial function. +// Added support for storing * and # in both redial and speed dial memories. +// Added blue box and hotline modes and EEPROM feature setting storage, tone mode stored in memories +// Added programmable digit length and hotdelay delay, EEPROM saved +// // This code is distributed under the GNU Public License // which can be found at http://www.gnu.org/licenses/gpl.txt // @@ -38,7 +45,7 @@ #define PIN_DIAL PB1 #define PIN_PULSE PB2 -#define SPEED_DIAL_SIZE 32 +#define SPEED_DIAL_SIZE 33 #define STATE_DIAL 0x00 #define STATE_SPECIAL_L1 0x01 @@ -52,15 +59,30 @@ #define SLEEP_64MS 0x00 #define SLEEP_128MS 0x01 -#define SLEEP_2S 0x02 +#define SLEEP_500MS 0x02 +#define SLEEP_1S 0x03 +#define SLEEP_2S 0x04 -#define SPEED_DIAL_COUNT 8 // 8 Positions in total (Redail(3),4,5,6,7,8,9,0) +#define SPEED_DIAL_COUNT 8 // 8 Positions in total (Redial(3),4,5,6,7,8,9,0) #define SPEED_DIAL_REDIAL (SPEED_DIAL_COUNT - 1) #define L2_STAR 1 #define L2_POUND 2 #define L2_REDIAL 3 +#define MODE_DTMF 0 +#define MODE_MF 1 +#define MF_OFFSET 13 + +#define FEAT_HOTLINE 0 //Bit position, not value +#define FEAT_BLUEBOX 1 //Bit position, not value + +#define DTMF_DURATION_UNIT 50 //Base unit of DTMF duration in milliseconds + +#define FEAT_EE 511 //Storage for feature flag - last location in EEPROM +#define HOTLINE_DELAY_EE 510 //Storage for hotline delay +#define DTMF_DURATION_EE 509 //Storage for DTMF duration + typedef struct { uint8_t state; @@ -72,6 +94,14 @@ typedef struct int8_t dialed_digit; } runstate_t; +int8_t pending_digit = 0; //(DRF) Stores * or # for injecting into main loop after dialing so they are picked up by the redial and programming functions. +int8_t prev_state; //(DRF) Keeps track of the previous state whenever a state change occurs. +int8_t tone_mode = MODE_DTMF; //(DRF) Default tone mode is DTMF +int8_t prev_tone_mode; +uint8_t feature_flags = 0; //(DRF) Feature flags +uint8_t hotline_delay = 1; //(DRF) Actual delay is 1000ms * this value, 1 second default +uint8_t dtmf_duration = 2; //(DRF) DTMF tone and space duration * 50 milliseconds (default 100ms) + static void init(void); static void process_dialed_digit(runstate_t *rs); static void dial_speed_dial_number(int8_t *speed_dial_digits, int8_t index); @@ -116,15 +146,56 @@ int main(void) rs->state = STATE_DIAL; rs->dial_pin_state = true; rs->flags = F_NONE; - rs->speed_dial_digit_index = 0; + rs->speed_dial_digit_index = 1; //Start after tone mode, which is saved at index 0. rs->speed_dial_index = 0; dial_pin_prev_state = true; - for (uint8_t i = 0; i < SPEED_DIAL_SIZE; i++) + //Initialize the local dial memory + rs->speed_dial_digits[0] = MODE_DTMF; //Save DTMF tone mode in first location - No redial storage in MF mode + for (uint8_t i = 1; i < SPEED_DIAL_SIZE; i++) rs->speed_dial_digits[i] = DIGIT_OFF; + + + //(DRF)Retrieve feature flags + feature_flags = eeprom_read_byte((uint8_t*)FEAT_EE); + + //Initialize EEPROM location, if needed + if(feature_flags > ((1 << FEAT_HOTLINE) | (1 << FEAT_BLUEBOX))){ + feature_flags = 0; + eeprom_write_byte((uint8_t*)FEAT_EE, feature_flags); + } + + //Retrieve hotline delay + hotline_delay = eeprom_read_byte((uint8_t*)HOTLINE_DELAY_EE); + + //Initialize EEPROM location, if needed + if((hotline_delay > 4) || (hotline_delay < 1)){ + hotline_delay = 1; + eeprom_write_byte((uint8_t*)HOTLINE_DELAY_EE, hotline_delay); + } + + //Retrieve DTMF duration + dtmf_duration = eeprom_read_byte((uint8_t*)DTMF_DURATION_EE); + + //Initialize EEPROM location, if needed + if((dtmf_duration > 4) || (dtmf_duration < 1)){ + dtmf_duration = 2; //* Initialize to 100ms + eeprom_write_byte((uint8_t*)DTMF_DURATION_EE, dtmf_duration); + } + + //(DRF)Set tone mode to DTMF for hotline feature + tone_mode = MODE_DTMF; + + //(DRF)For Hotline operation, dial location zero on powerup if enabled + if(feature_flags & (1 << FEAT_HOTLINE)){sleep_ms(hotline_delay * 1000); dial_speed_dial_number(rs->speed_dial_digits, _g_speed_dial_loc[0]);} + + //(DRF)Set tone mode according to stored feature flag now that hotline feature is done + if(feature_flags & (1 << FEAT_BLUEBOX)){tone_mode = MODE_MF;} else{tone_mode = MODE_DTMF;} + while (1) - { + { + rs->dial_pin_state = bit_is_set(PINB, PIN_DIAL); if (dial_pin_prev_state != rs->dial_pin_state) @@ -143,6 +214,7 @@ int main(void) { // Disable SF detection (should be already disabled) rs->flags = F_NONE; + // Check that we detect a valid digit if (rs->dialed_digit <= 0 || rs->dialed_digit > 10) @@ -177,7 +249,8 @@ int main(void) if (rs->dial_pin_state) { // Rotary dial at the rest position - // Reset all variables + // Reset all variablesrs->state + prev_state = rs->state; rs->state = STATE_DIAL; rs->flags = F_NONE; rs->dialed_digit = DIGIT_OFF; @@ -185,6 +258,9 @@ int main(void) } dial_pin_prev_state = rs->dial_pin_state; + + //(DRF) If a pending * or # or 2600 digit has been saved, play it immediately after returning to normal dial mode + if(pending_digit){rs->dialed_digit = pending_digit; pending_digit = 0; process_dialed_digit(rs);} // Don't power down if special function detection is active if (rs->flags & F_DETECT_SPECIAL_L1) @@ -198,6 +274,7 @@ int main(void) { // SF mode detected rs->flags &= ~F_WDT_AWAKE; + prev_state = rs->state; rs->state = STATE_SPECIAL_L1; rs->flags &= ~F_DETECT_SPECIAL_L1; rs->flags |= F_DETECT_SPECIAL_L2; @@ -216,6 +293,7 @@ int main(void) { // SF mode detected rs->flags &= ~F_WDT_AWAKE; + prev_state = rs->state; rs->state = STATE_SPECIAL_L2; rs->flags &= ~F_DETECT_SPECIAL_L2; @@ -240,15 +318,19 @@ static void process_dialed_digit(runstate_t *rs) { // Standard (no speed dial, no special function) mode // Generate DTMF code - dtmf_generate_tone(rs->dialed_digit, DTMF_DURATION_MS); + //(DRF) Add MF tone capability + if (tone_mode == MODE_MF){dtmf_generate_tone(rs->dialed_digit + MF_OFFSET, dtmf_duration * DTMF_DURATION_UNIT);} + else {dtmf_generate_tone(rs->dialed_digit, dtmf_duration * DTMF_DURATION_UNIT);} if (rs->speed_dial_digit_index < SPEED_DIAL_SIZE) { + if(tone_mode == MODE_DTMF){ //Only save to redial if in DTMF mode // During regular dial always save into the 'Redial' position of the speed dial memory rs->speed_dial_digits[rs->speed_dial_digit_index] = rs->dialed_digit; rs->speed_dial_digit_index++; write_current_speed_dial(rs->speed_dial_digits, SPEED_DIAL_REDIAL); + } } } else if (rs->state == STATE_SPECIAL_L1) @@ -256,48 +338,118 @@ static void process_dialed_digit(runstate_t *rs) if (rs->dialed_digit == L2_STAR) { // SF 1-* - dtmf_generate_tone(DIGIT_STAR, DTMF_DURATION_MS); + //dtmf_generate_tone(DIGIT_STAR, dtmf_duration * DTMF_DURATION_UNIT); + pending_digit = DIGIT_STAR; //(DRF) Just push the tone to the pending_digit variable to be played immediately when returned to STATE_DIAL } else if (rs->dialed_digit == L2_POUND) { // SF 2-# - dtmf_generate_tone(DIGIT_POUND, DTMF_DURATION_MS); + //dtmf_generate_tone(DIGIT_POUND, dtmf_duration * DTMF_DURATION_UNIT); + pending_digit = DIGIT_POUND; //(DRF) Just push the tone to the pending_digit variable to be played immediately when returned to STATE_DIAL } else if (rs->dialed_digit == L2_REDIAL) { // SF 3 (Redial) - dial_speed_dial_number(rs->speed_dial_digits, SPEED_DIAL_REDIAL); + //(DRF) Add MF tone capability + if (tone_mode == MODE_MF){pending_digit = DIGIT_PRE2600;} //No redial function in MF mode. Play 2600 instead + else{dial_speed_dial_number(rs->speed_dial_digits, SPEED_DIAL_REDIAL);} } else if (_g_speed_dial_loc[rs->dialed_digit] >= 0) { // Call speed dial number dial_speed_dial_number(rs->speed_dial_digits, _g_speed_dial_loc[rs->dialed_digit]); } + rs->state = prev_state; //(DRF) Return to the previous state after entering STATE_SPECIAL_L1. Allows normal dialing after using + //special functions, not possible before the fix. Also allows * and # to be programmed into speed dial, + //returning to programming mode if a * or # is dialed while programming. } else if (rs->state == STATE_SPECIAL_L2) { if (_g_speed_dial_loc[rs->dialed_digit] >= 0) { - rs->speed_dial_index = _g_speed_dial_loc[rs->dialed_digit]; - rs->speed_dial_digit_index = 0; - - for (uint8_t i = 0; i < SPEED_DIAL_SIZE; i++) + rs->speed_dial_index = _g_speed_dial_loc[rs->dialed_digit]; //Set the speed dial memory slot to dialed number + rs->speed_dial_digit_index = 1; //Reset dialed digits buffer pointer + rs->speed_dial_digits[0] = tone_mode; //Save current tone mode in first location + for (uint8_t i = 1; i < SPEED_DIAL_SIZE; i++) //Initialize the digits buffer rs->speed_dial_digits[i] = DIGIT_OFF; - + prev_state = rs->state; rs->state = STATE_PROGRAM_SD; - } - else - { - // Not a speed dial position. Revert back to ordinary dial + } + //(DRF) Add hotline capability. + else if(rs->dialed_digit == 1){ + //Set Hotline flag and cycle through delays + if(feature_flags & (1 << FEAT_HOTLINE)){ //If feature is "on"... + hotline_delay += 1; //Increase the delay by one second + if(hotline_delay > 4){ + hotline_delay = 1; + feature_flags &= ~(1 << FEAT_HOTLINE); //Turn off the hotline feature if more than 4 seconds + dtmf_generate_tone(DIGIT_TUNE_DESC2, 800); + } + else{ + for(int i=1; i<=hotline_delay; i++){ //Beep out number of seconds set + dtmf_generate_tone(DIGIT_BEEP_LOW, 200); + sleep_ms(200); + } //Beep out number of seconds set + } + } + else { //If hotline feature is off + feature_flags |= (1 << FEAT_HOTLINE); //Turn it on + for(int i=1; i<=hotline_delay; i++){ + if(i == 1){dtmf_generate_tone(DIGIT_TUNE_ASC2, 800); sleep_ms(200);} + dtmf_generate_tone(DIGIT_BEEP_LOW, 200); + sleep_ms(200); + } //Beep out number of seconds set + } + eeprom_write_byte((uint8_t*)FEAT_EE,feature_flags); + eeprom_write_byte((uint8_t*)HOTLINE_DELAY_EE, hotline_delay); + prev_state = rs->state; rs->state = STATE_DIAL; - } + } + //(DRF) Add DTMF duration setting capability. + else if(rs->dialed_digit == 2){ + //Cycle through DTMF duration settings in 50ms steps + dtmf_duration += 1; //Increase the duration by 50ms + if(dtmf_duration > 4){dtmf_duration = 1;} + for(int i=1; i<=dtmf_duration; i++){ //Beep out number of 50ms units set + dtmf_generate_tone(DIGIT_BEEP, 200); + sleep_ms(200); + } + eeprom_write_byte((uint8_t*)DTMF_DURATION_EE, dtmf_duration); + prev_state = rs->state; + rs->state = STATE_DIAL; + } + //(DRF) Add MF tone capability. If entering program mode on Digit 1, toggle DTMF/MF tone mode + else if(rs->dialed_digit == 3){ + //Toggle Bluebox flag + if(feature_flags & (1 << FEAT_BLUEBOX)){ //If feature is "on"... + feature_flags &= ~(1 << FEAT_BLUEBOX); + tone_mode = MODE_DTMF; + dtmf_generate_tone(DIGIT_TUNE_DESC2, 800); + } + else { + feature_flags |= (1 << FEAT_BLUEBOX); + tone_mode = MODE_MF; + dtmf_generate_tone(DIGIT_TUNE_ASC2, 800); + } + eeprom_write_byte((uint8_t*)FEAT_EE,feature_flags); + prev_state = rs->state; + rs->state = STATE_DIAL; + } + else{ + // Not a speed dial position. Revert back to ordinary dial + prev_state = rs->state; + rs->state = STATE_DIAL; + } } + + else if (rs->state == STATE_PROGRAM_SD) { // Do we have too many digits entered? if (rs->speed_dial_digit_index >= SPEED_DIAL_SIZE) { // Exit speed dial mode + prev_state = rs->state; rs->state = STATE_DIAL; // Beep to indicate that we done dtmf_generate_tone(DIGIT_TUNE_DESC, 800); @@ -309,7 +461,7 @@ static void process_dialed_digit(runstate_t *rs) rs->speed_dial_digit_index++; // Generic beep - do not gererate DTMF code - dtmf_generate_tone(DIGIT_BEEP_LOW, DTMF_DURATION_MS); + dtmf_generate_tone(DIGIT_BEEP_LOW, dtmf_duration * DTMF_DURATION_UNIT); } // Write SD on every digit so user can hang up to save @@ -323,21 +475,32 @@ static void dial_speed_dial_number(int8_t *speed_dial_digits, int8_t index) if (index >= 0 && index < SPEED_DIAL_COUNT) { eeprom_read_block(speed_dial_digits, &_g_speed_dial_eeprom[index][0], SPEED_DIAL_SIZE); - - for (uint8_t i = 0; i < SPEED_DIAL_SIZE; i++) + + prev_tone_mode = tone_mode; //Save current tone mode + tone_mode = speed_dial_digits[0]; //Set saved tone mode as active + for (uint8_t i = 1; i < SPEED_DIAL_SIZE; i++) { // Dial the number // Skip dialing invalid digits - if (speed_dial_digits[i] >= 0 && speed_dial_digits[i] <= DIGIT_POUND) + //(DRF) Add MF tone capability + if (speed_dial_digits[i] >= 0 && speed_dial_digits[i] <= DIGIT_PRE2600) { - dtmf_generate_tone(speed_dial_digits[i], DTMF_DURATION_MS); - // Pause between DTMF tones - sleep_ms(DTMF_DURATION_MS); + //(DRF) Add MF tone capability + //if (tone_mode == MODE_DTMF && speed_dial_digits[i] == DIGIT_PRE2600){i++;} //Skip saved 2600 if in DTMF mode + if(tone_mode == MODE_MF){dtmf_generate_tone(speed_dial_digits[i] + MF_OFFSET, dtmf_duration * DTMF_DURATION_UNIT);} + else {dtmf_generate_tone(speed_dial_digits[i], dtmf_duration * DTMF_DURATION_UNIT);} + //(DRF)Add MF support + if(tone_mode == MODE_MF){ + if(speed_dial_digits[i] == DIGIT_PRE2600){sleep_ms(DURATION_MS_2600);} else{sleep_ms(dtmf_duration * DTMF_DURATION_UNIT);} + } + else{sleep_ms(dtmf_duration * DTMF_DURATION_UNIT);} } } + tone_mode = prev_tone_mode; //Restore tone mode from value saved in speed dial } } + static void write_current_speed_dial(int8_t *speed_dial_digits, int8_t index) { if (index >= 0 && index < SPEED_DIAL_COUNT) @@ -386,6 +549,11 @@ static void wdt_timer_start(uint8_t delay) case SLEEP_128MS: WDTCR = _BV(WDIE) | _BV(WDP1) | _BV(WDP0); break; + case SLEEP_500MS: + WDTCR = _BV(WDIE) | _BV(WDP0) | _BV(WDP2); // 500ms + case SLEEP_1S: + WDTCR = _BV(WDIE) | _BV(WDP1) | _BV(WDP2); // 1024ms + break; case SLEEP_2S: WDTCR = _BV(WDIE) | _BV(WDP0) | _BV(WDP1) | _BV(WDP2); // 2048ms break; @@ -440,4 +608,4 @@ ISR(BADISR_vect) ISR(WDT_vect) { _g_run_state.flags |= F_WDT_AWAKE; -} \ No newline at end of file +} diff --git a/rotarydial.hex b/rotarydial.hex index 31b1bd6..380806c 100644 --- a/rotarydial.hex +++ b/rotarydial.hex @@ -1,116 +1,178 @@ -:100000000EC07EC092C026C025C0C6C023C022C07C -:1000100021C020C01FC01EC08AC01CC01BC011242C +:100000000EC05DC073C026C025C053C323C022C02C +:1000100021C020C01FC01EC07DC01CC01BC0112439 :100020001FBECFE5D2E0DEBFCDBF11E0A0E6B0E05D -:10003000EEE7F6E002C005900D92A230B107D9F7C5 -:1000400021E0A2E0B1E001C01D92A233B207E1F7C6 -:10005000A0D113C36BC0A895F89414BE91B5986154 -:1000600091BD813031F0823031F082E481BD7894ED -:10007000089583E4FBCF87E4F9CFA895F89414BEE4 -:1000800081B5886181BD11BC7894089585B7877E5C -:10009000806185BFF89485B7806285BF85B7846825 -:1000A00085BF8B7F85BF7894889585B78F7D85BF09 -:1000B00008950F931F93CF93DF938C01062E000CAE -:1000C000770B85E0660F771F8A95E1F760507040E7 -:1000D00040E250E0C801A0D2E801005E1F4F8991C4 -:1000E0008C3030F464E670E0F6D084E690E0CDD059 -:1000F000C017D107A1F7DF91CF911F910F910895FC -:100100001F921FB61F9211248F93809104018111B9 -:1001100007C010920301809127018F5F8093270110 -:100120008F911F901FBE1F901895189518958F934B -:100130008FB78F93EF93FF93E2E0F1E081818460CA -:100140008183FF91EF918F918FBF8F9118958AB521 -:1001500080688ABD8AB58F7B8ABD089582E089BF99 -:1001600083E08ABD81E083BF12BE19BCB89A1092A9 -:100170002F0110922C0110922E0110922D0110923D -:100180003101109230011092280110922901109231 -:100190002A0110922B0108950F920FB60F921F9211 -:1001A00011242F933F934F935F938F939F93AF931C -:1001B000BF93EF93FF9380912F0120912D013091F8 -:1001C0002E01820F932F911D90932E0180932D016C -:1001D000E0912D01F0912E01349633E0F695E795EC -:1001E0003A95E1F7EF770E2E000CFF0BEE57FF4F1D -:1001F000808190912C01992309F445C020912C0114 -:100200004091300150913101240F352F311D309331 -:10021000310120933001E0913001F09131013496A9 -:1002200093E0F695E7959A95E1F7EF770E2E000C9F -:10023000FF0BEE57FF4F9081890F96959695891B7E -:1002400089BD8091280190912901A0912A01B09146 -:100250002B010196A11DB11D8093280190932901C6 -:10026000A0932A01B0932B01FF91EF91BF91AF9121 -:100270009F918F915F914F913F912F911F900F9080 -:100280000FBE0F90189590E0D7CF109228011092D2 -:10029000290110922A0110922B0125B7277E25BF34 -:1002A0006FE070E094D1B0E0A0E04091280150915F -:1002B000290160912A0170912B0184179507A607E7 -:1002C000B70708F4089525B7206225BF889525B79C -:1002D0002F7D25BFEACFCF93DF93EB011BBE8C3080 -:1002E000F0F4E82FEE0FFF0BE659FF4F808180936B -:1002F0002F01818180932C012ADFCE01C6DF8AB5D0 -:100300008F778ABD8AB58F7B8ABDC09810922F01E6 -:1003100010922C0180E68BBFDF91CF910895863F2C -:1003200031F482E480932F0110922C01E5CF833FBA -:1003300011F481E2F7CF853FB1F482E280932F017F -:1003400010922C0104DFCE0163E070E051D1EB018B -:10035000CB019BDF8BE280932F01CE0196DF83E3FD -:1003600080932F01CACF843F51F683E380932F01FE -:1003700010922C01ECDECE0163E070E039D1EB018C -:10038000CB0183DF8BE280932F01CE017EDF82E2FF -:10039000E7CF90E896BD16BC88B3866088BB8BE03B -:1003A00080BD98B983E085BF80E68BBF86E085BBC2 -:1003B000789481E050DE6ADE60DED0DE10920201C9 -:1003C00081E08093040110920301109206011092C3 -:1003D0000501E7E0F1E08FEF819391E0E732F90763 -:1003E000D9F701E0D1E0CFEF13E026B3922F92705E -:1003F00021FB882780F980930401801709F4BEC08F -:10040000911122C0809103018160809303011092B9 -:10041000270180E020DE3ADE009104018091030193 -:1004200080FFB6C082E017DE31DE8091030182FFDB -:10043000DCCFD09302018A7F82608093030168EC55 -:1004400070E083EF48DFD1CF109203018091270144 -:100450009FEF980F9A3018F0C0932701DACF8A30B7 -:1004600011F41092270181E0F6DD10DE06DE8091A6 -:10047000020181111BC064E670E0809127012BDF2F -:1004800080910601803240F6E82FF0E0EE5FFE4FEB -:100490009091270195838F5F8093060140E250E0A1 -:1004A00060EE70E087E091E0C7D0B6CF8130F1F424 -:1004B000E091270164E670E08AE0E13029F0E23063 -:1004C00029F464E670E08BE006DFA6CF67E0E33056 -:1004D00049F00E2E000CFF0BE05AFF4F6081683090 -:1004E00008F09ACF87E091E0E4DD96CF8230D9F42E -:1004F000E09127010E2E000CFF0BE05AFF4F808188 -:1005000087FD0EC08093050110920601E7E0F1E03F -:10051000C19381E0E732F807D9F7109302017CCF4D -:100520001092020179CF833009F076CF80910601D5 -:100530008032B0F01092020160E273E084EFCBDE13 -:1005400060910501683008F067CF70E085E0660FC4 -:10055000771F8A95E1F76050704040E250E0A2CFEB -:10056000E82FF0E0EE5FFE4F9091270195838F5FBB -:100570008093060164E670E083EFE1CF992309F4EC -:100580004BCF1092020110920301C093270144CF78 -:1005900081FF11C082E05FDD79DD8091030182FF80 -:1005A00024CF92E090930201897F8093030168EC4D -:1005B00070E085EF47CF85B7877E806185BF85B7BF -:1005C000806285BF889585B78F7D85BF0ECF00245B -:1005D000552704C0080E591F880F991F009729F04E -:1005E00076956795B8F37105B9F7802D952F089525 -:1005F000AA1BBB1B51E107C0AA1FBB1FA617B70749 -:1006000010F0A61BB70B881F991F5A95A9F7809564 -:100610009095BC01CD010895DC01CB01FC01E1996D -:10062000FECF06C0FFBBEEBBE09A31960DB20D9235 -:1006300041505040B8F70895DC01A40FB51F415058 -:10064000504040F0CB01840F951F2E9105D04150B2 -:100650005040D8F70895262FE199FECF9FBB8EBB5F -:10066000E09A01970DB2021639F01CBA2DBB0FB6F5 -:0E067000F894E29AE19A0FBE0895F894FFCF35 -:10067E0000FFFFFF010203040506573D4F2E572EC4 -:10068E00602E4F32573260324F38573860384F3DF8 -:10069E00603D404346494C4F5255585B5E60636621 -:1006AE00686A6D6F7173757678797B7C7D7E7E7FDF -:1006BE007F7F7F7F7F7F7E7E7D7C7B797876757373 -:1006CE00716F6D6A686663605E5B5855524F4C4938 -:1006DE004643403C393633302D2A2724211F1C191E -:1006EE00171512100E0C0A09070604030201010069 -:1006FE0000000000000001010203040607090A0CB5 -:10070E000E10121517191C1F2124272A2D303336CF -:02071E00393C64 +:10003000E2E4FAE002C005900D92A032B107D9F7D0 +:1000400011E0A0E2B1E001C01D92A635B107E1F7D1 +:100050000CD2F5C455C0982FA895F89414BE81B55C +:10006000886181BD923081F0933028F4992341F06A +:10007000913081F407C0933049F0943059F408C0AE +:1000800082E407C083E405C085E481BD86E401C045 +:1000900087E481BD7894089585B7877E806185BFA8 +:1000A000F89485B7806285BF85B7846885BF8B7FEC +:1000B00085BF7894889585B78F7D85BF08951F92F9 +:1000C0000F920FB60F9211248F93809125018823F0 +:1000D00039F410922401809149018F5F8093490186 +:1000E0008F910F900FBE0F901F9018951F920F9237 +:1000F0000FB60F9211240F900FBE0F901F901895FE +:100100001F920F920FB60F9211240F900FBE0F90F7 +:100110001F9018951F920F920FB60F9211248F9374 +:10012000809124018460809324018F910F900FBEF1 +:100130000F901F9018951F93CF93DF93EC016830B9 +:1001400008F049C0862F992787FD909561E270E0FD +:1001500009D4BC0160507040CE0141E250E028D487 +:100160008091210180934B0188818093210111E0CE +:1001700029812D3040F580912101909161008130DD +:1001800049F4892F90E062E370E0ECD3BC01822F48 +:10019000835F07C0892F90E062E370E0E3D3BC0186 +:1001A000822F22D380912101813031F489818C30DA +:1001B00019F48CED95E006C08091610090E062E357 +:1001C00070E0D0D3EAD21F5F2196113289F6809178 +:1001D0004B0180932101DF91CF911F9108950F93DF +:1001E0001F93CF93DF93EC018881882369F5809179 +:1001F000210190916100813051F42EA1892F90E06E +:1002000062E370E0AFD3BC01822F835F07C0892F08 +:1002100090E062E370E0A6D3BC018EA1E5D29C81A0 +:10022000913208F01DC180912101882309F018C185 +:10023000FE01E90FF11D8EA185839F5F9C83CE0196 +:10024000059667EE70E009C1813029F5EEA1E13035 +:1002500011F48AE00BC0E23011F48BE007C0E33008 +:1002600061F480912101813021F48CE080932001A0 +:100270000FC0CE01059667E00AC0FF27E7FDF095A5 +:10028000EE59FF4F608167FD03C0CE01059653DF35 +:1002900080914A011FC0823009F0B5C02EA1E22F23 +:1002A000FF27E7FDF095EE59FF4FE081E7FD14C011 +:1002B000EB8381E08C83809121018D83FE0181E0BD +:1002C0009FEF96838F5F31968132D9F78881809333 +:1002D0004A0183E08883C4C0213009F051C0909165 +:1002E000220190FF24C0809160008F5F80936000A6 +:1002F000853018F401E010E013C0209360009E7F69 +:100300009093220181EF60E273E06ED22FC083EF01 +:1003100068EC70E069D288EC90E03FD20F5F1F4F2D +:100320008091600090E0801791078CF71FC091606A +:100330009093220101E010E013C00130110539F45F +:1003400082EF60E273E050D288EC90E026D283EF37 +:1003500068EC70E049D288EC90E01FD20F5F1F4F2D +:100360008091600090E0801791073CF78FEF91E05B +:100370006091220156D38EEF91E0609160003DC004 +:10038000223001F5809161008F5F8093610085309C +:1003900018F081E08093610001E010E009C086EF71 +:1003A00068EC70E021D288EC90E0F7D10F5F1F4F2E +:1003B00060916100862F90E08017910784F78DEFA0 +:1003C00091E01BC02330D9F48091220181FF07C046 +:1003D0008D7F809322011092210181EF07C08260FE +:1003E0008093220181E08093210182EF60E273E03B +:1003F000FBD18FEF91E06091220113D3888180932C +:100400004A0118822DC0833059F59C81913238F011 +:1004100080934A01188284EF60E273E00FC0FE010E +:10042000E90FF11D8EA185839F5F9C838091610000 +:1004300090E062E370E096D2BC0183EFD5D18B816E +:10044000883070F4992787FD909561E270E08AD238 +:10045000BC0160507040CE01059641E250E0C0D230 +:10046000DF91CF911F910F910895FF920F931F93EA +:1004700090E896BD16BC88B3866088BB8BE080BDD3 +:1004800098B983E085BF80E68BBF86E085BB789412 +:1004900081E0E1DD01DEA895F89414BE81B58861A4 +:1004A00081BD11BC7894E7D01092230181E0809344 +:1004B00025011092240180932701109226011092A9 +:1004C0002801E9E2F1E08FEF819391E0E934F90747 +:1004D000D9F78FEF91E07CD280932201843030F005 +:1004E000109222018FEF91E060E09BD28EEF91E0BD +:1004F0006FD2809360008150843038F081E0809327 +:1005000060008EEF91E061E08CD28DEF91E060D2DF +:10051000809361008150843038F082E080936100E4 +:100520008DEF91E062E07DD2109221018091220155 +:1005300080FF0BC08091600090E068EE73E012D203 +:100540002CD188E291E060E0F6DD8091220181FF0C +:1005500004C081E08093210102C01092210111E0CA +:100560000FEF32E0F32E86B390E096958795817079 +:1005700080932501181759F1882341F480912401B3 +:10058000816080932401109249010AC010922401D5 +:1005900090914901892F81508A3030F000934901B0 +:1005A00080E059DD79DD1FC09A3011F410924901C5 +:1005B00081E051DD71DDA895F89414BE81B58861A4 +:1005C00081BD11BC789483E291E009DE0CC0112357 +:1005D00051F08091230180934A01109223011092DF +:1005E0002401009349011091250180912001882365 +:1005F00039F0809349011092200183E291E0EFDD10 +:100600008091240180FF14C084E025DD45DD9091B8 +:10061000240192FFA8CF8091230180934A0181E0B9 +:10062000809323019A7F92609093240183EF13C0FB +:1006300081FF15C084E00FDD2FDD9091240192FF32 +:1006400092CF8091230180934A01F0922301997FF8 +:100650009093240185EF68EC70E0C6D084CF85B715 +:10066000877E806185BF85B7806285BF889585B7A5 +:100670008F7D85BF78CF82E089BF83E08ABD81E02E +:1006800083BF12BE19BCB89A109253011092500148 +:100690001092520110925101109255011092540182 +:1006A00010924C0110924D0110924E0110924F0188 +:1006B00008951F920F920FB60F9211242F933F931C +:1006C0008F939F93AF93BF93EF93FF9380915101CB +:1006D0009091520120915301820F911D90935201EC +:1006E00080935101E0915101F0915201349693E0D1 +:1006F000F695E7959A95E1F7FF27E7FDF095EF77F7 +:10070000F070E459FF4F308180915001882311F43B +:10071000E0E01EC08091540190915501209150015C +:10072000820F911D9093550180935401E0915401E3 +:10073000F0915501349683E0F695E7958A95E1F7B7 +:10074000FF27E7FDF095EF77F070E459FF4FE08168 +:100750003E0FE695E6953E1B39BD80914C01909188 +:100760004D01A0914E01B0914F010196A11DB11D07 +:1007700080934C0190934D01A0934E01B0934F0193 +:10078000FF91EF91BF91AF919F918F913F912F91E9 +:100790000F900FBE0F901F90189510924C01109261 +:1007A0004D0110924E0110924F0125B7277E25BFB3 +:1007B0006FE070E0D7D09C0140E050E007C085B703 +:1007C000806285BF889585B78F7D85BF80914C01FC +:1007D00090914D01A0914E01B0914F01281739071A +:1007E0004A075B0760F708950F931F93282F1BBEDE +:1007F0008A31C8F4E82FFF27E7FDF095EE0FFF1FC1 +:10080000E451FF4F80818093530181818093500197 +:100810008AB580688ABD8AB58F7B8ABD2931A1F4EB +:100820008CED95E08EC0863F11F482E403C0833FD7 +:1008300069F481E280935301109250018AB5806877 +:100840008ABD8AB58F7B8ABDCB017BC0853FE1F431 +:1008500082E280935301109250018AB580688ABD6C +:100860008AB58F7B8ABDCB0163E070E08DD0162FF7 +:10087000072F862F972F91DF8BE280935301812FD3 +:10088000902F8BDF83E359C0823FE1F485E58093AD +:100890005301109250018AB580688ABD8AB58F7B5A +:1008A0008ABDCB0166E070E06FD0162F072F862F30 +:1008B000972F73DF82E680935301812F902F6DDF96 +:1008C0008FE63BC0843FE1F483E3809353011092B1 +:1008D00050018AB580688ABD8AB58F7B8ABDCB01FD +:1008E00063E070E051D0162F072F862F972F55DF2A +:1008F0008BE280935301812F902F4FDF82E21DC046 +:10090000813F01F58FE680935301109250018AB523 +:1009100080688ABD8AB58F7B8ABDCB0166E070E0B6 +:1009200033D0162F072F862F972F37DF82E680933D +:100930005301812F902F31DF85E580935301812F63 +:10094000902F2BDF8AB58F778ABD8AB58F7B8ABDC2 +:10095000C098109253011092500180E68BBF1F91F6 +:100960000F9108955527002480FF02C0060E571FDF +:10097000660F771F6115710521F096958795009791 +:1009800099F7952F802D0895AA1BBB1B51E107C035 +:10099000AA1FBB1FA617B70710F0A61BB70B881F0F +:1009A000991F5A95A9F780959095BC01CD0108959E +:1009B000DC01CB01FC01E199FECF06C0FFBBEEBB21 +:1009C000E09A31960DB20D9241505040B8F708951B +:1009D000E199FECF9FBB8EBBE09A99278DB3089516 +:1009E000DC01A40FB51F4150504040F0CB01840FF3 +:1009F000951F2E9105D041505040D8F70895262FCD +:100A0000E199FECF9FBB8EBBE09A01970DB2021613 +:100A100039F01CBA2DBB0FB6F894E29AE19A0FBEDA +:100A20000895262FE199FECF1CBA9FBB8EBB2DBB2C +:100A30000FB6F894E29AE19A0FBE01960895F894E1 +:020A4000FFCFE6 +:100A4200010200FFFFFF010203040506404346497D +:100A52004C4F5255585B5E606366686A6D6F717386 +:100A6200757678797B7C7D7E7E7F7F7F7F7F7F7FBF +:100A72007E7E7D7C7B7978767573716F6D6A686630 +:100A820063605E5B5855524F4C494643403C393691 +:100A920033302D2A2724211F1C19171512100E0C72 +:100AA2000A09070604030201010000000000000019 +:100AB20001010203040607090A0C0E101215171988 +:100AC2001C1F2124272A2D303336393C573D4F2E07 +:100AD200572E602E4F32573260324F3857386038B7 +:100AE2004F3D603D000055622E3B2E483B482E553F +:100AF2003B5548552E623B624862486F626FAA00BE :00000001FF diff --git a/rotarydial_nz.hex b/rotarydial_nz.hex index dd464e2..c81ce75 100644 --- a/rotarydial_nz.hex +++ b/rotarydial_nz.hex @@ -1,117 +1,178 @@ -:100000000EC07EC092C026C025C0C6C023C022C07C -:1000100021C020C01FC01EC08AC01CC01BC011242C +:100000000EC05DC073C026C025C056C323C022C029 +:1000100021C020C01FC01EC07DC01CC01BC0112439 :100020001FBECFE5D2E0DEBFCDBF11E0A0E6B0E05D -:10003000E2E8F6E002C005900D92A230B107D9F7D0 -:1000400021E0A2E0B1E001C01D92A233B207E1F7C6 -:10005000A0D115C36BC0A895F89414BE91B5986152 -:1000600091BD813031F0823031F082E481BD7894ED -:10007000089583E4FBCF87E4F9CFA895F89414BEE4 -:1000800081B5886181BD11BC7894089585B7877E5C -:10009000806185BFF89485B7806285BF85B7846825 -:1000A00085BF8B7F85BF7894889585B78F7D85BF09 -:1000B00008950F931F93CF93DF938C01062E000CAE -:1000C000770B85E0660F771F8A95E1F760507040E7 -:1000D00040E250E0C801A2D2E801005E1F4F8991C2 -:1000E0008C3030F464E670E0F6D084E690E0CDD059 -:1000F000C017D107A1F7DF91CF911F910F910895FC -:100100001F921FB61F9211248F93809104018111B9 -:1001100007C010920301809127018F5F8093270110 -:100120008F911F901FBE1F901895189518958F934B -:100130008FB78F93EF93FF93E2E0F1E081818460CA -:100140008183FF91EF918F918FBF8F9118958AB521 -:1001500080688ABD8AB58F7B8ABD089582E089BF99 -:1001600083E08ABD81E083BF12BE19BCB89A1092A9 -:100170002F0110922C0110922E0110922D0110923D -:100180003101109230011092280110922901109231 -:100190002A0110922B0108950F920FB60F921F9211 -:1001A00011242F933F934F935F938F939F93AF931C -:1001B000BF93EF93FF9380912F0120912D013091F8 -:1001C0002E01820F932F911D90932E0180932D016C -:1001D000E0912D01F0912E01349633E0F695E795EC -:1001E0003A95E1F7EF770E2E000CFF0BEE57FF4F1D -:1001F000808190912C01992309F445C020912C0114 -:100200004091300150913101240F352F311D309331 -:10021000310120933001E0913001F09131013496A9 -:1002200093E0F695E7959A95E1F7EF770E2E000C9F -:10023000FF0BEE57FF4F9081890F96959695891B7E -:1002400089BD8091280190912901A0912A01B09146 -:100250002B010196A11DB11D8093280190932901C6 -:10026000A0932A01B0932B01FF91EF91BF91AF9121 -:100270009F918F915F914F913F912F911F900F9080 -:100280000FBE0F90189590E0D7CF109228011092D2 -:10029000290110922A0110922B0125B7277E25BF34 -:1002A0006FE070E096D1B0E0A0E04091280150915D -:1002B000290160912A0170912B0184179507A607E7 -:1002C000B70708F4089525B7206225BF889525B79C -:1002D0002F7D25BFEACFCF93DF93EB011BBE8C3080 -:1002E000F0F4E82FEE0FFF0BE659FF4F808180936B -:1002F0002F01818180932C012ADFCE01C6DF8AB5D0 -:100300008F778ABD8AB58F7B8ABDC09810922F01E6 -:1003100010922C0180E68BBFDF91CF910895863F2C -:1003200031F482E480932F0110922C01E5CF833FBA -:1003300011F481E2F7CF853FB1F482E280932F017F -:1003400010922C0104DFCE0163E070E053D1EB0189 -:10035000CB019BDF8BE280932F01CE0196DF83E3FD -:1003600080932F01CACF843F51F683E380932F01FE -:1003700010922C01ECDECE0163E070E03BD1EB018A -:10038000CB0183DF8BE280932F01CE017EDF82E2FF -:10039000E7CF90E896BD16BC88B3866088BB8BE03B -:1003A00080BD98B983E085BF80E68BBF86E085BBC2 -:1003B000789481E050DE6ADE60DED0DE10920201C9 -:1003C00081E08093040110920301109206011092C3 -:1003D0000501E7E0F1E08FEF819391E0E732F90763 -:1003E000D9F7FF24F394D1E0CFEF1AE003E026B36E -:1003F000922F927021FB882780F9809304018F153A -:1004000009F4BEC0911122C08091030181608093E4 -:1004100003011092270180E01EDE38DEF090040117 -:100420008091030180FFB6C082E015DE2FDE80914F -:10043000030182FFDCCFD09302018A7F8260809328 -:10044000030168EC70E083EF46DFD1CF1092030127 -:10045000809127019FEF980F9A3018F0C0932701E1 -:10046000DACF912F981B9093270181E0F4DD0EDE07 -:1004700004DE8091020181111BC064E670E080916E -:10048000270129DF80910601803240F6E82FF0E055 -:10049000EE5FFE4F9091270195838F5F8093060159 -:1004A00040E250E060EE70E087E091E0C7D0B6CF68 -:1004B0008130F1F4E091270164E670E08AE0E130F8 -:1004C00029F0E23029F464E670E08BE004DFA6CF87 -:1004D00067E0E33049F00E2E000CFF0BE05AFF4FAF -:1004E0006081683008F09ACF87E091E0E2DD96CF36 -:1004F0008230D9F4E09127010E2E000CFF0BE05A58 -:10050000FF4F808187FD0EC0809305011092060188 -:10051000E7E0F1E0C19381E0E732F807D9F7009313 -:1005200002017CCF1092020179CF833009F076CF9F -:10053000809106018032B0F01092020160E273E017 -:1005400084EFC9DE60910501683008F067CF70E084 -:1005500085E0660F771F8A95E1F76050704040E2B2 -:1005600050E0A2CFE82FF0E0EE5FFE4F9091270120 -:1005700095838F5F8093060164E670E083EFE1CF9F -:10058000992309F44BCF1092020110920301C093FA -:10059000270144CF81FF11C082E05DDD77DD8091CE -:1005A000030182FF24CF92E090930201897F809320 -:1005B000030168EC70E085EF47CF85B7877E8061E7 -:1005C00085BF85B7806285BF889585B78F7D85BFDC -:1005D0000ECF0024552704C0080E591F880F991FFD -:1005E000009729F076956795B8F37105B9F7802DD6 -:1005F000952F0895AA1BBB1B51E107C0AA1FBB1F63 -:10060000A617B70710F0A61BB70B881F991F5A959E -:10061000A9F780959095BC01CD010895DC01CB012F -:10062000FC01E199FECF06C0FFBBEEBBE09A31961C -:100630000DB20D9241505040B8F70895DC01A40F5F -:10064000B51F4150504040F0CB01840F951F2E91B3 -:1006500005D041505040D8F70895262FE199FECF9C -:100660009FBB8EBBE09A01970DB2021639F01CBAFF -:100670002DBB0FB6F894E29AE19A0FBE0895F89454 -:02068000FFCFAA -:1006820000FFFFFF010203040506573D4F2E572EC0 -:10069200602E4F32573260324F38573860384F3DF4 -:1006A200603D404346494C4F5255585B5E6063661D -:1006B200686A6D6F7173757678797B7C7D7E7E7FDB -:1006C2007F7F7F7F7F7F7E7E7D7C7B79787675736F -:1006D200716F6D6A686663605E5B5855524F4C4934 -:1006E2004643403C393633302D2A2724211F1C191A -:1006F200171512100E0C0A09070604030201010065 -:1007020000000000000001010203040607090A0CB0 -:100712000E10121517191C1F2124272A2D303336CB -:02072200393C60 +:10003000E8E4FAE002C005900D92A032B107D9F7CA +:1000400011E0A0E2B1E001C01D92A635B107E1F7D1 +:100050000CD2F8C455C0982FA895F89414BE81B559 +:10006000886181BD923081F0933028F4992341F06A +:10007000913081F407C0933049F0943059F408C0AE +:1000800082E407C083E405C085E481BD86E401C045 +:1000900087E481BD7894089585B7877E806185BFA8 +:1000A000F89485B7806285BF85B7846885BF8B7FEC +:1000B00085BF7894889585B78F7D85BF08951F92F9 +:1000C0000F920FB60F9211248F93809125018823F0 +:1000D00039F410922401809149018F5F8093490186 +:1000E0008F910F900FBE0F901F9018951F920F9237 +:1000F0000FB60F9211240F900FBE0F901F901895FE +:100100001F920F920FB60F9211240F900FBE0F90F7 +:100110001F9018951F920F920FB60F9211248F9374 +:10012000809124018460809324018F910F900FBEF1 +:100130000F901F9018951F93CF93DF93EC016830B9 +:1001400008F049C0862F992787FD909561E270E0FD +:100150000CD4BC0160507040CE0141E250E02BD481 +:100160008091210180934B0188818093210111E0CE +:1001700029812D3040F580912101909161008130DD +:1001800049F4892F90E062E370E0EFD3BC01822F45 +:10019000835F07C0892F90E062E370E0E6D3BC0183 +:1001A000822F25D380912101813031F489818C30D7 +:1001B00019F48CED95E006C08091610090E062E357 +:1001C00070E0D3D3EDD21F5F2196113289F6809172 +:1001D0004B0180932101DF91CF911F9108950F93DF +:1001E0001F93CF93DF93EC018881882369F5809179 +:1001F000210190916100813051F42EA1892F90E06E +:1002000062E370E0B2D3BC01822F835F07C0892F05 +:1002100090E062E370E0A9D3BC018EA1E8D29C819A +:10022000913208F01DC180912101882309F018C185 +:10023000FE01E90FF11D8EA185839F5F9C83CE0196 +:10024000059667EE70E009C1813029F5EEA1E13035 +:1002500011F48AE00BC0E23011F48BE007C0E33008 +:1002600061F480912101813021F48CE080932001A0 +:100270000FC0CE01059667E00AC0FF27E7FDF095A5 +:10028000EE59FF4F608167FD03C0CE01059653DF35 +:1002900080914A011FC0823009F0B5C02EA1E22F23 +:1002A000FF27E7FDF095EE59FF4FE081E7FD14C011 +:1002B000EB8381E08C83809121018D83FE0181E0BD +:1002C0009FEF96838F5F31968132D9F78881809333 +:1002D0004A0183E08883C4C0213009F051C0909165 +:1002E000220190FF24C0809160008F5F80936000A6 +:1002F000853018F401E010E013C0209360009E7F69 +:100300009093220181EF60E273E071D22FC083EFFE +:1003100068EC70E06CD288EC90E042D20F5F1F4F27 +:100320008091600090E0801791078CF71FC091606A +:100330009093220101E010E013C00130110539F45F +:1003400082EF60E273E053D288EC90E029D283EF31 +:1003500068EC70E04CD288EC90E022D20F5F1F4F27 +:100360008091600090E0801791073CF78FEF91E05B +:100370006091220159D38EEF91E0609160003DC001 +:10038000223001F5809161008F5F8093610085309C +:1003900018F081E08093610001E010E009C086EF71 +:1003A00068EC70E024D288EC90E0FAD10F5F1F4F28 +:1003B00060916100862F90E08017910784F78DEFA0 +:1003C00091E01BC02330D9F48091220181FF07C046 +:1003D0008D7F809322011092210181EF07C08260FE +:1003E0008093220181E08093210182EF60E273E03B +:1003F000FED18FEF91E06091220116D38881809326 +:100400004A0118822DC0833059F59C81913238F011 +:1004100080934A01188284EF60E273E00FC0FE010E +:10042000E90FF11D8EA185839F5F9C838091610000 +:1004300090E062E370E099D2BC0183EFD8D18B8168 +:10044000883070F4992787FD909561E270E08DD235 +:10045000BC0160507040CE01059641E250E0C3D22D +:10046000DF91CF911F910F910895EF92FF920F931B +:100470001F9390E896BD16BC88B3866088BB8BE05E +:1004800080BD98B983E085BF80E68BBF86E085BBE1 +:10049000789481E0E0DD00DEA895F89414BE81B583 +:1004A000886181BD11BC7894E9D01092230181E06C +:1004B0008093250110922401809327011092260138 +:1004C00010922801E9E2F1E08FEF819391E0E934A5 +:1004D000F907D9F78FEF91E07ED280932201843023 +:1004E00030F0109222018FEF91E060E09DD28EEF0C +:1004F00091E071D2809360008150843038F081E0C7 +:10050000809360008EEF91E061E08ED28DEF91E0FC +:1005100062D2809361008150843038F082E0809311 +:1005200061008DEF91E062E07FD210922101809115 +:10053000220180FF0BC08091600090E068EE73E0C4 +:1005400014D22ED188E291E060E0F5DD80912201A5 +:1005500081FF04C081E08093210102C0109221013B +:1005600011E04AE0E42E0FEF32E0F32E86B390E084 +:1005700096958795817080932501181759F18823E6 +:1005800041F48091240181608093240110924901FB +:100590000AC01092240190914901892F81508A301C +:1005A00030F00093490180E056DD76DD1FC08E2DCE +:1005B000891B8093490181E04EDD6EDDA895F8949A +:1005C00014BE81B5886181BD11BC789483E291E04D +:1005D00006DE0CC0112351F08091230180934A0163 +:1005E00010922301109224010093490110912501DA +:1005F00080912001882339F08093490110922001D5 +:1006000083E291E0ECDD8091240180FF14C084E05E +:1006100022DD42DD9091240192FFA8CF8091230139 +:1006200080934A0181E0809323019A7F92609093A6 +:10063000240183EF13C081FF15C084E00CDD2CDDA5 +:100640009091240192FF92CF8091230180934A01DF +:10065000F0922301997F9093240185EF68EC70E07C +:10066000C6D084CF85B7877E806185BF85B780621D +:1006700085BF889585B78F7D85BF78CF82E089BF9C +:1006800083E08ABD81E083BF12BE19BCB89A109284 +:100690005301109250011092520110925101109288 +:1006A00055011092540110924C0110924D0110927C +:1006B0004E0110924F0108951F920F920FB60F92A4 +:1006C00011242F933F938F939F93AF93BF93EF93F7 +:1006D000FF93809151019091520120915301820F1B +:1006E000911D9093520180935101E0915101F0913D +:1006F0005201349693E0F695E7959A95E1F7FF2736 +:10070000E7FDF095EF77F070E459FF4F308180916D +:100710005001882311F4E0E01EC0809154019091B3 +:10072000550120915001820F911D909355018093A6 +:100730005401E0915401F0915501349683E0F6950F +:10074000E7958A95E1F7FF27E7FDF095EF77F070E1 +:10075000E459FF4FE0813E0FE695E6953E1B39BD1B +:1007600080914C0190914D01A0914E01B0914F01AB +:100770000196A11DB11D80934C0190934D01A09352 +:100780004E01B0934F01FF91EF91BF91AF919F91B7 +:100790008F913F912F910F900FBE0F901F90189542 +:1007A00010924C0110924D0110924E0110924F0187 +:1007B00025B7277E25BF6FE070E0D7D09C0140E0D1 +:1007C00050E007C085B7806285BF889585B78F7D6B +:1007D00085BF80914C0190914D01A0914E01B09147 +:1007E0004F01281739074A075B0760F708950F93F1 +:1007F0001F93282F1BBE8A31C8F4E82FFF27E7FD7F +:10080000F095EE0FFF1FE451FF4F8081809353015D +:100810008181809350018AB580688ABD8AB58F7BBB +:100820008ABD2931A1F48CED95E08EC0863F11F48C +:1008300082E403C0833F69F481E280935301109204 +:1008400050018AB580688ABD8AB58F7B8ABDCB018D +:100850007BC0853FE1F482E2809353011092500106 +:100860008AB580688ABD8AB58F7B8ABDCB0163E07B +:1008700070E08DD0162F072F862F972F91DF8BE2F8 +:1008800080935301812F902F8BDF83E359C0823FE8 +:10089000E1F485E580935301109250018AB5806898 +:1008A0008ABD8AB58F7B8ABDCB0166E070E06FD0D0 +:1008B000162F072F862F972F73DF82E68093530121 +:1008C000812F902F6DDF8FE63BC0843FE1F483E3FF +:1008D00080935301109250018AB580688ABD8AB511 +:1008E0008F7B8ABDCB0163E070E051D0162F072FBC +:1008F000862F972F55DF8BE280935301812F902F06 +:100900004FDF82E21DC0813F01F58FE680935301E6 +:10091000109250018AB580688ABD8AB58F7B8ABDE6 +:10092000CB0166E070E033D0162F072F862F972F6C +:1009300037DF82E680935301812F902F31DF85E5E9 +:1009400080935301812F902F2BDF8AB58F778ABD3B +:100950008AB58F7B8ABDC0981092530110925001C6 +:1009600080E68BBF1F910F9108955527002480FFCB +:1009700002C0060E571F660F771F6115710521F023 +:1009800096958795009799F7952F802D0895AA1B26 +:10099000BB1B51E107C0AA1FBB1FA617B70710F06A +:1009A000A61BB70B881F991F5A95A9F7809590959C +:1009B000BC01CD010895DC01CB01FC01E199FECF22 +:1009C00006C0FFBBEEBBE09A31960DB20D924150CE +:1009D0005040B8F70895E199FECF9FBB8EBBE09AD7 +:1009E00099278DB30895DC01A40FB51F41505040E5 +:1009F00040F0CB01840F951F2E9105D041505040FF +:100A0000D8F70895262FE199FECF9FBB8EBBE09AC1 +:100A100001970DB2021639F01CBA2DBB0FB6F8942F +:100A2000E29AE19A0FBE0895262FE199FECF1CBAF3 +:100A30009FBB8EBB2DBB0FB6F894E29AE19A0FBE16 +:080A400001960895F894FFCF20 +:100A4800010200FFFFFF0102030405064043464977 +:100A58004C4F5255585B5E606366686A6D6F717380 +:100A6800757678797B7C7D7E7E7F7F7F7F7F7F7FB9 +:100A78007E7E7D7C7B7978767573716F6D6A68662A +:100A880063605E5B5855524F4C494643403C39368B +:100A980033302D2A2724211F1C19171512100E0C6C +:100AA8000A09070604030201010000000000000013 +:100AB80001010203040607090A0C0E101215171982 +:100AC8001C1F2124272A2D303336393C573D4F2E01 +:100AD800572E602E4F32573260324F3857386038B1 +:100AE8004F3D603D000055622E3B2E483B482E5539 +:100AF8003B5548552E623B624862486F626FAA00B8 :00000001FF diff --git a/we500_schematic.jpg b/we500_schematic.jpg new file mode 100644 index 0000000..422866a Binary files /dev/null and b/we500_schematic.jpg differ