Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Erik Jansson
LabComm
Commits
4583884b
Commit
4583884b
authored
Dec 14, 2011
by
Sven Robertz
Browse files
more cleanup and reorganization
parent
d7b40aa9
Changes
20
Hide whitespace changes
Inline
Side-by-side
examples/simple
_java
/Decoder.java
→
examples/simple/Decoder.java
View file @
4583884b
File moved
examples/simple
_java
/Encoder.java
→
examples/simple/Encoder.java
View file @
4583884b
File moved
examples/simple
_java
/README
→
examples/simple/README
View file @
4583884b
File moved
examples/simple
_java
/compile.sh
→
examples/simple/compile.sh
View file @
4583884b
(
cd
../../lib/c
;
make
)
java
-jar
../../labComm.jar
--java
=
gen
--c
=
gen/simple.c
--h
=
gen/simple.h simple.lc
javac
-cp
../../lib/java:. gen/
*
.java Encoder.java Decoder.java
...
...
examples/simple/datagram/README
0 → 100644
View file @
4583884b
The simple labcomm example over a datagram channel
files:
udp_encoder.c : the same as the simple encoder, but over an UDP writer
udp_decoder.c : d:o
thr_example.c : the samei over a raw ethernet datagram protocol, in one file,and parameterized
to take the ethernet interface to use and the destination to send to as
command line parameters
examples/simple/datagram/thr_compile.sh
0 → 100644
View file @
4583884b
(
cd
../../../lib/c
;
make
)
gcc
-o
thr_example
-L
../../../lib/c
-I
.
-I
..
-I
../../../lib/c thr_example.c ../gen/simple.c
-llabcomm
#gcc -o thr_example -L ../../../lib/c -I . -I .. -I ../../../lib/c thr_example.c ../gen/simple.c ../../../lib/c/labcomm_thr_reader_writer.c ../../../lib/c/ThrottleDrv/*.c -llabcomm
examples/simple
_java
/thr_example.c
→
examples/simple
/datagram
/thr_example.c
View file @
4583884b
File moved
examples/simple/datagram/udp_compile.sh
0 → 100644
View file @
4583884b
(
cd
../../../lib/c
;
make
)
gcc
-g
-o
udp_encoder
-L
../../../lib/c
-I
.
-I
..
-I
../../../lib/c udp_encoder.c ../gen/simple.c ../../../lib/c/labcomm_udp_reader_writer.c udp_hack.c
-llabcomm
gcc
-g
-o
udp_decoder
-L
../../../lib/c
-I
.
-I
..
-I
../../../lib/c udp_decoder.c ../gen/simple.c ../../../lib/c/labcomm_udp_reader_writer.c udp_hack.c
-llabcomm
examples/simple
_java
/udp_decoder.c
→
examples/simple
/datagram
/udp_decoder.c
View file @
4583884b
File moved
examples/simple
_java
/udp_encoder.c
→
examples/simple
/datagram
/udp_encoder.c
View file @
4583884b
File moved
examples/simple
_java
/example_decoder.c
→
examples/simple/example_decoder.c
View file @
4583884b
File moved
examples/simple
_java
/example_encoder.c
→
examples/simple/example_encoder.c
View file @
4583884b
File moved
examples/simple
_java
/run.sh
→
examples/simple/run.sh
View file @
4583884b
File moved
examples/simple
_java
/simple.lc
→
examples/simple/simple.lc
View file @
4583884b
File moved
examples/simple
_java
/thr_decoder.c
→
examples/simple/thr_decoder.c
View file @
4583884b
File moved
examples/simple
_java
/thr_encoder.c
→
examples/simple/thr_encoder.c
View file @
4583884b
File moved
examples/simple_java/thr_compile.sh
deleted
100644 → 0
View file @
d7b40aa9
#gcc -o thr_encoder -L ../../lib/c -I . -I ../../lib/c thr_encoder.c gen/simple.c ../../lib/c/labcomm_thr_reader_writer.c ../../lib/c/ThrottleDrv/*.c -llabcomm
#gcc -o thr_decoder -L ../../lib/c -I . -I ../../lib/c thr_decoder.c gen/simple.c ../../lib/c/labcomm_thr_reader_writer.c ../../lib/c/ThrottleDrv/*.c -llabcomm
gcc
-o
thr_example
-L
../../lib/c
-I
.
-I
../../lib/c thr_example.c gen/simple.c ../../lib/c/labcomm_thr_reader_writer.c ../../lib/c/ThrottleDrv/
*
.c
-llabcomm
examples/simple_java/udp_compile.sh
deleted
100644 → 0
View file @
d7b40aa9
gcc
-g
-o
udp_encoder
-L
../../lib/c
-I
.
-I
../../lib/c udp_encoder.c gen/simple.c ../../lib/c/labcomm_udp_reader_writer.c ../../lib/c/udp_hack.c
-llabcomm
gcc
-g
-o
udp_decoder
-L
../../lib/c
-I
.
-I
../../lib/c udp_decoder.c gen/simple.c ../../lib/c/labcomm_udp_reader_writer.c ../../lib/c/udp_hack.c
-llabcomm
lib/c/Makefile
View file @
4583884b
CC
=
gcc
CFLAGS
=
-g
liblabcomm.a
:
labcomm.o labcomm_fd_reader_writer.o ethaddr.o
ar
-r
liblabcomm.a labcomm.o labcomm_fd_reader_writer.o ethaddr.o
liblabcomm.a
:
labcomm.o labcomm_fd_reader_writer.o labcomm_udp_reader_writer.o labcomm_thr_reader_writer.o ethaddr.o ThrottleDrv/ethernet_drv.o ThrottleDrv/throttle_drv.o
# ar -r liblabcomm.a labcomm.o labcomm_fd_reader_writer.o ethaddr.o
ar
-r
liblabcomm.a
$^
labcomm.o
:
labcomm.c labcomm.h labcomm_private.h
...
...
@@ -10,6 +11,8 @@ labcomm_fd_reader_writer.o : labcomm_fd_reader_writer.c labcomm_fd_reader_write
ethaddr.o
:
ethaddr.c
%o
:
%c %h
clean
:
rm
*
.o
...
...
lib/c/README
0 → 100644
View file @
4583884b
Throttlenet library
The library consists of a generic part and readers/writers for the low-level transport.
The stable low-level is the _fd_ variety, on top of unix sockets.
Currently, experimental varieties include datagrams on top of UDP and raw ethernet
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment