Netduino home hardware projects downloads community

Jump to content


The Netduino forums have been replaced by new forums at community.wildernesslabs.co. This site has been preserved for archival purposes only and the ability to make new accounts or posts has been turned off.
Photo

Spark Core (TI CC3000) Porting for Super WiFI Mini?

CW2 Ziggurat29

  • Please log in to reply
256 replies to this topic

#61 Valkyrie-MT

Valkyrie-MT

    Advanced Member

  • Members
  • PipPipPip
  • 315 posts
  • LocationIndiana, USA

Posted 06 July 2013 - 04:42 PM

Anyway, I started working in Eagle yesterday but didn't get much farther than removing removing mosfets and moving some passives closer to each other. Naturally, you'll get to give your input when I get something to show. Oh and also, I removed the proto area.

 

I'd love to see pads for LEDs for the WifiEnable pin (labelled "enabled") and IRQ pin (labelled "activity").  



#62 Valkyrie-MT

Valkyrie-MT

    Advanced Member

  • Members
  • PipPipPip
  • 315 posts
  • LocationIndiana, USA

Posted 08 July 2013 - 04:14 AM

OK, I have made a staggering amount of progress.  I have constructed the beginnings of a managed library.  It still can't connect or open a socket, but it communicates quite readily with the CC3000 over spi.  I am about to start working on the call to get local access points...  If a lot of people have contributions, we'll have to move to codeplex to keep our sanity...  

 

I have been using the Stellaris Launchpad to sniff the messages and learn how it works.  That is working out quite well for me.  Anyway... The current solution is attached.  

 

I am posting it in it's current/incomplete state because I don't want people to duplicate work.  

 

All the code is Apache 2.0 licensed.  

Attached Files



#63 hanzibal

hanzibal

    Advanced Member

  • Members
  • PipPipPip
  • 1287 posts
  • LocationSweden

Posted 08 July 2013 - 05:26 AM

That is some great work there!

 

I saw your other post about LEDs and there will be plenty of time to change the design before manufacture.



#64 baxter

baxter

    Advanced Member

  • Members
  • PipPipPip
  • 415 posts

Posted 08 July 2013 - 07:24 AM

Hi Valkyrie-MT, You have indeed made outstanding progress. If you are using a Launchpad, I am assuming that you are using the CC3000 Boost module. If so, could you post your pin connections from the CC3000 module to Netduino. Also, with this code are you connecting to your regular network or just a separate network?

 var ap = new AccessPoint() { Ssid = "linksys", Password = "secret", Security = WifiSecurityType.WPA2 }; WifiAdapter.Connect(ap);

@hanzibal: If I might make a suggestion, try to stick with 1206 passives and at a minimum 0805. The Centerblack breakout boards that I ordered are using 0405 and even using my magnifying equipment I can hardly see the 0405.  



#65 hanzibal

hanzibal

    Advanced Member

  • Members
  • PipPipPip
  • 1287 posts
  • LocationSweden

Posted 08 July 2013 - 09:06 AM

Don't worry, I won't use anything smaller than 0805 or I can't solder by hand. I suppose the CC3000 will require re-flow but even so, placing will be done manually.



#66 ziggurat29

ziggurat29

    Advanced Member

  • Members
  • PipPipPip
  • 244 posts

Posted 08 July 2013 - 01:22 PM

Sweet Jesus!  That's great valkyrie; if you want, go ahead and put it on the codeplex; it probably would be messy to shuffle intermediate builds back and forth as forum attachments, and possibly confusing for someone who wants to download it.  I've not used the codeplex, but I imagine it is similar to all the other hosted scm, but with a dotnet focus.

I look forward to checking it out!

 

Hanzibal, I'd love to see your board layout when your ready to share (and if you're open to possibly annoying but respetful feedback).  Maybe even you could stick your eagles in a directory in the hypothetical hosted scm?



#67 hanzibal

hanzibal

    Advanced Member

  • Members
  • PipPipPip
  • 1287 posts
  • LocationSweden

Posted 08 July 2013 - 02:14 PM

Sure, you'll all be able to have you're saying about it and yes, I can put the Eagle files on CodePlex or elsewhere later on. Just so that you know though, in couple of days I'll be going away for a week and I'm pretty sure the design won't be ready until after I get back.



#68 ziggurat29

ziggurat29

    Advanced Member

  • Members
  • PipPipPip
  • 244 posts

Posted 08 July 2013 - 02:23 PM

we've got functioning dev boards and plenty of coding work to do.  Have fun on holiday (well, if it is holiday; 'good luck' if it's business)



#69 hanzibal

hanzibal

    Advanced Member

  • Members
  • PipPipPip
  • 1287 posts
  • LocationSweden

Posted 08 July 2013 - 11:06 PM

Thanks, it's a family holiday in the greek archipelago.

#70 Valkyrie-MT

Valkyrie-MT

    Advanced Member

  • Members
  • PipPipPip
  • 315 posts
  • LocationIndiana, USA

Posted 09 July 2013 - 12:11 AM

If you are using a Launchpad, I am assuming that you are using the CC3000 Boost module. If so, could you post your pin connections from the CC3000 module to Netduino. 

 

Actually, I am using a CC3000EM with the Netduino and the CC3000Boost with the Stellaris Launchpad.  Having said that, I can tell you how to connect the CC3000Boost to the Netduino, because I have it wired up for the Logic Analyzer.  This should work:  

 

Using the Netduino SPI1 Profile.  

 

SPI CLK == Netduino D13 => J9-Pin 7 on CC3000Boost => J4-Pin 12 on CC3000EM

SPI Data1 == Netduino D12 => J10-Pin 7 on CC3000Boost => J4-Pin 9 on CC3000EM

SPI Data2 == Netduino D11 => J10-Pin 6 on CC3000Boost => J4-Pin 11 on CC3000EM

SPI Chip Select == Netduino D4 => J10-Pin 3 on CC3000Boost => J4-Pin 8 on CC3000EM

Wifi Power Enable == Netduino D5 => J9-Pin 2  on CC3000Boost => J5-Pin 5 on CC3000EM

Interrupt == Netduino D6 => J10-Pin 2 on CC3000Boost => J4-Pin 10 on CC3000EM

 

For CC3000EM ONLY (Boost uses a dedicated Power adapter):

Ground => J4-Pin 7 and J5-Pin 10

3.3V DC Power (you may need an external supply because Netduino may not have enough current) => J5-Pin 8  

 

CC3000EM jumpers: J3 should always have a jumper.  J2 should always be user mode, jumper on 2-3

 

CC3000Boost jumpers: J2 should be 2-3, J13 should be 2-3, J15 should have a jumper

 

Update -- here is what my Netduino setup looks like:  

 

Posted Image



#71 hanzibal

hanzibal

    Advanced Member

  • Members
  • PipPipPip
  • 1287 posts
  • LocationSweden

Posted 09 July 2013 - 07:38 AM

Have you measured the actual power consumption of the the [color=rgb(40,40,40);font-family:helvetica, arial, sans-serif;]CC3000EM while it's fully running?[/color]

 

[color=rgb(40,40,40);font-family:helvetica, arial, sans-serif;]I blew my [/color][color=rgb(40,40,40);font-family:helvetica, arial, sans-serif;]CC3000EM[/color][color=rgb(40,40,40);font-family:helvetica, arial, sans-serif;] but a new [/color][color=rgb(40,40,40);font-family:helvetica, arial, sans-serif;]CC3000Boost arrived the other day  :)[/color]



#72 baxter

baxter

    Advanced Member

  • Members
  • PipPipPip
  • 415 posts

Posted 09 July 2013 - 08:22 AM

Hi Valkyrie-MT,

Many thanks ... that's a good reference list. I hooked the Boost module to a Netduino Plus 2. I entered my router SSID and  WPA2-AES key with Security = WifiSecurityType.WPA2 in,

 

[color=rgb(255,0,0);]var ap = new AccessPoint(){ ...}[/color]

 

but I get no response,

 

CC3000 Example Application
IRQ state = False
PowerUp enabled
Sending Command: 4000
Waiting for Response...

 

It freezes on this line,

 

[color=rgb(255,0,0);]InitWaiter.WaitOne();  // This makes the Constructor a blocking call while init completes[/color]

 

in,

 

[color=rgb(255,0,0);]internal CC3000Driver(Cpu.Pin intPin, Cpu.Pin csPin, Cpu.Pin enablePin, SPI.SPI_module spiMod)[/color]

 

I have the module powered from 3.3V on the Netduino (VBAT_IN). Maybe it's not getting enough power.



#73 Valkyrie-MT

Valkyrie-MT

    Advanced Member

  • Members
  • PipPipPip
  • 315 posts
  • LocationIndiana, USA

Posted 09 July 2013 - 03:19 PM

Hi Valkyrie-MT,

Many thanks ... that's a good reference list. I hooked the Boost module to a Netduino Plus 2. 

 

I am also using the NetduinoPlus 2.  Is that all the output from the output Window?  I'll post this evening what you should see.  But briefly, it should show a series of Sending command: xxxx, then a response received for each one.  Check your interrupt pin.  

 

Note: the network connect commands are not completed, I am struggling with those now.  If you or anyone else wants the latest version, just ask...  I do have a few new commands successfully implemented (setpolicy and wlan_disconnect).  



#74 Valkyrie-MT

Valkyrie-MT

    Advanced Member

  • Members
  • PipPipPip
  • 315 posts
  • LocationIndiana, USA

Posted 09 July 2013 - 03:21 PM

Have you measured the actual power consumption of the the [color=rgb(40,40,40);font-family:helvetica, arial, sans-serif;]CC3000EM while it's fully running? [/color] :)

 

That's a good idea...  I have a Kill-o-watt.  Maybe I can measure with that.  



#75 hanzibal

hanzibal

    Advanced Member

  • Members
  • PipPipPip
  • 1287 posts
  • LocationSweden

Posted 09 July 2013 - 06:02 PM

I was simply thinking of the current draw (but used the wrong term) and given it's 3V3, it should be practically the same thing.

#76 baxter

baxter

    Advanced Member

  • Members
  • PipPipPip
  • 415 posts

Posted 09 July 2013 - 08:38 PM

Well, I think I have somehow killed my CC3000 Boost. I have now tried 3 different platforms; a MSPG2553 launchpad, Netduino Plus2 and a Sparkfun Arduino Pro Micro (3.3V). For the pro Micro I am using the Arduino port. All fail with the initialization step. I think this has something to with updating the CC3000 firmware. I initially applied the patches recommended here,

http://processors.wi...Wi-Fi_Downloads

They were successful, but as stated nothing has worked relative to configuration. The MSP430 will take  some CC3000 commands and respond, but nothing relative to connecting to an access point.

 

I am beginning to think the most painless way to add wireless to the Netduino plus 1 and 2 is the Edimax Nano. It works flawlessly and consumes about the same power as the CC3000 and costs about $20 . For the Mini, the CC3000 appears to be the ideal solution. I am now starting to assemble the breakout boards I ordered and will not  apply any patches and perhaps one will work if I don't screw up the reflow process. For DIY reflowing, it would be helpful to extend to the CC3000 non-heatsink pads slightly so that when the solder paste liquifies it is observable.



#77 hanzibal

hanzibal

    Advanced Member

  • Members
  • PipPipPip
  • 1287 posts
  • LocationSweden

Posted 10 July 2013 - 01:02 AM

Sorry to hear that, is it possible to downgrade the module by installing factory firmware? I noted what you said about extending the cc3000 pads.

#78 Valkyrie-MT

Valkyrie-MT

    Advanced Member

  • Members
  • PipPipPip
  • 315 posts
  • LocationIndiana, USA

Posted 10 July 2013 - 04:05 AM

SUCCESS!  I connected to my Wifi network by ssid, got an IP by DHCP and was able to ping the CC3000!!!!

 

Posted Image

 

Here is the output from my console.  I annotated the events at the end:

 

CC3000 Example Application

IRQ state = True

PowerUp enabled

Sending Command: 4000

Waiting for Response...

New Event: OpCode: 4000

Handling Response for 4000

Response Received -- Simple Link Start Confirmed

Sending Command: 0008

Waiting for Response...

New Event: OpCode: 0008

Handling Response for 0008

Response Received -- Event Mask confirmed

Sending Command: 0207

Waiting for Response...

New Event: OpCode: 0207

Handling Response for 0207

SP Version is 0.6.1.7.2

Sending Command: 400B

Waiting for Response...

New Event: OpCode: 400B

Handling Response for 400B

Buffer Size is 115082496

The thread '<No Name>' (0x3) has exited with code 0 (0x0).

Sending Command: 0004

Waiting for Response...

New Event: OpCode: 0004

Handling Response for 0004

Sleeping for 8s

Sending Connect...!

Sending Command: 0001

Waiting for Response...

New Event: OpCode: 0001  <- [color=rgb(255,0,0);]WLAN Connect command accepted[/color]

Handling Response for 0001

New Event: OpCode: 8001  <- [color=rgb(255,0,0);]WLAN Connect Event (HCI_EVNT_WLAN_UNSOL_CONNECT)[/color]

Handling Response for 8001

New Event: OpCode: 8010  <- [color=rgb(255,0,0);]WLAN DHCP Event (HCI_EVNT_WLAN_UNSOL_DHCP)[/color]

Handling Response for 8010



#79 Valkyrie-MT

Valkyrie-MT

    Advanced Member

  • Members
  • PipPipPip
  • 315 posts
  • LocationIndiana, USA

Posted 10 July 2013 - 04:20 AM

Holy cow!  I just tried connecting with WPA2 security and it worked the first time.  The code got a bit messy while I tried to decipher the connect command, so I won't post the code tonight.  I have to go to bed.  But, the next thing after some cleanup will be UDP support!  :ph34r:



#80 hanzibal

hanzibal

    Advanced Member

  • Members
  • PipPipPip
  • 1287 posts
  • LocationSweden

Posted 10 July 2013 - 06:40 AM

Wow, that is just so cool, you are a wizard! That was using the managed driver, yes?




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

home    hardware    projects    downloads    community    where to buy    contact Copyright © 2016 Wilderness Labs Inc.  |  Legal   |   CC BY-SA
This webpage is licensed under a Creative Commons Attribution-ShareAlike License.