handbuch update
This commit is contained in:
parent
a34ff7a572
commit
e5f0386dc1
4 changed files with 46 additions and 24 deletions
30
control/examples/diode/Makefile
Normal file
30
control/examples/diode/Makefile
Normal file
|
@ -0,0 +1,30 @@
|
|||
# Name: Makefile
|
||||
# Project: B15F (board15 Famulus Edition)
|
||||
# Author: Tristan Krause
|
||||
# Creation Date: 2019-05-15
|
||||
|
||||
# Environment
|
||||
COMPILER_PATH = g++
|
||||
|
||||
# Options
|
||||
CFLAGS = -std=c++17 -O3 -Wall -Wextra
|
||||
LDFLAGS = -lb15fdrv
|
||||
OBJECTS = main.o
|
||||
OUT = main.elf
|
||||
|
||||
COMPILE = $(COMPILER_PATH) $(CFLAGS)
|
||||
|
||||
main: $(OBJECTS)
|
||||
$(COMPILE) $(OBJECTS) -o $(OUT) $(LDFLAGS)
|
||||
|
||||
help:
|
||||
@echo "This Makefile has the following targets:"
|
||||
@echo "make main .... to compile"
|
||||
@echo "make clean ... to delete objects and executables"
|
||||
|
||||
clean:
|
||||
@echo "Cleaning..."
|
||||
rm -f $(OBJECTS) $(OUT) *.bin gnuplotscript.gp
|
||||
|
||||
.cpp.o:
|
||||
$(COMPILE) -c $< -o $@
|
|
@ -1,7 +1,7 @@
|
|||
#include <iostream>
|
||||
#include <cmath>
|
||||
#include "drv/b15f.h"
|
||||
#include "drv/plottyfile.h"
|
||||
#include <b15f/b15f.h>
|
||||
#include <b15f/plottyfile.h>
|
||||
|
||||
|
||||
void kennlinieErsterQuadrant()
|
||||
|
@ -156,23 +156,6 @@ void testFunktionen()
|
|||
int main()
|
||||
{
|
||||
//testFunktionen();
|
||||
//kennlinieZweiterQuadrant();
|
||||
|
||||
B15F& drv = B15F::getInstance();
|
||||
while(1)
|
||||
{
|
||||
//uint8_t be0 = drv.digitalRead0();
|
||||
//uint8_t be1 = drv.digitalRead1();
|
||||
//uint8_t dsw = drv.readDipSwitch();
|
||||
drv.analogRead(0);
|
||||
drv.analogRead(1);
|
||||
drv.analogRead(2);
|
||||
drv.analogRead(3);
|
||||
drv.analogRead(4);
|
||||
drv.analogRead(5);
|
||||
drv.analogRead(6);
|
||||
drv.analogRead(7);
|
||||
}
|
||||
|
||||
kennlinieZweiterQuadrant();
|
||||
std::cout << "Schluss." << std::endl;
|
||||
}
|
BIN
control/examples/diode/test_plot
Normal file
BIN
control/examples/diode/test_plot
Normal file
Binary file not shown.
Loading…
Add table
Add a link
Reference in a new issue