lairdcp / bl652-applications Goto Github PK
View Code? Open in Web Editor NEWLaird Connectivity BL652 smartBASIC applications
License: ISC License
Laird Connectivity BL652 smartBASIC applications
License: ISC License
Hello sir i am trying to receive spi data from stm32f103, but cannot find it working.
BL652 need to receive data from controller on the interrupt. I have found this interrupt in the guide but cannot find any example elaborating functionality of this interrupt (EVSPISLAVETXRX).
please help
Does anyone have experience upgrading the firmware on the BL652 using BL65xUartFwUpgrade.exe, running under a Linux/Wine environment? While trying to upgrade, as soon as I select the appropriate COM port, the upgrade utility crashes, with this error:
Exceptipon EInOutError in module
BL65xUartFwUpgrade.exe at 000150AB.
Device read error.
I've tried playing with permissions/owernship of /dev/ttyUSB0, wine registry settings, and a few other ideas, but can't seem to get around this. Any help would be much appreciated.
Hello,
this might not be the place to post this, but as there's no BL652 forum I'll post this here.
When following the quick start guide here:
https://www.lairdtech.com/bl652-quick-start
The
In the moduleLink app, the device is discovered, and once you click on it it get stuck at service discovery.
All it does is writting in the UwTerminalX:
======================== BLE Device connected =======================
Connection: Interval=48750us LinkTimeout=20000000us SlaveLatency=0
=====================================================================
# CCCD() Vcc, 0
# CCCD() Temperature, 0
# CCCD() Packet ID, 0
# CCCD() Rssi, 0
# CCCD() Buttons, 0
====================== BLE Device disconnected ======================
The service discovery eventually time out and pop-up the Alert:
Service Discovery Failed; Device may be unsupported! If trying to use OTA download, restart the app.
When using Xamarin and debbuging the ModuleLink app, I see that the GPIOs service is not instancing since it's never discovered.
So I guess the service is never created/activated in the SmartBasic.
EDIT:
So after some tests. I've tried another phone and it worked. Both phone are Galaxy s4 same model SGH-I337M.
Also tried with a galaxy S6 and it worked. I wonder what cause this issue...
Hi, My DVK-BL652 board has a firmware version of 28.6.2.0, which prevents me from compiling the code. So according to one of the answers, I need a firmware upgrade. but I cannot download anything from the software session of the product page. any thought?
Failed to compile -9; Application failed to compile
rc = BlePhySet(hConn, PhyTx, PhyRx, 0)
Compile Error: (0x0433) TOK_UNEXPECTED_TOKEN_IN_EXPR
File :
Line : 901
Source : rc = BlePhySet(hConn, PhyTx, PhyRx, 0)
: ---------^
Dear Community ,
I would like to understand the data rate that can be supported over the Laird BL 652 VSP service. I use the BL-652 as part of my product and have been using the VSP for a while now without any issues. We started out with a data rate of 300 bytes per second. Over time we are now at a data rate of 2800 bytes per second. I now see a lot of dropped bytes. I am still debugging this and have so far not been able to firmly concluded if the issue is on the BL 652 side or the receiver side.
Some items that have been checked are listed below
On the BL 652 side, the UART RX line is tapped out and forwarded to a windows laptop and read using serial. The data is fine. So I have confirmed that the BL 652 RX pin is indeed seeing the correct data.
I tried to receive the BLE data using PunchThrough LightBlue BLE app on android. Here is see only around 1200 to 1500 bytes of data per second. This log is generated by the Light Blue Android app.
On Windows i have used the below applications
https://github.com/sensboston/BLEConsole
https://github.com/noble/noble-device
Both these applications receive around 1000 odd bytes similar to the light blue. That's when i started to think if the issue is actually on the BL 652 side.
While I have yet to do a lot of debugging my query is just to understand the data rates that can be supported and if there have been similar observations with the vsp.
Thanks,
Abel.
Hello Sir
i am trying to read SPI slave data using example code (SpiSlaveRxBufferRead.sb) but when i read the buffer it is always empty and i get the message "No SPI slave data read".
I have successfully get the other example (SpiSlaveTxBufferWrite.sb) working where SPI slave transmits the data and master SPI receives it.
I am using an stm32f103 as SPI master. I am doing following steps, please let me know where i am making mistake.
Hello,
I keep receiving Config_Fail during the provisioning stage in the Mesh example.
Please help!
Hello everybody,
I try to do the following:
Four modules are to measure the pressure and the values should then be sent to a fifth module.
I try to write two codes. For the four modules I want to write a code as a client and for the one moduel the values receives a code as a server.
The code for the server is ready. Server and client connect but I can not get it that he receives the data. How can I do that the values arrive here?
The code for the clients is a bit harder.
On the board is a MS5803 pressure sensor on it, which should measure pressure.
I found an example code in the language C, which I am trying to rewrite in smartBASIC.
The CRC check, but I can not continue because I am constantly displayed errors.
These two problems have, it would be great if someone could help me or give me tips
In this document is the sample code for the pressure sensor in c:
MS5803.pdf
`//Client--CRC check
n_rem = 0x00
crc_read = sensorCoefficients[7] //save read CRC
sensorCoefficients[7] = ( 0xFF00 & ( sensorCoefficients[7] ) ) //CRC byte is replaced by 0
for count=0 to 16 //operation is performed on bytes
if ( count%2 == 1 ) n_rem ^= ( ( sensorCoefficients[count>>1] ) & 0x00FF ) //choose LSB or MSB
else n_rem ^= (sensorCoefficients[count>>1]>>8)
for (n_bit=8; n_bit>0; n_bit--)
if (n_rem&(0x800))
n_rem=(n_rem<<1) ^ 0x3000
else n_rem = (n_rem<<1)
n_rem = (0x00F & (n_rem >> 12))
sensorCoefficients[7] = crc_read`
`//SERVER--- receive value
FUNCTION HandlerCharVal(BYVAL hChar_written AS INTEGER, BYVAL offset, BYVAL len) AS INTEGER
// Characteristic handle that was returned when the characteristic was registered using the function
BleCharCommit()
PRINT "beispeiltext" // ----> error, is not displayed
DIM attr$
IF hChar_written == hChar THEN
rc = BleCharValueRead(hChar,attr$) //Read the value
print "\n written to service: ";attr$
IF ms_buffer_pos>=MEASUREMENT_BUFFER_SIZE THEN
//If Buffer full, than stop. Otherwise save the pressure and who send it
PRINT "\n buffer full, can't accept more measurements"
ELSE
//ToDo: have to split up the message into id and value!
ms_buffer_value[ms_buffer_pos]=STRVALDEC(attr$) //Save the pressure value
ms_buffer_id[ms_buffer_pos]=STRVALDEC(attr$) //Save who sent it
ms_buffer_pos=ms_buffer_pos+1
ENDIF
ENDIF
ENDFUNC 1`
// issue retracted //
Actually while receiving query from laird toolkit as an VSP communication,it only reads 14 characters and after 14 characters it consider it as a another msg....pls help me with it
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.