After posting this thread a year ago, viewtopic.php?f=117&t=57315&p=234819&hi … 21#p234819 , when I thought I had resolved my problems on my Mac, I was unable subsequently to upload code to either SAMD21 from either OSX Catalina or Raspberry Pi Linux, so I stopped working on that project.
I recently replaced that Mac with a new one (M2, Apple Silicon) with Ventura (13.4) installed, and I would really like to get back to working with the SAMD21. So I removed all traces (all that I could find) of Arduino on the new Mac, following removal instructions, and installed Arduino IDE 2.1.0.
I tried to compile & upload blink via USB to one of my SAMD’s, and it failed – there was no usbmodem port visible to the Arduino IDE.
I installed the CH341SER_MAC driver (v 1.5), rebooted, and tried again. There was one usbmodem port, which I selected with the SAMD21 board, and it compiled the code and uploaded successfully … then broke the connection and lost the usbmodem port. I rebooted the Mac and the driver reappeared as both a /dev/cu* device (seen by Arduino IDE) and as one of the USB devices listed by the Mac System Report. Uploaded again and it again broke the connection and deleted the driver.
I did a little more searching and found that there’s a newer driver (CH34xVCPDriver, v 1.8) that is supposed to work on Apple Silicon. Tried to install it, and the driver doesn’t even show up under /Library/Extensions, much less in the System Report.
Attempts to delete all the CH34* drivers to start again from scratch seem to be successful, but when I reboot, System Report shows that the Sparkfun SAMD21 is attached to a USB port … until I try to upload to usbmodem port again, after which it disappears again.
So I appear to have a phantom installation of something that blocks installation of the newer CH34x driver, and sorta works but disappears. The upload of the compiled code seems to complete, then the USB connection is dropped and the SAMD goes dark except for the red LED. But when powercycled, the new, just-downloaded code starts running. So uploads work, but then something kills the connection and deletes the driver.
If I plug an Arduino Uno into the same USB port to my Mac, the IDE sees it on port /dev/cu.usbmodem314401, so this problem seems to be with the SAMD21 USB interface.
Yes, I did the Command-R reboot during the driver install, went into Security Utility and enabled installation of Apple Developer extensions as a part of the first installation, and Privacy/Security settings shows that those extensions are enabled.
If you have successfully uploaded from OSX Ventura to a SAM21, could you tell me what you’re using for a driver and where I might find it?
And if you’re familiar with the details of the SAMD21 USB interface, could you tell me what driver I should be looking for? CH34x? I’ve seen FTDI mentioned in this context, too, but I’m not sure if that’s relevant. I’m not even sure if that’s a meaningful question, since I don’t (yet) understand the USB-serial uploading process.
Any suggestions for things to explore would be welcome. I’d really like to get back to working on the SAMD21.
Addendum:
Removed the CH341 install and rebooted; the usbmodem device reappeared. Compiled and uploaded sparfun’s blink.
Here’s the output from the compile and upload. After the upload, the port usbmodem port disappeared from the IDE, the SAMD21 is no longer listed as attached in the Mac System Report, and the SAMD21 sits there with the red light on. And this time, the upload apparently didn’t succeed since after a power cycle, the SAMD is not flashing the LED’s in sequence.
Sketch uses 10192 bytes (3%) of program storage space. Maximum is 262144 bytes.
Atmel SMART device 0x10010005 found
Device : ATSAMD21G18A
Chip ID : 10010005
Version : v2.0 [Arduino:XYZ] Sep 24 2018 14:26:24
Address : 8192
Pages : 3968
Page Size : 64 bytes
Total Size : 248KB
Planes : 1
Lock Regions : 16
Locked : none
Security : false
Boot Flash : true
BOD : true
BOR : true
Arduino : FAST_CHIP_ERASE
Arduino : FAST_MULTI_PAGE_WRITE
Arduino : CAN_CHECKSUM_MEMORY_BUFFER
Erase flash
done in 0.858 seconds
Write 10448 bytes to flash (164 pages)
[=========== ] 39% (64/164 pages)
[======================= ] 78% (128/164 pages)
[==============================] 100% (164/164 pages)
done in 0.068 seconds
Verify 10448 bytes of flash with checksum.
Verify successful
done in 0.009 seconds
CPU reset.