3 min to read
How To Propose Your Crush Using an Oscilloscope
In this article, I help you propose your crush using an oscilloscope. I plan to show some messages on an Oscilloscope in the X-Y mode with the help of an ESP32 microcontroller board. Please ensure your crush likes your project skills, otherwise, this method may be a complete failure.
Components Required
- ESP32 microcontroller board
- An Oscilloscope (I am using Keysight’s EDUX1002A model DSO)
Circuit Diagram
Note: Connect both grounds of DSO channel1 and channel2 to ESP32’s any of the GND pin
Programme
#include <driver/dac.h>
/* START */
const int NUM_POINTS = 1702;
const unsigned long x_points[NUM_POINTS] = {15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,220,221,222,223,224,225,226,227,228,229,230,231,232,233,234,235,236,237,238,239,15,34,177,196,220,239,15,34,177,196,220,239,15,34,177,196,220,239,15,34,177,196,220,239,15,34,177,196,220,239,15,34,177,196,220,239,15,34,177,196,220,239,15,34,88,89,90,91,92,93,94,95,96,97,115,116,117,118,119,120,121,122,123,124,177,196,220,239,15,34,86,87,88,89,90,95,96,97,98,99,113,114,115,116,117,118,119,120,121,122,123,124,125,126,177,196,220,239,15,34,84,85,86,87,98,99,100,101,111,112,113,124,125,126,127,128,177,196,220,239,15,34,83,84,85,99,100,101,102,110,111,112,126,127,128,129,177,196,220,239,15,34,82,83,84,100,101,102,103,109,110,111,127,128,129,130,177,196,220,239,15,34,81,82,83,102,103,104,108,109,110,128,129,130,177,196,220,239,15,34,81,82,103,104,105,108,109,129,130,131,177,196,220,239,15,34,80,81,104,105,107,108,130,131,132,177,196,220,239,15,34,80,81,105,106,107,108,130,131,132,177,196,220,239,15,34,80,106,107,131,132,177,196,220,239,15,34,79,80,131,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,132,133,177,196,220,239,15,34,79,80,131,132,133,177,196,220,239,15,34,80,131,132,177,196,220,239,15,34,80,130,131,132,177,196,220,239,15,34,81,130,131,132,177,196,220,239,15,34,81,130,131,177,196,220,239,15,34,81,82,129,130,131,177,196,220,239,15,34,82,83,129,130,177,196,220,239,15,34,82,83,128,129,130,177,196,220,239,15,34,83,84,128,129,177,196,220,239,15,34,83,84,85,127,128,129,177,196,220,239,15,34,84,85,126,127,128,177,196,220,239,15,34,85,86,126,127,177,196,220,239,15,34,86,125,126,127,177,196,220,239,15,34,86,87,124,125,126,177,178,196,220,239,15,34,87,88,89,124,125,178,196,220,238,239,15,34,88,89,123,124,178,196,220,238,15,34,89,90,122,123,178,196,220,238,15,34,90,91,122,178,196,197,219,220,238,15,34,91,92,121,178,179,197,219,238,15,34,92,93,120,179,197,198,218,219,238,15,34,93,94,118,119,179,198,199,218,237,238,15,34,94,95,117,118,179,199,217,218,237,15,34,95,96,116,117,179,180,199,200,201,215,216,217,236,237,15,34,96,97,115,116,180,201,202,203,213,214,215,236,15,34,97,98,113,114,115,180,181,203,204,205,206,207,208,209,210,211,212,213,236,15,34,99,112,113,181,235,236,15,34,100,101,111,112,181,182,234,235,15,34,101,102,110,111,182,183,234,15,34,102,103,109,110,183,233,234,15,34,103,104,108,109,183,184,232,233,15,34,104,105,107,108,184,185,231,232,15,34,105,106,107,185,186,230,231,15,34,186,187,229,230,15,34,187,188,189,227,228,229,15,34,189,190,191,225,226,227,15,34,191,192,193,223,224,225,15,34,193,194,195,196,197,220,221,222,223,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,197,198,199,200,201,202,203,204,205,206,213,214,215,216,217,218,219,220,206,207,208,209,210,211,212,213,46,47,48,49,50,51,52,53,54,55,68,69,70,71,72,73,74,75,76,77,78,94,95,96,97,98,99,100,101,102,103,104,105,106,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,147,148,149,150,151,152,153,154,155,156,157,158,159,160,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,46,55,56,68,78,94,106,122,136,146,147,160,167,195,46,56,68,78,94,106,107,122,136,146,160,167,195,46,56,57,68,78,93,94,107,122,136,146,160,167,195,46,57,58,68,78,93,107,122,136,137,146,160,167,195,46,58,68,78,93,107,108,122,137,145,146,160,167,195,46,58,59,68,78,92,93,108,122,137,145,160,167,195,46,59,60,68,78,92,108,109,122,137,145,160,167,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,46,60,68,78,91,92,109,122,130,137,138,145,152,160,167,177,46,60,61,68,78,91,99,100,101,109,122,130,138,144,145,152,160,167,177,46,61,62,68,78,91,99,101,102,109,110,122,130,131,132,138,144,152,160,167,177,46,55,62,68,78,90,98,99,102,110,122,130,132,138,144,150,151,152,160,167,177,46,55,62,63,68,78,90,98,102,110,122,130,132,138,139,144,150,152,160,167,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,46,55,63,64,68,78,90,98,102,103,110,111,122,130,132,133,139,143,144,149,150,152,160,167,194,46,55,56,64,65,68,78,89,90,98,103,111,122,130,133,139,143,149,152,160,167,194,46,55,56,57,65,68,78,89,97,98,103,111,112,122,130,133,139,143,149,152,160,167,194,46,55,57,65,66,68,78,88,89,97,103,112,122,130,133,139,140,143,149,152,160,167,194,46,55,57,58,66,67,68,78,88,97,103,104,112,122,130,133,134,140,142,143,148,149,152,160,167,194,46,55,58,59,78,88,96,97,104,112,113,122,130,134,140,141,142,148,152,160,167,194,46,55,59,78,87,88,96,104,113,122,130,134,148,152,160,167,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,46,55,59,60,78,87,96,97,98,99,100,101,102,103,104,113,122,130,134,135,148,152,160,167,177,46,55,60,61,78,87,113,114,122,130,135,147,148,152,160,167,177,46,55,61,78,86,87,114,122,130,135,147,152,160,167,177,46,55,61,62,78,86,114,122,130,135,147,152,160,167,177,46,55,62,63,78,85,86,114,115,122,130,135,136,147,152,160,167,177,46,55,63,78,85,115,122,130,136,146,147,152,160,167,177,46,55,63,64,78,85,115,116,122,130,136,146,152,160,167,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196,46,55,64,65,78,84,85,94,95,96,97,98,99,100,101,102,103,104,105,106,107,115,116,122,130,136,146,152,160,167,196,46,55,65,78,84,93,94,107,116,122,130,136,137,146,152,160,167,196,46,55,65,66,78,84,93,107,116,117,122,130,137,145,146,152,160,167,196,46,55,66,67,78,83,84,93,107,117,122,130,137,145,152,160,167,196,46,55,67,78,83,92,93,107,108,117,122,130,137,145,152,160,167,196,46,55,67,68,78,82,83,92,108,117,118,122,130,137,138,145,152,160,167,196,46,47,48,49,50,51,52,53,54,55,68,69,70,71,72,73,74,75,76,77,78,82,83,84,85,86,87,88,89,90,91,92,108,109,110,111,112,113,114,115,116,117,118,122,123,124,125,126,127,128,129,130,138,139,140,141,142,143,144,145,152,153,154,155,156,157,158,159,160,167,168,169,170,171,172,173,174,175,176,177,178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196};
const unsigned long y_points[NUM_POINTS] = {209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,209,208,208,208,208,208,208,207,207,207,207,207,207,206,206,206,206,206,206,205,205,205,205,205,205,204,204,204,204,204,204,203,203,203,203,203,203,202,202,202,202,202,202,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,201,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,200,199,199,199,199,199,199,199,199,199,199,199,199,199,199,199,199,199,199,199,199,199,199,198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,198,197,197,197,197,197,197,197,197,197,197,197,197,197,197,197,197,197,197,197,197,196,196,196,196,196,196,196,196,196,196,196,196,196,196,196,196,196,196,195,195,195,195,195,195,195,195,195,195,195,195,195,195,195,195,194,194,194,194,194,194,194,194,194,194,194,194,194,194,194,193,193,193,193,193,193,193,193,193,193,193,193,193,193,193,192,192,192,192,192,192,192,192,192,192,192,191,191,191,191,191,191,191,191,191,191,191,190,190,190,190,190,190,190,190,190,190,189,189,189,189,189,189,189,189,189,189,188,188,188,188,188,188,188,188,188,188,187,187,187,187,187,187,187,187,187,187,186,186,186,186,186,186,186,186,186,186,185,185,185,185,185,185,185,185,185,185,184,184,184,184,184,184,184,184,184,184,183,183,183,183,183,183,183,183,183,183,182,182,182,182,182,182,182,182,182,182,181,181,181,181,181,181,181,181,181,181,180,180,180,180,180,180,180,180,180,180,180,179,179,179,179,179,179,179,179,179,178,178,178,178,178,178,178,178,178,178,177,177,177,177,177,177,177,177,177,177,176,176,176,176,176,176,176,176,176,175,175,175,175,175,175,175,175,175,175,175,174,174,174,174,174,174,174,174,174,174,173,173,173,173,173,173,173,173,173,173,173,172,172,172,172,172,172,172,172,172,172,171,171,171,171,171,171,171,171,171,171,171,171,170,170,170,170,170,170,170,170,170,170,170,169,169,169,169,169,169,169,169,169,169,168,168,168,168,168,168,168,168,168,168,167,167,167,167,167,167,167,167,167,167,167,167,166,166,166,166,166,166,166,166,166,166,166,166,165,165,165,165,165,165,165,165,165,165,164,164,164,164,164,164,164,164,164,164,163,163,163,163,163,163,163,163,163,163,163,162,162,162,162,162,162,162,162,162,162,161,161,161,161,161,161,161,161,161,161,161,160,160,160,160,160,160,160,160,160,160,160,160,159,159,159,159,159,159,159,159,159,159,159,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,158,157,157,157,157,157,157,157,157,157,157,157,157,157,157,156,156,156,156,156,156,156,156,156,156,156,156,156,156,156,156,156,156,156,156,156,155,155,155,155,155,155,155,155,154,154,154,154,154,154,154,154,154,154,153,153,153,153,153,153,153,153,153,152,152,152,152,152,152,152,152,152,151,151,151,151,151,151,151,151,151,151,150,150,150,150,150,150,150,150,150,150,149,149,149,149,149,149,149,149,149,148,148,148,148,148,148,147,147,147,147,147,147,147,147,146,146,146,146,146,146,146,146,145,145,145,145,145,145,145,145,144,144,144,144,144,144,144,144,144,144,144,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,143,142,142,142,142,142,142,142,142,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,98,97,97,97,97,97,97,97,97,97,97,97,97,97,97,96,96,96,96,96,96,96,96,96,96,96,96,96,95,95,95,95,95,95,95,95,95,95,95,95,95,95,94,94,94,94,94,94,94,94,94,94,94,94,94,94,93,93,93,93,93,93,93,93,93,93,93,93,93,93,92,92,92,92,92,92,92,92,92,92,92,92,92,92,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,91,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,89,89,89,89,89,89,89,89,89,89,89,89,89,89,89,89,89,89,89,88,88,88,88,88,88,88,88,88,88,88,88,88,88,88,88,88,88,88,88,88,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,87,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,86,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,85,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,84,83,83,83,83,83,83,83,83,83,83,83,83,83,83,83,83,83,83,83,83,83,83,83,82,82,82,82,82,82,82,82,82,82,82,82,82,82,82,82,82,82,82,82,82,82,82,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,81,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,80,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,79,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,78,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,77,76,76,76,76,76,76,76,76,76,76,76,76,76,76,76,75,75,75,75,75,75,75,75,75,75,75,75,75,75,75,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,74,73,73,73,73,73,73,73,73,73,73,73,73,73,73,73,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,72,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,71,70,70,70,70,70,70,70,70,70,70,70,70,70,70,70,70,70,70,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,69,68,68,68,68,68,68,68,68,68,68,68,68,68,68,68,68,68,68,67,67,67,67,67,67,67,67,67,67,67,67,67,67,67,67,67,67,66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65,65};
/* END */
void setup() {
dac_output_enable(DAC_CHANNEL_1);
dac_output_enable(DAC_CHANNEL_2);
}
void loop() {
for(int loop_counter = 0; loop_counter < NUM_POINTS; loop_counter++) {
dac_output_voltage(DAC_CHANNEL_1, x_points[loop_counter]);
dac_output_voltage(DAC_CHANNEL_2, y_points[loop_counter]);
delayMicroseconds(1);
}
}
Generate Your own Code
I just developed an online web tool to convert 255x255px images to ADC values for showing on the oscilloscope. You can use the test image file provided below to generate the exact code on the example and also you can modify the image and generate a code with your crush name.
- open my OscillosPlot web app and insert your image
- Convert to monochrome
- Copy the code from
/* START */
to/* END */
and paste it on the example given above.
Demo Video
Backup
In any case, if things don’t go according to your plan, remember
Be Water, My Friend
Bruce Lee
Thnx!