Week06: Electronics Design¶
group assignment
use the test equipment in your lab to observe the operation of a microcontroller circuit board
This article was written by Shintaro Ito.
01. Oscilloscope settings.¶
- oscilloscope Information
Item | Details |
---|---|
Manufacturer | Tektronix |
Series | TBS1000B |
Model | TBS1202B (200MHz), TBS1152B (150MHz), TBS1102B (100MHz), TBS1072B (70MHz), TBS1052B (50MHz), TBS1032B (30MHz) |
Frequency Band | 200MHz, 150MHz, 100MHz, 70MHz, 50MHz, 30MHz (30MHz model is limited to North America and Europe) |
Number of Input Channels | 2 |
Maximum Sample Rate | 2GS/s on all channels |
Record Length | 2.5k points on all channels |
Trigger Function | Advanced triggers (pulse trigger, selectable line video trigger, etc.) |
Display | 7-inch (17.78 cm) WVGA (800×480) Active TFT Color Display |
Automatic Measurement Items | 34 types |
FFT Function | Dual-window FFT (simultaneous display of time domain and frequency domain) |
USB Port | USB host port on the front panel, USB device port on the rear panel |
Other Features | Limit Test, Data Logging, Frequency Counter, TrendPlot™, Context-sensitive Help Menu |
02. Probe Compensation¶
Compensation is performed first because noise may be present in the probe.
Procedure¶
- connect the probe to the equipment.
- You need to rotate it when connecting.
- The terminal comes out by pulling the probe.
Steps 2, 3, and 4 are described in the image.
A: Main signal terminal: Voltage signal flows here.
B: GND terminal: Terminal for grounding.
- Connect A: Main signal terminal on top of the probe compensation, and B: GND terminal below.
- C: By pressing Autoset, a rectangle for compensation appears and is compensated. Fine adjustments are possible with the compensation driver.

- Port: Serial port of XIAO RP2040
Warning
The serial port differs depending on each environment, so select the port for your environment.
-
Write the code
- This time’s code
main.py
from machine import Pin, PWM import time # Output pin (GPIO of RP2040) PWM_PIN = 7 # PWM initialization pwm = PWM(Pin(PWM_PIN)) pwm.freq(50000) # Set PWM frequency to 50kHz pwm.duty_u16(32768) # 50% duty with 16bit value (range of 0 to 65535) while True: time.sleep(1) # Maintain PWM signal in an infinite loop
- To write, save as main.py, then right-click the target from the file list on the left and select write.
- This time’s code
- After writing, the signal should be outputting. Connect the probe and check the signal. At this time, the output pin needs to be re-read between Xiao rp2040 and Raspberry Pi pico.
-
The re-reading is as shown in the table below.
-
Connect the probe to GND of Xiao rp2040 and pin 7 set in the code (5pin in xiao rp2040 by re-reading).
A: Main signal terminal: Voltage signal flows here.
B: GND terminal: Terminal for grounding.
-
make a measurement with an oscilloscope. The information on the measurement screen is as follows .
- Average voltage: 1.68V
- Voltage offset: 2V
- Time Base (time scale): 10.0µs/div
- Ch1 (Channel 1 setting): 100mV/div Sampling Rate: 50.0006kHz
- Peak-Peak voltage: 6.80V