Martine Lenders
1f6f02e196
cpu/native: adapt start-up and auto-init for multiple netdev2_tap
2017-01-19 12:07:10 +01:00
Toon Stegen
37c4810fba
cpu/native: allow multiple netdev2 tap devices
...
With arg added to async_read callback in 7020b7c0
, we don't need to keep
track of netdev2_tap locally. As a result we can use multiple
netdev2_tap instances.
2017-01-18 23:03:44 +01:00
Oleg Hahm
bfc439aa04
doc: native: do not parse internal functions
2017-01-15 13:06:43 +01:00
Cenk Gündoğan
0b85959efc
Revert "netdev2_tap: return actual byte number on read request"
...
This reverts commit 613bceeae3
.
FIONREAD seems to be unsupported for tun/tap interfaces in Linux.
2016-12-14 14:17:14 +01:00
Martine Lenders
613bceeae3
netdev2_tap: return actual byte number on read request
2016-11-16 23:57:04 +01:00
Ludwig Ortmann
0b72be7c87
native: add syscall-leave trampoline
2016-10-15 07:50:44 +02:00
Martine Lenders
16cae9771f
Merge pull request #5613 from OTAkeys/pr/async_read_cb_args
...
cpu/native: add args to async_read callback
2016-08-05 14:17:18 +02:00
Ludwig Knüpfer
d639f0b9a3
cpu/native: rewrite cpu_print_last_instruction
...
circumvent assembly by using a GCC/LLVM builtin
2016-07-26 12:44:43 +02:00
Toon Stegen
7020b7c09c
cpu/native: add args to async_read callback
...
this makes it possible to pass some generic pointer that's given back as
an argument when the callback is called.
2016-07-07 17:40:13 +02:00
zhuoshuguo
efbbca1322
cpu: Fix header include guards
2016-06-20 10:18:59 +02:00
MohmadAyman
720136491a
cpu: unify naming of ISR stacksize macro
2016-06-01 22:47:34 +02:00
Oleg Hahm
3f1c2e1f1b
native: assert that the pktbuf is big enough
...
Rationale: the netdev2_tap Ethernet driver for native requires to temporarily store at least a maximum sized Ethernet frame.
2016-04-20 09:10:55 +02:00
Yonezawa-T2
79d33897cb
native: add UART driver based on /dev/tty
...
uart0 functionality is removed by #3164 . This patch implements periph/uart,
rather than deprecated uart0, using /dev/tty.
To use with netdev2_tap simultaneously, this patch adds asynchronus read system
and modifies netdev2_tap to use it.
A TTY device is specified on command line with -c (COM) option, since -t was
used by the old implementation.
This patch also implements empty GPIO driver needed by the xbee driver.
2016-03-31 16:59:12 +09:00
Oleg Hahm
59674a679b
netdev2: use params parameter for setup
2016-03-28 20:22:20 +02:00
Joakim Nohlgård
405811da2b
native: remove unused XTIMER_USLEEP_UNTIL_OVERHEAD
2016-03-14 08:26:44 +01:00
9082273746
core: header cleanup
2016-02-28 22:46:28 +01:00
Hauke Petersen
940097336a
cpu: cleanup and unification of CPUID implementations
...
- moved definition of CPUID_LEN to periph_cpu.h
- fixed some doxygen
- simplyfied some implementations
2016-02-08 14:36:03 +01:00
5f44a6938d
cpu: native: adapt xtimer backoff values to periph/timer change
2016-01-06 22:07:13 +01:00
effb15a2cc
Merge pull request #3313 from gebart/pr/eINT-fixes
...
eINT/dINT fixes
2015-09-29 12:39:16 +02:00
Ludwig Knüpfer
eda6328e21
documentation: update my name (Ortmann -> Knüpfer)
2015-09-27 18:58:30 +02:00
Joakim Gebart
27565a655e
cpu/native: remove dINT/eINT definitions
2015-09-19 10:38:18 +02:00
4e8bf2cb69
cpu: native: remove hwtimer traces
2015-09-16 10:58:53 +02:00
fb773bf90a
cpu: native: remove hwtimer_compat dependency
2015-09-16 10:58:51 +02:00
Martine Lenders
93f555ef69
Merge pull request #3782 from OlegHahm/RIOT_assert
...
core: RIOT's own assert macro
2015-09-12 13:12:34 +02:00
Oleg Hahm
f3245cecac
core: panic: last instruction's address for assert
2015-09-11 23:23:31 +02:00
Oleg Hahm
d7161b6d4b
cpu: inline function to print instruction register
2015-09-11 23:23:31 +02:00
344b56bca8
Merge pull request #3167 from haukepetersen/fix_native_stacksizes
...
cpu/native: adjusted stacksizes
2015-09-05 23:17:45 +02:00
Hauke Petersen
7701aed546
Merge pull request #3164 from kaspar030/remove_uart0
...
sys: remove uart0
2015-09-04 18:54:30 +02:00
0e4386a46f
native: remove uart0
2015-09-04 17:46:23 +02:00
ef972735dc
sys: net: replace dev_eth with netdev2, adapt native tap driver
2015-09-04 15:39:04 +02:00
Thomas Eichinger
f10939c01e
cpu/native: add conditional include on OS X for IFNAMSIZ
2015-09-02 17:34:47 +02:00
Martine Lenders
ca71ae4f59
dev_eth: fix documentation
2015-08-09 22:02:10 +02:00
Martine Lenders
472ee315f0
ethernet/ethertype: remove ng_ prefix
2015-08-07 17:09:19 +02:00
Hauke Petersen
75472eddf4
cpu: remove transceiver defines from cpu_conf files
2015-08-06 12:13:54 +02:00
5d8349298f
remove bulk of legacy network stack and drivers
2015-08-06 12:12:47 +02:00
Benoît Canet
22da1f834b
native: ng: net: Close tap device and cleanup on reboot
2015-08-03 18:17:53 +02:00
Benoît Canet
800b057fac
native: net: Make _native_tap_fd static
...
One global variable less is always good.
2015-08-03 18:17:52 +02:00
21238b2ccc
Merge pull request #3347 from benoit-canet/timer
...
native: timer: synchronize HWTIMER_SPIN_BARRIER with native timer min resolution
2015-07-29 10:14:58 +02:00
Thomas Eichinger
cbc9ddc639
native: add missing include for FreeBSD
2015-07-21 18:31:13 +02:00
Hauke Petersen
08c4732fba
cpu/native: adjusted stacksizes
...
The stacksizes for native were defined in a way, so that
DEBUG did not work inside of interrupt routines. The new
values should still be large enough but allow now for this.
2015-07-14 15:06:50 +02:00
Benoît Canet
e01329796d
native: timer: synchronize HWTIMER_SPIN_BARRIER with timer min resolution
...
This keeps the test/hwtimer_wait test duration correct.
2015-07-09 20:42:21 +02:00
Benoît Canet
dfbd4f946e
cpu: native: switch to hwtimer_compat
...
The hwtimer_wait test was tortured with the
following script which ran several hours.
----
make clean all-debug
while :
do
date
./bin/native/hwtimer_wait.elf > log &
pid=$!
sleep 20
success=$(cat log|grep success)
if [ "$success" != "success" ]
then
date
echo "BUG"
exit
fi
kill $pid
done
----
Closes #715 .
2015-07-09 02:43:04 +02:00
fe96d379f6
native: add periph/timer.h timer implementation
2015-07-09 02:43:04 +02:00
Hauke Petersen
5abd2ffc0a
cpu/native: added periph_cpu.h
2015-06-12 19:10:49 +02:00
Hauke Petersen
a5e4b02ed8
cpu: fixed doxygen for multiple headers
2015-05-28 15:45:05 +02:00
Hauke Petersen
9943f51080
global: renamed cpu-conf.h into cpu_conf.h
2015-05-28 15:45:05 +02:00
cfd9a5905a
Merge pull request #2766 from kaspar030/add_dev_eth
...
sys: net: introduce low-level ethernet driver API
2015-05-26 19:28:14 +02:00
fbfb0954eb
cpu: native: add tap implementation of dev_eth (ng_nativenet)
2015-05-26 15:37:55 +02:00
Lucas Jenss
426170b064
Improve naming of thread stacksize/priority constants
...
As discussed in #2725 , this commit renames a number of stacksize constants to
better convey their intended usage. In addition, constants for thread priority
are given a `THREAD_` prefix. Changes are:
* KERNEL_CONF_STACKSIZE_PRINTF renamed to THREAD_EXTRA_STACKSIZE_PRINTF
* KERNEL_CONF_STACKSIZE_DEFAULT renamed to THREAD_STACKSIZE_DEFAULT
* KERNEL_CONF_STACKSIZE_IDLE renamed to THREAD_STACKSIZE_IDLE
* KERNEL_CONF_STACKSIZE_MAIN renamed to THREAD_STACKSIZE_MAIN
* Move thread stacksizes from kernel.h to thread.h, since the prefix changed
* PRIORITY_MIN renamed to THREAD_PRIORITY_MIN
* PRIORITY_IDLE renamed to THREAD_PRIORITY_IDLE
* PRIORITY_MAIN renamed to THREAD_PRIORITY_MAIN
* Move thread priorities from kernel.h to thread.h since the prefix has changed
* MINIMUM_STACK_SIZE renamed to THREAD_STACKSIZE_MINIMUM for consistency
2015-05-21 00:14:23 +02:00
Oleg Hahm
3dd3bbb461
transceiver: use transceiver specific broadcast
2015-04-19 20:35:11 +02:00
Ludwig Ortmann
9a130e2e84
cpu/native: add some syscall wrappers
...
Add wrappers for chdir, setsid, and umask.
2015-02-17 22:00:14 +01:00
Cenk Gündoğan
432f0014c0
cpu: restrict => __restrict
2015-02-08 19:15:14 +01:00
Ludwig Ortmann
88fa49ab38
cpu/native: add high-quality random implementation
...
Per default random data is read from `/dev/random` now.
If specified (e.g. `-s 4711`), data is generated by calls to POSIX
random function like before. The POSIX random API is initialize with
the given seed (`srandom(4711);` in this example).
2015-01-14 11:51:23 +01:00
Oleg Hahm
6dac96ad1b
Merge pull request #1904 from LudwigOrtmann/native_bufferbloat
...
native: increase buffer size, set defaults conditionally
2015-01-07 03:00:01 +01:00
Ludwig Ortmann
c0ef84bb9f
native: move rtc to periph
...
* adapt implementation to new interface
* remove now superfluous drivers directory
2014-12-13 15:21:52 +01:00
Oleg Hahm
d92e9af91c
doc: fixed broken param descriptions
2014-11-30 22:34:50 +01:00
Oleg Hahm
f8ecbf2a0a
doc: add to group instead of redefining
2014-11-30 21:45:24 +01:00
Oleg Hahm
df9c09d946
doc: fixed typos and other misspellings
2014-11-30 21:32:12 +01:00
Oleg Hahm
cc73296d43
doc: added missing titles
2014-11-30 21:22:52 +01:00
Ludwig Ortmann
00092e8308
native: add time syscalls
2014-11-25 22:47:27 +01:00
Ludwig Ortmann
7901d24053
native: add missing syscall declarations
2014-11-25 22:47:26 +01:00
BytesGalore
a4d2ee307c
cpu: added extern "C"
to headers
2014-11-24 19:10:15 +01:00
Ludwig Ortmann
adb24b06b8
native: add random peripheral implementation
2014-11-19 14:26:58 +01:00
Ludwig Ortmann
d8641ff525
native: add random syscalls
2014-11-19 14:26:58 +01:00
Ludwig Ortmann
42e43d5e12
FIXUP: remove erroneous comment
2014-11-17 09:56:03 +01:00
Ludwig Ortmann
acaa6481cb
native: add more syscall declarations
2014-11-14 20:52:17 +01:00
Ludwig Ortmann
641cb4c488
native: add accept syscall declaration
2014-11-14 17:49:56 +01:00
Martine Lenders
bbeb4941fa
nativenet: add missing include
2014-11-10 05:19:28 +01:00
Ludwig Ortmann
4545c15f70
native: inrease default transceiver buffer
2014-10-30 13:20:51 +01:00
Ludwig Ortmann
5d606b676d
native: set net buffer defaults conditionally
2014-10-30 13:20:45 +01:00
Ludwig Ortmann
7bcf896ec6
native: add and use callback type
2014-10-30 12:11:22 +01:00
Martine Lenders
264785852e
nativenet: Supply net_dev_t support for nativenet
2014-10-09 09:40:58 +02:00
Ludwig Ortmann
b849b848a0
native: add two more syscall declarations
2014-10-01 21:56:43 +02:00
Ludwig Ortmann
289c4c0ee4
doc: add license headers to some .h files
2014-09-18 17:45:11 +02:00
Ludwig Ortmann
b7992922ce
fix license headers in non-.c files
2014-08-23 16:16:26 +02:00
Ludwig Ortmann
1c3f481702
tests, native: fixup for cpuid
...
- adopt test name to new scheme
- make cppcheck happy / dont overwrite the target memory location twice
- fix license header
- don't redefine define if it already exists
- don't write more cpuid than is defined as size
2014-08-05 16:55:42 +02:00
Oleg Hahm
983d056c75
core: harmonizes the data type for the process ID
...
Instead of using differing integer types use kernel_pid_t for process
identifier. This type is introduced in a new header file to avoid
circular dependencies.
2014-08-01 12:02:54 +02:00
Martine Lenders
b1bc11c7fc
native: cpu: Add documentatiton for CPUID_ID_LEN
2014-07-31 23:27:38 +02:00
Martin Lenders
239f2e0f24
Implement CPU id getter for native
2014-07-31 23:05:15 +02:00
Ludwig Ortmann
3cda0369cb
native: cleanup
...
fix style
fix some syscall declarations
reorder syscall declarations
init syscalls in dedicated function
substitute 1 with EXIT_FAILURE
2014-07-27 15:16:38 +02:00
Ludwig Ortmann
c6bcc344ca
native: uart reconnect buffer replay
...
When using socket stdio, add option to replay what has been written to
stdout while not connected (`-r`).
The implementation is to simply use the existing log file (which is
implicitly created when the option is used), and read from it until
EOF upon reconnect.
closes #476
2014-07-27 15:16:38 +02:00
Ludwig Ortmann
df36f6304a
native: remove stale TODOs and blank line
...
The values are quite OK.
2014-07-13 07:24:01 +02:00
René Kijewski
63dd8546af
Merge pull request #1335 from Kijewski/fix-all-warnings-for-native-and-qemu-i386
...
Fix all warnings for native and qemu-i386
2014-07-02 10:58:48 +02:00
Oleg Hahm
44e5d8cfd0
nativenet: change max packet size to 127
...
Real IEEE 802.15.4 transceivers have a payload of 127. Hence, for
testing - particular 6lowpan - it would make sense to have the same
limitation in nativenet. Especially to test fragmentation this is
helpful.
2014-07-01 18:31:40 +02:00
René Kijewski
3063e3c2b1
Fix all warnings for native and qemu-i386
...
Missing returns, unused variables (only used for debugging), empty
translation units, missing function prototypes, and GNU extensions.
2014-06-24 16:50:32 +02:00
René Kijewski
2f871ca885
native: remove some warnings about undef functions
...
This PR implements `real_X` for `X in (fork, dup2, unlink, execve)`.
These function caused warnings while making the default example.
2014-06-18 20:34:12 +02:00
René Kijewski
2e9a1773e9
native: use real_pipe()
and read_close()
2014-06-14 00:39:02 +02:00
Ludwig Ortmann
dbc36fc2c5
native: add id option
2014-06-06 16:30:54 +02:00
Ludwig Ortmann
1e5e19bc23
native: set optional path with unix socket option
...
fixes #1045
2014-06-03 16:46:40 +02:00
Oleg Hahm
ef4fe6616c
documentation: unified descriptive text for cpu
2014-05-24 15:56:57 +02:00
Ludwig Ortmann
98bbb80571
documentation: append my email to my name everywhere
2014-05-15 18:07:17 +02:00
Thomas Eichinger
7a031e5669
net: handle macro redefinitions for OS X
...
undefine macros and reorder header includes to get rid of system
defined macros on OS X
fixes #1165
2014-05-14 19:43:58 +02:00
René Kijewski
8038e96d09
Merge pull request #1119 from Kijewski/error_old-style-definition
...
Exterminate old-style function definitions
2014-05-14 13:31:30 +02:00
Ludwig Ortmann
166b88f1ae
native: internal getpid syscall
2014-05-14 09:13:57 +02:00
Ludwig Ortmann
4c961bfb6e
native: refactor getpid calls
2014-05-14 09:13:57 +02:00
René Kijewski
628419eb11
Exterminate old-style function declaration/prototypes
2014-05-12 21:57:09 +02:00
Hauke Petersen
7545eff784
core/cpu/board: moved F_CPU define to board
2014-05-06 10:36:09 +02:00
Ludwig Ortmann
42aa3d9f5b
native: update support for FreeBSD
...
works with FreeBSD 10.0 amd64/i386
fixes : #505
2014-04-20 07:31:40 +02:00
René Kijewski
0b75a11291
native: don't use RIOT read/write in UART
2014-03-30 22:33:50 +02:00
Hauke Petersen
8a937e1a1c
hwtimer: clean up of interfaces to board/cpu
2014-03-26 13:19:18 +01:00
Ludwig Ortmann
0501fe8980
native: config_load: set PID as id, net address
2014-03-18 08:07:30 +01:00
Ludwig Ortmann
561eefab07
implement rudimentary native reboot
2014-02-14 16:20:36 +01:00
Ludwig Ortmann
114aaa65e5
Merge pull request #626 from LudwigOrtmann/issue_621
...
add EUI-64 support for nativenet
2014-02-11 19:30:23 +01:00
Ludwig Ortmann
2525920426
remove trailing whitespace and newlines
2014-02-11 18:45:06 +01:00
Ludwig Ortmann
d5d3bbcd44
add EUI-64 support for nativenet
2014-02-10 08:33:57 +01:00
Ludwig Ortmann
4939473afb
guard malloc/free family
2014-01-24 17:30:47 +01:00
Ludwig Ortmann
6fe1ecd1b4
Merge pull request #479 from LudwigOrtmann/nativenet_lenchck
...
Nativenet length check and cleanup
2014-01-10 01:47:35 -08:00
Oleg Hahm
fe575d52df
Merge pull request #364 from OlegHahm/float_stack_sizes
...
added a dedicated stacksize for float printfs
2014-01-09 10:48:38 -08:00
Ludwig Ortmann
ac0ec1f6b3
nativenet clean up
...
Make nativenet tap payload type consistent with radio_packet_t
Also remove a trailing space
2014-01-08 14:57:11 +01:00
Ludwig Ortmann
ea8b735232
fix nativenet_send documentation
2013-12-24 11:57:54 +01:00
Ludwig Ortmann
cf87e647c0
make native includes RIOT posix compatible
2013-12-22 23:26:54 +01:00
Ludwig Ortmann
ef315ed662
improve nativenet send functions return type
2013-12-21 16:56:42 +01:00
Martin Lenders
69809928d3
Make UART0_BUFSIZE configurable by CPU
2013-12-20 11:10:42 +01:00
Oleg Hahm
ead2e117a1
Merge pull request #439 from OlegHahm/thread_yield_prototype
...
put prototype for thread_yield() in core/include
2013-12-18 13:36:55 -08:00
Christian Mehlis
2a9aac7f0b
Merge pull request #423 from OlegHahm/fix_warnings
...
Fix warnings
2013-12-18 12:02:37 -08:00
Oleg Hahm
2cdfc5b585
Merge pull request #382 from OlegHahm/transceiver_return
...
transceiver return signed values for sending
2013-12-18 09:33:32 -08:00
Oleg Hahm
d87d827d88
transceiver return signed values for sending
...
negative values indicate an error value
2013-12-18 18:22:59 +01:00
Oleg Hahm
227c847135
put prototype for thread_yield() in core/include
2013-12-18 17:47:49 +01:00
Hauke Petersen
edcabf7cb6
Fixed a lot of comments by removing tabs and correcting format.
2013-12-16 14:00:33 +01:00
Hauke Petersen
3785fe956b
Fixed doxygen comments, focused on file headers and group definitions
2013-12-16 14:00:24 +01:00
Oleg Hahm
72586f7a6d
limit maximum payload size to 255 for nativenet if 6lowpan is used
2013-12-13 18:53:48 +01:00
Ludwig Ortmann
916757cf4c
implement err.h
...
valgrind reported invalid reads/writes with glibc err[x]|warn[x] (in
glibc printf) when stdio had been redirected in between.
define _progname (pointing to argv[0])
2013-12-10 17:00:01 +01:00
Ludwig Ortmann
d6c213fb47
fix grammar in license header
2013-11-23 13:11:56 +01:00
Oleg Hahm
6a1fcaf288
added a dedicated stacksize for float printfs
2013-11-21 20:41:28 +01:00
Ludwig Ortmann
c764728398
pre-init native hwtimer
...
make it behaver more like a regular timer
2013-11-13 01:31:31 +01:00
Ludwig Ortmann
7b9d199ec8
make system calls safer/clean up headers
...
wrap some libc functions that do system calls (terminal output)
wrap read/write with syscall guard
define real_read/write (next dynamic linker find for read/write)
guard system calls in remaining code
introduce native_internhal.h
throw out some debug statements that break things
clean up includes a bit
declare board_init in native_internhal.h
add -ldl to LINKFLAGS for cpu/syscalls
2013-11-13 00:01:42 +01:00
Christian Mehlis
4f4c4bfedd
use radio_packet_length_t for native frames
2013-10-29 20:36:13 +01:00
Ludwig Ortmann
7f7290a26a
normalize stack defines
2013-10-25 11:40:33 +02:00
Ludwig Ortmann
24b2cfd95a
general clean up
...
make some variables volatile
remove rx_buffer_next from header
more DEBUG output
fix warnings
coding conventions
change puts to DEBUG
rename end-context/stack
2013-09-30 18:03:53 +02:00
Ludwig Ortmann
c6180a6e4f
fix NATIVE_MAX_DATA_LENGTH
2013-08-29 16:16:47 +02:00
Ludwig Ortmann
74b1a74525
documentation for nativenet interface
2013-08-29 16:16:47 +02:00
Ludwig Ortmann
37c3059e1c
clean up nativenet, add src addr
2013-08-29 16:16:46 +02:00
Ludwig Ortmann
52b4370e7d
fix register_interrupt callback parameter
2013-08-18 11:25:43 +02:00
Oleg Hahm
2d4de90a9c
added missing header guards
2013-08-15 19:39:29 +02:00
Ludwig Ortmann
708ece68cc
cc1100 -> nativenet
2013-08-15 14:05:26 +02:00
Ludwig Ortmann
a634709c00
native cc1100x_ng network
...
not properly passing received data to transceiver atm
2013-08-15 14:05:26 +02:00
Oleg Hahm
3ad55cce8b
changed default stacksize
...
* the default stacksize no longer set for a thread using printf
* the stacksize for the main thread therefore adds the necessary space
2013-08-14 18:04:25 +02:00
Oleg Hahm
3adb6fa217
removed senseless include of debug.h in a header
2013-07-25 21:56:09 +02:00
Oleg Hahm
33423cdadb
redefining default stack sizes dependent on the use of printf
2013-07-23 13:42:58 +02:00
Christian Mehlis
837bad38eb
rename kernel_intern.h
...
german "intern" to english "internal"
2013-07-16 16:36:37 +02:00
Oliver Hahm
b571286574
* fixed typo
2013-06-18 17:26:53 +02:00
Oliver Hahm
ac10da4509
Merge branch 'fixes-06-14' of git://github.com/mehlis/RIOT into mehlis-fixes-06-14
2013-06-18 17:25:44 +02:00
Oliver Hahm
0d6d8390c0
* updated copyright and license headers in various files
2013-06-18 17:21:38 +02:00
Martin
0dd314afbb
fix multiple definition of TRANSCEIVER_STACK_SIZE for using with native cpu
2013-06-14 20:21:22 +02:00
Ludwig Ortmann
4f0e4dec90
fix ucontext.h include for OSX, FreeBSD
2013-06-03 13:10:42 +02:00
Ludwig Ortmann
35f9062e37
inital OSX support for native port
2013-05-15 17:45:43 +02:00
Ludwig Ortmann
7bf9fa0314
increase MINIMUM_STACK_SIZE to allow for DEBUG
2013-05-15 10:46:09 +02:00
Ludwig Ortmann
c6553f6492
interrupt handling rewrite
...
(including uart0 integration, rt-extension removal)
2013-05-14 18:31:47 +02:00
Ludwig Ortmann
2d29a26b64
fix stack and interrupt bugs
2013-04-15 20:08:46 +02:00
Ludwig Ortmann
2f74d35709
removed posix real-time extension timers from cpu
2013-04-03 18:53:19 +02:00