mbed library sources
Dependents: frdm_kl05z_gpio_test
Fork of mbed-src by
targets/hal/TARGET_NXP/TARGET_LPC176X/TARGET_UBLOX_C027/platform_init.c
- Committer:
- mbed_official
- Date:
- 2014-03-10
- Revision:
- 113:65a335a675de
- Parent:
- 83:5a6f638110fe
- Child:
- 114:826c6eb78fdc
File content as of revision 113:65a335a675de:
#include "gpio_api.h" #include "wait_api.h" // called before main void mbed_sdk_init() { gpio_t modemEn, modemRst, modemPwrOn, modemLvlOe, modemILvlOe, modemUsbDet; gpio_t gpsEn, gpsRst, led, modemRts; // start with modem disabled gpio_init_out_ex(&modemEn, MDMEN, PullNone, 0); gpio_init_out_ex(&modemRst, MDMRST, PullNone, 1); gpio_init_out_ex(&modemPwrOn, MDMPWRON, PullNone, 1); gpio_init_out_ex(&modemLvlOe, MDMLVLOE, PullNone, 1); gpio_init_out_ex(&modemILvlOe, MDMILVLOE, PullNone, 0); gpio_init_out_ex(&modemUsbDet, MDMUSBDET, PullNone, 0); gpio_init_out_ex(&modemRts, MDMRTS, PullNone, 0); // start with gps disabled gpio_init_out_ex(&gpsEn, GPSEN, PullNone, 0); gpio_init_out_ex(&gpsRst, GPSRST, PullNone, 1); // led should be off gpio_init_out_ex(&led, LED, PullNone, 0); wait_ms(50); // when USB cable is inserted the interface chip issues // multiple resets to the target CPU We wait here for a short period to // prevent those resets from propagating to the modem and other // components. }