Wiz-IO / Arduino-Quectel-BC66

Arduino port for Quectel BC66 LTE Narow Band modules ( OpenCPU based )
46 stars 20 forks source link

BC66 Fails to wake up for flashing? #16

Closed spit4520 closed 4 years ago

spit4520 commented 4 years ago

Hello,

I found your platform last week and I am almost through the woods on all of the software and hardware up and running. This is the last major issue I have run into.

The device is currently attached to my system and connected over /dev/ttyUSB0 I have made all of the modifications to udev and restarted udev to allow for dialout access, but I still cannot connect. I have tried setting the board to both bc66 and bc66-te-b both built successfully, but neither elf's were able to be flashed.

Below is the debug trace. Let me know your throughts

`> Executing task: platformio run --target upload <

Processing bc66 (platform: quectel; board: bc66; framework: arduino)

Verbose mode can be enabled via -v, --verbose option <<<<<<<<<<<< QUECTEL BC66 MODULE 2018 Georgi Angelov >>>>>>>>>>>> CONFIGURATION: https://docs.platformio.org/page/boards/quectel/bc66.html PLATFORM: Quectel 2.0.14 > Quectel BC66 module HARDWARE: ARM, MT2625 78MHz, 97.66KB RAM, 195.31KB Flash DEBUG: Current (uart) On-board (uart) PACKAGES: framework-quectel fc4089a, toolchain-gccarmnoneeabi 1.70201.0 (7.2.1), tool-quectel b65e42d LDF: Library Dependency Finder -> http://bit.ly/configure-pio-ldf LDF Modes: Finder ~ chain, Compatibility ~ soft Found 8 compatible libraries Scanning dependencies... Dependency Graph |-- 2.7 |-- 1.0.0 Building in release mode ADD HEADER Checking size .pio/build/bc66/program.elf Advanced Memory Usage is available via "PlatformIO Home > Project Inspect" DATA: [ ] 3.7% (used 3657 bytes from 100000 bytes) PROGRAM: [ ] 0.9% (used 1716 bytes from 200000 bytes) Configuring upload protocol... Looking for upload port... Auto-detected: /dev/ttyUSB0 Uploading: program Waiting module for POWER-ON or RESET <=================== ERROR: Boot timeout *** [upload] Explicit exit, status 2 ============================================== [FAILED] Took 10.29 seconds ============================================== The terminal process terminated with exit code: 1

Terminal will be reused by tasks, press any key to close it.`

Wiz-IO commented 4 years ago

Driver... Look here, Olimex make for their board https://www.olimex.com/Products/IoT/NB-IoT/NB-IoT-DevKit/open-source-hardware

spit4520 commented 4 years ago

Got it working.

The drivers for Linux on the site listed are too old. Please see this link for up to date drivers

https://learn.sparkfun.com/tutorials/how-to-install-ch340-drivers/all#linux

I had to also hold the power-on and reset button at the same time to trigger a temporary interrupt, but it flashed afterword.

Is there any way to set the APN for the MQTT example? I am having issues now getting the device to connect to the network

Wiz-IO commented 4 years ago

Are you read BC66 documentation

https://github.com/Wiz-IO/platform-quectel/wiki/BOARD-Olimex-NB-IoT-DevKit#config-and-store-apn

Wiz-IO commented 4 years ago

After this module will connect auto to APN

spit4520 commented 4 years ago

I made the mistake of uploading a program before configuring. How do I restore the modem and manually write AT commands?

I am also on Linux/MacOS the flasher looks like it is only for Windows, do you have a version for Linux?

Wiz-IO commented 4 years ago

https://github.com/Wiz-IO/platform-quectel/wiki/Framework-OpenCPU#bc66-bc26-attention

spit4520 commented 4 years ago

I have borrowed a colleagues computer and loaded all of the drivers and reflashing software. I receive S_COM_PORT_OPEN_FAIL (1011) when I try to manually write over the physical address. I have already uploaded the restore application and experience this issue.

Best,

Scott

Wiz-IO commented 4 years ago

No idea ... contact with Quectel support

spit4520 commented 4 years ago

Is it possible to reenter the AT command interface through software? Where over a serial communication AT command can be directly written to the hardware? I have been unsuccessful in contacting the manufacturer. I have also been unable to use the flasher to restore the state of the device.

Please advise

Wiz-IO commented 4 years ago

there is two serials ( USB-COM) one is debug, other is AT(flasher) switch to other com

spit4520 commented 4 years ago

Where can I find the documentation on the jumper the change the usb mode? Sorry for all of the questions, I just get lost with the links from the 3 different repositories

Wiz-IO commented 4 years ago

what board

spit4520 commented 4 years ago

Olimex Nb-IoT-Dev Kit

https://www.olimex.com/Products/IoT/NB-IoT/NB-IoT-DevKit/open-source-hardware

This is the board I have

Wiz-IO commented 4 years ago

the usb create two com ports

Wiz-IO commented 4 years ago

and if module is OFF you need click power-on button if module is ON - click reset

in platformio uploader make this auto for this board ( if is selected Olimex NB-IoT-DevKit as board) https://github.com/Wiz-IO/platform-quectel/wiki/BOARD-Olimex-NB-IoT-DevKit

Wiz-IO commented 4 years ago

Untitled-1

spit4520 commented 4 years ago

In windows it may create two comm ports, but in Linux all I can see is /dev/ttyUSB0 as the default device. I know that Linux may not be your go to platform, but I would appreciate any help. I have installed the Kernel Module (driver) and I am only able to see /dev/ttyUSB0 for the standard serial interface not the AT interface. Is there a jumper on the board I can switch to force the standard USB to be used at the AT interface? I really look forward to using this board and your software stack for my project, thank you for your help

scott

spit4520 commented 4 years ago

Or is there a way to have the code running on the BC66 directly access the AT command interface? Maybe I could open a bi-directional serial tunnel to take commands from my laptop, process them on the BC66 and send them to the AT command interface? :)

Wiz-IO commented 4 years ago

for Linux driver - ask Olimex ... I only integrate their board ... I not have Unix machine to test I test compiler in VirtualBox for Unix-Like, but VirtualBox use Windows drivers ......

You can config module and from API as this script https://github.com/Wiz-IO/platform-quectel/wiki/Framework-OpenCPU#how-to-restore-bc66-at-command-interface

Ql_RIL_SendATCmd() send config for APN this commands https://github.com/Wiz-IO/platform-quectel/wiki/BOARD-Olimex-NB-IoT-DevKit#config-and-store-apn

then module will be ready

Wiz-IO commented 4 years ago

after Ql_RIL_Initialize(); Ql_RIL_SendATCmd( your commands

spit4520 commented 4 years ago

I will ask them, and I will post my findings here :) I wouldn't mind helping contribute to the Wiki for Linux/MacOs devices if that would be helpful to the community :)

Wiz-IO commented 4 years ago

Thanks - I can not make all alone....

DanKoloff commented 4 years ago

I see several issues were resolved in this issue thread. What is the current issue since I lost track?

One thing to notice is that CH340T has a single-channel serial-USB interface. No driver would make a second appear. The debug UART of NB-IoT-DevKit is routed to the extension header EXT1 (pin #5 and #6). They are 3.3V levels. You can attach serial debug cable to them (+ GND, of course).

Drivers for CH340T are well-known and included in most major OS releases. Yet, if these are missing by chance, you can download drivers from the SOFTWARE section of this product's page:

https://www.olimex.com/Products/Breadboarding/BB-CH340T/open-source-hardware