You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mynewt.apache.org by aditi hilbert <ad...@runtime.io> on 2018/03/20 01:11:36 UTC

Sample apps in mynewt-core

Hi all,

We have been adding a lot of features and functionality in Apache Mynewt recently. Sample apps make it easy to see how to use them; so adding some sample apps would be much appreciated. Here's an initial list of sample apps that we could add. Please respond if you wish to contribute one or add to the list. And I think we should add a README.md for every app in the repo.

* PWM - control LED brightness
* ADC, UART - read voltage on ADC, print value to UART
* ADC, I2C - read out an ADC over I2C
* Expose a resource by enabling a CoAP server 
* CoAP, LoRa - enable CoAP client on one LoRa node, CoAP server on another, retrieve a resource value
* Cycle through available power states (deep sleep, low power etc.)
* Sensor - change sampling rate
* Sensor - read multiple I2C sensors simultaneously
* Sensor - trigger a notification when a threshold is crossed
* Logging, Sensor - enable FCB to log timestamped sensor data
* MMC, SPI, stats - write system stats to the card, read back
* testutil - adding a test for a package in sim using the testutil framework
* sensor, testutil - how to add a test for a sensor HW using the testutil framework

thanks,
Aditi

Re: Sample apps in mynewt-core

Posted by Lukasz Wolnik <lu...@gmail.com>.
Hi Łukasz,

Thanks for the tip! I'll try it out.

Kind regards,
Łukasz

On Wed, Mar 21, 2018 at 9:09 AM, Łukasz Rymanowski <
lukasz.rymanowski@codecoup.pl> wrote:

> Hi Łukasz,
>
> If your application supports pairing (like btshell for example), you
> will get Secure Connections  by setting MYNEWT_VAL BLE_SM_SC to 1.
> It is stack who handles it for you then.
>
> Hope that helps.
>
> Best regards
> Łukasz
>
> On 20 March 2018 at 19:11, aditi hilbert <ad...@runtime.io> wrote:
> > Lukasz,
> >
> > Yes - great addition!
> >
> > thanks,
> > aditi
> >
> >> On Mar 20, 2018, at 8:16 AM, Lukasz Wolnik <lu...@gmail.com>
> wrote:
> >>
> >> Hi Aditi,
> >>
> >> Could we also add a sample app that uses NimBLE's Secure Connections
> please?
> >>
> >> Kind regards,
> >> Lukasz
> >>
> >> On Tue, Mar 20, 2018 at 1:11 AM, aditi hilbert <ad...@runtime.io>
> wrote:
> >>
> >>> Hi all,
> >>>
> >>> We have been adding a lot of features and functionality in Apache
> Mynewt
> >>> recently. Sample apps make it easy to see how to use them; so adding
> some
> >>> sample apps would be much appreciated. Here's an initial list of sample
> >>> apps that we could add. Please respond if you wish to contribute one
> or add
> >>> to the list. And I think we should add a README.md for every app in the
> >>> repo.
> >>>
> >>> * PWM - control LED brightness
> >>> * ADC, UART - read voltage on ADC, print value to UART
> >>> * ADC, I2C - read out an ADC over I2C
> >>> * Expose a resource by enabling a CoAP server
> >>> * CoAP, LoRa - enable CoAP client on one LoRa node, CoAP server on
> >>> another, retrieve a resource value
> >>> * Cycle through available power states (deep sleep, low power etc.)
> >>> * Sensor - change sampling rate
> >>> * Sensor - read multiple I2C sensors simultaneously
> >>> * Sensor - trigger a notification when a threshold is crossed
> >>> * Logging, Sensor - enable FCB to log timestamped sensor data
> >>> * MMC, SPI, stats - write system stats to the card, read back
> >>> * testutil - adding a test for a package in sim using the testutil
> >>> framework
> >>> * sensor, testutil - how to add a test for a sensor HW using the
> testutil
> >>> framework
> >>>
> >>> thanks,
> >>> Aditi
> >
>

Re: Sample apps in mynewt-core

Posted by Łukasz Rymanowski <lu...@codecoup.pl>.
Hi Łukasz,

If your application supports pairing (like btshell for example), you
will get Secure Connections  by setting MYNEWT_VAL BLE_SM_SC to 1.
It is stack who handles it for you then.

Hope that helps.

Best regards
Łukasz

On 20 March 2018 at 19:11, aditi hilbert <ad...@runtime.io> wrote:
> Lukasz,
>
> Yes - great addition!
>
> thanks,
> aditi
>
>> On Mar 20, 2018, at 8:16 AM, Lukasz Wolnik <lu...@gmail.com> wrote:
>>
>> Hi Aditi,
>>
>> Could we also add a sample app that uses NimBLE's Secure Connections please?
>>
>> Kind regards,
>> Lukasz
>>
>> On Tue, Mar 20, 2018 at 1:11 AM, aditi hilbert <ad...@runtime.io> wrote:
>>
>>> Hi all,
>>>
>>> We have been adding a lot of features and functionality in Apache Mynewt
>>> recently. Sample apps make it easy to see how to use them; so adding some
>>> sample apps would be much appreciated. Here's an initial list of sample
>>> apps that we could add. Please respond if you wish to contribute one or add
>>> to the list. And I think we should add a README.md for every app in the
>>> repo.
>>>
>>> * PWM - control LED brightness
>>> * ADC, UART - read voltage on ADC, print value to UART
>>> * ADC, I2C - read out an ADC over I2C
>>> * Expose a resource by enabling a CoAP server
>>> * CoAP, LoRa - enable CoAP client on one LoRa node, CoAP server on
>>> another, retrieve a resource value
>>> * Cycle through available power states (deep sleep, low power etc.)
>>> * Sensor - change sampling rate
>>> * Sensor - read multiple I2C sensors simultaneously
>>> * Sensor - trigger a notification when a threshold is crossed
>>> * Logging, Sensor - enable FCB to log timestamped sensor data
>>> * MMC, SPI, stats - write system stats to the card, read back
>>> * testutil - adding a test for a package in sim using the testutil
>>> framework
>>> * sensor, testutil - how to add a test for a sensor HW using the testutil
>>> framework
>>>
>>> thanks,
>>> Aditi
>

Re: Sample apps in mynewt-core

Posted by aditi hilbert <ad...@runtime.io>.
Lukasz,

Yes - great addition!

thanks,
aditi

> On Mar 20, 2018, at 8:16 AM, Lukasz Wolnik <lu...@gmail.com> wrote:
> 
> Hi Aditi,
> 
> Could we also add a sample app that uses NimBLE's Secure Connections please?
> 
> Kind regards,
> Lukasz
> 
> On Tue, Mar 20, 2018 at 1:11 AM, aditi hilbert <ad...@runtime.io> wrote:
> 
>> Hi all,
>> 
>> We have been adding a lot of features and functionality in Apache Mynewt
>> recently. Sample apps make it easy to see how to use them; so adding some
>> sample apps would be much appreciated. Here's an initial list of sample
>> apps that we could add. Please respond if you wish to contribute one or add
>> to the list. And I think we should add a README.md for every app in the
>> repo.
>> 
>> * PWM - control LED brightness
>> * ADC, UART - read voltage on ADC, print value to UART
>> * ADC, I2C - read out an ADC over I2C
>> * Expose a resource by enabling a CoAP server
>> * CoAP, LoRa - enable CoAP client on one LoRa node, CoAP server on
>> another, retrieve a resource value
>> * Cycle through available power states (deep sleep, low power etc.)
>> * Sensor - change sampling rate
>> * Sensor - read multiple I2C sensors simultaneously
>> * Sensor - trigger a notification when a threshold is crossed
>> * Logging, Sensor - enable FCB to log timestamped sensor data
>> * MMC, SPI, stats - write system stats to the card, read back
>> * testutil - adding a test for a package in sim using the testutil
>> framework
>> * sensor, testutil - how to add a test for a sensor HW using the testutil
>> framework
>> 
>> thanks,
>> Aditi


Re: Sample apps in mynewt-core

Posted by Lukasz Wolnik <lu...@gmail.com>.
Hi Aditi,

Could we also add a sample app that uses NimBLE's Secure Connections please?

Kind regards,
Lukasz

On Tue, Mar 20, 2018 at 1:11 AM, aditi hilbert <ad...@runtime.io> wrote:

> Hi all,
>
> We have been adding a lot of features and functionality in Apache Mynewt
> recently. Sample apps make it easy to see how to use them; so adding some
> sample apps would be much appreciated. Here's an initial list of sample
> apps that we could add. Please respond if you wish to contribute one or add
> to the list. And I think we should add a README.md for every app in the
> repo.
>
> * PWM - control LED brightness
> * ADC, UART - read voltage on ADC, print value to UART
> * ADC, I2C - read out an ADC over I2C
> * Expose a resource by enabling a CoAP server
> * CoAP, LoRa - enable CoAP client on one LoRa node, CoAP server on
> another, retrieve a resource value
> * Cycle through available power states (deep sleep, low power etc.)
> * Sensor - change sampling rate
> * Sensor - read multiple I2C sensors simultaneously
> * Sensor - trigger a notification when a threshold is crossed
> * Logging, Sensor - enable FCB to log timestamped sensor data
> * MMC, SPI, stats - write system stats to the card, read back
> * testutil - adding a test for a package in sim using the testutil
> framework
> * sensor, testutil - how to add a test for a sensor HW using the testutil
> framework
>
> thanks,
> Aditi

Re: Sample apps in mynewt-core

Posted by Oscar Carrillo <os...@gmail.com>.
Hi,

I'd like to suggest a sample app that turns off everything that is
consuming power to get to the best-case scenario of achieving low-power.
For example, GPIO pins, timers, etc.

Of course this is MCU-specific. My preference is to see this for the nrf52.
I think most things can be done as a config or programatically, so an
example of both would be great.

Thanks,
Oscar

On Wed, Mar 21, 2018 at 3:22 AM, Wayne Keenan <wa...@gmail.com>
wrote:

> Hi Aditi,
>
> I'm guessing what's below is already there but spread out over a number of
> existing apps and in the docs, and maybe even exist already, but my first
> thoughts are...
>
> Perhaps add standalone (pure OS) examples that demonstrate basic, and more
> advanced, uses of multiple tasks and message passing (with and (maybe)
> without queuing) between tasks, e.g. MyNewt RTOS building blocks.
>
> Perhaps also include RTOS task examples that demonstrate best practice
> handling of Nimble and other IRQ context switches (e.g. GPIO IRQ).
>
> Apologies if such things already do exist, I've not kept on top of MyNewt
> things.
>
> Thanks,
> Wayne
>
> On 20 March 2018 at 01:11, aditi hilbert <ad...@runtime.io> wrote:
>
> > Hi all,
> >
> > We have been adding a lot of features and functionality in Apache Mynewt
> > recently. Sample apps make it easy to see how to use them; so adding some
> > sample apps would be much appreciated. Here's an initial list of sample
> > apps that we could add. Please respond if you wish to contribute one or
> add
> > to the list. And I think we should add a README.md for every app in the
> > repo.
> >
> > * PWM - control LED brightness
> > * ADC, UART - read voltage on ADC, print value to UART
> > * ADC, I2C - read out an ADC over I2C
> > * Expose a resource by enabling a CoAP server
> > * CoAP, LoRa - enable CoAP client on one LoRa node, CoAP server on
> > another, retrieve a resource value
> > * Cycle through available power states (deep sleep, low power etc.)
> > * Sensor - change sampling rate
> > * Sensor - read multiple I2C sensors simultaneously
> > * Sensor - trigger a notification when a threshold is crossed
> > * Logging, Sensor - enable FCB to log timestamped sensor data
> > * MMC, SPI, stats - write system stats to the card, read back
> > * testutil - adding a test for a package in sim using the testutil
> > framework
> > * sensor, testutil - how to add a test for a sensor HW using the testutil
> > framework
> >
> > thanks,
> > Aditi
>

Re: Sample apps in mynewt-core

Posted by Wayne Keenan <wa...@gmail.com>.
Hi Aditi,

I'm guessing what's below is already there but spread out over a number of
existing apps and in the docs, and maybe even exist already, but my first
thoughts are...

Perhaps add standalone (pure OS) examples that demonstrate basic, and more
advanced, uses of multiple tasks and message passing (with and (maybe)
without queuing) between tasks, e.g. MyNewt RTOS building blocks.

Perhaps also include RTOS task examples that demonstrate best practice
handling of Nimble and other IRQ context switches (e.g. GPIO IRQ).

Apologies if such things already do exist, I've not kept on top of MyNewt
things.

Thanks,
Wayne

On 20 March 2018 at 01:11, aditi hilbert <ad...@runtime.io> wrote:

> Hi all,
>
> We have been adding a lot of features and functionality in Apache Mynewt
> recently. Sample apps make it easy to see how to use them; so adding some
> sample apps would be much appreciated. Here's an initial list of sample
> apps that we could add. Please respond if you wish to contribute one or add
> to the list. And I think we should add a README.md for every app in the
> repo.
>
> * PWM - control LED brightness
> * ADC, UART - read voltage on ADC, print value to UART
> * ADC, I2C - read out an ADC over I2C
> * Expose a resource by enabling a CoAP server
> * CoAP, LoRa - enable CoAP client on one LoRa node, CoAP server on
> another, retrieve a resource value
> * Cycle through available power states (deep sleep, low power etc.)
> * Sensor - change sampling rate
> * Sensor - read multiple I2C sensors simultaneously
> * Sensor - trigger a notification when a threshold is crossed
> * Logging, Sensor - enable FCB to log timestamped sensor data
> * MMC, SPI, stats - write system stats to the card, read back
> * testutil - adding a test for a package in sim using the testutil
> framework
> * sensor, testutil - how to add a test for a sensor HW using the testutil
> framework
>
> thanks,
> Aditi