Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

accelerometer example no longer works for microbit #24915

Closed
saewoonam opened this issue May 3, 2020 · 1 comment
Closed

accelerometer example no longer works for microbit #24915

saewoonam opened this issue May 3, 2020 · 1 comment
Labels
bug The issue is a bug, or the PR is fixing a bug

Comments

@saewoonam
Copy link

saewoonam commented May 3, 2020

Describe the bug
The accelerometer can not be found on the board...
Here is the output from gdb is below

  1. It can't find the accelerometer
  2. Somehow, it is using the wrong "return statement", instead of line 38, it is line 50

To Reproduce
west build -t pristine
west build -b bbc_microbit samples/sensor/fxos8700 -- -DCONF_FILE="prj_accel.conf"

gdb session:

0002701:INFO:loader:Erased 0 bytes (0 sectors), programmed 0 bytes (0 pages), skipped 33792 bytes (33 pages) at 23.72 kB/s
Start address 0x27bc, load size 33474
Transfer rate: 23 KB/sec, 1154 bytes/write.
(gdb) break main
Breakpoint 1 at 0x0: main. (2 locations)
(gdb) continue
Continuing.
Note: automatically using hardware breakpoints for read-only addresses.

Breakpoint 1, main () at zephyr/include/generated/syscalls/device.h:32
32 compiler_barrier();
(gdb) next
34 struct device *dev = device_get_binding(DT_LABEL(DT_INST(0, nxp_fxos8700)));
(gdb) next
36 if (dev == NULL) {
(gdb) print dev
$1 = (struct device *) 0x0 <z_finalize_fd>
(gdb) next
49 return;
(gdb)

@saewoonam saewoonam added the bug The issue is a bug, or the PR is fixing a bug label May 3, 2020
@saewoonam
Copy link
Author

Sorry, I just realized that I have a newer (not older) microbit. So, it uses a different accelerometer... Does anyone know if there is an example using the LSM303AGR on the microbit?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug The issue is a bug, or the PR is fixing a bug
Projects
None yet
Development

No branches or pull requests

1 participant