Commit graph

56 commits

Author SHA1 Message Date
bunnie
d583e20b18 very basic battery monitoring via COM 2020-11-25 05:11:32 +08:00
bunnie
058c4473bb helps to add the source code too 2020-11-24 22:45:44 +08:00
bunnie
fa12e513cd inital take at com 2020-11-24 22:45:10 +08:00
bunnie
bc832b3a50 fix interrupt pending clear issue in debug module
during conversion to documented interrupts from Litex a case was
missed.
2020-11-24 22:44:19 +08:00
Sean Cross
e7aa2c70a0 shell: use connect() instead of try_connect()
We don't need to use `try_connect()` anymore since we now have
`connect()` which will automatically retry as necessary.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-23 20:05:36 +08:00
Sean Cross
958fa96fde Merge branch 'master' of github.com:betrusted-io/xous-core 2020-11-23 19:32:31 +08:00
Sean Cross
0732075869 graphics-server: bounds-check the circle drawing
Otherwise we could overflow the buffer.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-23 19:31:52 +08:00
bunnie
1aa01fdf5d confirm sleep works, some minor fixup to UTRA style usage 2020-11-23 19:02:02 +08:00
Sean Cross
d5ba92a483 shell: re-enable msleep
Now that things work, we should be able to sleep.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-23 17:35:09 +08:00
Sean Cross
72a466bc61 ticktimer: use interrupt from UTRA
Previously UTRA didn't have an interrupt, so we just made one up. Use
the correct interrupt to get things working on hardware.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-23 17:34:18 +08:00
Sean Cross
5c89487ca2 shell: fix const debug warnings on 1.48
This fixes a bunch of warnings that appeared with Rust 1.48.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-23 17:21:24 +08:00
Sean Cross
12532e1734 log-server: fix const warnings on rust 1.48
Rust 1.48 changed how warnings of const values operate.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-23 17:21:03 +08:00
Sean Cross
78a47ab4ba services: ticktimer: fix debug warnings on hardware
These appeared in Rust 1.48.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-23 16:13:19 +08:00
Sean Cross
6c17531512 Merge branch 'master' of github.com:betrusted-io/xous-core 2020-11-23 16:03:57 +08:00
bunnie
d26c80582e clean up gfx server API, allow for string size setting 2020-11-23 15:42:58 +08:00
bunnie
41d7f2a0e5 add ScreenSize message, add hanzi test to boot screen 2020-11-23 14:55:56 +08:00
Sean Cross
be1687ffdd Merge branch 'master' of github.com:betrusted-io/xous-core 2020-11-23 14:20:27 +08:00
bunnie
48720dc6a7 right, comment out the offending line 2020-11-23 03:52:40 +08:00
bunnie
a2670a7537 minor tweaks to improve the rendering of the bouncyball 2020-11-23 03:49:09 +08:00
bunnie
2d5bd20c16 bouncing ball "招财猫"-like totem now working 2020-11-23 03:18:43 +08:00
bunnie
16e9f43015 add circle drawing to graphics 2020-11-23 00:40:40 +08:00
bunnie
710abce418 fixup to latest soc.svd register documentation standard 2020-11-22 03:45:44 +08:00
Sean Cross
796c9c5998 services: ticktimer: remove excess hosted printing
This was used to try and debug an issue in the ticktimer server, which
ended up being an issue in the kernel.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-11 16:23:23 +08:00
Sean Cross
d9272ba21a ticktimer: use log server
Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-11 16:09:34 +08:00
Sean Cross
aa315c534c ticktimer: implement msleep
Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-11 16:09:01 +08:00
Sean Cross
5a66f72938 ticktimer: add opcodes for msleep
Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-11 16:08:48 +08:00
Sean Cross
b8f69b4a7f ticktimer: use correct debug port
Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-11 16:07:33 +08:00
Sean Cross
1a0be47d05 shell: add loop number to msleep
This allows us to trace the loop number through the syscall.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-11 16:06:39 +08:00
Sean Cross
7391b98f4e log-server: remove excess printing from log string
Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-01 16:30:07 +08:00
Sean Cross
719549a2cb xous: rename ReturnToParentI -> ReturnToParent
This syscall isn't the only one that can be called from an interrupt
context.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-11-01 16:26:19 +08:00
Sean Cross
4f2be0c0e1 shell: use log-server for message logging
This paves the way for no longer needing our own UART for this process.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 21:27:35 +08:00
Sean Cross
1ffc440565 graphics-server: use log-server for all message printing
Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 21:27:06 +08:00
Sean Cross
e18219b078 log-server: add first draft of logging server
This server implements `log`, and comes with a `lib` that allows for
setting up logging.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 21:26:19 +08:00
Sean Cross
f46f7c6e81 shell: use new String struct from xous
Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 11:19:43 +08:00
Sean Cross
9192775e5e graphics-server: use String for String opcode
Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 11:19:17 +08:00
Sean Cross
c33794c859 shell: use new graphics subsystem
Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 10:30:34 +08:00
Sean Cross
7fc8dafc39 shell: add StringBuffer struct
Add a StringBuffer struct that can be used to create string messages.

This will eventually be promoted to Xous.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 10:29:58 +08:00
Sean Cross
2d4a2bf871 ticktimer: use millis instead of nanos on hosted
The `elapsed_ms()` function should probably return milliseconds rather
than nanoseconds. Time marches on.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 10:29:12 +08:00
Sean Cross
c7164c461d log-server: unify print messages for log_string
Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 10:28:01 +08:00
Sean Cross
5823c23472 log-server: unify log messages
Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 10:27:13 +08:00
Sean Cross
d9f858bcf0 log-server: remove pancurses dependency
This hasn't been required in a very long time.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 10:26:16 +08:00
Sean Cross
af1a7f5ba5 graphics-server: first general merge of gfxlib
Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 10:22:03 +08:00
Sean Cross
7607b0f9ee graphics-server: remove embedded-graphics from backends
Use native drawing for these platforms.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 10:21:06 +08:00
Sean Cross
a2fd6b0438 graphics-server: remove dependency on embedded-graphics
The graphics server will implement its own routines.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-30 10:20:19 +08:00
Sean Cross
0bce0eeb53 ticktimer: implement hosted version of ticktimer
This gets the basic ticktimer server working in a hosted environment.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-28 11:14:26 +08:00
Sean Cross
4334e7c23e shell: fix build for hosted
Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-28 11:14:09 +08:00
Sean Cross
f9af2322f7 log-server: fix compiling for hosted builds
Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-28 11:13:39 +08:00
Sean Cross
dfed13bd9f shell: initialize the logstr before using it
This fixes UB when accessing an uninitialized value.

Signed-off-by: Sean Cross <sean@xobs.io>
2020-10-15 11:58:23 +08:00
bunnie
9ee43a7acc some more attempts to get log strings working... 2020-10-15 00:01:02 +08:00
bunnie
c8a2f34998 add debug output to log_string 2020-10-14 23:15:33 +08:00