Developing a universal module

More
05 Mar 2014 16:48 #21259 by victzh
Replied by victzh on topic Developing a universal module

PhracturedBlue wrote: I haven't looked at Midelic's code, but every Arduino solution I've seen (which uses our protocol code) has ended up significantly modifying it to run on Arduino. I don't understand why to be honest, as it means more work for everyone because bug fixes can't easily move between projects.


My reason is simpler and probably less excuse - historical. I wrote a small TX code handling sticks and radio for V202 protocol and THEN ported it to Deviation. Later I modified at least some parts of my code to make such ports easier - the stick range is -10000..10000 as it is in Deviation, but that's probably it. Arduino is C++ basic and I followed it in using nRF library (which is C++ class) and it would require to recode it as C pseudo-class. It's less convenient, so I did not went this way the first time.

I probably should take a look again and bring my Arduino code to Deviation as close as possible to facilitate the development (at least my own), but I never expected it to be useful more than one time (now it is 4th time I use this code and port every time to Devo :-( ).

Please Log in or Create an account to join the conversation.

More
07 Mar 2014 21:01 #21358 by blackmoon
Replied by blackmoon on topic Developing a universal module
PB you wrote this in the Frsky compatibility thread :

If you want to use telemetry, you should wire:
PA_EN to GDO0
LNA_EN to GDO2


Does the module's 1.2rev have those pins wired like that ?

Thank you.

Please Log in or Create an account to join the conversation.

More
07 Mar 2014 21:55 #21361 by PhracturedBlue
Replied by PhracturedBlue on topic Developing a universal module
yes. The board is pre-wired with the proper connections

Please Log in or Create an account to join the conversation.

More
07 Mar 2014 22:08 #21362 by PhracturedBlue
Replied by PhracturedBlue on topic Developing a universal module

midelic wrote: I was thinking long time about a multi protocol project...I wanted to make one ..happy I found this one...a little late...if I was here from the beginning...maybe I could suggest some changes .
For example power supply to each module.IMO it was better not be common but separate connected to a different pin of and avr(more powerful) by means of a transistor controllable the power on/off from software.(for example a command from avr open the gate of a transistor enabling powering the specific module).
Atm all modules are powered on/off at the same time ..which is not good imo.

There will be more iterations of the board in the future (like the 1.3 board I've already designed and am waiting for delivery of). If there are specific design enhancements, feel free to raise them.

As for your suggestion about controlling the power supply, the power consumption of these modules when in sleep mode is actually quite low. certainly low enough that it won't significantly affect battery longevity, so there is no need to power down a module from my perspective. The goal of this projects was to make it as easy to build as possible. I did that by using a single chip to do all functions. no extra resistors or transistors. Since I expect user to build this themselves, a primary design goal was to make it as simple as possible, and I don't think it can get much simpler than what I now have.

As for this:

yes it 's true any porting from your code in arduino ends up changed...
One reason because of control.... I need to "feel" I can control the project in all aspects...
Second I use different pinout and bitbanging...free the avr programming pins for more flexibility , integration and compatibility with other systems.

If you reuse any of my code, I expect you to abide by my license and make the source freely available. Other than that, you are welcome to do what you like, but you will find maintainability to be much more challenging if you change the protocol stack. I'm not sure why bit-banging an interface is relevant. The SPI level code is in a different layer than the protocol layer. I'm using bit-banging for the X9D and it doesn't require any protocol change. I've also used the same stack on a non-interrupt driven system, so the protocol stack really has very few requirements. But I'm not going to convince you, and I'm not going try any harder than that.

Please Log in or Create an account to join the conversation.

More
07 Mar 2014 23:27 - 07 Mar 2014 23:47 #21366 by midelic
Replied by midelic on topic Developing a universal module
Thanks for...restating the invitation of using your code freely.
You are right posting code is easy.....maintaing it and keeping up to date..is other game.
My intention is as soon as I received the PA/LNA cc2500 and test it sucesfully to open another thread on RCG....DIY Any TX/RX(RF) module ..something like that(for the moment FlySKy ,Hubsan,FRSKy_1/2 .......also RX except Hubsan....aso).....now that I have your permission explicitly...I'll use your code.
Thanks again!

About multi protocol module maybe consider using an Atmel chip with more pins.If using with a multi switch is good for protocol selection.
Last edit: 07 Mar 2014 23:47 by midelic.

Please Log in or Create an account to join the conversation.

More
08 Mar 2014 00:23 #21368 by PhracturedBlue
Replied by PhracturedBlue on topic Developing a universal module
GPL3 is GPL3. You don't need my permission as long as your code is freely available and licensed under the GPL3 as well.

As far a using more pins, We are already tasking the AVR at 8MHz to keep up. I don't think the one on the universal module can do anything else. The controller board (with all the protocol code) could easily have such a selection control though. The only reason I can think of that I'd need more than 14 pins is if I want to support more than 4 modules (actually probably more than 5, as we could squeeze one more in on the current ATTiny chip)

Please Log in or Create an account to join the conversation.

More
09 Mar 2014 20:12 #21400 by nusbr
Replied by nusbr on topic Developing a universal module
I habe ordernd PCB at oshpark.com. PCB is arrived friday. Now i want solder it and Mount in my Devo 8S. Could you please help me to connect them to Devo 8S?

I have a question about PCB connector P1.
I dont know where i can connect in the transmitter.
P1 Pinout
1: +5V
2: +3.3V
3: /Reset
4: Mosi
5: Miso
6: Sck
7: GND
8: chip select

How i can program Atmel in Transmitter?

Thanks and best regards

Bruno

Please Log in or Create an account to join the conversation.

More
09 Mar 2014 21:25 - 09 Mar 2014 21:29 #21401 by PhracturedBlue
Replied by PhracturedBlue on topic Developing a universal module
I'm working on updating the Module installation instructions

You will need to connect TMS to the NCS pin, and TCK to the /RESET pin. You do not need to connect the 5V pin.

You'll program it by:
installing the included dfu file
copying the included hex file to your Tx (assume you already use Deviation and have formatted the flash drive) as 'avr.hex'
turn on the tx, and the screen should indicate that it is programming. If it fails, try turning the Tx off and then back on, it can take a few cycles to properly enter programming mode.

Now you can install a nightly build of Deviation and start testing the board.

You need your hardware.ini to look like:
  enable-switch=A13
  enable-cyrf6936=B12
  has_pa-cyrf6936=1
  enable-a7105=S1
  has_pa-a7105=1
  enable-cc2500=S3
  has_pa-cc2500=1
  enable-nrf24l01=S402
  has_pa-nrf24l01=1
(comment out any modules you don't have installed)

Note the pin order of the module (with the AVR facing skyward and 'P1' horizontal):
7 5 3 1
8 6 4 2
  P1
Attachments:
Last edit: 09 Mar 2014 21:29 by PhracturedBlue.

Please Log in or Create an account to join the conversation.

More
10 Mar 2014 07:05 #21414 by nusbr
Replied by nusbr on topic Developing a universal module
Thank you very much for help me :)
So i will solder them and Test it with the Hubsan X4. This is really a great project from you. Thanks for all

Please Log in or Create an account to join the conversation.

More
10 Mar 2014 16:34 #21423 by PhracturedBlue
Replied by PhracturedBlue on topic Developing a universal module
FYI, I've started porting the Module install documentation into the Wiki

So far I've only done the connectivity table, But I took a page from Daryoon's approach and color-coded everything to make it easier to understand. I also included higher res images than are in the pdf:
bitbucket.org/PhracturedBlue/deviation/wiki/ModuleList

Note: These instructions are currently targeted for the Deviation nightlies only and are not suitable for Deviation 4.0.1. the reason is that the PA/LNA are now directly controlled where available to improve battery life, but those connections aren't supported in 4.0.1. I am considering doing a 4.0.2 release that supports PA/LNA control and fixes some of the critical 4.0.1 bugs, since it doesn't appear that Deviation 4.1 is around the corner.

I will start porting the actual installation instructions in the near future

Please Log in or Create an account to join the conversation.

More
10 Mar 2014 17:44 #21427 by SeByDocKy
Replied by SeByDocKy on topic Developing a universal module

PhracturedBlue wrote: FYI, I've started porting the Module install documentation into the Wiki

So far I've only done the connectivity table, But I took a page from Daryoon's approach and color-coded everything to make it easier to understand. I also included higher res images than are in the pdf:
bitbucket.org/PhracturedBlue/deviation/wiki/ModuleList

Note: These instructions are currently targeted for the Deviation nightlies only and are not suitable for Deviation 4.0.1. the reason is that the PA/LNA are now directly controlled where available to improve battery life, but those connections aren't supported in 4.0.1. I am considering doing a 4.0.2 release that supports PA/LNA control and fixes some of the critical 4.0.1 bugs, since it doesn't appear that Deviation 4.1 is around the corner.

I will start porting the actual installation instructions in the near future


Great job :)

Please Log in or Create an account to join the conversation.

More
12 Mar 2014 12:56 #21496 by SeByDocKy
Replied by SeByDocKy on topic Developing a universal module
PB,

I started to order RFchips ( www.ebay.com/itm/181091377178 + www.aliexpress.com/item/CC2500-PA-LNA-wi...-2-4G/359941652.html + www.ebay.com/itm/400611170500 ), pins ( www.ebay.com/itm/10pcs-2mm-40-Pin-Male-S...-Strip-/370506212713 ), cable ( www.ebay.com/itm/4Pcs-IPEX-UFL-RP-SMA-Fe...wandbid=321278066123 ) according to your wiki.

I plan to install in on my futur devo10 (so no CYRF6939 requiered). Maybe later, will also do another version for my devo7E

Actually only the V1.2 is available on order. Is the V1.3 on the way ?

I would prefer to program the ATTy with my USBASP. I take the hex file provided in the threads ?

Please Log in or Create an account to join the conversation.

More
12 Mar 2014 13:29 #21499 by PhracturedBlue
Replied by PhracturedBlue on topic Developing a universal module
Looks like you got all the right stuff. You do not need the 1.3 board for that layout. The 1.3 board adds support for this:

www.ebay.com/itm/CC2500-PA-LNA-SI4432-NR...&hash=item19d726245b

The only benefit is that you don't need to bug any pin headers if you use it (but you lose the U.FL antenna

The Aliexpress module you bought will work fine.

I STILL don't have my v1.3 boards, so I haven't verified the connections and don't want to release the boards. I hope they'll come this week, they seem to be traveling around the US in a circuitous route :)

Please Log in or Create an account to join the conversation.

More
12 Mar 2014 13:44 #21500 by SeByDocKy
Replied by SeByDocKy on topic Developing a universal module

PhracturedBlue wrote: Looks like you got all the right stuff. You do not need the 1.3 board for that layout. The 1.3 board adds support for this:

www.ebay.com/itm/CC2500-PA-LNA-SI4432-NR...&hash=item19d726245b

The only benefit is that you don't need to bug any pin headers if you use it (but you lose the U.FL antenna

The Aliexpress module you bought will work fine.

I STILL don't have my v1.3 boards, so I haven't verified the connections and don't want to release the boards. I hope they'll come this week, they seem to be traveling around the US in a circuitous route :)


I got also this version of the CC2500 (didn't use yet)... Wich one would you advise ?. When FrSky protocol will be maybe available ? (I am not sure, but I believed your managed to hack it completly ?)

Please Log in or Create an account to join the conversation.

More
12 Mar 2014 16:10 #21502 by SeByDocKy
Replied by SeByDocKy on topic Developing a universal module
Ok I ordered the V1.2 .... Hope I didn't forget something ...

Now with all my differents orders (200 bucks spended today outch ...), I will have everything not bedore 3 weeks, I guess :)

Please Log in or Create an account to join the conversation.

More
12 Mar 2014 17:10 #21503 by PhracturedBlue
Replied by PhracturedBlue on topic Developing a universal module
Well, a few folks have ordered boards, but I don't think anyone but me has actually built one. We'll see how it goes when they start showing up. I just designed a v1.4 board which supports the BuyChina CYRF module. Ordered it from OshPark, so should get it next week most likely. I really wish i could find modules with 0.1" headers and U.FL antennas...these SMA antenna plugs are difficult to work with. I should try removing the SMA antenna and install a U.FL socket to see how hard that is.

Please Log in or Create an account to join the conversation.

More
12 Mar 2014 17:52 - 12 Mar 2014 18:05 #21504 by sbstnp
Replied by sbstnp on topic Developing a universal module
Ordered v1.2 5 minutes ago. Will mount AliExpress CC2500 and NRF24L01 uFl module.

Since I'll have 3 boards, if anyone in the EU wants the extra 2 I'll be happy to share (once I have them) at no extra cost but the $3/board plus shipping (which should be around $1 for letter inside EU).

Devo 10 + 4in1
Spektrum Dx9
FrSky Taranis + TBS Crossfire
Last edit: 12 Mar 2014 18:05 by sbstnp.

Please Log in or Create an account to join the conversation.

More
12 Mar 2014 18:44 #21505 by SeByDocKy
Replied by SeByDocKy on topic Developing a universal module

sbstnp wrote: Ordered v1.2 5 minutes ago. Will mount AliExpress CC2500 and NRF24L01 uFl module.

Since I'll have 3 boards, if anyone in the EU wants the extra 2 I'll be happy to share (once I have them) at no extra cost but the $3/board plus shipping (which should be around $1 for letter inside EU).


The same, I will have 1 available in EU (from FR). I will keep another one to eventually mod my devo 7E too

Please Log in or Create an account to join the conversation.

More
12 Mar 2014 20:49 #21511 by jo-loom
Replied by jo-loom on topic Developing a universal module
@sbstnp and @SeByDocKy

I will be glad to buy the non-needed PCBs from you.
If this will be possible and you are able to ship them to a German address please send me your bank details (or paypal account name) and the resulting total costs.
I will prepay - so there wont be any risk for you.

=> johannes.mueller (at) advantech-studios.com

Thanks a lot,
Johannes

Please Log in or Create an account to join the conversation.

More
13 Mar 2014 02:42 #21516 by PhracturedBlue
Replied by PhracturedBlue on topic Developing a universal module

SeByDocKy wrote: PB,
I would prefer to program the ATTy with my USBASP. I take the hex file provided in the threads ?

I forgot to answer this:
If you want to program with a USBASP (which is what I also use), it will work fine, but either program it before installing it, or alternatively after installing the ATTiny but before installing any modules. The USBASP will (I'm pretty sure) program at 5V, but most of the modules are not tolerant to that voltage. I have programmed mine with the USBASP with the modules installed, but I do not recommend it, as you may damage them.

Please Log in or Create an account to join the conversation.

Time to create page: 0.100 seconds
Powered by Kunena Forum