Erfassen und Analysieren der Beschleunigungssensordaten eines Roboters

Kundenbedarf analysieren - und direkt erfassen (Juli 2019).

$config[ads_text] not found
Anonim

Erfassen und Analysieren der Beschleunigungssensordaten eines Roboters


Ein Beschleunigungssensor kann eine wertvolle Ergänzung für ein Roboterprojekt sein. Dieser Artikel zeigt Ihnen einen Ansatz zum Generieren und Analysieren von Beschleunigungsdaten.

zusätzliche Informationen

  • Entwerfen Sie ein benutzerdefiniertes Microcontroller-Programmier- und -Testboard
  • Custom PCB Design mit einem EFM8 Microcontroller
  • Entwerfen einer Steuerplatine für ein Romi Robot Chassis

Der Beschleunigungsmesser

In einem früheren Artikel habe ich das Romi Roboterchassis von Pololu und eine kundenspezifische Romi-Steuerplatine vorgestellt. Sie können den folgenden Link verwenden, um den vollständigen Schaltplan und die Stückliste herunterzuladen.

Schema und Stückliste

Diese Leiterplatte enthält unter anderem einen Beschleunigungsmesser. Der Teil, den ich gewählt habe, ist der ADXL326 von Analog Devices. Es ist ein Drei-Achsen-Analog-Ausgabegerät und aus der Sicht des Benutzers ist es überhaupt nicht kompliziert. Wie Sie sehen können, sind nur wenige externe Komponenten erforderlich:

Wenn wir diese Ausrichtung mit dem Datenblatt und den Roboterbewegungsrichtungen wie hier definiert kombinieren, können wir das bestimmen

  • die Vorwärtsrichtung des Roboters entspricht der negativen X-Achsenbeschleunigung,
  • die umgekehrte Richtung entspricht positiver x-Achsenbeschleunigung,
  • die Richtung nach rechts entspricht einer positiven y-Achsenbeschleunigung,
  • und die Richtung nach links entspricht der negativen y-Achsenbeschleunigung.

Der ADC

Wir werden den Analog-Digital-Wandler des EFM8 verwenden, um die drei vom ADXL326 erzeugten analogen Beschleunigungssignale zu digitalisieren. Wir verwenden die volle 14-Bit-Auflösung und die intern generierte 2, 4-V-Referenz. Sie können auf die Hardwarekonfigurationsdatei und die ADC.c-Quelldatei für ADC-Konfigurationsdetails verweisen; Diese können zusammen mit allen anderen Quell- und Projektdateien durch Klicken auf den folgenden Link heruntergeladen werden:

Quell- und Projektdateien

Wenn Sie sich das gesamte Schaltbild ansehen, werden Sie feststellen, dass die Ausgangssignale des Beschleunigungsmessers direkt mit den ADC-Eingängen verbunden sind. Es wird kein Anti-Aliasing-Filter benötigt, weil die Bandbreitenbeschränkung durch das oben diskutierte Tiefpassfilter erreicht wird, und ich bin ziemlich sicher, dass wir keinen Spannungsfolger benötigen, da das ADC-Modul ein Modul mit wählbarer Dämpfung umfasst, das vermutlich einige enthält Art von Schaltung, die zu einer niedrigen Ausgangsimpedanz führt.

Wir verwenden die Auto-Scan-Funktion des ADC, um 2400 Byte ADC-Daten zu sammeln. Jede Probe benötigt zwei Bytes und wir haben drei Kanäle (für drei Achsen), und somit haben wir (2400/2) / 3 = 400 Proben pro Achse.

Daten übertragen

Wir müssen die Beschleunigungsdaten zur Visualisierung und Analyse an einen PC senden. In der Vergangenheit habe ich einen USB-fähigen Mikrocontroller in Verbindung mit einem benutzerdefinierten Scilab-Skript verwendet (siehe diesen Artikel, einschließlich der Links im Abschnitt "Hintergrundinformationen"). Ich habe mich jedoch für ein einfacheres und vielseitigeres System entschieden. Der bisherige Ansatz hat zwar Vorteile, ist aber restriktiv (weil man einen Mikrocontroller mit USB-Funktionalität verwenden muss) und kompliziert (wegen der zusätzlichen USB-Firmware und der gesamten Scilab-Entwicklung).

Die neue Methode beruht auf YAT ("Yet Another Terminal" -Programm) und Excel. Ich nehme an, dass andere Tabellenkalkulationssoftware verwendet werden könnte, aber die Anweisungen hier sind spezifisch für Excel.

Ich schätze die Einfachheit der UART-Kommunikation, aber Computer haben keine seriellen Anschlüsse mehr. Die einfachste Lösung für diese Situation ist ein USB-zu-UART-Konverter; Ich benutze diesen von Pololu. Es ist im Wesentlichen ein Breakout Board für den CP2104 von Silicon Labs; Ich könnte meine eigenen entwerfen, aber wenn Pololu ihre für $ 5, 95 verkauft, warum kümmern. Dieses praktische kleine Board ermöglicht es mir, Firmware zu schreiben, als ob USB nicht existiert - senden Sie einfach ein Byte, erhalten Sie ein Byte, wie in den guten alten Tagen von RS-232.Das folgende Foto zeigt die Romi Steuerplatine, die mit dem C2 Adapter verbunden ist Board auf der rechten Seite und der USB-zu-UART-Konverter auf der linken Seite.

Hinweis: Wenn Sie die Karte über USB mit Strom versorgen, sollten Sie sicherstellen, dass Ihr Code die Aktivierung der Motoren nicht zulässt. USB-Anschlüsse sind nicht für diese Art von Stromaufnahme ausgelegt. Ich empfehle, die Motoren physisch zu trennen, um sicher zu gehen.

Wenn der ADC die 1200 Abtastungen (400 pro Achse) beendet hat, schreiben wir einfach jedes Byte aus der seriellen Schnittstelle, wie folgt:

 void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n 
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.
void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

  • void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
    The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
    Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.
  • void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
    The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
    Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

  • void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
    The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
    Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.

void Transfer_ADCBuffer(unsigned int num_bytes) { unsigned int n; SFRPAGE = UART0_PAGE; SCON0_TI = 0; //make sure that the transmit interrupt flag is cleared for(n=0; n
The ADC is configured to sequentially sample from P1.5, then P1.6, then P1.7, back to P1.5, and so forth. YAT If everything is working correctly, the ADC data will appear in the YAT window. Here is what you need to do to make it very easy to inspect this data and work with it in Excel: Go to Terminal->Settings and select "Binary" for "Terminal Type." In the same window, click "Binary Settings"; check the box for "Separate settings for Tx and Rx" then enter "6" for "Break lines after" in the "Rx" section. Now when you transfer the data, it will appear as follows: Now you can import this space-separated data into Excel using the "From Text" button in the "Data" ribbon. Note that this block of data will remain "connected" to the data file, so to bring in new data you simply use the "refresh" functionality (see the video below for a demonstration). Once you have the raw data in Excel, you can convert it to ADC counts and to volts (or millivolts). I have my worksheet set up like this: (The initial rising edge is a result of the accelerometer's startup delay.) Self-test causes the analog outputs to assume a predetermined value; if the measured voltages correspond to the expected voltages, you know that the accelerometer is functional. And because the predetermined value is different for each axis, self-test allows you to confirm that you are associating the samples with the correct axis. Here are plots for two more data sets. In the first, the PCB is not moving; in the second, I am using my hand to jiggle the robot chassis. The following video helps to clarify the overall procedure:
Summary We discussed the hardware implementation of a three-axis, analog-output accelerometer, and I presented a straightforward method of getting stored accelerometer data from the robot's microcontroller to a PC. We then moved the data into Excel and plotted the results.