How to use those cheap Bluetooth modules with the Prop (and more)
Oldbitcollector (Jeff)
Posts: 8,091
I've been playing with those cheap Bluetooth modules (All kinds of them on Ebay under $15.00)
The catch with these is that they are cheap from China, but it takes some digging to get the documentation straight.
Hopefully, this project will save some folks some of the time and frustration I've gone through, as they are cheap, and easy to use serial devices which will provide good short range communication with the Propeller. To top it off, I've added an Introduction to Just Basic for creating a snazzy interface on the PC to control your Propeller projects.
Here's the link:
http://www.gadgetgangster.com/news/56-jeffs-shop/534-bluetooth-howto.html
The catch with these is that they are cheap from China, but it takes some digging to get the documentation straight.
Hopefully, this project will save some folks some of the time and frustration I've gone through, as they are cheap, and easy to use serial devices which will provide good short range communication with the Propeller. To top it off, I've added an Introduction to Just Basic for creating a snazzy interface on the PC to control your Propeller projects.
Here's the link:
http://www.gadgetgangster.com/news/56-jeffs-shop/534-bluetooth-howto.html
Comments
I have some notes on that here that I can dig out, but it wasn't really a big item for the article. Spent a lot of time figuring out how to get proper communication settings between the Propeller and the module. Hopefully, that will be remedied with this.
This does look like the lowest cost path to wireless (if your laptop or PC already has Bluetooth).
http://www.dealextreme.com/p/wireless-bluetooth-rs232-ttl-transceiver-module-80711
phishguy - nice find!
Beats wasting 3-4 cogs and a $1 Bluetooth although smaller.
Now we just need a similar priced wifi version
While wi-fi versions would be nice they would have to look like a serial port surely, much like the XPORT modules I use in other products.
Yes, would like the wifi to be serial too.
The ones with the connector are like the one you found, but soldered onto a slightly larger motherboard...
I reconfigured PropForth to output 9600 baud serial onto different I/O on a separate header I have on one of my pcbs which is basically 2 Prop I/Os and +5V and ground. So I plugged the BT module in and went back to Windows and paired via a COM port then I just use TeraTerm to communicate. Having Forth preloaded onto the Prop means that you only need this BT link to download new code etc. I can issue commands for my systems directly to the Forth console which makes it a very easy platform to develop on, and now, no wires!
BTW, BlueTerm from an Android tablet works beautifully too!
I didn't order any yet, but these are looking really cool.
Are these the same modules that I am using? Do you have a link for the ones that Sal is using?
The best price I can get for the 4-pin version is $6.80 in 50 off but I may end up using the SMD version on my own adaptor to suit my standard 8-pin PropPlug/Expansion header.
Here's a screenshot of the pcb artwork with the brown patch on the right side reserved for the BT's PCB antenna. The 5-pin connector on the left side is for SPI programming of the BT module via CSR's SDK while the 4x2 connector is what I want. The left hand side of this connector is PropPlug compatible if you flip the module upside down in which case I might allow for an extra LED to be mounted on the same side as the BT module to indicate state. The other 4 pins are usually I2C and VCC and a spare although in this version I have allowed for RTS/CTS if required, and if not then I don't loaded the resnet next to it.
It's a pity that Parallax standardized on a 4-pin programming connector but never allowed for power with a 5th pin. On some boards I just add an extra power pin in series with the four however this pin is usually 5V so I always have a good LDO regulator so that I can operate from 5 or 3.3V as in the case of this adapter.
So what do you think? Is there something I can add to this to help make it a bit more universal that more people can use?
If possible, I use 5V,GND,/RTS,SI,SO,OUT as a 1x6pin header where the middle 4 are propplug. You don't have room for the OUT pin, but if possible I would like the 5V to be added above the gnd piin on your 2x4 header. My propplug equiv has this 6pin header (its on tubulars smorgasboard) which can provide 5v from the USB. This would make your board compatible to this propplug connection. IIRC Bill uses 3v3 and gnd the I/Os as a standard also. Just need provision for a link to bypass the onboard regulator.
Which 3v3 regulator are you using. I use the MCP1700T-3V3 and use large pads to give a bit of heatsinking. The other day I found Element14 (local) have a sot23 regulator that will take up to ~15V input and 800mA and about the same price. I need to check its full specs but think this may be better than we are both using. I'll let you know offline.
Do you have soace perhaps for an ATTiny 44/84 SOIC16 on the underside? If so, it can be programmed by the prop (I have posted code).
If I use an ATTiny I would go for the QFN pack due to it's compactness. There doesn't seem to be any TSSOP packs readily available. My favorite is to use the Silabs chips even though they cost a little more, they are easy to ICP etc.
Yes, its a pity there is not TSSOP for the ATTiny's. The SOIC16 (ATtiny24/44/84) takes the same space as the SOIC8 (ATtiny25/45/85) and they are almost the same price, so pointless using them. I am still not into QFN packages yet.
OT I have a small pcb with QFNs for gyro, accelerometer, compass and pressure/temp. Could you do me a favour and reflow one for me???
Are you going to make these boards available assembled? If so, how much & how soon?
Jim
The Prop uses the center outside 4 pins when this module is flipped over otherwise the connector suits my 4x2 and 5x1 PropPlug pin-outs. So there is a VCC connection on either side of the 4-pinProp Plug to suit other formats such as Cluso's. The other two extra pins are for programming the on-board micro.
BTSER - Bluetooth Prop backplane module
Overall length including BT antenna is 1.3" x 0.56"
And yes, I will make these available soon as an assembled item, I just need to get some pcbs back and test them out. Should be good. Price is going to be a little bit more than what you would pay for the 4-pin ebay version but I will keep it cheaper than the PropPlug.
Jim
but you could make a file with a compiler and then send it directly to your prop? ill have to look at what the compilers that run on an android can do in terms of this.
just to clarify im not a fourh hater! i acually am building a calculator for programmers/hardware guys and i want to add bt com and sd. the reasoning is to make it fully wirelessly programmable with the intergrated 4th engine.
the problem at hand though is mostly abobout using a standard wirless protocol to program the prop with its native programming protocol. this makes programming with a phone a snap.
like i said above i belive the ebay chips have spi and rts which could be used as reset. then all the tools are in order to do bt programming from a phone. im willing to mail my bt key to someone to compare with an ebay key if they can find the rts pin on the ebay. this would entail running bt software on any platform that uses rts. monitoring the csr16 wave forms/logic/bus data. then running the same code on the ebay csr17 and trying to find matching wave forms. im sure there are other ways but thats my solution. i just dont have the tools or the know how to connect to the spots where i burned off the pads. im also not sure how to get my key doing spp when pluged into a pc
Here is a shot I took of it next to a footprint compatible PropPlug (my version). There's also a shot of it in place of the PropPlug inside of one of my DIN raill mount products so that this product can be accessed via a laptop or smartphone/tablet while it is in operation.
So the BTSER module looks like a PropPlug if you just use the 4 pins in the center on the edge.
Once I sort out the bootloader I will put these up for sale.
Is that an aluminium extrusion? What material do you use or endplates?
When I get all these modules and a website organized I will offer the PuppySolo and the PuppyProp preloaded with PropForth and a Bluetooth "puppyback" module, that way you just plug it in or connect power and start programming it, even with your smartphone.
Yes of course you can get hex files out of GCC.
GCC compiles source files to binary object modules, these are then linked to a binary program in ELF format.
There is a program supplied with GCC, objcopy, that can be used to extract the executable codes from an ELF file and write them out in hex.
The throughput looks really high but I should know a bit more once I test this in a controlled setup. I want to be able to initiate a connection from a module to another module but the firmware on these does not allow this as it is setup to work transparently, which is also a good thing. However I happened to have gotten hold of the SDK for the Bluetooth chip and I have the module's SPI programming pins connected to my bootloader micro so I should eventually be able to load in different firmware such as the HC05 instead of HC06 version. This means the module can work as a master.
I have also successfully set this parameter and the module name and pin straight from the Prop assuming the Bluetooth link is not active at the time.
What is the latest ?
Jim