Traducido del English por IA ·
La pregunta de Daniel es el primer paso correcto. En macOS no hace falta controlador: avrdude se comunica con el USBasp a través de libusb, que Homebrew instala junto con él. Si Información del sistema > USB no muestra «USBasp» en absoluto, el problema está en el adaptador, no en avrdude. Me pasó exactamente esto con dos adaptadores USB-C baratos en nuestra planta: el USBasp es un dispositivo USB de baja velocidad cuyo firmware implementa USB por software (bit-banging), y algunos adaptadores y hubs USB-C no lo enumeran de forma fiable. Un hub USB-A con alimentación entre el adaptador y el USBasp lo solucionó, y también otro adaptador (de Apple).Una vez encontrado, el siguiente error que probablemente verá en chips nuevos es este:
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: error: program enable: target does not answer (0x01)
Un 328P nuevo funciona a 1 MHz con el oscilador interno, y el reloj ISP por defecto es demasiado rápido para él. Reduzca la velocidad:
avrdude -c usbasp -p m328p -B 32 -U lfuse:w:0xFF:m -U hfuse:w:0xDE:m -U efuse:w:0xFD:m
avrdude -c usbasp -p m328p -B 4 -U flash:w:rs485node.hex:i
(esos fusibles son para un cristal externo de 16 MHz; compruebe el suyo antes de escribirlos). La advertencia «cannot set sck period» la provoca el firmware antiguo del USBasp y es inofensiva mientras funcione -B; en versiones antiguas, el jumper de reloj lento hace lo mismo.
Daniel’s question is the right first step. No driver is needed on macOS, avrdude talks to the USBasp through libusb, which Homebrew installs with it. If System Information > USB doesn’t list «USBasp» at all, it’s the adapter, not avrdude. I had exactly this with two cheap USB-C adapters at our plant: the USBasp is a low-speed USB device with the firmware bit-banging USB, and some USB-C adapters and hubs don’t enumerate those reliably. A powered USB-A hub between the adapter and the USBasp fixed it for me, so did a different (Apple) adapter.
Once it’s found, the next error you’ll probably meet on fresh chips is this:
avrdude: warning: cannot set sck period. please check for usbasp firmware update.
avrdude: error: program enable: target does not answer (0x01)
A new 328P runs at 1 MHz from the internal oscillator, and the default ISP clock is too fast for it. Slow it down:
avrdude -c usbasp -p m328p -B 32 -U lfuse:w:0xFF:m -U hfuse:w:0xDE:m -U efuse:w:0xFD:m
avrdude -c usbasp -p m328p -B 4 -U flash:w:rs485node.hex:i
(those fuses are for an external 16 MHz crystal, check yours before you write them). The «cannot set sck period» warning is the old USBasp firmware talking, harmless as long as -B works; on older ones the slow-clock jumper does the same.

