Beispiel #1
0
//--------------------------------------------------------------------------
// do_led --
//
static void
do_led (int argc, char *argv[])
{
    struct option_info opts[1];
    unsigned long mask;
    bool mask_set;

    init_opts (&opts[0], 'm', true, OPTION_ARG_TYPE_NUM,
               &mask, &mask_set, "mask");
    if (!scan_opts (argc, argv, 1, opts, 1, 0, 0, "")) {
        return;
    }
    if (!mask_set) {
        diag_printf ("led what <mask>?\n");
        return;
    }
    hal_lpc2xxx_set_leds (mask);
    return;
}
void
hal_diag_led(int mask)
{
    hal_lpc2xxx_set_leds(mask);
}