1 / 17

Interlude – microcontroller flash tool

Learn about essential tools like OpenOCD, gdb-multiarch, and cross compilers for microcontroller programming. Get demo code, compiling tips, debugging techniques, and code formatting practices. Build projects, control LEDs, and configure pins effectively. Explore documentation for LED control and programming tips.

dmartin
Télécharger la présentation

Interlude – microcontroller flash tool

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Interlude – microcontroller flash tool

  2. Openocd

  3. Cross-Debugger „gdb-multiarch“

  4. Interlude – cross compiler

  5. Interlude – Get the Demo code

  6. Interlude - Compiling

  7. println! on microcontrollers

  8. Debugging with gdb

  9. Automatic code formatting

  10. Aufbau eines Projekts für den Mikrocontroller Ansteuerung einer Leuchtdiode

  11. Blinking pins.led.set(true); let mut last_led_toggle = system_clock::ticks(); loop { let ticks = system_clock::ticks(); if ticks – last_led_toogle >= 10 { pins.led.toggle(); last_led_toggle = ticks; } }

  12. 10. Exkurs: Dokumentation

  13. 10. Exkurs: Dokumentation

  14. 13. Led - pin vorbereiten fnmain(…) // configure led pin as output pin let led_pin = (gpio::Port::PortI, gpio::Pin::Pin1); let mut led = gpio.to_output(led_pin, gpio::OutputType::PushPull, gpio::OutputSpeed::Low, gpio::Resistor::NoPull) .expect("led pin already in use"); // turn led on led.set(true);

  15. 13. Excurs: Pinkonfigurationen VDD VDD VDD + - Ausgang Ausgang Ausgang -VDD -VDD -VDD VDD VDD VDD VDD Ausgang Ausgang Ausgang Ausgang -VDD

  16. 14. Programm fnmain(…) let mut last_led_toggle = system_clock::ticks(); loop { let ticks = system_clock::ticks(); // every 0.5 seconds if ticks - last_led_toggle >= 500 { // toggle the led let led_current = led.get(); led.set(!led_current); last_led_toggle = ticks; } }

  17. 16. Dokumentation

More Related