This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/CC3100MOD: Need example on CC3100MOD SPI driver for Linux

Part Number: CC3100MOD

Tool/software: Linux

Dear Sir/Madam,

I am using CC3100MODR11MAMOBR in my design to interface to beaglebone black board. I am facing issue to get the CC3100MOD to work.

Below is the steps I use to bring up the module but I can't get response from the Module via SPI. Hope you can advise me which part gone wrong.

-> By the way, on my hardware connection, since I am not using hibernate function I had pull it up to 3.3V, is this ok?

1. I had downloaded the SDK from http://www.ti.com/tool/cc3100sdk

2. Download from https://github.cm/rpricken/cc3100-linux. It mentioned it works with CC3100SDK-1.0.0-windows-installer.exe, so I downloaded the CC3100SDK-1.0.0 version.

3. Driver patch

IRT WIFI_Support _1.pdf

4. SDK Modify Makefile and Build

vi cc3100-spi-kernelmodul/Makefile

CROSS_COMPILE=arm-linux-

KERNEL_SRC=/work/a/BBB_Echo_4.1/version2/linux-4.4.16-ti-rt-r38

ARCH ?= arm

EXTRA_CFLAGS := -Wall

vi cc3100-spi-kernelmodul/Makefile

CROSS_COMPILE=arm-linux-

CC=$(CROSS_COMPILE)gcc

INCLUDES = -I./examples/common \

   -I./simplelink/include \

   -I./simplelink/source \

   -I./platform/linux \

    -I./cc3100-spi-kernelmodul \

Build ko:

make -C cc3100-spi-kernelmodul make: Entering directory `/work/a/BBB_Echo_4.1/version2/wifi2/sdk/cc3100-sdk/cc3100-spi

                                                                                      

       -kernelmodul' make ARCH=arm CROSS_COMPILE=arm-linux- -C /work/a/BBB_Echo_4.1/version2/linux-4.

4.16-ti                                                                                  

             -rt-r38 SUBDIRS=`pwd` modules make[1]: Entering directory `/work/a/BBB_Echo_4.1/version2/linux-4.4.16-ti-rt-r38'

CC [M]   /work/a/BBB_Echo_4.1/version2/wifi2/sdk/cc3100-sdk/cc3100-spi-kernelmodul/cc3

                                                                                               100-spi.o

Building modules, stage 2.

MODPOST 1 modules

CC       /work/a/BBB_Echo_4.1/version2/wifi2/sdk/cc3100-sdk/cc3100-spi-kernelmodul/cc3

                                                                                                 100-spi.mod.o

LD [M]   /work/a/BBB_Echo_4.1/version2/wifi2/sdk/cc3100-sdk/cc3100-spi-kernelmodul/cc3

                                                                                      

         100-spi.ko make[1]: Leaving directory `/work/a/BBB_Echo_4.1/version2/linux-4.4.16-ti-rt-r38' make: Leaving directory `/work/a/BBB_Echo_4.1/version2/wifi2/sdk/cc3100-sdk/cc3100-spi-                                                                                                 kernelmodul'

Build app:

 

make

arm-linux-gcc -I./examples/common -I./simplelink/include -I./simplelink/source -I./platform/linu x -I./cc3100-spi-kernelmodul   -w -D _GNU_SOURCE -pthread simplelink/source/device.c sim plelink/source/driver.c simplelink/source/flowcont.c simplelink/source/fs.c simplelink/source/neta pp.c simplelink/source/netcfg.c simplelink/source/nonos.c simplelink/source/socket.c simplelink/ source/spawn.c simplelink/source/wlan.c platform/linux/user_functions.c examples/getting_starte d_with_wlan_ap/main.c -o wlanap

 

Target Image:

          cc3100-spi-kernelmodul/cc3100-spi.ko     

 wlanap

 5. Problem faced

It will hang up at:        

 

simplelink/source/device.c             if (NULL == pInitCallBack)

        {

                 OSI_RET_OK_CHECK(sl_SyncObjWait(&g_pCB->ObjPool[ObjIdx].SyncObj, SL_O

S_WAIT_FOREVER));

              /*release Pool Object*/

               _SlDrvReleasePoolObj(g_pCB->FunctionParams.AsyncExt.ActionIndex);                return _sl_GetStartResponseConvert(AsyncRsp.Status);

        }

 

Even I can skip it, but it will hang at sl_WlanSetMode() SPI operation, can't get response from WIFI chip.

Any expert can guide me what is wrong?

Is pull up nHIB is ok when hibernate function is not used?


Best regards,

Kpk