update examples

This commit is contained in:
Morgan Redfield 2018-07-03 16:02:21 -07:00
parent a9f3380f85
commit 176814bc98
7 changed files with 14 additions and 3 deletions

View File

@ -50,6 +50,7 @@ void setup() {
radio.initialize(); radio.initialize();
radio.frequency(144390); radio.frequency(144390);
radio.setRfPower(0); radio.setRfPower(0);
radio.bypassPreDeEmph(); // needed for digital modes
dds.start(); dds.start();
afsk.start(&dds); afsk.start(&dds);
delay(100); delay(100);

View File

@ -8,9 +8,12 @@
* a message under 254 characters into the bar at the top of * a message under 254 characters into the bar at the top of
* the monitor. Click the "Send" button. Check for output on * the monitor. Click the "Send" button. Check for output on
* AFSK receiver. * AFSK receiver.
*
* NOTE: add message receive code * To send a message: connect to the Arduino over a Serial link.
*/ * Send the following over the serial link:
* `from,to,:message
* example: * `KG7OGM,KG7OGM,:Hi there
*/
@ -55,6 +58,7 @@ void setup() {
radio.setSQHiThresh(-100); radio.setSQHiThresh(-100);
radio.setSQLoThresh(-100); radio.setSQLoThresh(-100);
radio.setSQOn(); radio.setSQOn();
radio.bypassPreDeEmph();
dds.start(); dds.start();
afsk.start(&dds); afsk.start(&dds);
delay(100); delay(100);

View File

@ -54,6 +54,7 @@ void setup() {
Serial.print(F(" / ")); Serial.print(F(" / "));
Serial.println(radio.getSQLoThresh()); Serial.println(radio.getSQLoThresh());
radio.setModeReceive(); radio.setModeReceive();
radio.bypassPreDeEmph(); // needed for digital modes
Serial.println(F("DDS Start")); Serial.println(F("DDS Start"));
delay(100); delay(100);
dds.start(); dds.start();

View File

@ -139,11 +139,13 @@ void loop() {
if (Serial.available()) { if (Serial.available()) {
code = char2code(Serial.read()); code = char2code(Serial.read());
if (code == 255) code = 0xE; // throw a * in there so we don't break things with an invalid code
radio.setDTMFCode(code); // set first radio.setDTMFCode(code); // set first
} else { } else {
dtmf_to_tx = false; dtmf_to_tx = false;
} }
} }
delay(20); // make sure the last code is done
// done with tone // done with tone
radio.setModeReceive(); radio.setModeReceive();
radio.setTxSourceMic(); radio.setTxSourceMic();

View File

@ -56,6 +56,7 @@ void setup() {
radio.setSQLoThresh(-100); radio.setSQLoThresh(-100);
radio.setSQOn(); radio.setSQOn();
radio.frequency(144390); radio.frequency(144390);
radio.bypassPreDeEmph();
dds.start(); dds.start();
afsk.start(&dds); afsk.start(&dds);

View File

@ -44,6 +44,7 @@ void setup() {
Serial.println(result); Serial.println(result);
radio.initialize(); radio.initialize();
radio.frequency(446000); radio.frequency(446000);
radio.bypassPreDeEmph();
radio.setModeReceive(); radio.setModeReceive();
} }

View File

@ -54,6 +54,7 @@ void setup() {
radio.initialize(); radio.initialize();
radio.setRfPower(0); radio.setRfPower(0);
radio.frequency(145500); radio.frequency(145500);
radio.bypassPreDeEmph();
// put your setup code here, to run once: // put your setup code here, to run once:
//dds.setReferenceClock(34965/4); //dds.setReferenceClock(34965/4);
dds.start(); dds.start();