Arduino Forum

Using Arduino => Networking, Protocols, and Devices => Topic started by: 1saac_k on Oct 28, 2016, 01:58 pm

Title: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: 1saac_k on Oct 28, 2016, 01:58 pm
I'd like to share some stuff about JDY-08 BLE module.

I made Fritzing part and translate datasheet using google translation and refine format.

- fritzing part -> refer attachment
- datasheet -> https://docs.google.com/document/d/14mHWT3GhELCj-6yxsam0k5bjzazq8nnPoz4B_gYh04k

If you ever heard about JDY-08, let me a summary about Bluetooth modules for Arduino.

I think HC-05 and HC-06 are the most popular Bluetooth module.
But these are Bluetooth 2.0 + EDR.

In BLE (Bluetooth Low Energy) domain, HM-10 is popular. And there are many clone models like AT-09.
These modules can be found at Aliexpress or any Chinese market.

These module using same Bluetooth LE chipset that is Ti CC2541.
And circuit is very similar. But, be careful about  the difference of firmware. AT command also different.
(Some alternatives of CC2541 are Nordic nRf51822, Dialog DA14580)

Another BLE module, HM-11 has small form factor. And maybe JDY-08 is clone of it.

So, the main pros of JDY-08 are the price. It's just $1.64 and really works.
When Aug. 13, the lowest price of JDY-08 was about $2.1 and after a month it dropped to $1.73 and now $1.64. And maybe will..?

The cons are,
- has no baseboard that logic level converter (3.3v<->5v)
- the pitch is smaller than 2.54 but can be soldering
- document hardly found



Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: BMWS1000RR on Nov 04, 2016, 07:35 pm
Thank you so much for providing all the details. I don't have bare ATTiny85 but do have the DigiSpark USB board as well as the Arduino UNO. Do you have any sample Arduino code for the same which I can use to test this module? To be specific, I want to Send/Receive small data from my Phone (Android/iOS) to this BLE module. So any code close to the same application would really be helpful!

A bit about me, I ordered HM-11 from China and the seller sent me something similar with CC2541 (after hours of hunt online, I realized it's JDY-08) and now after reading your post, I know a little bit more.

I am a starter in Arduino and wanted to work with BLE. After looking into all the online forums and all, I figured out CC2541/CC2650 are the modules extensively used for its low power and reliable performance.

Anyways, thanks again for sharing the details. It really helped me and I am sure would do the same for many others.

Waiting for your reply.

Thanks.
Vicky
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: 1saac_k on Dec 05, 2016, 02:58 pm
Writing in English is painful for me  :smiley-evil:
um.. (deep sigh)

I strongly doubt that there are some bugs in the official firmware of JDY-08 (version 2.1).
BLE connection and AT-command (serial using UART) works.
But serial pass-through using BLE does not works (serial Rx of JDY-08 is working but Tx does not work)
To be clear, If I connect between RasberryPi and JDY-08, I can send data to JDY-08. But I can't receive data.

Another problem is that pin code (passkey) configuration does not work. I set a password using AT+PASS and then set AT+ISCEN1 (authentication enable).
When I connect to JDY-08, there was no pop-up to input pin code but disconnected after a few seconds.

I googling very hard and found a datasheet for version 2.63. I didn't translate it but here is update log.
------
V2.6 version update:
The functionality of the module is exactly the same as the old version, and the update is only to accommodate more customer requirements
1: The number of feature UUIDs is reduced. Currently, only two feature UUIDs are reserved
2: Added IO disconnect function
3: updated password connection, the new version of the Bluetooth default password connection
4: changed the AT + HOSTEN0 only for the APP transparent transmission mode, WeChat function for the individual mode AT + HOSTEN4
-----
I think patch #2 and #4 are the culprits of my problems.
I can not found v2.63 firmware but found better firmware that is the official firmware of HM-10!

I updated google docs, please check 'Quick start' part. Then you can move to HM-10 v540. After that, you can update to v544 using the official tool of HM-10 (HMSoft).

Hey.. I just moved to v540 yesterday :)
(not updated to v544 yet)

What I tested,
- BLE connection is successful with default configuration
- AT-command is successful (uart serial)
- serial pass-through using BLE is OK
- system LED is OK

What I'm testing now,
- passkey (pin code) authentication
 (successful on LightBlue app, needs more test for linux gatt-tool)
- PIO in and out
 (tested on both AT-command and BLE. PIO2 PWM, PIO3 is OK. PIO 4~11 not work as HM-11 rather than HM-10. strange.. need more investigation)

It's interesting that JDY-08 and HM-11 have similar size but the pinout is more similar to HM-10. So updating to HM-10's firmware is better than HM-11's.
Here is a small gift, I made a pin-map cheat sheet for JDY-08 on HM-10 firmware.


Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: 1saac_k on Dec 06, 2016, 04:21 pm
experimental result.

- PIO in and out (successful)
 * PIO3~11 out, PIO3 PWM out
 * PIO5 ADC in, I tested using LDR(a.k.a CDS)

Tested on both AT-command and BLE on the v544 firmware.
I failed before because I set AT+MODE to 1. We need to set 0 or 2 to output PIO3~11.

- passkey (pin code) authentication
 * successful on LightBlue app
 * needs more test for Linux environment

The passkey problem could be subject of BlueZ rather than JDY-08.
I'm using BlueZ v5.43, (latest now, 12/7/2016)

I compared genuine HM-11 and firmed-up JDY-08.
Result is little bit different but both are fail.

I think 'gatttool' does not support passkey pairing.
'bluetoothctl' ask passkey after 'agent on' and 'default-agent' but fail to authentication.

Here is some log snippet of HM-11.
(I'll try to use HM-11 first)

<configuration>

AT+PASS?
>> OK+Get:001111
AT+TYPE?
>> OK+Get:3

<bluetoothctl log>

[bluetooth]# pair 5C:F8:21:8F:E1:BB
Attempting to pair with 5C:F8:21:8F:E1:BB
[CHG] Device 5C:F8:21:8F:E1:BB Connected: yes
Failed to pair: org.bluez.Error.AuthenticationFailed
[CHG] Device 5C:F8:21:8F:E1:BB Connected: no

################

[bluetooth]# agent on
Agent registered
[bluetooth]# default-agent
Default agent request successful
[bluetooth]# pair 5C:F8:21:8F:E1:BB
Attempting to pair with 5C:F8:21:8F:E1:BB
[CHG] Device 5C:F8:21:8F:E1:BB Connected: yes
Request passkey
[NEW] Primary Service
        /org/bluez/hci0/dev_5C_F8_21_8F_E1_BB/service000c
        00001801-0000-1000-8000-00805f9b34fb
        Generic Attribute Profile
[NEW] Characteristic
        /org/bluez/hci0/dev_5C_F8_21_8F_E1_BB/service000c/char000d
        00002a05-0000-1000-8000-00805f9b34fb
        Service Changed
[NEW] Descriptor
        /org/bluez/hci0/dev_5C_F8_21_8F_E1_BB/service000c/char000d/desc000f
        00002902-0000-1000-8000-00805f9b34fb
        Client Characteristic Configuration
[NEW] Primary Service
        /org/bluez/hci0/dev_5C_F8_21_8F_E1_BB/service0010
        0000ffe0-0000-1000-8000-00805f9b34fb
        Unknown
[NEW] Characteristic
        /org/bluez/hci0/dev_5C_F8_21_8F_E1_BB/service0010/char0011
        0000ffe1-0000-1000-8000-00805f9b34fb
        Unknown
[NEW] Descriptor
        /org/bluez/hci0/dev_5C_F8_21_8F_E1_BB/service0010/char0011/desc0013
        00002902-0000-1000-8000-00805f9b34fb
        Client Characteristic Configuration
[NEW] Descriptor
        /org/bluez/hci0/dev_5C_F8_21_8F_E1_BB/service0010/char0011/desc0014
        00002901-0000-1000-8000-00805f9b34fb
        Characteristic User Description
[CHG] Device 5C:F8:21:8F:E1:BB UUIDs: 00001800-0000-1000-8000-00805f9b34fb
[CHG] Device 5C:F8:21:8F:E1:BB UUIDs: 00001801-0000-1000-8000-00805f9b34fb
[CHG] Device 5C:F8:21:8F:E1:BB UUIDs: 0000ffe0-0000-1000-8000-00805f9b34fb
[CHG] Device 5C:F8:21:8F:E1:BB ServicesResolved: yes
[agent] Enter passkey (number in 0-999999): 001111      <-------------- asking...
Failed to pair: org.bluez.Error.AuthenticationFailed            <-------------- failed
[CHG] Device 5C:F8:21:8F:E1:BB ServicesResolved: no
[CHG] Device 5C:F8:21:8F:E1:BB Connected: no
[bluetooth]#


<btmon log>
# after enter passkey

< ACL Data... flags 0x00 dlen 21  [hci0] 5714.284480
      SMP: Pairing Confirm (0x03) len 16
        Confim value: 6541825c5b9a5f6381919483d89594b1
> HCI Event: Num.. (0x13) plen 5  [hci0] 5714.292082
        Num handles: 1
        Handle: 69
        Count: 1
> ACL Data... flags 0x02 dlen 21  [hci0] 5714.331585
      SMP: Pairing Confirm (0x03) len 16
        Confim value: ab17c3c10789bfa67236f580dc62e56a
< ACL Data... flags 0x00 dlen 21  [hci0] 5714.331867
      SMP: Pairing Random (0x04) len 16
        Random value: 8c8ec790640b3b5e8ca7bc9d2220de92
> HCI Event: Num.. (0x13) plen 5  [hci0] 5714.372072
        Num handles: 1
        Handle: 69
        Count: 1
> ACL Data R.. flags 0x02 dlen 6  [hci0] 5714.411724
      SMP: Pairing Failed (0x05) len 1
        Reason: Confirm value failed (0x04)
< HCI Com..nd (0x01|0x0006) plen 3  [hci0] 5714.412026
        Handle: 69
        Reason: Authentication Failure (0x05)
@ Authentication Failed: 5C:F8:21:8F:E1:BB (1) status 0x05
> HCI Event: Com.. (0x0f) plen 4  [hci0] 5714.416117
      Disconnect (0x01|0x0006) ncmd 1
        Status: Success (0x00)
> HCI Event: Dis.. (0x05) plen 4  [hci0] 5714.492088
        Status: Success (0x00)
        Handle: 69
        Reason: Connection Terminated By Local Host (0x16)
@ Device Disconnected: 5C:F8:21:8F:E1:BB (1) reason 2

##############
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: 1saac_k on Dec 07, 2016, 01:49 pm
I success to passkey!

In short, don't use 'pair' command in 'bluetoothctl', use 'connect' directly.
I think 'pair' command is for ordinary Bluetooth only (not for LE).

<configuration>
AT+PASS?
>> OK+Get:123123
AT+TYPE?
>> OK+Get:3

<genuine HM-11 results>

[bluetooth]# agent on                                                    <----------------        
Agent is already registered                                                      
[bluetooth]# default-agent                                              <----------------        
Default agent request successful                                                
[bluetooth]# connect 5C:F8:21:8F:E1:BB                           <----------------                
Attempting to connect to 5C:F8:21:8F:E1:BB                                      
[CHG] Device 5C:F8:21:8F:E1:BB Connected: yes                                    
Connection successful                                                            
Request passkey                                                                  
[NEW] Primary Service                                                            
       /org/bluez/hci0/dev_5C_F8_21_8F_E1_BB/service000c                        
       00001801-0000-1000-8000-00805f9b34fb                                    
       Generic Attribute Profile                                                
....skip....                                      
[NEW] Descriptor                                                                
       /org/bluez/hci0/dev_5C_F8_21_8F_E1_BB/service0010/char0011/desc0014      
       00002901-0000-1000-8000-00805f9b34fb                                    
       Characteristic User Description                                          
[CHG] Device 5C:F8:21:8F:E1:BB UUIDs: 00001800-0000-1000-8000-00805f9b34fb      
[CHG] Device 5C:F8:21:8F:E1:BB UUIDs: 00001801-0000-1000-8000-00805f9b34fb      
[CHG] Device 5C:F8:21:8F:E1:BB UUIDs: 0000ffe0-0000-1000-8000-00805f9b34fb      
[CHG] Device 5C:F8:21:8F:E1:BB ServicesResolved: yes                            
3agent] Enter passkey (number in 0-999999): 12312                        <-------------
[CHG] Device 5C:F8:21:8F:E1:BB Paired: yes                                  <-------------
[DEL] Device 00:15:83:00:73:9C BT05                                          
[DEL] Device 00:15:83:00:6E:F7 BT05                                              
[DEL] Device 00:19:86:00:00:38 WIN-KAMUIA0O9GF                                  
[HMSoft]#                                                                        



<results of JDY-08 on HM-10 firmware>
(already set 'agent on' and 'default-agent')

[bluetooth]# scan on                                                               <----------
Discovery started                                                                  
[CHG] Controller 00:1A:7D:DA:71:0A Discovering: yes                                
[CHG] Device 00:15:83:00:5B:44 RSSI: -77                                          
[CHG] Device 00:15:83:00:43:88 RSSI: -72                                          
[CHG] Device 00:15:83:00:6E:F7 RSSI: -67                                          
[NEW] Device 88:4A:EA:45:A7:B2 HMSoft                                              
[bluetooth]# scan off                                                                 <----------
[CHG] Device 00:15:83:00:73:9C RSSI: -75                                          
[CHG] Device 00:15:83:00:6E:F7 RSSI is nil                                        
[NEW] Device 00:19:86:00:00:38 WIN-KAMUIA0O9GF                                    
[CHG] Device 00:15:83:00:73:9C RSSI is nil                                        
[CHG] Device 88:4A:EA:45:A7:B2 TxPower is nil                                      
[CHG] Device 88:4A:EA:45:A7:B2 RSSI is nil                                        
[CHG] Device 00:15:83:00:43:88 RSSI is nil                                        
[CHG] Device 00:15:83:00:5B:44 RSSI is nil                                        
Discovery stopped                                                                  
[CHG] Controller 00:1A:7D:DA:71:0A Discovering: no                                
[bluetooth]# connect 88:4A:EA:45:A7:B2                                   <-----------      
Attempting to connect to 88:4A:EA:45:A7:B2                                    
[CHG] Device 88:4A:EA:45:A7:B2 Connected: yes                                  
Connection successful                                                          
Request passkey                                                                
[NEW] Primary Service                                                          
       /org/bluez/hci0/dev_88_4A_EA_45_A7_B2/service000c                      
       00001801-0000-1000-8000-00805f9b34fb                                  
       Generic Attribute Profile                                              
... skip ...                               
[NEW] Descriptor                                                              
       /org/bluez/hci0/dev_88_4A_EA_45_A7_B2/service0010/char0011/desc0014    
       00002901-0000-1000-8000-00805f9b34fb                                  
       Characteristic User Description                                        
[CHG] Device 88:4A:EA:45:A7:B2 UUIDs: 00001800-0000-1000-8000-00805f9b34fb    
[CHG] Device 88:4A:EA:45:A7:B2 UUIDs: 00001801-0000-1000-8000-00805f9b34fb    
[CHG] Device 88:4A:EA:45:A7:B2 UUIDs: 0000ffe0-0000-1000-8000-00805f9b34fb    
[CHG] Device 88:4A:EA:45:A7:B2 ServicesResolved: yes                          
3agent] Enter passkey (number in 0-999999): 12312                            <-----------  
[CHG] Device 88:4A:EA:45:A7:B2 Paired: yes                                     <-----------
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: jameschen0125 on Dec 29, 2016, 08:59 am
Very nice contribution !

Best Regards,
James
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: asd234 on Jan 08, 2017, 02:39 pm
Thanks,
it is very useful post.

Is can "JDY-08" module works with Bluetooth v2.0 or Bluetooth v1.2?

PS: I want use this module with Bluetooth v2.0 usb dongle(based on ht6630) or Android phone with Bluetooth v4.0 pair.
Not sure which module I should choose  "JDY-08 BLE Bluetooth v4.0 based on CC2541" or "SPP Bluetooth V2.1+EDR based on bk3231".
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: kutysam on Jan 29, 2017, 05:19 am
Now the price is $1.60USD haha
https://www.aliexpress.com/af/JDY%25252d08.html

Btw, just curious, you managed to flash it to hm10 firmware right?
Shouldn't it be a hm11 instead?

And in addition to this, after flashing, are you able to run AT+SLEEP ?

Thank you!
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: moisesmagno on Feb 02, 2017, 09:39 pm
After proceed with a firmware update on JDY-08 to the HM-10 official one (following 1saac_k guides) and a lot of time unsuccessfully spent trying to send AT commands to the module, I've figured out that the following must be done:

System KEY function (PIO0):
    Long press system KEY >=1000 ms.
    After wake up module, you can send and receive AT commands.

(ref. http://eezone.co.uk/blog/wireless/hm-10-cc2541-4-0-ble-bluetooth-to-uart-transceiver-module.html)

According to 1saac_k (again) after the firmware update the System KEY pin on the JDY-08 board is mapped as the pin 09.

That way to send AT commands to the module through UART interface, the pin 09 (or the PIO0 on the HM-10) must be pulled down (GND) for at least 1 second after the board power on and after every bluetooth connection established.

Best,
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: Luisk87 on Feb 17, 2017, 11:27 am
HI,  someone has the PINMAP of the JDY-10 Bluetooth LE Module, I need to locate the PIN RESET?
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: 1saac_k on Mar 17, 2017, 05:27 pm
Is can "JDY-08" module works with Bluetooth v2.0 or Bluetooth v1.2?

PS: I want use this module with Bluetooth v2.0 usb dongle(based on ht6630) or Android phone with Bluetooth v4.0 pair.
Not sure which module I should choose  "JDY-08 BLE Bluetooth v4.0 based on CC2541" or "SPP Bluetooth V2.1+EDR based on bk3231".
Bluetooth LE (4.0~) is not compatible Bluetooth legacy(~3.0).
But the most of Bluetooth LE Dongles (master) support Dual mode (support both 'LE' and legacy).
In this case, you can not use it with a USB dongle but android phone.
You could buy Bluetooth 2.1 module or upgrade the USB dongle.

======================



Btw, just curious, you managed to flash it to hm10 firmware right?
Shouldn't it be a hm11 instead?

And in addition to this, after flashing, are you able to run AT+SLEEP ?
Because HM-11 is smaller than HM-10, has less IO ports.
In this matter, we would be better to use HM-10 firmware than HM-11.
Anyway you can use HM-10 firmware but there is no benefit.

And.. I didn't test SLEEP.


===============================

After proceed with a firmware update on JDY-08 to the HM-10 official one (following 1saac_k guides) and a lot of time unsuccessfully spent trying to send AT commands to the module, I've figured out that the following must be done:

System KEY function (PIO0):
    Long press system KEY >=1000 ms.
    After wake up module, you can send and receive AT commands.
hmm... strange. I'm configuring without pulling down System Key.
I'll take a look at whenever this problem reproduced. Thanks :)


=====================================

HI,  someone has the PINMAP of the JDY-10 Bluetooth LE Module, I need to locate the PIN RESET?
JDY-'10'..? Did you mean JDY-08 with HM-10 firmware?
Refer an attachment "JDY-08 + HM-10 firmware.png" (third post)
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: alex_olvt on Mar 19, 2017, 08:35 am
I tryed to starp PWM from BLE function. Use this document https://docs.google.com/document/d/14mHWT3GhELCj-6yxsam0k5bjzazq8nnPoz4B_gYh04k/edit#

I just found UUIDs:

Service UUID found: 0000ffe0-0000-1000-8000-00805f9b34fb
Characteristic found: 0000ffe1-0000-1000-8000-00805f9b34fb
Characteristic found: 0000ffe2-0000-1000-8000-00805f9b34fb
Service UUID found: 00001800-0000-1000-8000-00805f9b34fb
Characteristic found: 00002a00-0000-1000-8000-00805f9b34fb
Characteristic found: 00002a01-0000-1000-8000-00805f9b34fb
Characteristic found: 00002a02-0000-1000-8000-00805f9b34fb
Characteristic found: 00002a03-0000-1000-8000-00805f9b34fb
Characteristic found: 00002a04-0000-1000-8000-00805f9b34fb
Service UUID found: 00001801-0000-1000-8000-00805f9b34fb
Characteristic found: 00002a05-0000-1000-8000-00805f9b34fb

but UUID ffe9 for PWM not found.

How to start it?
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: arturx on Jul 06, 2017, 11:28 am
Hi guys,

I've already bought JDY-8 and trying to figure out how to make it work with my project.
I wrote simple program that allows me to communicate with JDY-8 using serial in IDE.
That part works.
I can see also my bluetooth module both from Raspberry PI (hcitool lescan command) and my Android mobile.

But when I'm trying to connect to it, for example using Bluez or Python bluepy library, I'm getting strange errors, like "Host is down" etc.

Is here anyone who can provide me simple instruction or share your code, that allows to communicate with JDY-8 from remote linux system with BLE dongle?

What I want to achieve is just to set "0" or "1" to power off/on LED.

Thanks.
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: Luca12 on Jul 19, 2017, 01:19 pm
Hi 1saac_k, I have found this rar file while clicking link in chinese in the serial client, there is an updated datasheet that could help better understand this module.

https://pan.baidu.com/s/1pLEzyfp  (click the second button)

However, I have the jdy-08 with me now and the TX doesn't work like you said, is there a way to make it works or it only works with the hm-10 firmware?

Thank you
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: samuelbles on Jul 23, 2017, 10:51 am
hi, does anyone know about jdy-10 module? it's the same ic that use cc2541 from texas instrument. The only information about this module is datasheet (https://drive.google.com/open?id=0BzL2zZ8R3JAuek9nRTVCVmhmTEU) .

There's just a couple AT-command working from the datasheet you guys share. I aware that the firmware is different from jdy-08. when i send AT+VER through at command the return is +JDY-10-V1.8 . I already succeed to make it work to  send data using at-command mode to the android app that i download called beacon simulator (https://play.google.com/store/apps/details?id=net.alea.beaconsimulator&hl=en).

If someone have info about this module and willing to share with me thanks
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: androidfanboy on Oct 03, 2017, 06:38 am
I have this JDY-08/10 module and it doesn't work! I simply can't get it to respond to AT commands... I am using 115200 baud with 3.3V and with PWRC pin connected to GND. I spent the whole day trying to get it to work. Any ideas?
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: snoopy20 on Oct 30, 2017, 06:08 pm
They use different chipsets.

My JDY-08 says +ERR to every command I send. The JDY-10 mostly worked command wise (could save name etc) but I could not get it into "data" mode. Some say it's automatic once connected but mine wasn't.
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: androidfanboy on Oct 30, 2017, 06:12 pm
I thought they both use CC2541. Did you mean different "firmware"? Try the following:

- "AT+BOUD1" to set baud rate to 57600
- "mySerial.begin(57600);" to initialize at that baud rate
- "AT+HOSTEN0" to enable master/slave
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: snoopy20 on Oct 31, 2017, 10:19 pm
No, JDY-10 is much newer. You can find the chip by a Chinese company online but it's not well documented (surprise surprise).

I was sending end terminations to JDY-08 and that was giving the ERR. That's another plus for JDY-10. I've resolved that and some commands work. Most don't, for example;

AT+NAME => +ERR:1002

While

AT+VER => +JDY-08-V3.3843


My LE Scan on PC isn't finding it, AT+HOSTEN0 didn't return anything over UART. Probably it will be yet another fake/crap/POS destined to join the rest.

More JDY-10's on order, I could discover that one but could never make it send data.

Andrew
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: snoopy20 on Oct 31, 2017, 10:48 pm
Figured it, here's a better manual which shows which functions work in which mode.

To set it to slave use AT+HOSTEN3. AT+NAME etc now work.

It should now be discoverable I think... but it isn't.
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: snoopy20 on Nov 01, 2017, 01:37 am
Now it is, my laptop BLE card had an issue. I've connected and discovered several characteristics. At this point my knowledge falls short.

I assume given there's no official protocol that if I'm in "transparent" mode (is that still AT+HOSTEN3?) then writing a character will change one of these characteristics and another characteristic will act as a flag which the master will poll and then know when to pull a value. Is that right?

If so what's the best way of going about working it out, writing a char to UART and checking each one?


Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: androidfanboy on Nov 01, 2017, 02:33 am
I just used the HM-10 service and char UUID's:

service UUID: 0000ffe0-0000-1000-8000-00805f9b34fb
RX characteristic UUID: 0000ffe1-0000-1000-8000-00805f9b34fb
TX characteristic UUID: 0000ffe1-0000-1000-8000-00805f9b34fb
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: snoopy20 on Nov 01, 2017, 10:10 am
So the characteristic is set to NULL to indicate it's been read? How large is the RX/TX characteristic?
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: androidfanboy on Nov 01, 2017, 02:15 pm
I honestly don't know, I used an app to communicate.
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: snoopy20 on Nov 02, 2017, 11:25 am
Are you sure you used 0000ffe0-0000-1000-8000-00805f9b34fb?

I have this service but it has no characteristics.

I also have two others for Generic Access and Generic Attribute but as the name implies I believe these are Generic (one contains the device name for example).

Maybe 0000ffe0-0000-1000-8000-00805f9b34fb is correct but the characteristics are not exposed until the device is switched into pass-through...?

Andrew
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: androidfanboy on Nov 02, 2017, 02:24 pm
Yup I used "0000ffe0-0000-1000-8000-00805f9b34fb" for the service UUID and "0000ffe1-0000-1000-8000-00805f9b34fb" for both RX and TX characteristic UUID. I used "AT+HOSTEN0"
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: snoopy20 on Nov 07, 2017, 11:22 am
I've got JDY-10 wired up and commands are working. There are three services;

Code: [Select]

attr handle: 0x0001, end grp handle: 0x0007 uuid: 00001800-0000-1000-8000-00805f9b34fb
attr handle: 0x0008, end grp handle: 0x0010 uuid: 0000ffe0-0000-1000-8000-00805f9b34fb
attr handle: 0x0011, end grp handle: 0x001b uuid: 0000fee7-0000-1000-8000-00805f9b34fb


I read the characteristics from the second service which the manual says is the "transparent transmission service";

Code: [Select]

handle: 0x0009, char properties: 0x14, char value handle: 0x000a, uuid: 0000ffe1-0000-1000-8000-00805f9b34fb
handle: 0x000d, char properties: 0x14, char value handle: 0x000e, uuid: 0000ffe2-0000-1000-8000-00805f9b34fb



I assume these map to RX/TX. The manual says ffe1 is the "pass-through characterised ID"

Neither of this characteristics have any value.

Unlike JDY-08 there's no master/slave mode, so the question now is now to get data from UART in/out of these characteristics.

According to text regarding pin B0, the device enters transparent mode when a bluetooth connection is established, but can be overridden by this pin. Since I've left it floating I would expect the AT commands to cease operating upon connection, yet they don't.

Both these characteristics have a descriptor;

Code: [Select]

[A4:C1:38:77:28:E6][LE]> char-desc 0x0009 0x0009
handle: 0x0009, uuid: 00002803-0000-1000-8000-00805f9b34fb
[A4:C1:38:77:28:E6][LE]> char-desc 0x000d 0x000d
handle: 0x000d, uuid: 00002803-0000-1000-8000-00805f9b34fb
[A4:C1:38:77:28:E6][LE]> char-read-uuid 00002803-0000-1000-8000-00805f9b34fb
handle: 0x0002 value: 12 03 00 00 2a
handle: 0x0004 value: 02 05 00 01 2a
handle: 0x0006 value: 02 07 00 04 2a


Which I figure with the char-properties bitmask value 0x14 sets read/write/notification etc. Unsure at this point though.


If I attempt a write;


Code: [Select]

[A4:C1:38:77:28:E6][LE]> char-write-cmd 0x000e 0x01
[A4:C1:38:77:28:E6][LE]> char-read-hnd 0x000e
Characteristic value/descriptor:
[A4:C1:38:77:28:E6][LE]> char-write-cmd 0x000a 0x01
[A4:C1:38:77:28:E6][LE]> char-read-hnd 0x000a
Characteristic value/descriptor:



No value for either, nothing in UART.

Unsure where to head next.


Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: snoopy20 on Nov 07, 2017, 01:25 pm
Some progress, I found a Chinese app for the JDY-08 and the two UUID's of interest are;

00002902-0000-1000-8000-00805f9b34fb (notificiation)
0000ffe1-0000-1000-8000-00805f9b34fb (tx/rx - looks like half duplex?)


Setting notifications to "1" puts the device into transparent mode

Code: [Select]

[A4:C1:38:77:28:E6][LE]> char-read-uuid 00002902-0000-1000-8000-00805f9b34fb
handle: 0x000b value: 00 00
[A4:C1:38:77:28:E6][LE]> char-write-cmd 0x000b 01 00


Now UART text comes through;

Code: [Select]

Notification handle = 0x000a value: 41 54 2b 4e 41 4d 45 0d 0a
Notification handle = 0x000a value: 41 54 2b 4e 41 4d 45 0d 0a
Notification handle = 0x000a value: 41 54 2b 42 41 55 44 0d 0a
Notification handle = 0x000a value: 31 30 0d 0a
Notification handle = 0x000a value: 31 0d 0a



However checking 0000ffe1-0000-1000-8000-00805f9b34fb offers no value, so perhaps this is a FIFO buffer.

Anyhow, doing a write to this char pumps it through to UART;

Code: [Select]

[A4:C1:38:77:28:E6][LE]> char-write-req 0x000a 01105D3A
Characteristic value was written successfully


So mission complete.  :)  Use the DISC pin to force a disconnect, or for a pre-configure prior to allowing a connection to go through.
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: verge2050 on May 29, 2018, 01:55 pm
see this video
https://www.youtube.com/watch?v=6LFKlrigP7I
I have completed the communication between two jdy-08-ble modules.
for further information connect me on youtube. I will help you.
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: verge2050 on May 29, 2018, 02:07 pm
See this video
https://www.youtube.com/watch?v=6LFKlrigP7I (https://www.youtube.com/watch?v=6LFKlrigP7I)
Here you will see my project that I have completed the communication between two jdy-08-ble modules.
for any issue regarding to this module contact me on youtube via comment your problem in my video.
Verge2050.
Title: Re: JDY-08 Bluetooth LE Module - Datasheet, Fritzing part
Post by: donnelt on Jun 10, 2019, 07:46 am
Is here anyone who can provide me simple instruction or share your code, that allows to communicate with JDY-8 from remote linux system with BLE dongle?

What I want to achieve is just to set "0" or "1" to power off/on LED.

Thanks.
If you stick with genuine HM-10 and the Huamao software that exposes i/o pins, you can use digital i/o, ADC, and PWM directly on the module without any AT pass-through nonsense to another MCU.

I show here..

HM-10 BLE Android App using HM10 & AI2 only. NO ARDUINO (https://www.youtube.com/watch?v=PINCucGRhA8)