That may very well be a bug i the nrf51 adc tree. From the adc_nrf52.h: #include <adc/adc.h>
#include <nrf.h> #include <nrf_saadc.h> vs the adc_nrf51.h: #include <adc/adc.h> #include <nrf.h> #include <nrf_adc.h> dg > On Feb 9, 2017, at 2:01 PM, Jacob Rosenthal <[email protected]> wrote: > > Swapping nrf52 where you said nrf51 as thats what Im working with, Thats > what Im doing and I still get the > > > Error: repos/mynewt_nordic/hw/drivers/adc/adc_nrf51/src/adc_nrf51.c:27:21: > fatal error: nrf_adc.h: No such file or directory > #include <nrf_adc.h> > ^ > compilation terminated. > > The underlying adc_nrf51 package cant seem to see the nrf_adc header from > the nordic sdk package. > > > > On Tue, Feb 7, 2017 at 1:34 PM, David G. Simmons <[email protected]> wrote: > >> In your pkg.yml file: >> >> "@mynewt_nordic/hw/drivers/adc/adc_nrf52" >> >> In your source file: >> >> #include <adc/adc.h> >> #include <adc_nrf52/adc_nrf52.h> >> #include "nrf_drv_saadc.h" >> >> For an ADC app that (at least used to work) see https://github.com/ >> davidgs/incubator-mynewt-core/blob/adc_demo/apps/nrf52_adc/src/main.c >> >> dg >> >> On Feb 7, 2017, at 3:30 PM, Jacob Rosenthal <[email protected]> >> wrote: >> >> Im not sure how to include, or if nrf adc works. >> >> If I add >> - "@mynewt_nordic/hw/mcu/nordic_sdk" >> >> I get: >> >> Error: repos/mynewt_nordic/hw/drivers/adc/adc_nrf51/src/adc_nrf51.c:27:21: >> fatal error: nrf_adc.h: No such file or directory >> >> #include <nrf_adc.h> >> >> >> Am I missing some other resources in pkg? or is maybe an include path bad? >> >> Thanks, >> Jacob >> >> >> -- >> David G. Simmons >> (919) 534-5099 >> Web <https://davidgs.com> • Blog <https://davidgs.com/davidgs_blog> • >> Linkedin <http://linkedin.com/in/davidgsimmons> • Twitter >> <http://twitter.com/TechEvangelist1> • GitHub <http://github.com/davidgs> >> /** Message digitally signed for security and authenticity. >> * If you cannot read the PGP.sig attachment, please go to >> * http://www.gnupg.com/ Secure your email!!! >> * Public key available at keyserver.pgp.com >> **/ >> ♺ This email uses 100% recycled electrons. Don't blow it by printing! >> >> There are only 2 hard things in computer science: Cache invalidation, >> naming things, and off-by-one errors. >> >> >> -- David G. Simmons (919) 534-5099 Web <https://davidgs.com/> • Blog <https://davidgs.com/davidgs_blog> • Linkedin <http://linkedin.com/in/davidgsimmons> • Twitter <http://twitter.com/TechEvangelist1> • GitHub <http://github.com/davidgs> /** Message digitally signed for security and authenticity. * If you cannot read the PGP.sig attachment, please go to * http://www.gnupg.com/ <http://www.gnupg.com/> Secure your email!!! * Public key available at keyserver.pgp.com <http://keyserver.pgp.com/> **/ ♺ This email uses 100% recycled electrons. Don't blow it by printing! There are only 2 hard things in computer science: Cache invalidation, naming things, and off-by-one errors.
signature.asc
Description: Message signed with OpenPGP
