avr: Fix documentation for Bus
[avr-sim.git] / tools / interrupts.awk
blob77b256f4841c1b9f14906c2d9fc8c5bccf70fc1e
1 BEGIN { print "<interrupts>" }
2 END { print "</interrupts>" }
4 function xml(vector, addr, name, comment) {
5 print "\t<interrupt vector=\"" vector "\" address=\"" addr "\" name=\"" name "\"> <!-- " comment " --></interrupt>"
8 $1 ~ /[0-9]+/ && $2 ~ /0x[0-9A-F]+/ {
10 comment = ""
11 for(x = 4; x <= NF; ++x) {
12 sub(/[^a-zA-Z0-9]/, "", $x)
13 comment = comment " " $x
16 xml($1, $2, $3, comment)
17 next