Pgm->set_sck_period = usbasp_spi_set_sck_period Pgm->paged_write = usbasp_spi_paged_write Pgm->write_byte = avr_write_byte_default Pgm->program_enable = usbasp_spi_program_enable You can see that it's using libusb if on Linux. So that's how it works.Īnd from the avrdude source, this is the file which defines the how to communicate with my programmer, ( sorry I'm using usbasp ). So the AVR dude, with enough permissions, it can access it's endpoints and write and read from them. And there are libraries like libusb, winusb to access them in user mode, so in theory, you only need to study how to use a library like libusb. Any modern operating system exposes interface level functionality of USB stack to the user mode by API. Nowadays USB device drivers are written in ring3 instead of ring0. This is more belongs to stackoverflow and this is more related to the device drivers.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |