42 #include <ti/devices/DeviceFamily.h> 43 #include DeviceFamily_constructPath(driverlib/ioc.h) 44 #include DeviceFamily_constructPath(driverlib/cpu.h) 45 #include <ti/drivers/pin/PINCC26XX.h> 47 #include <ti/drivers/Board.h> 55 void CC1312R1_LAUNCHXL_sendExtFlashByte(PIN_Handle pinHandle, uint8_t byte)
60 PIN_setOutputValue(pinHandle, IOID_20, 0);
62 for (i = 0; i < 8; i++) {
63 PIN_setOutputValue(pinHandle, IOID_10, 0);
66 PIN_setOutputValue(pinHandle, IOID_9, (byte >> (7 - i)) & 0x01);
67 PIN_setOutputValue(pinHandle, IOID_10, 1);
77 PIN_setOutputValue(pinHandle, IOID_10, 0);
78 PIN_setOutputValue(pinHandle, IOID_20, 1);
92 PIN_Config extFlashPinTable[] = {
94 IOID_20 | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL |
95 PIN_INPUT_DIS | PIN_DRVSTR_MED,
98 PIN_State extFlashPinState;
99 PIN_Handle extFlashPinHandle = PIN_open(&extFlashPinState, extFlashPinTable);
107 PIN_setOutputValue(extFlashPinHandle, IOID_20, 0);
110 PIN_setOutputValue(extFlashPinHandle, IOID_20, 1);
114 PIN_close(extFlashPinHandle);
128 PIN_Config extFlashPinTable[] = {
130 IOID_20 | PIN_GPIO_OUTPUT_EN | PIN_GPIO_HIGH | PIN_PUSHPULL |
131 PIN_INPUT_DIS | PIN_DRVSTR_MED,
133 IOID_10 | PIN_GPIO_OUTPUT_EN | PIN_GPIO_LOW | PIN_PUSHPULL |
134 PIN_INPUT_DIS | PIN_DRVSTR_MED,
136 IOID_9 | PIN_GPIO_OUTPUT_EN | PIN_GPIO_LOW | PIN_PUSHPULL |
137 PIN_INPUT_DIS | PIN_DRVSTR_MED,
139 IOID_8 | PIN_INPUT_EN | PIN_PULLDOWN,
142 PIN_State extFlashPinState;
143 PIN_Handle extFlashPinHandle = PIN_open(&extFlashPinState, extFlashPinTable);
145 uint8_t extFlashShutdown = 0xB9;
147 CC1312R1_LAUNCHXL_sendExtFlashByte(extFlashPinHandle, extFlashShutdown);
149 PIN_close(extFlashPinHandle);
156 void Board_initHook()
void CC1312R1_LAUNCHXL_shutDownExtFlash(void)
Turn off the external flash on LaunchPads.
void CC1312R1_LAUNCHXL_wakeUpExtFlash(void)
Wake up the external flash present on the board files.