Werner Almesberger
5b1f722568
tools/: -S now dumps samples to stdout; -S -S produces graphical output
2012-06-23 14:35:44 -03:00
Werner Almesberger
2f120fa683
tools/antorcha.c (samples): move reading of X/Y samples to shared function
2012-06-23 14:25:08 -03:00
Werner Almesberger
18c7b43a59
fw/reset.c: oops, forgot to commit the reset protocol handler
2012-06-23 12:03:25 -03:00
Werner Almesberger
06f9907cae
fw/image.c: put image_secret in PROGMEM to save scarce RAM
2012-06-23 12:01:37 -03:00
Werner Almesberger
a59bb00a27
fw/hash.[ch]: new function hash_merge_progmem to read from Flash instead of RAM
2012-06-23 11:59:47 -03:00
Werner Almesberger
420370ee9c
Merge branch 'detached'
...
Had a detached head for several hours :-(
Conflicts:
doc/PROTOCOL
fw/sample.c
2012-06-21 21:20:05 -03:00
Werner Almesberger
e2f228907b
fw/accel.c (adcsra): let ADC run at 125 kHz (instead of 67.5 kHz)
2012-06-21 21:12:20 -03:00
Werner Almesberger
b262e2f142
fw/spi.c (spi_init): revert the SPI speed increase (caused instability)
...
Some more testing showed that transfers would get stuck after ~40 packets.
Need to find out what happened before trying this again.
2012-06-21 19:52:41 -03:00
Werner Almesberger
ffcfd3d09d
fw/spi.c (spi_init): raise SPI speed from fosc/4 to fosc/2
2012-06-21 19:38:44 -03:00
Werner Almesberger
ea994c8ed0
tools/antorcha.c (samples): show the timestamp when printing sample values
2012-06-21 19:19:40 -03:00
Werner Almesberger
28cf696a08
fw/sample.c (handler): set the time in samples (was set to zero, for debugging)
2012-06-21 19:16:55 -03:00
Werner Almesberger
77bd5797d3
tools/plot.c: clear sample mode screen with C
2012-06-21 18:56:18 -03:00
Werner Almesberger
87050bc12a
tools/: exit from sample mode by pressing Q or by closing the window
2012-06-21 18:48:54 -03:00
Werner Almesberger
4eb1065dd7
tools/: add sampling mode (-S) with graphical output
2012-06-21 16:21:56 -03:00
Werner Almesberger
734e33cd19
doc/PROTOCOL: clarify byte order in SAMPLES messages
2012-06-21 16:20:21 -03:00
Werner Almesberger
8eca4c99c7
fw/sample.c: fix logic in handler() and filter incomplete samples
...
An incomplete sample would be an X value followed by another X value,
or Y followed by Y. Not entirely sure why this happens in the first
place, but it does happen.
2012-06-21 16:17:47 -03:00
Werner Almesberger
58e0dda95d
fw/accel.c: use timer 0 to trigger a pair of conversions (X/Y) only every 1 ms
2012-06-21 16:15:56 -03:00
Werner Almesberger
c7494c80fa
fw/accel.c: fix update() add interrupt-friendly update_irq()
...
Still untested.
2012-06-21 16:14:56 -03:00
Werner Almesberger
7356fccbfd
tools/Makefile: target "off" to load an empty image
2012-06-21 12:57:35 -03:00
Werner Almesberger
27455749bd
fw/: add acceleration sensor sample protocol (untested)
2012-06-21 12:51:57 -03:00
Werner Almesberger
f0e79b8dcc
fw/: add acceleration sensor sample protocol (untested)
2012-06-21 12:12:10 -03:00
Werner Almesberger
7a0bc4cb9c
fw/spi.c: clean up code and add option for running at fosc/2 instead of fosc/4
...
Not enabled yet. There's a RF comm regression elsewhere that needs fixing
first.
2012-06-21 12:03:32 -03:00
Werner Almesberger
eaa11b110c
fw/: sample the acceleration sensor (untested)
2012-06-21 08:56:56 -03:00
Werner Almesberger
7045109090
fw/accel.c: keep track of uptime and return it with uptime() (untested)
2012-06-21 08:56:41 -03:00
Werner Almesberger
3b7c3017fc
tools/Makefile: new targets "update" and "ping" for firmware update and ping
2012-06-20 18:43:26 -03:00
Werner Almesberger
2bac5e74a7
fw/image.c (image_first): call image_more to process the payload
...
This makes things work also for zero-sized files. I.e.,
./antorcha /dev/null
does precisely what one would expect. (Before, the transfer was
accepted, but the first salt block became the new image.)
2012-06-20 18:39:29 -03:00
Werner Almesberger
2011c515c8
fw/: pass limit also to "first" function of protocol handlers
2012-06-20 18:37:13 -03:00
Werner Almesberger
647f029775
tools/bit2ant: X bitmap to Antorcha image converter
2012-06-20 18:28:30 -03:00
Werner Almesberger
87f0ed17fc
tools/antorcha.c (send_image): fix packet type
...
Argh. Image upload now seems to work.
2012-06-20 17:17:23 -03:00
Werner Almesberger
625f262e1d
tools/antorcha.c: new option -d to enable message content dumping
...
This was a quick and dirty compile-time option before.
2012-06-20 17:17:16 -03:00
Werner Almesberger
bafdc8c563
tools/antorcha.c (usage): document image upload syntax
2012-06-20 17:13:30 -03:00
Werner Almesberger
c6fc8190de
fw/image.c: fix use of hash functions; make image pointer setup more readable
...
It was almost impossible NOT to read
next_image = p = image == images[0] ? ...
^^^^
as if it was
next_image = p = image = images[0] ? ...
^^^
2012-06-20 16:51:40 -03:00
Werner Almesberger
1668e702e5
fw/dispatch.c: fix initial sequence number; some cleanup
2012-06-20 16:50:55 -03:00
Werner Almesberger
1d1c83f926
tools/antorcha.c: add image upload (doesn't work yet)
2012-06-20 16:50:23 -03:00
Werner Almesberger
ab00d8e231
fw/antorcha.c: don't overrun image by one line in test mode
2012-06-20 16:48:16 -03:00
Werner Almesberger
b7d80f1340
fw/fw.c: simplify the use of the sequence number a little (untested)
...
Not sure if this even produces better code. It looks a bit cleaner, though.
2012-06-20 16:46:27 -03:00
Werner Almesberger
6286aa9bbc
fw/sweep.c: use ICR1 instead of double-buffered OCR1A; set pixel_ticks
...
Our timing is now accurate within a measured 0.5% on the test device,
which is well within the specified 1% of the calibrated RC oscillator.
2012-06-20 16:40:33 -03:00
Werner Almesberger
878498a405
PROTOCOL: move over to doc/
2012-06-20 11:39:18 -03:00
Werner Almesberger
ea2cd37c04
properly implement "ping" and invoke it with antorcha -P
2012-06-20 11:31:56 -03:00
Werner Almesberger
823fdcfcb1
tools/antorcha.c: require option -F for firmware upload
2012-06-20 10:56:11 -03:00
Werner Almesberger
9bc9c57fb2
fw/: simple image test mode (still untested)
2012-06-20 10:41:27 -03:00
Werner Almesberger
87cc67d5f7
fw/: add image data upload (completely untested)
2012-06-20 10:30:40 -03:00
Werner Almesberger
6223a58552
fw/: move image data from sweep.[ch] to new image.[ch]
2012-06-20 07:45:04 -03:00
Werner Almesberger
7003c9c35b
fw/: added image sweep (completely untested)
2012-06-20 07:39:24 -03:00
Werner Almesberger
2ecd291ca5
really remove NOTES (didn't do that in previous commit)
2012-06-20 07:26:10 -03:00
Werner Almesberger
8cb774b671
doc/DESIGN: moved over from NOTES
2012-06-19 10:05:16 -03:00
Werner Almesberger
2a5b6d4c0b
README: explain directory placement and avrdude.conf entry
2012-06-18 20:49:11 -03:00
Werner Almesberger
3c4855deff
fw/Makefile: cleanup
...
Remove references to a reset-secret, removed remote control via
programming interface.
2012-06-18 20:37:51 -03:00
Werner Almesberger
cc4b5607c7
RESET protocol to jump from application to boot loader without power cycling
2012-06-18 20:31:20 -03:00
Werner Almesberger
683056bca7
fw/Makefile: generate random unlock secret (from /dev/urandom)
2012-06-18 19:26:25 -03:00