I have a Particle Photon which I'm trying to setup. I've tried flashing code both from the web IDE, and locally and it always times out. The device is connecting as it can be seen in these pictures:
The web IDE does not give me much information. It only says "Request Timed Out". This is what I get when I try to flash an .ino code
MacBook-Pro:Desktop User$ particle flash ABCDEFGH123456789 sketch_jun09a/
Including:
sketch_jun09a/sketch_jun09a.ino
attempting to flash firmware to your device ABCDEFGH123456789
Flash device failed.
Request Timed Out
And when I try to flash a firmware.bin file this is what I get:
MacBook-Pro:Downloads Usesr$ particle flash --usb firmware.bin
Found DFU device 2b04:d006
spawning dfu-util -d 2b04:d006 -a 0 -i 0 -s 0x080A0000:leave -D firmware.bin
dfu-util 0.9
Copyright 2005-2009 Weston Schmidt, Harald Welte and OpenMoko Inc.
Copyright 2010-2016 Tormod Volden and Stefan Schmidt
This program is Free Software and has ABSOLUTELY NO WARRANTY
Please report bugs to http://sourceforge.net/p/dfu-util/tickets/
dfu-util: Invalid DFU suffix signature
dfu-util: A valid DFU suffix will be required in a future dfu-util release!!!
Opening DFU capable USB device...
ID 2b04:d006
Run-time device DFU version 011a
Claiming USB DFU Interface...
Setting Alternate Setting #0 ...
Determining device status: state = dfuIDLE, status = 0
dfuIDLE, continuing
DFU mode device DFU version 011a
Device returned transfer size 4096
DfuSe interface name: "Internal Flash "
Downloading to address = 0x080a0000, size = 5224
Download [=========================] 100% 5224 bytes
Download done.
File downloaded successfully
dfu-util: Error during download get_status
Error writing firmware...dfu-util: Invalid DFU suffix signature
dfu-util: A valid DFU suffix will be required in a future dfu-util release!!!
dfu-util: Error during download get_status
I've seen online that the firmware.bin file seems to be compiled for the Particle Core, and not the Photon, so the device does not allow the code to be flashed. How should I compile the code for it to work? Is there any other solution to this problem? Thank you in advance.
You won't be able to flash a Core firmware to a Photon (they have different architecture and firmware layout). To compile the code for photon you can also use the CLI:
$ particle compile photon sketch_jun09a/
the resulting binary can be flashed using the CLI the same way you did.
To figure out the failed over the air flash I would recommend contacting the support.
Related
I am trying to Interface a BLE module based on Nordic's nrf52840 to a Yocto based SBC, to which all the BlueZ related packages have been added.
I have flashed Zephyr's sample hci_uart program onto the module. The module seems to run perfectly on my Linux PC (BlueZ version 5.48), whereas on the SBC(BlueZ version 5.54) it fails to get inited. Here's the error that comes when I use
root#rb-imx6:~# hciconfig hci0 up
root#rb-imx6:~# Can't init device hci0: Cannot assign requested address (99)
Can anyone please help me out on this?
Thanks in advance.
The error of assigning an address is caused by missing Linux kernel configuration options:
CONFIG_CRYPTO_USER
CONFIG_CRYPTO_USER_API
CONFIG_CRYPTO_USER_API_AEAD
CONFIG_CRYPTO_USER_API_HASH
CONFIG_CRYPTO_AES
CONFIG_CRYPTO_CCM
CONFIG_CRYPTO_AEAD
CONFIG_CRYPTO_CMAC
This is likely to happen with a self-built Buildroot or Yocto Embedded Linux system. If you run into this error, you should enable above options and recompile the kernel.
See the BlueZ requirements here: https://git.kernel.org/pub/scm/bluetooth/bluez.git/tree/README#n64
To see detailed debug output from BlueZ, run it with -d option:
bluetoothd -d
I am having some issues with the Send Data with Sound Project on Arduino. I have my Arduino nano BLE sense, ChirpSDK by Asio Ltd Version 3.4.0 installed, I put in the CHIRP_APP_KEY, CHIRP_APP_SECRET, CHIRP_APP_CONFIG from the chirp website, and I also have the Arduino nano BLE board selected when uploading the code. But for some reason I keep getting this error below:
ChirpColor:22:10: error: chirp_connect.h: No such file or directory
#include "chirp_connect.h"
^~~~~~~~~~~~~~~~~
compilation terminated.
exit status 1
chirp_connect.h: No such file or directory
Any help would be very much appreciated, thanks.
The SDK functions have been renamed in the latest release. So connect is replaced with sdk.
With the latest version, you need to
#include "chirp_sdk.h"
See the latest header file for the function declarations - https://github.com/chirp/chirp-arduino/blob/develop/src/chirp_sdk.h
I used to programing my uCu before but now I have very weird error. It seems to be problem with programmer but I'm not sure. Avrdude throws this error:
C:\Users\Adam>avrdude -p m328p -c avrispmkII
avrdude: ser_open(): can't open device "\.\com1": The system cannot find the file specified.
and atmel studio this
Failed to enter programming mode. ispEnterProgMode: Error status received: Got 0xc0, expected 0x00 (Command has failed to execute on the tool)
Unable to enter programming mode. Verify device selection, interface settings, target power, security bit, and connections to the target device
I have tried use different ports but it didn't help. Device Menager said I already have good driver. Please help me find the solution.
This is a picture of my circuit
I'm having a pretty annoying issue. When I try to silent install a program, that program depends on the WIA or TWAIN driver (for scanners) NOT being "in use". The problem is that driver can be "in use" even after the scanner is unplugged from the computer (if it was plugged in before, the driver is used and doesn't stop being in use after unplugging)
My question is, to your knowledge, what controls this WIA / TWAIN driver? Is it a service I can force close or a process?
I have found these 2 services for WIA :
stisvc
WiaRpc
but nothing regarding TWAIN.
My goal would be to add that force close in the installation script so it makes SURE that WIA or TWAIN cannot be in use whatsoever before installing.
I found the solution, might be useful for any other people having problems with these drivers. First download ListDlls by SysInternals : https://learn.microsoft.com/en-us/sysinternals/downloads/listdlls
Then with PowerShell:
Stop-Service -Name stisvc -Force
[string]$twain_utilise = C:\TEMP\Listdlls.exe -d TwainDSM.dll | select-string "pid"
if ($twain_utilise) {
$processus = ($twain_utilise -Split(": "))[1]
}
Stop-Process -id $processus -Force
Explanation :
-Stop the service STISVC which is in charge of WIA (Windows Image Acquisition (WIA))
-Run ListDlls.exe on TWAINDSM.DLL to find out what is using the dll by selecting the PID of found program.
-IF the command was successful (in other terms, if the PID was found, meaning a program IS using that DLL), split the content so you can isolate the PID number only.
-Stop the process with it's PID so TWAIN isn't in use anymore
You now have stopped any use of WIA or TWAIN and can proceed to install drivers or software that require these drivers not to be in use! Cheers.
I am using the excellent http://platformio.org/ together with Visual Studio Code to develop for Teensy 3.6 (an Arduino compatible board).
This works great. But I wanted to do better debugging via SWD (serial wire debug).
So I disconnected the Arduino-compatible USB-chip and connected via SWD and JLINK instead. Similar to this: https://mcuoneclipse.com/2017/04/29/modifying-the-teensy-3-5-and-3-6-for-arm-swd-debugging/
I can flash firmware that I built via platformio using the "J-Link Lite" software just fine. Also I can run the J-Link GDB Server without a problem.
But I can't get the IDE integration to work.
My platformio.ini looks like this:
[env:teensy36]
platform = teensy
board = teensy36
framework = arduino
upload_protocol = jlink
debug_tool = jlink
Still the upload_protocol is ignored and when I invoke upload (platformio.exe run --target upload) via the IDE all I get is
Linking .pioenvs\teensy36\firmware.elf
Checking program size
text data bss dec hex filename
17348 172 2696 20216 4ef8 .pioenvs\teensy36\firmware.elf
Building .pioenvs\teensy36\firmware.hex
Uploading .pioenvs\teensy36\firmware.hex
Teensy Loader, Command Line, Version 2.1
Read ".pioenvs\teensy36\firmware.hex": 17520 bytes, 1.7% usage
Soft reboot is not implemented for Win32
Waiting for Teensy device...
(hint: press the reset button)
So it's still trying to upload via Arduino compatible USB connection instead of via SWD connection. How can I get platformio to change the upload method or upload_protocol?
From Project Configuration File platformio.ini, it provides an example of how to configure Jlink GDB server:
[env:bluepill_f103c8]
...
; Debug options
debug_tool = custom
debug_server =
JLinkGDBServer
-singlerun
-if
SWD
-select
USB
-port
2331
-device
STM32F103C8
If JLinkGDBServer.exe is not included in PATH, then you need to specify the full file name of JLinkGDBServer.exe.
I have tried this, it works.
There is another example of using JlinkGDBServerCL.exe - J-Link and ST Nucleo.