First of all take a look at the GitHub of this project for pinouts and other information. I spent sometime figuring out the connection and testpads on the circuit board, fortunately Amazon has all the important signals broken out, including SWD signals for the microcontroller and JTAG for the wireless module. So it's very easy to hook up your favourite programmer and upload your own program into it. I used the ST-Link v2 on a discovery board to upload a blink program to the Dash Button:
Discussions
Become a Hackaday.io Member
Create an account to leave a comment. Already have an account? Log In.
Have you figured out how to execute code when the button is pressed ? I am using the Wiced SDK with ST-LINK. I have the blink example working and some of the others. I want to detect the button press and utilize the power management already seemingly present in the dash button. I have tried this but to no avail :
static void irq_handler_l( void *arg );
void application_start(void)
{
wiced_init();
wiced_gpio_output_low( WICED_LED3 );
wiced_gpio_input_irq_enable(WICED_BUTTON1, IRQ_TRIGGER_LEVEL_HIGH, irq_handler_l, 0);
}
void irq_handler_l (void *arg)
{
wiced_gpio_output_low( WICED_LED2 );
wiced_rtos_delay_milliseconds(5000);
wiced_gpio_output_high( WICED_LED2 );
}
Is there a button handler I should be looking at ? I applied the patch located at https://github.com/maximus64/amazon-dash-wiced and also read somewhere that the button press could be only detected to a battery and not the ST-LINK's 3.3v. So I tried to hook it up to a AAA battery but that still didn't work ... Any ideas would be greatly appreciated.
Are you sure? yes | no