C++ DevKit
C++ set of OOP library
Loading...
Searching...
No Matches
probe.h
Go to the documentation of this file.
1
11#pragma once
12
13#include "pico/stdlib.h"
14
20class Probe
21{
22private:
27 uint _gpio;
33 constexpr static int _channel_map[8] = {6, 7, 8, 9, 16, 17, 21, 26};
34
35public:
44 Probe(uint _channel);
49 void hi();
54 void lo();
60 void pulse_us(uint _duration = 1);
66 void copy(bool _value);
67
70 void pulse_train(uint nb);
71};
void pulse_us(uint _duration=1)
Generates a HI level pulse on the GPIO during _duration µs.
Definition probe.cpp:23
Probe(uint _channel)
Construct a new Probe object.
Definition probe.cpp:4
void copy(bool _value)
Used to copy the boolean _value on th GPIO.
Definition probe.cpp:30
void hi()
Generates a HI logical level on the GPIO.
Definition probe.cpp:13
static constexpr int _channel_map[8]
this is the mapping of GPIO number to the logic analyser channel. The choice of GPIO number is arbitr...
Definition probe.h:33
void pulse_train(uint nb)
Generates a train of 10 us pulses on the GPIO.
Definition probe.cpp:35
void lo()
Generates a LO logical level on the GPIO.
Definition probe.cpp:18
uint _gpio
this is the GPIO output on wich signals will be generated. The numbers are those of Raspberry Pi Pico...
Definition probe.h:27