arm

Pointer

Arrays und Strings

Worin liegt der Unterschied?

char a[] = "hello";
char *p = "world";

Das macht der Compiler draus

   +---+---+---+---+---+---+
a: | h | e | l | l | o |\0 |
   +---+---+---+---+---+---+

   +-----+     +---+---+---+---+---+---+
p: |  *======> | w | o | r | l | d |\0 |
   +-----+     +---+---+---+---+---+---+

a[3] for the compiler means: start at the location a and move three past it and fetch the char there

p[3] means go to the location p, dereference the value there, move three past it (add three to pointer) and fetch the char there.

a[3] is three places past (the start of) the object named a, while p[3] is three places past the object pointed to by p.

ABER in Funktionen:

void foo(int *a);

und

void foo(int a[]);

sind äquivalent.

Gleiches gilt hier

void foo(int *a) {
    a[98] = 0xFEADFACE;
}

void bar(int b[]) {
    *(b+498) = 0xFEADFACE;
}
int * a; /* pointer to int. points nowhere in paticular right now */
int b[10]; /* array of int. Memory for 10 ints has been allocated on the stack */
foo(a); /* calls foo with parameter `int*` */
foo(b); /* also calls foo with parameter `int*` because here the name b basically
           is a pointer to the first elment of the array */

Embedded

Pointer auf Memory in Mikrocontrollern (via https://microcontrollerslab.com/accessing-memory-mapped-io-microcontrollers-pointer/)

Adressen

Base address of PORTF = 0x40025000
Offset address of GPIODIR = 0x400 //page number 663 TM4C123GH6PM datasheet
GPIOFDIR Physical address =  0x40025000+0x400 = 0x40025400

Pointer-Variable anlegen: Pointer zeigt direkt auf Adresse im Speicher

Unsigned int * GPIO_PORTF_DIR_R = (unsigned int*)0x40025400; 

Pointer derefenzieren (Inhalt an Adresse schreiben, auf die der Zeiger zeigt)

*GPIO_PORTF_DIR_R = 0xF0; 

Hier werden die ersten 4 Pins als Ausgang konfiguriert

Alternativ ein Pointer direkt auf GPIO

// write value 0xF0 to GPIOFDIR register
 (* ( ( volatile unsigned int * ) 0x40025400 ) ) = 0xF0; 
//read value GPIOFDIR register memory address and store it in variable data. 
 data =  (* ( ( volatile unsigned int * ) 0x40025400 ) ) ;
#define GPIO_PORTF_DIR_R  (*( ( volatile unsigned int * )0x40025400 ) ) 
GPIO_PORTF_DIR_R = 0xF0;
data =  GPIO_PORTF_DIR_R;
Mastering Microcontroller and Embedded Driver Development | Udemy
CUDA on WSL :: CUDA Toolkit Documentation
TensorFlow 2.0 Complete Course - Python Neural Networks for Beginners Tutorial - YouTube
nvidia - Install Tensorflow-GPU on WSL2 - Stack Overflow
WSL2 & CUDA does not work [v20226] · Issue #6014 · microsoft/WSL · GitHub
python - "Could not load dynamic library 'libcudnn.so.8'" when running tensorflow on ubuntu 20.04 - Stack Overflow
Installing cuDNN and CUDA Toolkit on Ubuntu 20.04 for Machine Learning Tasks | by Rahul Bhadani | Geek Culture | Medium
Installation Guide :: NVIDIA Deep Learning cuDNN Documentation
TensorFlow.js Layer-API für Keras-Benutzer
Discrete Cosine Transform
abseil / C++ Quickstart With CMake
Welcome to the Course - Introduction to Machine Learning | Coursera
tinyML Talks Schedule - Quip
PowerPoint Presentation - tinyML_Talks_Pierre_Gembaczka_211201.pdf
GitHub - Fraunhofer-IMS/AIfES_for_Arduino: This is the Arduino® compatible port of the AIfES machine learning framework, developed and maintained by Fraunhofer Institute for Microelectronic Circuits and Systems.
cuFFT | NVIDIA Developer
GitHub - microsoft/PowerToys: Windows system utilities to maximize productivity
Get started with TensorBoard  |  TensorFlow
TensorBoard Tutorial: TensorFlow Graph Visualization [Example]
ROS2 Basics Exercise — Industrial Training documentation