Good morning,

The difference between the bletiny program and the blinky program is that the 
bletiny program has an event queue defined and running, whereas the blinky 
program does not. Without a default event queue, there is no event queue 
available to handle shell commands. I suspect that the reason you are getting 
anythig at all is that you have local echo turned on in minicom, so you're 
simly seeing your text echoed back by minicom, not by mynewt. 

I guess I should add a short tutorial on adding the shell to blinky. In the 
meantime, you can work throiugh the 
http://mynewt.apache.org/latest/os/tutorials/tasks_lesson/ 
<http://mynewt.apache.org/latest/os/tutorials/tasks_lesson/> tutorial on how to 
add a task handler, or look in the bletiny source code for how the default task 
handler is instantiated. 

Best regards,
dg

> On Dec 19, 2016, at 3:50 AM, then yon <[email protected]> wrote:
> 
> Dear Support,
> 
> After successfully enabled the console and shell in bletiny project; i used 
> the same method with blinky project but the console only echo back the word i 
> typed without any other response. (LED blinking worked as it should)
> 
> I have attached output.png, main.c, pkg.yml and syscfg.yml. Changes made as 
> followed:
> 1. pkg.yml - added "@apache-mynewt-core/sys/console/full"
>                                 "@apache-mynewt-core/sys/shell"
>                                 "@apache-mynewt-core/sys/sysinit"
> 2. main.c - added  #include "console/console.h"
>                                #include "shell/shell.h"
>                                #include "syscfg/syscfg.h"
> 
>                                rc = console_init(NULL);
>                                assert(rc == 0);
> 3. syscfg.yml - Added
> #Package: apps/bletiny
> syscfg.vals:
>    # Enable the shell task.
>    SHELL_TASK: 1
> 
>    CONSOLE_TICKS: 1
>    CONSOLE_PROMPT: 1
> 
> Please let me know is there any important initializing step i missed out.
> 
> Thank you.
> 
> Regards,
> 
> Then Yoong Ze
> <pkg.yml><syscfg.yml><main.c>

--
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.


Reply via email to