I see only port 1 as available with cmd “python3 -m serial” . Guide indicates that 5 ports should be available. What am I doing wrong? Thanks
Hello @jagdish, if you look a bit closer at the associated section in Getting Started, it states there are two Bristlemouth serial ports:
Steps 3 and 4 of that section of guide explain which port to connect to:
Would you be able to share a bit more information on what port you are seeing, whether or not it matches one of the labelled “Bristlemouth” ports on the screenshots shared above, and the previous steps you have taken in order to see that port?
Hi,
Thanks for getting back.
Here’s a screenshot -
Jagdishs-MBP:~ jagdishgirimaji$ python3 -m serial
— Available ports:
— 1: /dev/cu.Bluetooth-Incoming-Port ‘n/a’
— Enter port index or full name:
I do not see ports 2-5.
@jagdish, thanks for sharing.
It looks like you are not able to view the development kit using pyserial.
A few questions:
- Is the board supplied power as mentioned in step 2 of the Communicating with the Dev Kit over a USB serial connection section of the Getting Started guide? Have you seen the LED blinking Green after powering up the board?
- Is the development kit connected to the PC you are attempting talk with over serial with a USB-C cable?
- If answered yes to 2, have you tried another USB-C cable to rule out a faulty cable?
Hi Matthew,
Yes to 1 & 2. No to 3. I have ordered a few new USB C data cables, arriving today & will try that as soon as I get them.
Hi Matthew,
I got a new set of USB-C cables and tried with no luck. Running “python3 -m serial” shows port 1 available. Same as before.
Thanks,
Jagdish
@jagdish it looks like you are using a Mac.
Would you be able to check if you can see the device, and send a screenshot of the output, by running the command:
ls /dev/cu.*
This could helpfully rule out if it is a Mac issue or an issue with python.
Are you connecting the cable directly to you Mac or is there a hub in between? This could be a potential issue if so, try connecting it directly to your Mac.
Another troubleshooting step would be to attempt to see the device on another computer if available:
- The following is a good guide to check if you can see a serial device on Windows.
- If you have access to a Linux machine, I would attempt to follow the getting started guide again and see if it works on that platform
Thanks for your guidance. I was able to resolve the issue. I now have the following -
— Available ports:
— 1: /dev/cu.Bluetooth-Incoming-Port ‘n/a’
— 2: /dev/cu.usbmodem0000078EB72E1 ‘Bristlemouth’
— 3: /dev/cu.usbmodem0000078EB72E3 ‘Bristlemouth’
— Enter port index or full name: 2
— Miniterm on /dev/cu.usbmodem0000078EB72E1 9600,8,N,1 —
— Quit: Ctrl+] | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H —
hum_temp | tick: 294188, rtc: 0, hum: 38.582932, temp: 22.717409
pressure | tick: 294199, rtc: 0, temp: 22.713987, pressure: 1007.625122
power | tick: 294206, rtc: 0, addr: 67, voltage: 0.001600, current: -0.000250
power | tick: 294208, rtc: 0, addr: 65, voltage: 23.731199, current: -0.000250
hum_temp | tick: 296188, rtc: 0, hum: 38.610573, temp: 22.714920
pressure | tick: 296199, rtc: 0, temp: 22.708075, pressure: 1007.632324
I will now move to section 2 & get back if I run into any issues. Thanks a lot.
Can you pls point me to docs, videos you may have to understand the technology, especially 2 wire communication.
Jagdish
Sure thing!
Here is the page for the spec on Bristlemouth.
Click the download link to obtain the full document.
When I run ‘bm topo’ I get the following error -
Jagdishs-MBP:~ jagdishgirimaji$ bm topo
-bash: bm: command not found
How do I proceed?
Some more context.
I was able to run ‘python3 -m serial’ and get telemetry data continuously. Then I stopped using CTRL] & then ran ‘bm topo’ which returned the error msg ‘command not found’
You need to run the specified commands while in the serial terminal. So the steps in your case would be:
- Run
python -m serial
and connect to the device - Send the command
bm topo
Do not exit the serial terminal with ctrl + ]
if you wish to send commands to the device.
the telemetry data does not stop, not sure how to pause. I have tried to run ‘bm topo’ but the screen keeps updating with pressure, temp data.
how do i stop the serial sensor readings to continuously stream on the terminal and get the >
prompt to run the commands. As you can see I pasted bm topo (highlighted below) and was able to get the right response but telemetry data is streaming.
Jagdishs-MBP:~ jagdishgirimaji$ python3 -m serial.tools.miniterm /dev/cu.usbmodem0000078EB72E1 9600
— Miniterm on /dev/cu.usbmodem0000078EB72E1 9600,8,N,1 —
— Quit: Ctrl+] | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H —
hum_temp | tick: 32210188, rtc: 2024-12-19T00:34:38.000, hum: 42.945400, temp: 21.416050
pressure | tick: 32210199, rtc: 2024-12-19T00:34:38.011, temp: 21.411383, pressure: 1003.869080
power | tick: 32210206, rtc: 2024-12-19T00:34:38.019, addr: 67, voltage: 0.001600, current: -0.000250
power | tick: 32210208, rtc: 2024-12-19T00:34:38.019, addr: 65, voltage: 23.939199, current: -0.000250
hum_temp | tick: 32212188, rtc: 2024-12-19T00:34:40.000, hum: 43.027935, temp: 21.413561
pressure | tick: 32212199, rtc: 2024-12-19T00:34:40.011, temp: 21.412004, pressure: 1003.858154
power | tick: 32212206, rtc: 2024-12-19T00:34:40.019, addr: 67, voltage: 0.001600, current: -0.000250
power | tick: 32212208, rtc: 2024-12-19T00:34:40.019, addr: 65, voltage: 23.939199, current: -0.000250
bm topo
(root)05dde5d0078eb72e:1 | 1:e3ceca5d38a2dda9
Set RTC to 2024-12-19T00:34:42.875
hum_temp | tick: 32214188, rtc: 2024-12-19T00:34:42.003, hum: 42.939789, temp: 21.405781
pressure | tick: 32214199, rtc: 2024-12-19T00:34:42.011, temp: 21.406094, pressure: 1003.856873
power | tick: 32214206, rtc: 2024-12-19T00:34:42.019, addr: 67, voltage: 0.001600, current: -0.000250
power | tick: 32214208, rtc: 2024-12-19T00:34:42.023, addr: 65, voltage: 23.939199, current: 0.000000
hum_temp | tick: 32216188, rtc: 2024-12-19T00:34:44.003, hum: 43.220551, temp: 21.405470
pressure | tick: 32216199, rtc: 2024-12-19T00:34:44.011, temp: 21.412628, pressure: 1003.862549
power | tick: 32216206, rtc: 2024-12-19T00:34:44.019, addr: 67, voltage: 0.001600, current: -0.000250
power | tick: 32216208, rtc: 2024-12-19T00:34:44.023, addr: 65, voltage: 23.939199, current: -0.000250
— exit —
Jagdishs-MBP:~ jagdishgirimaji$
@jagdish the console print statements are constantly streaming as of current and will not stop. The keystrokes you enter in to the console are read and interpreted.
Thanks. I have got past that hurdle.
Now I am directly connected to Spotter & running ‘python3 -m serial’ returns the following -
Jagdishs-MBP:~ jagdishgirimaji$ python3 -m serial
— Available ports:
— 1: /dev/cu.Bluetooth-Incoming-Port ‘n/a’
— 2: /dev/cu.usbmodemSPOT_32074C1 ‘Spotter’
— Enter port index or full name:
The guide says I should be seeing a longer list of possible ports. Why am I not?
If you are attempting to connect to spotter, the only port you need be concerned with is port 2 here labeled Spotter
.
Hi Matthew,
I have made quite a bit of progress and am in section 5, part 2b.
The issue I am facing now is I am not able to update FW to SD card. I have successfully compiled the code and copied the …elf.bin file to the root directory in SD card and after re-inserting and running it keeps executing from the previous build hence I cannot chk the changes.
I want to stay with updating FW via SD card.
Thanks,
Jagdish
Hello @jagdish,
To flash the dev kit through the spotter’s SD card I recommend taking a look at the following guide.
Note that the file from the build directory you want to flash ends with .elf.dfu.bin
.
Can you please walk me through the steps done to try and flash the dev kit with an SD card?
I have tried flashing .elf.dfu.bin and dbg.elf.bin and neither have worked.
In guide 3, under “Updating the Dev kit Firmware” it says use .elf.dfu.bin. But in guide 5 section 01, it asks to use .elf.dfu.bin.
This is the process I used:
- Made changes to code in visual studio. Saved changes made.
- Compiled using ‘make -j’ cmd & got 100% Built
- Ejected SD card from Spotter
- Inserted SD card into laptop & copied .elf.dfu.bin to root directory on SD card
- Safely ejected SD card from laptop and inserted into Spotter
- Spotter reboots
- On Dev Kit serial port ran "python3 -m serial’ to see results. This is where it seems to be executing the last code