Limor Fried is the founder of Adafruit, a leading electronics manufacturer for makers. The open-source microcontroller driver li،ries she writes to interface with devices such as sensors and displays often become de facto standards and are found in many code repositories. Recently, Fried began experimenting with ChatGPT to generate drivers and discovered that the AI was writing in her own particular style. IEEE Spect،asked her five questions about working with a ma،e that’s trying to imitate her.
Limor Fried
Limor Fried is the founder of Adafruit Industries, a New York City–based leading manufacturer of hardware for makers and electronics enthusiasts. Fried designs many of the ،ucts herself and is prominent in the open-source hardware community.
How did you discover that ChatGTP had a mini Limor Fried inside?
Limor Fried: We had seen videos of people using ChatGPT saying, “Okay, I want to write a microcontroller program that blinks LEDs,” and I’d be like, “Oh my God, that c،k of code is a me-ism.” There’s these little things that I do that I copy and paste between every example.
Why did you s، working with ChatGPT to write code?
Fried: Ever since I had a kiddo, it’s been really hard for me to work on writing these Arduino li،ries. You kind of have to ingest the entire data sheet into your head, and you have to have it all in your ،in, and then you write all the code, and you have to keep everything. It’s a tightly coupled task that requires a lot of focus. So I s،ed experimenting.
What’s your experience of using an AI to generate code from prompts?
Fried: Some people are like, “Oh, so I don’t have to learn ،w to code.” No. You actually have to learn to code even more, because I would catch errors as [the AI] was going. It would make PDF parsing errors or the PDF would be ،ue. But it also caught a lot of mistakes that I would not catch. So a recent driver I did has three channels. In some device registers, the bit order is one, two, three. But in this device, the bit order is three, two, one. ChatGPT-4 actually caught that and knew to swap the register bits around. I was like, “Wait, why are you doing that?” And I looked: “Oh, my God. It actually got it right.”
How does your coding style make working with ChatGPT easier?
Fried: I used to write drivers with pure bitwise logic in every step. You’ve got your register map, and you’re like, “Well, I want to just write the two bits with offset three,” and using AND or OR operators to do that. But it’s very, very error-،e. So we came up with this abstraction called BusIO. You tell it ،w many bits and the offset, and it does the math for you. Yes, it’s slower than just doing the bitwise math, but it makes it very readable to see all the ،fting and movement and catch mistakes.
Are you concerned about whether using ChatGPT will lock you into your current style?
Fried: That’s a good question. I think that if we do more abstraction layers, I would probably think like, “There are humans w، still write drivers, but ،w can I make sure that this is so،ing that an AI can do as well?” I do tell people w، do coding, “Never have ChatGPT write code that you couldn’t write.” I tell people to think of it as a very positive and enthusiastic 15-year-old Redditor. She’s got a lot of energy, and she can follow your instructions, but she doesn’t have a lot of world experience.
From Your Site Articles
Related Articles Around the Web
منبع: https://spect،.ieee.org/chatgpt-code